1 Reply Latest reply on Jul 31, 2009 7:24 PM by Arbi Sookazian

    Multiple LRC programatically in the same Request. How?

    Pedro Sena Newbie

      Hi Guys,


      I need to create a couple of conversations programatically in the same request.


      I'm trying to do it in a testCase (using ComponentTest) but appears that I'm justing promoting a temp conversation to a LRC.


      I would like to know if this is possible, to start a couple of conversations and make all of them LRC programatically.


      Thanks,


      PS

        • 1. Re: Multiple LRC programatically in the same Request. How?
          Arbi Sookazian Master

          Per window/tab, there can be maximum one active LRC.  You can create nested conversations within a root/parent LRC.  You can probably leave the conversation (becomes a background LRC and eligible for timeout and eventual destruction) and then create a new LRC (active).


          This is why we usually use @Begin(join=true) if that method can be re-executed during the same LRC, otherwise you'll get an exception if an LRC is already running and you exec a @Begin method.


           java.lang.IllegalStateException: begin method invoked from a long-running conversation, try using @Begin(join=true) on method: startup



          SiA:



          If you get to the end of the use case and no longer need the current long-running
          conversation, it’s usually best to end the conversation properly rather than abandon it.
          However, if you’re not ready to call it quits, then abandoning the conversation is the
          appropriate choice. Before deciding to abandon a conversation to allow the user to go
          off on a tangent, consider whether it’s more appropriate to suspend the current longrunning
          conversation by nesting a new long-running conversation within it.