hi all
I am trying to implement the Shipper example from the J2sdkee1.2.1 guides.
It is a combination of
Statefull Session bean and a BMP Entity Bean. the entity bean takes a db
connection from the connection pool
in the setEntityContextMethod and closes the connection in unSetEntityConext
method.
The session bean calls the business method of the BMP EntityBean. This
method updates the contents of the Entity Bean
resulting in the update of the db and second one just reads the contents of
the db. Client invokes the session bean method.
the session bean method finds the entitybean using findbyPrimaryKey method.
all methods of both beans are in the transaction. iam using oracle as my
database.
when i call the method of session bean from the client, for the first time,
the database is updated. the transaction is committed
(if i update the table using SQL prompt it gets done). the client ends with
out giving any errors.
but when i invoke the client again, the client completes with out giving any
errors. but the db is not updated. even if i try to
update through the SQL prompt, it hangs (may be it is indicating that the
row is locked by the db) . if i kill the jboss then
the update completes successfully(does this indicates that the row is locked
by the txn from jboss??)
in the jboss examples for a BMP bean , connection is opened by each method
independently and is closed after the method is
completed. but here iam opening the connection in setEntityContext and
closing in unSetEntityContext()
where does the problem lies???
Vamsi
--
--------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
List Help?: [EMAIL PROTECTED]