The user interfaces (ui-flex, ui-client-hud, ui-client-menu, ui-console) need to get informed about changes on the Inexor Tree. The general problem is that a node, a sub tree or even the complete tree has to be pulled (even if there aren't any changes). Using websockets changes on the tree can be transferred without delay and is limited to the changed node only. This way we have way less overhead and faster response times.
Goal
Send changes on the Inexor Tree via websockets to client side (e.g. user interfaces)
Content of a node has changed (Inexor Tree event postSet)
A new node has been added (Inexor Tree event add)
Store a copy of the Inexor Tree on client side (e.g. user interfaces)
Note: This is the most usable way until there is real support for GRPC clients on browser side which connects directly to Inexor Core (C++).
[x] Inexor Flex: Listen on tree node changes and push via websocket
[x] postSet
[x] add
[x] Inexor UI Client HUD
[x] Integrate webpack
[x] Integrate Inexor Tree on browser side
[x] Receive tree node changes and update the local Inexor Tree
[x] postSet
[x] add
Using the websockets
var exampleSocket = new WebSocket("ws://localhost:31416/api/v1/ws/tree", "protocolOne");
exampleSocket.onmessage = function (event) {
let response = event.data;
console.log(response);
};
The user interfaces (
ui-flex
,ui-client-hud
,ui-client-menu
,ui-console
) need to get informed about changes on the Inexor Tree. The general problem is that a node, a sub tree or even the complete tree has to be pulled (even if there aren't any changes). Using websockets changes on the tree can be transferred without delay and is limited to the changed node only. This way we have way less overhead and faster response times.Goal
postSet
)add
)Note: This is the most usable way until there is real support for GRPC clients on browser side which connects directly to Inexor Core (C++).
Tasks
Inexor Flex
: Integrate express websocketInexor Flex
: Listen on tree node changes and push via websocketpostSet
add
Inexor UI Client HUD
Inexor Tree
on browser sidepostSet
add
Using the websockets
Output
See also
These technologies also try to bring GRPC support to the web browser.