Package com.arjuna.mw.wsas.activity

Examples of com.arjuna.mw.wsas.activity.Outcome


    public void close () throws InvalidActivityException, WrongStateException, ProtocolViolationException, NoCoordinatorException, CoordinatorCancelledException, NoPermissionException, SystemException
    {
  try
  {
      Outcome res = UserActivityFactory.userActivity().end(Success.instance());

      /*
       * TODO
       *
       * What happens if the coordinator has already been terminated?
View Full Code Here


    public void cancel () throws InvalidActivityException, WrongStateException, ProtocolViolationException, NoCoordinatorException, CoordinatorConfirmedException, NoPermissionException, SystemException
    {
  try
  {
      Outcome res = UserActivityFactory.userActivity().end(Failure.instance());
     
      if (res != null)
      {
    if (res instanceof CompositeOutcomeImple)
        res = ((CompositeOutcomeImple) res).get(CoordinationOutcome.class.getName());
View Full Code Here

    public Outcome processMessage (Message notification) throws WrongStateException, ProtocolViolationException, SystemException
    {
  if (_resource == null)
      return new CoordinationOutcome(TwoPhaseResult.FINISH_ERROR);

  Outcome result = new CoordinationOutcome(TwoPhaseResult.FINISH_ERROR);

  if (notification instanceof BeforeCompletion)
  {
      try
      {
View Full Code Here

    public Outcome processMessage (Message notification) throws WrongStateException, ProtocolViolationException, SystemException
    {
  if (_resource == null)
      return new CoordinationOutcome(TwoPhaseResult.FINISH_ERROR);

  Outcome result = new CoordinationOutcome(TwoPhaseResult.FINISH_ERROR);
 
  if ((notification instanceof NestedPrepare) || (notification instanceof TopLevelPrepare))
  {
      result = doPrepare(notification.qualifiers());
  }
View Full Code Here

  return true;
    }

    private final Outcome doPrepare (Qualifier[] qualifiers) throws WrongStateException, ProtocolViolationException, SystemException
    {
  Outcome result = new VoteCancel();
 
  try
  {
      com.arjuna.mw.wstx.common.Vote v = _resource.prepare(qualifiers);
     
View Full Code Here

          throw new InvalidActivityException(
              wsasLogger.log_mesg.getString("com.arjuna.mwlabs.wsas.activity.ActivityImple_2")
                  + " " + this);
        }

        Outcome current = null;

        try
        {
          setCompletionStatus(cs);
        }
        catch (Exception ex)
        {
          // ignore and complete with the status we have.
        }

        _status = Completing.instance();

        try
        {
          OrderedList hls = HLSManager.HLServices();
          OrderedListIterator iter = new OrderedListIterator(hls);
          HLSWrapper elem = (HLSWrapper) iter.iterate();

          while (elem != null)
          {
            Outcome result = null;

            try
            {
              result = elem.hls().complete(getCompletionStatus());
            }
View Full Code Here

  /*
  if (currentActivity.parent() != null)
      throw new ActiveChildException();
  */

  Outcome res = null;
 
  try
  {
      res = currentActivity.end();
  }
View Full Code Here

  /*
  if (currentActivity.parent() != null)
      throw new ActiveChildException();
  */

  Outcome res = null;
 
  try
  {
      res = currentActivity.end(cs);
  }
View Full Code Here

      System.out.println("\nEnding coordination.");
     
      ua.setCompletionStatus(Success.instance());
     
      Outcome res = ua.end();

      if (res instanceof XAOutcome)
      {
    XAOutcome out = (XAOutcome) res;
   
View Full Code Here

      System.out.println("\nEnding coordination.");
     
      ua.setCompletionStatus(Success.instance());
     
      Outcome res = ua.end();

      if (res instanceof XAOutcome)
      {
    XAOutcome out = (XAOutcome) res;
   
View Full Code Here

TOP

Related Classes of com.arjuna.mw.wsas.activity.Outcome

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.