Hi,

I'm using JBoss-4.0.0RC2. I'm calling an ejb whose
methods have Container/Required transaction setting.
The method getBalance
retrives the balance in a given account from a SQL
Server database. The method works fine and within the
method the transactional state is STATUS_ACTIVE.
However, when it returns I get the following exception
and the transaction is rolled back for no reason. I
wrote to the list earlier about mssql-xa-ds.xml not
getting deployed. I findout that when you place it
directly into the deploy directory (rather than
/META-INF of the ejb-jar archive) it deploys the
datasource. My database is OK since everything works
when I try this same code on jboss-3.2.4! Are there
any other setting that I have to setup when connecting
to a database other than to copy the jdbc drivers and
put the *-ds.xml file.

Can you please help me sort out this problem.

12:04:09,875 INFO  [EjbModule] Deploying Bank
12:04:09,984 INFO  [EJBDeployer] Deployed:
file:/C:/Dasarath/jboss-4.0.0RC2/server/default/deploy/bank.jar
12:04:28,265 INFO  [STDOUT] [BankBean]
getBalance(1001) STATUS_ACTIVE
12:04:28,265 INFO  [STDOUT] [BankBean] getConnection()
12:04:28,281 ERROR [LogInterceptor]
TransactionRolledbackException in method: public
abstract double test.Bank_.getBalance(int) throws
java.rm
i.RemoteException, causedBy:
org.jboss.tm.JBossRollbackException: Unable to commit,
tx=TransactionImpl:XidImpl[FormatId=257,
GlobalId=sarasavi-pub3/17, BranchQual=, localI
d=17] status=STATUS_NO_TRANSACTION
        at
org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:344)
        at
org.jboss.ejb.plugins.TxInterceptorCMT.endTransaction(TxInterceptorCMT.java:457)
        at
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:325)
        at
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:149)
        at
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:128)
        at
org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)
        at
org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
        at
org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:624)
        at
org.jboss.ejb.Container.invoke(Container.java:859)
        at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native
Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at
java.lang.reflect.Method.invoke(Method.java:324)
        at
org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:141)
        at
org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
        at
org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
        at
org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:236)
        at
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
        at
org.jboss.invocation.jrmp.server.JRMPInvoker$MBeanServerAction.invoke(JRMPInvoker.java:775)
        at
org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:382)
        at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native
Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at
java.lang.reflect.Method.invoke(Method.java:324)
        at
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
        at
sun.rmi.transport.Transport$1.run(Transport.java:148)
        at
java.security.AccessController.doPrivileged(Native
Method)
        at
sun.rmi.transport.Transport.serviceCall(Transport.java:144)
        at
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
        at
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
        at java.lang.Thread.run(Thread.java:534)

Thanks.

--Dasarath


                
_______________________________
Do you Yahoo!?
Express yourself with Y! Messenger! Free. Download now. 
http://messenger.yahoo.com


-------------------------------------------------------
This SF.Net email is sponsored by: YOU BE THE JUDGE. Be one of 170
Project Admins to receive an Apple iPod Mini FREE for your judgement on
who ports your project to Linux PPC the best. Sponsored by IBM.
Deadline: Sept. 24. Go here: http://sf.net/ppc_contest.php
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to