What system does the web app use to update data in real time on a page?
WebSocket, Java Script and DOM (Document Object Model)?
I would like to know which system (protocol) Xojo uses to update the values on a web page. In my test program, the web page has a timer that reads an app variable and updates a textbox every second.
I noticed that, despite sending only a few bytes of data, the messages exchanged with the server were at least 900 bytes in size.
Is this normal?
Is there a way to limit data usage?
The framework uses WebSockets to communicate. These packets are composed of JSON which contains instructions, either contextually to update an object, or to execute contained JavaScript. This JavaScript may, obviously, make changes to the DOM.
You can inspect Xojo’s framework JS file when running a web app to get more information about how the framework operates, or inspect the packets themselves using the browser’s developer tools to see what they contain.
You cannot really limit the amount of data transmitted by the framework unless you wish to use the WebSDK to build out your own components and communication methodologies, but at that point you should probably be using a different tool if you find yourself doing quite a lot of that.