0 Replies Latest reply on Apr 14, 2003 7:04 PM by Dave

    prepare called on a local tx. You are not getting the semant

    Dave Newbie

      I keep seeing the following in my jboss log ... I saw some previous posts on this exact error message and they all seemed JMS/MDB related ... I am using neither so I can't explain away this error message ...

      [LocalTxConnectionManager$LocalConnectionEventListener] prepare called on a local tx. You are not getting the semantics you expect!

      All of my transactions use the following pattern:

      TransactionManager trans = null;

      try{
      trans = (TransactionManager)getHome("java:/TransactionManager",TransactionManager.class);
      trans.begin();

      try{
      profile = profileHome.findByPrimaryKey(new Integer(params.getMemberID()));
      profileRec = profile.getRecord();
      }
      catch(FinderException fe){;} //Don't care

      if(profile == null)
      {
      profileRec = new MemberProfileRecord();
      profileRec.member_id = params.getMemberID();
      }

      profileRec.member_profile_name = parameterMap.getParameter("member_profile_name");
      profileRec.member_profile_email_address = parameterMap.getParameter("member_profile_email_address");
      profileRec.member_profile_nickname = parameterMap.getParameter("member_profile_nickname");

      if(profile == null)
      profile = profileHome.create(profileRec);
      else
      profile.setRecord(profileRec);


      trans.commit();

      params.ctx.put("profile_saved",Boolean.TRUE);

      }
      catch(Exception e){
      logger.error("Exception while trying to save member_profile!",e);

      if(trans == null)
      logger.info("No transaction exists to roll back...");
      else
      try{
      trans.rollback();
      logger.info("Transaction successfully rolled back");
      }
      catch(Exception rbe){
      logger.error("Unable to roll transaction back!",rbe);
      }
      }


      What causes this message? It isn't 100% consistent in its appearance ... (that is, it doesn't appear for EVERY method i've written that uses TransactionManager ... only for certain ones)

      What other debug info can i provide to help you track it down?

      Thanks in advance,
      Dave