0 Replies Latest reply on May 21, 2002 9:48 PM by jdestef

    Transaction in session bean with database access

    jdestef

      Hi,

      I have a MDB that calls a session bean that acts as a controller for the processing of a message. Both these beans use CMT with requires transaction set for all methods. The first thing that the controller session bean does is call another session bean (data saver) to persist the contents of the message to a database. This bean also uses CMT with RequiresNew transaction for all methods. The data saver bean uses a helper class to do the actual database calls. Because the data saver bean has RequiresNew set for all methods I thought that the data would be committed when the processing finishes in the method call. This is not happening. The data is not getting committed until the MDB exits its onMessage method. I'm I mistaken as to how this should work?

      Thanks