Skip to main content



      Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Server Push
Server Push [message #92103] Fri, 06 June 2008 06:03 Go to next message
Eclipse UserFriend
Originally posted by: jonas.bruestel.net

Hi,

I have a technical question. I'm planning to impl. a monitor application.
The server is supposed to push messages to the client. I know that it's
possible to use server-pushs in RAP. How does it technically work? Through
a polling mechanism?

Thanks,
Jonas
Re: Server Push [message #92118 is a reply to message #92103] Fri, 06 June 2008 06:20 Go to previous messageGo to next message
Eclipse UserFriend
Hi Jonas,

Jonas Brüstel schrieb:
> I have a technical question. I'm planning to impl. a monitor
> application. The server is supposed to push messages to the client. I
> know that it's possible to use server-pushs in RAP. How does it
> technically work? Through a polling mechanism?

That's quite simple:
The client connects to the server (via Ajax).
The server keeps the Ajax connection open until there's something to
send to the client (e.g. an UI update).
As soon as the server sent a response and the HTTP connection closed,
the client reconnects immediately to the server again.

See UICallBack for more information. Also Firebug for Firefox is a great
Add-on to see this mechanism live.

Bye - Reinhold.
Re: Server Push [message #92131 is a reply to message #92103] Fri, 06 June 2008 06:28 Go to previous messageGo to next message
Eclipse UserFriend
AFAIK, it uses a delayed answer mechanism, which simulates a push. Its not
an actual push, since it would create intense firewall problems. But it
creates a http request which is not directly answered, but answered when an
informaiton arrives. As soon as the request times out it will be renewed.
So in terms of speed it is like a push however there might be circumstances
in which the connection is closed without the browser noticing it where a
longer delay (until the next timeout) may happen. But I'm not sure of it.
Can anyone approve?

Greetings,
Torge.


"Jonas "Brüstel"" <jonas@bruestel.net> schrieb im Newsbeitrag
news:b1dde1f7a4f41763a7d082582fe1d2a5$1@www.eclipse.org...
> Hi,
>
> I have a technical question. I'm planning to impl. a monitor application.
> The server is supposed to push messages to the client. I know that it's
> possible to use server-pushs in RAP. How does it technically work? Through
> a polling mechanism?
>
> Thanks,
> Jonas
>
Re: Server Push [message #93479 is a reply to message #92118] Sat, 14 June 2008 13:59 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: jonas.bruestel.net

Hi,

I analyzed this mechanism and created a sequence diagram for a better
understanding. Could you take a look at my diagram?
It's located at http://zeus.fh-brandenburg.de/~bruestel/longpolling.png

Diagram description:
1. enable long polling by calling UICallback.activate() method
2. normal request by client (for example button click)
3. response by server, includes command to start polling
4. long polling request by client, client is waiting for answer
5. new event occurred (for example new mail message)
6. response to long polling request. response includes command to start
gui update request and to start new long polling request
7. and 8. update gui
9. new long polling request, and the game starts all over again


I tried this mechanism through a proxy. After about 2 minutes the proxy
server killed the long polling connection. Is there a way to define a
maximum for an open connection?

Thanks for your effort.


Greetings,
JB
Re: Server Push [message #93590 is a reply to message #93479] Mon, 16 June 2008 04:57 Go to previous message
Eclipse UserFriend
Originally posted by: fappel.innoopract.com

Hi,

I think the proxy timeout depends on the proxy's configuration. From my
current point of view I don't know if there's much we can do about this.
But we must investigate this more properly to come to a final
conclusion. Note that the timeout only comes into play if there's no
UI-Update from the serverside within those 2 minutes. So maybe it would
be a solution to initiate some 'unnecessary' updates from time to
time...



Ciao
Frank

-----Ursprüngliche Nachricht-----
Von: Jonas "Brüstel" [mailto:jonas@bruestel.net]
Bereitgestellt: Samstag, 14. Juni 2008 19:59
Bereitgestellt in: eclipse.technology.rap
Unterhaltung: Server Push
Betreff: Re: Server Push

Hi,

I analyzed this mechanism and created a sequence diagram for a better
understanding. Could you take a look at my diagram?
It's located at http://zeus.fh-brandenburg.de/~bruestel/longpolling.png

Diagram description:
1. enable long polling by calling UICallback.activate() method
2. normal request by client (for example button click)
3. response by server, includes command to start polling
4. long polling request by client, client is waiting for answer
5. new event occurred (for example new mail message)
6. response to long polling request. response includes command to start
gui update request and to start new long polling request
7. and 8. update gui
9. new long polling request, and the game starts all over again


I tried this mechanism through a proxy. After about 2 minutes the proxy
server killed the long polling connection. Is there a way to define a
maximum for an open connection?

Thanks for your effort.


Greetings,
JB
Previous Topic:custom controls - qooxdoo throws an error
Next Topic:FileLocator in BundleActivator
Goto Forum:
  


Current Time: Sun Jul 13 03:34:38 EDT 2025

Powered by FUDForum. Page generated in 0.06058 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top