WebSocket (WS) Gateway.
Rather simple pub/sub gateway that bridges UDP and WebSockets (WS). Producers share data through a UDP/WS connection, it only supports JSON data. Clients request data through a ws/upd connection.
It has been used to showcase small IoT scenarios in school demonstrations.
Most of my code requires a library named utils. This library is no exception, it also requires Jetty libraries (from WS support). Currently, it requires Java 8. In the future, the code will be converted to Java 10 and the Jetty requirement may/will be dropped.
The whole project was done in Maven, as such to package the application just run:
mvn package
To execute the application just run:
java -Djava.util.logging.config.file=logging.properties -jar target/wsgw-1.0.jar wsgw.properties
or (without the suggested logger configuration)
java -jar target/wsgw-1.0.jar wsgw.properties
A simple unit configuration file to start the WSGW in Linux systems is provided here. Update the paths in the file and add the unit to your system.
We provide some samples and examples. Several Arduino sketches, web pages and a systemd service can be found here.
This project is licensed under the MIT License - see the LICENSE.md file for details.