-
1. Re: Adding a webapp to the starter's kit
kgalligan Jul 27, 2005 10:14 PM (in response to kgalligan)Ok, scratch that. Still don't know what's wrong. Still think it didn't work till after I deleted the temp dir, but upon repeated testing, I can switch the problem on/off in a running instance.
Now, the problem. I'm assuming jboss must be using the same connection under the hood, even though I have different services set up for database connections. Basically, the jbpm system is being committed, then the hibernate for my app is being committed. This is where things are bombing. If I take out the code that creates a transaction in app, jbpm works fine. As soon as commit gets called in my code, things bomb.
More digging, poking and proding.
Now, obviously, I should somehow configure 1 hibernate session to include my code and the jbpm stuff, which would allow a single session. On second thought, that might not even be a great plan. However, I'm now curious as to why this is bombing, and fell compelled to continue... -
2. Re: Adding a webapp to the starter's kit
kgalligan Jul 27, 2005 11:08 PM (in response to kgalligan)Final plea. Any info would be great.
I have tried stripping out both jbpm and running and stripping out my hibernate calls, and both work individually in the same application. When both filters are running, it bombs out. The hibernate migration guide says that version 2.1 and 3 should be able to run side by side. I really have no idea what's wrong.
Also, I actually set jbpm up in a different database just to see if that was the trouble. It wasn't. Still getting the...
"You cannot commit during a managed transaction!"
Error. Any thoughts? -
3. Re: Adding a webapp to the starter's kit
kgalligan Jul 28, 2005 1:46 AM (in response to kgalligan)Ok, final post from me. Sorry for the spamming.
I have converted my code to use hibernate 3. I put my db code in a 'har' file, renamed my jboss-service to hibernate-server, etc. I removed the jars to version 2.
Now, with the jbpm filters commented out in my web.xml file, my app runs fine. With those filters in, it does the following...
MyAppFilter: grabs hibernate session and starts transaction
JBPMFilter: Begins jbpm transaction
MyApp: Runs a jsp page
JBPMFilter: Tries to close the jbpm transaction with 'jbpmSession.commitTransactionAndClose();'
It fails at this point. It should get past this and to my code to close the transaction for my app's code, but it bombs out with the old...
"You cannot commit during a managed transaction!"
So, my question to you all. Is this happening because my app's transactions are being handled by the jboss container, but the jbpm transactions aren't? At this point that seems to be the issue. If I run either in isolation, they're fine. Together, it seems like jboss gets upset because they should either both handle transactions on their own or both let jboss handle it.
I could also be completely wrong about that. However, I'm totally lost. My setup for the jbpm is pretty much stock. Please, if anybody can help it would be much appreciated. I'm completely lost at this point. -
4. Declarative transaction and jBPM integration.
dserodio Jul 29, 2005 1:53 PM (in response to kgalligan)I'd really like to hear about it, because we are having the same kind of problems, except we're using Spring managed transactions.
How can a webapp, using declarative transaction management use a single transaction for both our "Business Objects" and jBPM? -
5. Re: Adding a webapp to the starter's kit
kgalligan Aug 6, 2005 9:25 PM (in response to kgalligan)Not sure on your issue. All I did with mine is put jbpm first and my app filter second. Now they play together. This is good news and bad news. Good because it works. Bad because I have no idea why it works. I'm sure I'll run into something related to this in the future and I'll have the "final showdown" with this issue.
-
6. Re: Declarative transaction and jBPM integration.
icyjamie Sep 2, 2005 5:12 AM (in response to kgalligan)"dserodio" wrote:
I'd really like to hear about it, because we are having the same kind of problems, except we're using Spring managed transactions.
How can a webapp, using declarative transaction management use a single transaction for both our "Business Objects" and jBPM?
Any success on this part (meaning declaritive transaction management on business objects and jBPM)? We would like to use jBPM (it looks promising in handling our particular WF demands), but we are heavily into Spring as well (because of certain architectural constraints).