The _components field should be populated before your code gets invoked. Without looking at the code, it sounds like a Tapestry bug; but I can't imagine how a bug like that could have slipped through for so long that you're the only one who sees it.
Does this happen to only a single page, or are multiple pages afflicted? On Wed, Jan 7, 2009 at 10:40 AM, Mike Wasserman <mike.wasser...@intelliware.ca> wrote: > I added the following code to the AbstractComponent.getComponent(String id) > method: > > while(_components == null) { > try { > System.out.println("SLEEPING"); > Thread.currentThread().sleep(500); > } catch (InterruptedException e) { > e.printStackTrace(); > } > } > > I was hoping that by having the app sleep for a short period of time the > _components HashMap would eventually be populated. > It seems to work for a while, but eventually the app ends up in a state of > permanently sleeping (this seems to happen randomly, sometimes after 2 tests, > sometimes after 20 tests, sometimes after 50 tests). > So it appears that the _components HashMap is never populated under some > circumstances. > > Anyone have any clue why this is happening, or how it is possible for this to > happen in Tapestry? > > Thanks > > Mike > > > ________________________________ > > From: Mike Wasserman [mailto:mike.wasser...@intelliware.ca] > Sent: Tue 1/6/2009 2:58 PM > To: Tapestry users > Subject: RE: Tapestry Upgrade problem > > > > I've tried a variety of JDKs and the problem happens with all of them. > > I've tracked it through the code and what it seems to come down to is that > sometimes the _components Map in the AbstractComponent class is populated and > other times it's null. > My guess at this point is that it's some sort of threading problem within > Tapestry. > > Anyone have any ideas on how to fix this problem? > > Thanks > > Mike > > ________________________________ > > From: Mike Wasserman [mailto:mike.wasser...@intelliware.ca] > Sent: Thu 12/25/2008 1:07 PM > To: Tapestry users > Subject: RE: Tapestry Upgrade problem > > > > Thanks for your response. > No, we didn't have this problem with 4.1.2 > > I am off on holidays for a little while, but I will try your suggestion as > soon as I get back. > > Thanks again > > ________________________________ > > From: andre...@gmail.com on behalf of Andreas Andreou > Sent: Wed 12/24/2008 3:11 PM > To: Tapestry users > Subject: Re: Tapestry Upgrade problem > > > > So, you weren't seeing this problem with 4.1.2 ? > > I'd be interesting if you could try with a 1.6 VM, but apart from that > and since you're getting this consistently, i'm wondering if you can try this > (which is based on some old reports I remember reading here): > - Start your app and before running the tests, try to visit all the affected > pages by hand (making sure they load fine) and only then fire the tests. > Do you see problems after that? > > On Wed, Dec 24, 2008 at 8:16 PM, Mike Wasserman > <mike.wasser...@intelliware.ca> wrote: >> I've tried with JDK 1.5.0_10 and JDK 1.5.0_17 and I am experiencing the >> same problem with both. >> The Selenium tests are hitting the app pretty hard and I'm wondering if >> it's causing a threading problem within Tapestry. >> Isn't the component creation multi-threaded? >> >> >> -----Original Message----- >> From: Howard Lewis Ship [mailto:hls...@gmail.com] >> Sent: Tuesday, December 23, 2008 2:00 PM >> To: Tapestry users >> Subject: Re: Tapestry Upgrade problem >> >> What JDK are you running on? >> >> On Tue, Dec 23, 2008 at 10:50 AM, Mike Wasserman >> <mike.wasser...@intelliware.ca> wrote: >>> I am upgrading from Tapestry 4.1.2 to Tapestry 4.1.6. >>> When I run my integration tests (using Selenium) I am get a error >> randomly. >>> I receive a org.apache.hivemind.ApplicationRuntimeException that >> indicates that given component (page) does not contain a component >> shell. >>> All of the affected pages have <html jwcid="shell"> which leads me to >> believe that I have specified a shell component. >>> I have tracked the problem into the PageLoader class, but since the >> problem is random it is very difficult to debug. >>> Is it possible that this is a threading problem? >>> >>> Can anyone help? >>> >>> Mike >>> >> >> >> >> -- >> Howard M. Lewis Ship >> >> Creator Apache Tapestry and Apache HiveMind >> >> --------------------------------------------------------------------- >> 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 >> >> > > > > -- > Andreas Andreou - andy...@apache.org - http://blog.andyhot.gr > <http://blog.andyhot.gr/> <http://blog.andyhot.gr/> > <http://blog.andyhot.gr/> > Tapestry / Tacos developer > Open Source / JEE Consulting > > --------------------------------------------------------------------- > 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 > -- Howard M. Lewis Ship Creator Apache Tapestry and Apache HiveMind --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org