RE: non thread safe access to session

2010-07-22 Thread Jim O'Callaghan
Josh Canfield [mailto:joshcanfi...@gmail.com] > Sent: 22 July 2010 16:25 > To: Tapestry users > Subject: Re: non thread safe access to session > >> I do however have some buried code where I force a transaction to commit > to allow me to assign some non-customer facing entity keys in ba

Re: non thread safe access to session

2010-07-22 Thread Kalle Korhonen
[mailto:joshcanfi...@gmail.com] > Sent: 22 July 2010 16:25 > To: Tapestry users > Subject: Re: non thread safe access to session > >> I do however have some buried code where I force a transaction to commit > to allow me to assign some non-customer facing entity keys in batches, to

RE: non thread safe access to session

2010-07-22 Thread Jim O'Callaghan
o thread safety issues. I'm going to rearrange it to make it more service based. I think this is just down to bad coding practice. Regards, Jim. -Original Message- From: Josh Canfield [mailto:joshcanfi...@gmail.com] Sent: 22 July 2010 16:25 To: Tapestry users Subject: Re: non thread sa

Re: non thread safe access to session

2010-07-22 Thread Josh Canfield
l do it. Thanks for the tips guys. > > Regards, > Jim. > > -Original Message- > From: Jonathan Barker [mailto:jonathan.theit...@gmail.com] > Sent: 22 July 2010 02:31 > To: Tapestry users > Subject: Re: non thread safe access to session > > Jim, > >

RE: non thread safe access to session

2010-07-22 Thread Jim O'Callaghan
m. -Original Message- From: Jonathan Barker [mailto:jonathan.theit...@gmail.com] Sent: 22 July 2010 02:31 To: Tapestry users Subject: Re: non thread safe access to session Jim, I have vague recollections of hitting this before. IIRC, each hibernate object knows the Session that it is as

Re: non thread safe access to session

2010-07-21 Thread Jonathan Barker
. > > Regards, > Jim. > > -Original Message- > From: Thiago H. de Paula Figueiredo [mailto:thiag...@gmail.com] > Sent: 21 July 2010 18:22 > To: Tapestry users > Subject: Re: non thread safe access to session > > On Wed, 21 Jul 2010 13:58:15 -0300, Jim O'

Re: non thread safe access to session

2010-07-21 Thread Howard Lewis Ship
le data creation, I found I was > getting some "non thread safe access to session" type messages when I > launched a second user session and hit the same scratch page.  This doesn't > happen if I mark the relevant method in service A as synchronized, but this > brings with it a

RE: non thread safe access to session

2010-07-21 Thread Jim O'Callaghan
eiredo [mailto:thiag...@gmail.com] Sent: 21 July 2010 18:22 To: Tapestry users Subject: Re: non thread safe access to session On Wed, 21 Jul 2010 13:58:15 -0300, Jim O'Callaghan wrote: > Hi Thiago, Hi, Jim! > I'm talking about the hibernate session - I'm injecting it into

Re: non thread safe access to session

2010-07-21 Thread Thiago H. de Paula Figueiredo
On Wed, 21 Jul 2010 13:58:15 -0300, Jim O'Callaghan wrote: Hi Thiago, Hi, Jim! I'm talking about the hibernate session - I'm injecting it into the constructor of Service B at bind time. I thought Tapestry would treat the service as a thread safe singleton and control access to method

RE: non thread safe access to session

2010-07-21 Thread Jim O'Callaghan
gards, Jim. -Original Message- From: Thiago H. de Paula Figueiredo [mailto:thiag...@gmail.com] Sent: 21 July 2010 17:38 To: Tapestry users Subject: Re: non thread safe access to session Are you talking about Tapestry sessions or Hibernate sessions? Hibernate sessions should never be used a

Re: non thread safe access to session

2010-07-21 Thread Thiago H. de Paula Figueiredo
Are you talking about Tapestry sessions or Hibernate sessions? Hibernate sessions should never be used at the same time by more than one thread. -- Thiago H. de Paula Figueiredo Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and instructor Owner, Ars Machina Tecnolo

non thread safe access to session

2010-07-21 Thread Jim O'Callaghan
bind time. I have service A called in a finite loop in the setup (@SetupRender) method of a scratch page I use for some dev testing. To cut a long story short, when playing around with the sample data creation, I found I was getting some "non thread safe access to session" type messa