I ran the client through jdb and see this:
running ...
main[1] Getting a UserTransaction object from JNDI
Connecting to the AccountHome
Getting the list of existing accounts in database
109 John Smith 0.0 <------------------ this is wrong
main[1]
main[1] where
[1] java.lang.Object.wait (native method)
[2] java.lang.Object.wait (Object:424)
[3] org.objectweb.jonathan.libs.resources.JScheduler.wait (JScheduler:178)
[4]
org.objectweb.david.libs.protocols.giop.GIOPProtocol$ReplyHolder.listen (G
IOPProtocol$ReplyHolder:912)
[5] org.objectweb.jonas_tm.ControlImpl_Stub.commit (ControlImpl_Stub:73)
[6] org.objectweb.jonas_tm.TransactionImpl.commit (TransactionImpl:133)
[7] org.objectweb.jonas_tm.Current.commit (Current:206)
[8] eb.ClientAccount.accountList (ClientAccount:66)
The client calls utx.commit() in accountList and waits.
I killed the EJB server and the client also exited
main[1] Exception getting account list: javax.transaction.SystemException:
Unexp
ected Exception on commit
The application exited.
I then commented out the utx.commit line and again it is waiting
Initializing jdb...
> run eb.ClientAccount AccountExplHome
running ...
main[1] Getting a UserTransaction object from JNDI
Connecting to the AccountHome
Getting the list of existing accounts in database
109 John Smith 0.0
Creating a new Account in database
main[1] where
[1] java.lang.Object.wait (native method)
[2] java.lang.Object.wait (Object:424)
[3] org.objectweb.jonathan.libs.resources.JScheduler.wait (JScheduler:178)
[4]
org.objectweb.david.libs.protocols.giop.GIOPProtocol$ReplyHolder.listen (G
IOPProtocol$ReplyHolder:912)
[5] eb.JOnASAccountExplHome_Stub.create (JOnASAccountExplHome_Stub:41)
[6] eb.ClientAccount.main (ClientAccount:118)
On the server side the trace file shows this:
ConnectionImpl.prepareStatement(String insert into accountsample (accno,
custome
r, balance) values (?, ?, ?))
TimerEvent.process
JTM: timeout expired
JTM: Rolling back transaction
JTM: Send rollback to Resource
SubCoordinator.rollback()
SubCoordinator.doBeforeCompletion()
TransactionImpl.unsetTimer()
SubCoordinator.doRollback()
XAResource ---> ROLLBACK org.objectweb.jonas.jdbc_xa.XAResourceImpl@e969327a
Xid = 1006467479558145
XAResource ---> rollback: XA START without XA END
Are the examples supposed to run as is (after compiling) or are code changes
needed?
Thanks
Gopi
-----Original Message-----
From: Gopi Rajagopal [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, February 21, 2001 6:22 PM
To: '[EMAIL PROTECTED]'
Subject: eb example with Jeremie in Jonas 2.2.6
Has anyone run the eb example using Jeremie and Jonas 2.2.6?
I start the Jeremie registry
K:\bullejb\JONAS\bin\nt>java
-Djava.security.policy=k:\bullejb\JONAS\java.policy
org.objectweb.jeremie.libs.services.registry.JRMIRegistry
Jeremie Registry started
& the EJB Server successfully.
K:\bullejb\JONAS\examples\src\eb>java -Dinstall.root=k:\bullejb\JONAS
-Djava.sec
urity.policy=k:\bullejb\JONAS\java.policy
org.objectweb.jonas.server.Se
rver
JOnAS Server, version 2.2.6, running on Jeremie.
Mapping ConnectionManager jdbc:oracle:thin:@machinename:orc1 on jdbc_1
EJBHome:eb.JOnASAccountExplHome for AccountExpl available
EJBHome:eb.JOnASAccountImplHome for AccountImpl available
EJBServer is ready
When I run the client code it hangs after a few print statements.
K:\bullejb\JONAS\examples\classes>java eb.ClientAccount AccountImplHome
Getting a UserTransaction object from JNDI
Connecting to the AccountHome
Getting the list of existing accounts in database
109 John Smith 0.0
At this point there is no entry for John Smith in the db table.
I have tried both populated and empty accountsample tables.
What am I missing here?
Thanks
Gopi
PS The sb example works fine
----
To unsubscribe, send email to [EMAIL PROTECTED] and
include in the body of the message "unsubscribe jonas-users".
For general help, send email to [EMAIL PROTECTED] and
include in the body of the message "help".
----
To unsubscribe, send email to [EMAIL PROTECTED] and
include in the body of the message "unsubscribe jonas-users".
For general help, send email to [EMAIL PROTECTED] and
include in the body of the message "help".