Page 1 of 1

Break Message Handling

Posted: Mon Dec 30, 2013 12:23 pm
by emhill
We have pushed PUI out to 5 of our client sites now and one of the main questions that keeps popping up is "why do I not get my break messages like I did on the green screen?" We have changed some of the automatic messaging to use email but was wondering if anyone here was doing anything to handle break messages. I have read a couple of past posts but was just throwing this out there to see if anyone has had a recent brainstorm.

Thanks!!!!

Re: Break Message Handling

Posted: Mon Dec 30, 2013 1:09 pm
by David
The reason why break messages don't show up immediately is due to a limitation in HTTP communication. In Telnet 5250, the server can 'push' an update to the client screen at anytime. In HTTP, the server cannot 'push' to the client. The client has to initiate the process by requesting a page. This is why when the user has the screen in the browser, break messages do not show up right away.

Unfortunately, there is nothing that can be done about this, so long as Profound UI / Genie are using standard HTTP communication. This may change someday with things like Web Sockets that allow the server to push to the client, but as of now the technology is not quite 'there' yet.

Using email is the easiest solution, it gets more complicated if you want to pop something up on the screen right away, although that is possible. To do that, you'd need to have code running in the browser (JavaScript) periodically make a request to a server program (like a CGI program or PHP script) that checks for 'messages'. The 'messages' could be actual messages from an IBM i message queue, or maybe they are simply entries in a database file. If the server program reports that there are messages to display, the script could display a message on the screen that lets the user know to check their messages, or maybe it displays the message right then and there.

Re: Break Message Handling

Posted: Mon Dec 30, 2013 3:45 pm
by emhill
Thanks David. We just didn't want to have to reinvent the wheel if someone had already done something similar. We have a couple of ideas and if/when we get something going I will be sure to post what we did.

Thanks for the quick reply!!!!!

Re: Break Message Handling

Posted: Mon Dec 30, 2013 3:49 pm
by Scott Klement
Imagine if HTTP could push to the client... just imagine what the web would be like!

Every site that wanted to pop-up an ad in your browser could do so immediately when you opened your browser. No need to wait until you visit their site -- the server could initiate it, just connect to your browser and pop-up an ad! That would be a nightmare, for sure.

Would be nice for break messages, though :-)