Thanks Thiago, The markup returned is very simple. I'll try out the dispatcher 
approach. BTW you are right I am using Tapestry 5.1.0.5.

regards,
Rajesh


----- Original Message ----
From: Thiago H. de Paula Figueiredo <thiag...@gmail.com>
To: Tapestry users <users@tapestry.apache.org>
Sent: Wed, 12 May, 2010 5:59:12 PM
Subject: Re: comet implementation issue

On Wed, 12 May 2010 00:19:20 -0300, rajesh sukumaran <rajeshs_...@yahoo.co.in> 
wrote:

> Hi,

Hi!

> I implemented reverse ajax component that uses long polling technique.
> Basically what I did was to use JQuery's jQuery.getJSON(...)  method to make 
> an
> ajax call using an action event URL of the component. The action event on
> the component spawns another event(using resourse.triggerEvent()) which is 
> handled by the page that holds the component. The event handler in the page 
> waits for the relevant data to be available and when it is available return a 
> block for displaying the data.

Tapestry uses a pool of pages. So, when a request takes long to complete and 
more requests to the same page are done, the number of page instances checked 
out of pool the increases until it reaches the hard limit. So, yes, Tapestry 
pages were not meant to use in long polling.

Is the block your returning complex markup? If not, I would create a Dispatcher 
(that is not pooled) to handle these requests and return the information as 
JSON.

> BTW I am using Tapestry 5.0.1 with tomcat 6.0. Any help  is much
> appreciated.

5.0.1? Wouldn't it be 5.1? 5.0.1 is almost three years old now.

--Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and 
instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to