Do we have a J script/class to handle Server-Sent Events (SSE), i.e. requests from a EventSource class in js? That class is the client side of a Subscribe/Publish model using the browser.

  It appears we do not.

The websocket.ijs script is for the WebSockets transport layer, a full-duplex protocol. AFAICT the script is oriented towards implementing a J server to handle requests from the client.

What I need is a way for the server to push info (state, alarm, exception) to the client. In this day of IOT, isn't it a common need?

The websocket script is not easy to follow. Would it be possible to modify it (or make a derivative) to make a server push model? Probably. I used Demo 2 and modified it in the normal way, but my attempts at server pushes revealed that the script is not designed for that (I think).

  Implementing a SSE class would be ideal.

  The wiki has a page for library requests. It is empty!

  Any suggestion?

~ Gilles
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to