0 Replies Latest reply on Jan 23, 2008 7:40 AM by Phil Haigh

    Transaction.instance().setTransactionTimeout();

    Phil Haigh Novice

      Hi all,

      I'm trying to force an increase to a transaction timeout within a particular method... I'm using this:

      public void doScheduledSend(@Duration Long waitBeforeStart, @IntervalDuration Long interval)
       {
      
       log.info("Processing scheduled email tasks");
      
       try
       {
       Transaction.instance().setTransactionTimeout(100000);
       }
       catch (SystemException e1)
       {
       log.error("Oh dear", e1);
       }
      
       log.info("Set timeout");
      

      but it appears not to have any effect. Clearly I'm missing something else?

      My components xml contains:

      <core:init jndi-pattern="wildfrontiers/#{ejbName}/local"/>
      
       <transaction:ejb-transaction/>


      is that incorrect?

      any help greatly appreciated!