I have a EAR file which runs fine on IBM websphere (6.0 and 6.1), now I have deployed the same in Jboss 5.1.0.As this is a dynamic website I need to make an oracle connection and where the datasource name is different from DefaultDS. I am not using EJB's.
I have configured JBoss inside Eclipse 3.7 (Indigo) and going to do any modification on the code etc through eclipse-JBoss combination only.
The application is deployed successfully and is working fine (log in, quite almost all the functionality is working fine) except one, which is throwing the following exception. Though we have not changed anything for that functionality in the code.
What I have done so far in this approach,
1. Created the oracle-ds.xml with DB and application specific parameters.
2. Deployed the oracle-ds.xml in C:\jboss-5.1.0.GA_MYAPP\server\default\deploy directory
3. Kept the hsqldb-ds.xml as it is, in the same location (As it comes default)
4. Provided the ojdbc14.jar in C:\jboss-5.1.0.GA_MYAPP\common\lib
5. Created and kept jboss-web.xml in <project_home>/src/web/WEB-INF
Output ::
==========
1. JBoss starts successfully showing it is able to detect the new application specific JNDI name (MY_ds)
2. But I am getting the following 2 different exceptions ,
2.1
2.2 This exception we are getting whenever some basic functionality is hitting the DB
What has been done so far ::
=================
1. Tried with commeting out the autoCommit() statements from the code (As the log shows that the autoCommit is set at the JBoss level, so code level autocommit has been closed)
Output :: Receiving the same exception,
2. Modified the oracle-ds.xml with
connection property's autoCommit as 'false', but with no luck.
Info ::
oracle-ds.xml
Thanks in advance,
Joydeep
“Men are only as good as their technical development allows them to be.”
James Boswell
Ranch Hand
Joined: Nov 09, 2011
Posts: 343
posted
0
Hi
If it isn't too long, could you post the code for the entire class com.lilly.sdd.common.data.TwoBO please?
Are you sure you spelled the option correctly? Is it "autoCommit" or "autocommit"? Case matters! By the way, this in bot a JBoss question, it is a question about Oracle and its JDBC driver. All the JBossdoesi s pass the settings to the Oracle JDBC driver, which is the one complaining (though based on the exception stack trace it appears that JBoss is not properly wrapping the original exception).
Hi Peter,
I have tried with both "autoCommit" and "autocommit" in the parameter list, but both are giving the same exception :-(
Moreover the same code was deployed in webshpere AS, where it was working perfectly well.
And as you have mentioned "JBoss is not properly wrapping the original exception", is there any issue with this specific version of JBoss (Jboss 5.1) ? or if you can provide some more information on the same it will be great.
Hi James,
The complete code is more than 350 lines long so I am not putting that here.
But the method which is throwing the exceptions is,
Note :: 1. Originally the following two lines were not commented out, but once we received the above exception we have commented out the above two lines
2. I have checked the the control is going into the 'if (myTX)'
3. myTx is a boolean operator.
and same is the case for rollbackTrans()
I think the main issue is the following exception :-(
But just a thought, the same code works properly in Websphere but showing this exception in JBoss.
May be JBoss is more fine tuned from connection point of view.