0 Replies Latest reply on Jun 4, 2008 6:46 AM by agup10

    Issue with persistence | No inserts/updates statements getti

    agup10

      Context
      I have a session scoped seam component from where I am invoking a method persistUserFund() in domain layer.
      Seam version: 2.0.1.GA

      Problem Statement
      The method persistUserFund() does not fire an inserts/updates/deletes and the data is not peristed into theoracle database

      Problem Explanation
      The method in domain layer has the following code block. I am using session.flush to flush the session so that the inserts/updates/deletes could get fired.

      persistUserFund() {
      Session session = getSession();
      Block block = userfund.removeBlock();
      session.flush();
      userfund.setMainBlock(block);
      session.flush();
      }

      I tried executing the above method using TestNG and the method executes successfully generating inserts/updates statements.

      However, from the session scoped seam component, no inserts/updates/deletes are generated.

      I have tried using Conversation.changeFlushMode(FlushModeType.MANUAL); at the start of the method in seam component and Conversation.changeFlushMode(FlushModeType.AUTO); at the end of the seam component. But even this did not help.

      Could someone provide any insights to help me solve this problem?

      Thanks in Advance