Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp
[b]Hibernate version:[/b]
[b]Mapping documents:[/b]
[b]Code between sessionFactory.openSession() and session.close():[/b]
[b]Full stack trace of any exception that occurs:[/b]
[b]Name and version of the database you are using:[/b]
[b]The generated SQL (show_sql=true):[/b]
[b]Debug level Hibernate log excerpt:[/b]
When I tried to delete a detached object just after get from the database, hibernate complained that the object is transient and then rollback.
Client side code:
device = stub.getDeviceById(new Long(983040));
deleteReturn = stub.deleteDevice(device);
Server side print out:
[2005-06-20 22:19:24,291] DEBUG org.hibernate.transaction.JDBCTransaction begin
[2005-06-20 22:19:24,291] DEBUG org.hibernate.transaction.JDBCTransaction current autocommit status: false
[2005-06-20 22:19:24,291] INFO Transaction-2005-06-20 DeviceDAO:deleteDevice::starting --> the identifier is: 983040
[2005-06-20 22:19:24,291] DEBUG org.hibernate.event.def.DefaultDeleteEventListener deleting a transient instance
[2005-06-20 22:19:24,306] DEBUG org.hibernate.transaction.JDBCTransaction rollback
[2005-06-20 22:19:24,306] DEBUG org.hibernate.jdbc.JDBCContext before transaction completion
[2005-06-20 22:19:24,306] DEBUG org.hibernate.impl.SessionImpl before transaction completion
[2005-06-20 22:19:24,306] DEBUG org.hibernate.transaction.JDBCTransaction rolled back JDBC Connection
[2005-06-20 22:19:24,306] DEBUG org.hibernate.jdbc.JDBCContext after transaction completion
[2005-06-20 22:19:24,306] DEBUG org.hibernate.impl.SessionImpl after transaction completion
[2005-06-20 22:19:24,306] DEBUG org.hibernate.impl.SessionImpl closing session
[2005-06-20 22:19:24,306] DEBUG org.hibernate.jdbc.AbstractBatcher closing JDBC connection (open PreparedStatements: 0, globally: 0) (open ResultSets: 0, globally: 0)
[2005-06-20 22:19:24,306] DEBUG org.hibernate.connection.DriverManagerConnectionProvider returning connection to pool, pool size: 1
[2005-06-20 22:19:24,306] DEBUG org.hibernate.jdbc.JDBCContext after transaction completion
[2005-06-20 22:19:24,306] DEBUG org.hibernate.impl.SessionImpl after transaction completion
[2005-06-20 22:19:30,572] INFO DefaultTransaction Shutting down...
[2005-06-20 22:19:30,572] INFO org.mortbay.util.ThreadedServer Stopping Acceptor [SSL: ServerSocket[addr=0.0.0.0/0.0.0.0,port=0,localport=443]]
[2005-06-20 22:19:31,541] INFO org.mortbay.http.SocketListener Stopped SocketListener on 0.0.0.0:443
[2005-06-20 22:19:31,541] INFO org.mortbay.util.Container Stopped org.mortbay.jetty.servlet.WebApplicationHandler@d1fa5
[2005-06-20 22:19:31,541] INFO org.mortbay.util.Container Stopped WebApplicationContext[/jsentry,Apache-Axis]
[2005-06-20 22:19:31,541] INFO org.mortbay.util.Container Stopped org.mortbay.jetty.Server@1f9dc36
Any help would be appreciated.
Thanks.
Wade