« Return to Thread: Is there a Perpetual Listener or Server Push concept?

Re: Is there a Perpetual Listener or Server Push concept?

by Gene Amtower :: Rate this Message:

Reply to Author | View in Thread

Jim/Deech,

I'm wondering what this is going to look like on the server end, and if Apache or whatever web server is being called will consider this a hung server thread and close it?  If one has control over the server end, that might be configurable, but otherwise it might be hit or miss.  Besides the web server, I think PHP has a time limit for responses as well, but you didn't say what environment you're using on the server.  I remember having an old Apache 1.0 server drive itself into oblivion from hung server processes many years ago.  Each connection process consumes server memory, and too many open connections may cause the server behavior to become erratic or non-responsive.  If you have too many clients running the application at one time, this could be a significant concern for scalability of the app.

Deech, does it have to be real-time, as in immediate, instead of waiting for an update request communication to happen periodically (every few seconds)?  Do you have complete control over the configuration of the server in this case?  Are there other sites or applications running on the same server instance?  How often do you expect communications from the server to occur?  When you do get a response from the server, will communications come in bursts or singly? 

>From your question, it sounds like you're concerned about the time between one response and the time required to setup the next request.  Another idea might be to have two requests queued up at any given time, and initiate a new replacement when one of them gets a response.

Streaming media probably has a similar use case, but it keeps the connection alive through continuous data transfer or repeated requests - I'm not sure which.  I haven't implemented any streaming media applications, but it's functionality seems similar to your requirement.  Maybe there's a clue in how that type of application is implemented.

HTH,

   Gene

On Thu, 2009-06-25 at 21:18 -0700, Jim Hunter wrote:
If I was going to do this, I would set the timeout of the qooxdoo request object to something very high, then on the server side when you get the request from the client, don't respond until you heve something to send to the client. Then once that request is complete simply do it again.

Jim

On Thu, Jun 25, 2009 at 2:42 PM, aditya siram <aditya.siram@...> wrote:
Hi all,
I would like to set up continuous communication channel with the server. Right now I am trying to model this by having a button automatically requery the server with a dummy variable once it's request has been completed.

However because the Request object is 'dispose()'ed after a 'completed' event, there is a latency between the end of this request and the beginning of the next.

Is there a better way of doing this? If not is there some way for the server to push changes to the client?

-deech


------------------------------------------------------------------------------

_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel


------------------------------------------------------------------------------
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

------------------------------------------------------------------------------

_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

 « Return to Thread: Is there a Perpetual Listener or Server Push concept?