RE: CCM - Transactions. Please Help!!
"srini" <[email protected]> Fri, 14 May 2004 10:03:04 -0500
| Newsgroups | gmane.linux.redhat.ccm.general |
|---|---|
| Message-ID | <000001c439c4$92121b90$6b1ea8c0@admin7jz2nzgs0> |
Here is what I do in my web app: 1. Whenever a logged in user submits a job, I create an JOB instance in the database (using domain object), do an explicit disconnect of this instance and put into a Job Queue (in memory) 2. A thread monitors this Job Queue and processes each job in the queue. Since the stored job instances (in the queue are READ ONLY), I then retrieve the job details again from the database using this READ ONLY object's ID. That is when I run into this exception. (IMPORTANT: I can see the job details in the database) -----Original Message----- From: Vadim Nasardinov [mailto:[email protected]] Sent: Friday, May 14, 2004 9:44 AM To: srini; [email protected] Subject: Re: [redhat-ccm-list] CCM - Transactions. Please Help!! On Friday 14 May 2004 10:35, srini wrote: > The other transaction is opened from within a Thread. Would > that make any difference? What do you mean by that? IIRC, the way things are set up is that each thread gets its own Session. Barring possible rare edge cases, there is a one-to-one mapping between threads and sessions. Regardless, if a domain object has been successfully saved, you shouldn't be getting a DataObjectNotFoundException with the code you've shown. It might be a good idea for you to share a little more details of your exact setup and/or tell us about your attempts to debug this on your own. People on this list may get a clue from what you say or forget to say. -- Redhat-ccm-list mailing list [email protected] https://www.redhat.com/mailman/listinfo/redhat-ccm-list Archives: https://www.redhat.com/pipermail/redhat-ccm-list/