Max server Poll timeout / Max Topics

Nov 30, 2010 at 4:30 PM
Edited Nov 30, 2010 at 4:31 PM

Tomasz,

Can you comment on the effect of changing the server poll timeout and how this would alter performance?  I am thinking of using LaharSub but not sure if it will be the best tool for my needs. We will potentially have around 200/300 clients and each client is likely to subscribe to between 5-10 topics at a time.  While messages for some of these topics may be published fairly often, for a lot of them the messages will be very infrequent (sometimes not even per day).  Unfortunately I'm led to believe that some of the clients will leave their browsers open for long periods (days) without refreshes.  Would you recommend increasing the server timeout/re-subscriptions after every timeout?

On another note is there any limit that you know of for the number of topics that any one client can subscribe to at a time?

Cheers.

Nov 30, 2010 at 5:51 PM

Metaman,

Server poll timeout is a mechanism intended to prevent HTTP intermediaries (e.g. proxies) from terminating TCP connections underlying the HTTP long poll request in the absence of data sent from the server to the client. The shorter the timeout, the lower the risk an intermediary will terminate the inactive TCP connection. At the same time, the shorter the timeout, the greater the network bandwidth utilization. Choosing the right timeout depends on how much you know about the environment in which the app is deployed and used. For apps that are deployed in controlled network environments (e.g. company intranet) where you know and can rely on a certain behavior of intermediaries, you may be able to set the timeout to a larger value. If the app is deployed on the internet, 45 seconds is considered safe. Setting it at more then 1 minute is asking for trouble. Setting it below 15 seconds is unlikely to be beneficial. 

The only hard limit on the number of subscriptions is dictated by the maximum length of the URL (around 2KB in most browsers), as subscriptions parameters are passed using query parameters on HTTP GET requests. I don't think you are going to be anywhere near the limit with 10 subscriptions.

Thanks,
Tomasz