Examples of CreateSequence


Examples of org.apache.sandesha2.wsrm.CreateSequence

    // generating a new create sequence message.
    RMMsgContext createSeqRMMessage = RMMsgCreator.createCreateSeqMsg(rmsBean, applicationRMMsg);

    createSeqRMMessage.setFlow(MessageContext.OUT_FLOW);
    CreateSequence createSequencePart = createSeqRMMessage.getCreateSequence();

    SequenceOffer offer = createSequencePart.getSequenceOffer();
    if (offer != null) {
      String offeredSequenceId = offer.getIdentifer().getIdentifier();

      rmsBean.setOfferedSequence(offeredSequenceId);
    }
View Full Code Here

Examples of org.apache.sandesha2.wsrm.CreateSequence

 
    rmMsgContext.fromSOAPEnvelope(msgCtx.getEnvelope(), msgCtx.getWSAAction());

    String sequenceID = null;

    CreateSequence createSequence = rmMsgContext.getCreateSequence();
    CreateSequenceResponse createSequenceResponse = rmMsgContext.getCreateSequenceResponse();
    TerminateSequence terminateSequence = rmMsgContext.getTerminateSequence();
    TerminateSequenceResponse terminateSequenceResponse = rmMsgContext.getTerminateSequenceResponse();
    Iterator<SequenceAcknowledgement> sequenceAcknowledgementsIter = rmMsgContext.getSequenceAcknowledgements();
    Sequence sequence = rmMsgContext.getSequence();
    Iterator<AckRequested> ackRequestedIter = rmMsgContext.getAckRequests();
    CloseSequence closeSequence = rmMsgContext.getCloseSequence();
    CloseSequenceResponse closeSequenceResponse = rmMsgContext.getCloseSequenceResponse();
    MakeConnection makeConnection = rmMsgContext.getMakeConnection();
   
    String rmNamespace = null;

    if (createSequence != null) {
      rmNamespace = createSequence.getNamespaceValue();
    }

    if (createSequenceResponse != null) {
      rmNamespace = createSequenceResponse.getNamespaceValue();
    }
View Full Code Here

Examples of org.apache.sandesha2.wsrm.CreateSequence

      throw new AxisFault(message);
    }

    EndpointReference replyTo = createSequenceMsg.getReplyTo();

    CreateSequence createSequence = createSequenceMsg.getCreateSequence();
    if (createSequence == null) {
      String message = SandeshaMessageHelper.getMessage(SandeshaMessageKeys.createSeqEntryNotFound);
      log.debug(message);
      throw new AxisFault(message);
    }

    EndpointReference acksTo = createSequence.getAcksTo().getEPR();

    if (acksTo == null) {
      log.error(SandeshaMessageHelper.getMessage(SandeshaMessageKeys.acksToInvalid, ""));
      FaultManager.makeCreateSequenceRefusedFault(createSequenceMsg, SandeshaMessageHelper.getMessage(SandeshaMessageKeys.noAcksToPartInCreateSequence), new Exception(), null);
      return null;
    } else if (acksTo.getAddress().equals(AddressingConstants.Final.WSA_NONE_URI)){
      log.error(SandeshaMessageHelper.getMessage(SandeshaMessageKeys.acksToInvalid, acksTo.getAddress()));
      FaultManager.makeCreateSequenceRefusedFault(createSequenceMsg, "AcksTo can not be " + AddressingConstants.Final.WSA_NONE_URI, new Exception(), null);
      return null;
    }

    MessageContext createSeqContext = createSequenceMsg.getMessageContext();
   
    // If this create is the result of a MakeConnection, then we must have a related
    // outbound sequence.
    SequenceEntry entry = (SequenceEntry) createSeqContext.getProperty(Sandesha2Constants.MessageContextProperties.MAKECONNECTION_ENTRY);
    if(log.isDebugEnabled()) log.debug("This message is associated with sequence entry: " + entry);
    if(entry != null && entry.isRmSource()) {
      rmdBean.setOutboundInternalSequence(entry.getSequenceId());
    }

    rmdBean.setServerCompletedMessages(new RangeString());
   
    rmdBean.setReplyToEndpointReference(to);
    rmdBean.setAcksToEndpointReference(acksTo);

    // If no replyTo value. Send responses as sync.
    if (replyTo != null)
      rmdBean.setToEndpointReference(replyTo);

    // Store the security token alongside the sequence
    if(token != null) {
      String tokenData = securityManager.getTokenRecoveryData(token);
      rmdBean.setSecurityTokenData(tokenData);
    }   
   
    rmdBean.setSequenceID(SandeshaUtil.getUUID());
    rmdBean.setNextMsgNoToProcess(1);
   
    rmdBean.setToAddress(to.getAddress());
   
    // If this sequence has a 'To' address that is anonymous then we must have got the
    // message as a response to a poll. We need to make sure that we keep polling until
    // the sequence is closed.
    if(to.hasAnonymousAddress()) {
      String newKey = SandeshaUtil.getUUID();
      rmdBean.setPollingMode(true);
      rmdBean.setReferenceMessageKey(newKey);
      storageManager.storeMessageContext(newKey, createSeqContext);
    }

    String messageRMNamespace = createSequence.getNamespaceValue();

    String specVersion = null;
    if (Sandesha2Constants.SPEC_2005_02.NS_URI.equals(messageRMNamespace)) {
      specVersion = Sandesha2Constants.SPEC_VERSIONS.v1_0;
    } else if (Sandesha2Constants.SPEC_2007_02.NS_URI.equals(messageRMNamespace)) {
View Full Code Here

Examples of org.apache.sandesha2.wsrm.CreateSequence

    if (log.isDebugEnabled())
      log.debug("Enter: CreateSeqMsgProcessor::processInMessage");

    try {
     
      CreateSequence createSeqPart = createSeqRMMsg.getCreateSequence();
      if (createSeqPart == null) {
        if (log.isDebugEnabled())
          log.debug(SandeshaMessageHelper.getMessage(SandeshaMessageKeys.noCreateSeqParts));
        FaultManager.makeCreateSequenceRefusedFault(createSeqRMMsg, SandeshaMessageHelper.getMessage(SandeshaMessageKeys.noCreateSeqParts),
                                                    new Exception(), null);
        // Return false if an Exception hasn't been thrown.
        if (log.isDebugEnabled())
          log.debug("Exit: CreateSeqMsgProcessor::processInMessage " + Boolean.FALSE);       
        return false;

      }
 
      MessageContext createSeqMsg = createSeqRMMsg.getMessageContext();
      ConfigurationContext context = createSeqMsg.getConfigurationContext();
      StorageManager storageManager = SandeshaUtil.getSandeshaStorageManager(context, context.getAxisConfiguration());
     
      // If the inbound CreateSequence includes a SecurityTokenReference then
      // ask the security manager to resolve that to a token for us. We also
      // check that the Create was secured using the token.
      SecurityManager secManager = SandeshaUtil.getSecurityManager(context);
      OMElement theSTR = createSeqPart.getSecurityTokenReference();
      SecurityToken token = null;
      if(theSTR != null) {
        MessageContext msgcontext = createSeqRMMsg.getMessageContext();
        token = secManager.getSecurityToken(theSTR, msgcontext);
       
        // The create must be the body part of this message, so we check the
        // security of that element.
        OMElement body = msgcontext.getEnvelope().getBody();
        secManager.checkProofOfPossession(token, body, msgcontext);
      }
 
      //if toAddress is RMAnon we may need to terminate the request side sequence here.
      EndpointReference toEPR = createSeqMsg.getTo();
      if (toEPR.hasAnonymousAddress()) {
 
        RMSBean findBean = new RMSBean ();
        findBean.setReplyToEndpointReference(toEPR);
        findBean.setTerminationPauserForCS(true);
       
        //TODO recheck
        RMSBean rmsBean = storageManager.getRMSBeanMgr().findUnique(findBean);
        if (rmsBean!=null) {         
          //AckManager hs not done the termination. Do the termination here.
          MessageContext requestSideRefMessage = storageManager.retrieveMessageContext(rmsBean.getReferenceMessageStoreKey(),context);
          if (requestSideRefMessage==null) {
            FaultManager.makeCreateSequenceRefusedFault(createSeqRMMsg,
                SandeshaMessageHelper.getMessage(SandeshaMessageKeys.referencedMessageNotFound, rmsBean.getInternalSequenceID()),
                new Exception(), null);           
            // Return false if an Exception hasn't been thrown.
            if (log.isDebugEnabled())
              log.debug("Exit: CreateSeqMsgProcessor::processInMessage " + Boolean.FALSE);       
            return false;
          }
         
          RMMsgContext requestSideRefRMMessage = MsgInitializer.initializeMessage(requestSideRefMessage);
          TerminateManager.addTerminateSequenceMessage(requestSideRefRMMessage, rmsBean.getInternalSequenceID(), rmsBean.getSequenceID(), storageManager);
        }
      }

      MessageContext outMessage = null;
 
      // Create the new sequence id, as well as establishing the beans that handle the
      // sequence state.
      RMDBean rmdBean = SequenceManager.setupNewSequence(createSeqRMMsg, storageManager, secManager, token);
      if(rmdBean==null){
        // This did not work. Return false if an Exception hasn't been thrown.
        if (log.isDebugEnabled())
          log.debug("Exit: CreateSeqMsgProcessor::processInMessage " + Boolean.FALSE);       
        return false;
      }
       
      RMMsgContext createSeqResponse = RMMsgCreator.createCreateSeqResponseMsg(createSeqRMMsg, rmdBean);
      outMessage = createSeqResponse.getMessageContext();
      // Set a message ID for this Create Sequence Response message
      outMessage.setMessageID(SandeshaUtil.getUUID());
       
      createSeqResponse.setFlow(MessageContext.OUT_FLOW);
 
      // for making sure that this won't be processed again
      createSeqResponse.setProperty(Sandesha2Constants.APPLICATION_PROCESSING_DONE, "true");
     
      CreateSequenceResponse createSeqResPart = createSeqResponse.getCreateSequenceResponse();
 
      // OFFER PROCESSING
      SequenceOffer offer = createSeqPart.getSequenceOffer();
      if (offer != null) {
        Accept accept = createSeqResPart.getAccept();
        if (accept == null) {
          if (log.isDebugEnabled())
            log.debug(SandeshaMessageHelper.getMessage(SandeshaMessageKeys.noAcceptPart));
View Full Code Here

Examples of org.apache.sandesha2.wsrm.CreateSequence

    EndpointReference acksToEPR = rmsBean.getAcksToEndpointReference();
    if(acksToEPR == null){
      acksToEPR = new EndpointReference(SpecSpecificConstants.getAddressingAnonymousURI(addressingNamespace));
    }

    CreateSequence createSequencePart = new CreateSequence(rmNamespaceValue);

    // Check if this service includes 2-way operations
    boolean twoWayService = false;
    AxisService service = applicationMsgContext.getAxisService();
    if (service != null) {
      // if the user has specified this sequence as a one way sequence it should not
      // append the sequence offer.
      if (!JavaUtils.isTrue(applicationMsgContext.getOptions().getProperty(
        SandeshaClientConstants.ONE_WAY_SEQUENCE))) {
        Parameter p = service.getParameter(Sandesha2Constants.SERVICE_CONTAINS_OUT_IN_MEPS);
        if (p != null && p.getValue() != null) {
          twoWayService = ((Boolean) p.getValue()).booleanValue();
          if (log.isDebugEnabled()) log.debug("RMMsgCreator:: twoWayService " + twoWayService);
        }
      }
    }

    // Adding sequence offer - if present. We send an offer if the client has assigned an
    // id, or if the service contains out-in MEPs
    boolean autoOffer = twoWayService;

    //There may not have been a way to confirm if an OUT_IN MEP is being used.
    //Therefore doing an extra check to see what Axis is using.  If it's OUT_IN then we must offer.
    if(applicationMsgContext.getOperationContext() != null && applicationMsgContext.getOperationContext().getAxisOperation() != null){
      if(applicationMsgContext.getOperationContext().getAxisOperation().getAxisSpecificMEPConstant() == org.apache.axis2.wsdl.WSDLConstants.MEP_CONSTANT_OUT_IN
        || applicationMsgContext.getOperationContext().getAxisOperation().getAxisSpecificMEPConstant() == org.apache.axis2.wsdl.WSDLConstants.MEP_CONSTANT_OUT_OPTIONAL_IN){
        autoOffer = true;
      }
    }

    // We also do some checking at this point to see if MakeConection is required to
    // enable WS-RM 1.1, and write a warning to the log if it has been disabled.
    if(Sandesha2Constants.SPEC_2007_02.NS_URI.equals(rmNamespaceValue)) {
      SandeshaPolicyBean policy = SandeshaUtil.getPropertyBean(context.getAxisConfiguration());
      if(twoWayService && !policy.isEnableMakeConnection()) {
        String message = SandeshaMessageHelper.getMessage(SandeshaMessageKeys.makeConnectionWarning);
        log.warn(message);
      }
    }

    String offeredSequenceId = (String) applicationMsgContext.getProperty(SandeshaClientConstants.OFFERED_SEQUENCE_ID);
    if(autoOffer ||
       (offeredSequenceId != null && offeredSequenceId.length() > 0))  {
     
      if (offeredSequenceId == null || offeredSequenceId.length() == 0) {
        offeredSequenceId = SandeshaUtil.getUUID();
      }

      SequenceOffer offerPart = new SequenceOffer(rmNamespaceValue);
      Identifier identifier = new Identifier(rmNamespaceValue);
      identifier.setIndentifer(offeredSequenceId);
      offerPart.setIdentifier(identifier);
     
      if (Sandesha2Constants.SPEC_2007_02.NS_URI.equals(rmNamespaceValue)) {
        // We are going to send an offer, so decide which endpoint to include
        EndpointReference offeredEndpoint = (EndpointReference) applicationMsgContext.getProperty(SandeshaClientConstants.OFFERED_ENDPOINT);
        //If the offeredEndpoint hasn't been set then use the acksTo of the RMSBean
        if (offeredEndpoint==null) {
          offeredEndpoint = rmsBean.getAcksToEndpointReference();
        }
       
        Endpoint endpoint = new Endpoint (offeredEndpoint, rmNamespaceValue, addressingNamespace);
        offerPart.setEndpoint(endpoint);
      }
     
      createSequencePart.setSequenceOffer(offerPart);
    }

    EndpointReference toEPR = rmsBean.getToEndpointReference();
    if (toEPR == null || toEPR.getAddress()==null) {
      String message = SandeshaMessageHelper
          .getMessage(SandeshaMessageKeys.toBeanNotSet);
      throw new SandeshaException(message);
    }
    createSeqRMMsg.setTo(toEPR);
    if(log.isDebugEnabled()) log.debug("RMMsgCreator:: toEPR=" + toEPR);

    EndpointReference replyToEPR = rmsBean.getReplyToEndpointReference();
    if(replyToEPR != null) {
      replyToEPR = SandeshaUtil.getEPRDecorator(createSeqRMMsg.getConfigurationContext()).decorateEndpointReference(replyToEPR);
      createSeqRMMsg.setReplyTo(replyToEPR);
      if(log.isDebugEnabled()) log.debug("RMMsgCreator:: replyToEPR=" + replyToEPR);
    }
   

    AcksTo acksTo = new AcksTo(acksToEPR, rmNamespaceValue, addressingNamespace);
    createSequencePart.setAcksTo(acksTo);
    if(log.isDebugEnabled()) log.debug("RMMsgCreator:: acksTo=" + acksTo);
   
    createSeqRMMsg.setCreateSequence(createSequencePart);

    // Find the token that should be used to secure this new sequence. If there is a token, then we
    // save it in the properties so that the caller can store the token within the create sequence
    // bean.
    SecurityManager secMgr = SandeshaUtil.getSecurityManager(context);
    SecurityToken token = secMgr.getSecurityToken(applicationMsgContext);
    if(token != null) {
      OMElement str = secMgr.createSecurityTokenReference(token, createSeqmsgContext);
      createSequencePart.setSecurityTokenReference(str);
      createSeqRMMsg.setProperty(Sandesha2Constants.MessageContextProperties.SECURITY_TOKEN, token);
     
      // If we are using token based security, and the 1.1 spec level, then we
      // should introduce a UsesSequenceSTR header into the message.
      if(createSequencePart.getNamespaceValue().equals(Sandesha2Constants.SPEC_2007_02.NS_URI)) {
        UsesSequenceSTR usesSeqStr = new UsesSequenceSTR();
        usesSeqStr.toHeader(createSeqmsgContext.getEnvelope().getHeader());
      }

      // Ensure that the correct token will be used to secure the outbound create sequence message.
View Full Code Here

Examples of org.apache.sandesha2.wsrm.CreateSequence

        isSPEC2005_02 = SPEC_2005_02.NS_URI.equals(namespace);
      }

      if(isSPEC2005_02 || isSPEC2007_02){
        if(Sandesha2Constants.SPEC_2007_02.QNames.CreateSequence.equals(firstBodyQName)) {
          createSequence = new CreateSequence(namespace);
          createSequence.fromOMElement(body);
        } else if(Sandesha2Constants.SPEC_2005_02.QNames.CreateSequence.equals(firstBodyQName)) {
          createSequence = new CreateSequence(namespace);
          createSequence.fromOMElement(body);
        } else if(Sandesha2Constants.SPEC_2007_02.QNames.CreateSequenceResponse.equals(firstBodyQName)) {
          createSequenceResponse = new CreateSequenceResponse(namespace);
          createSequenceResponse.fromOMElement(body);
        } else if(Sandesha2Constants.SPEC_2005_02.QNames.CreateSequenceResponse.equals(firstBodyQName)) {
View Full Code Here

Examples of org.apache.sandesha2.wsrm.CreateSequence

        isSPEC2005_02 = SPEC_2005_02.NS_URI.equals(namespace);
      }

      if(isSPEC2005_02 || isSPEC2007_02){
        if(Sandesha2Constants.SPEC_2007_02.QNames.CreateSequence.equals(firstBodyQName)) {
          createSequence = new CreateSequence(namespace);
          createSequence.fromOMElement(body);
        } else if(Sandesha2Constants.SPEC_2005_02.QNames.CreateSequence.equals(firstBodyQName)) {
          createSequence = new CreateSequence(namespace);
          createSequence.fromOMElement(body);
        } else if(Sandesha2Constants.SPEC_2007_02.QNames.CreateSequenceResponse.equals(firstBodyQName)) {
          createSequenceResponse = new CreateSequenceResponse(namespace);
          createSequenceResponse.fromOMElement(body);
        } else if(Sandesha2Constants.SPEC_2005_02.QNames.CreateSequenceResponse.equals(firstBodyQName)) {
View Full Code Here

Examples of org.apache.sandesha2.wsrm.CreateSequence

    createSeqmsgContext.setTo(applicationRMMsg.getTo());
    createSeqmsgContext.setReplyTo(applicationRMMsg.getReplyTo());

    RMMsgContext createSeqRMMsg = new RMMsgContext(createSeqmsgContext);

    CreateSequence createSequencePart = new CreateSequence(factory);

    //Adding sequence offer - if present
    OperationContext operationcontext = applicationMsgContext
        .getOperationContext();
    if (operationcontext != null) {
      String offeredSequence = (String) applicationMsgContext
          .getProperty(Sandesha2ClientAPI.OFFERED_SEQUENCE_ID);
      if (offeredSequence != null && !"".equals(offeredSequence)) {
        SequenceOffer offerPart = new SequenceOffer(factory);
        Identifier identifier = new Identifier(factory);
        identifier.setIndentifer(offeredSequence);
        offerPart.setIdentifier(identifier);
        createSequencePart.setSequenceOffer(offerPart);
      }
    }

    SequencePropertyBean replyToBean = seqPropMgr.retrieve(internalSequenceId,
        Sandesha2Constants.SequenceProperties.REPLY_TO_EPR);
    SequencePropertyBean toBean = seqPropMgr.retrieve(internalSequenceId,
        Sandesha2Constants.SequenceProperties.TO_EPR);

    if (toBean == null || toBean.getValue() == null)
      throw new SandeshaException("To EPR is not set.");

    EndpointReference toEPR = (EndpointReference) toBean.getValue();
    EndpointReference replyToEPR = null;
    EndpointReference acksToEPR = null;

    if (acksTo == null || "".equals(acksTo))
      acksTo = Sandesha2Constants.WSA.NS_URI_ANONYMOUS;

    acksToEPR = new EndpointReference(acksTo);

    if (replyToBean != null && replyToBean.getValue() != null)
      replyToEPR = (EndpointReference) replyToBean.getValue();

    createSeqRMMsg.setTo(toEPR);

    //ReplyTo will be set only if not null.
    if (replyToEPR != null)
      createSeqRMMsg.setReplyTo(replyToEPR);

    createSequencePart.setAcksTo(new AcksTo(
        new Address(acksToEPR, factory), factory));

    createSeqRMMsg.setMessagePart(Sandesha2Constants.MessageParts.CREATE_SEQ,
        createSequencePart);
View Full Code Here

Examples of org.apache.sandesha2.wsrm.CreateSequence

    SOAPFactory factory = SOAPAbstractFactory.getSOAPFactory(SandeshaUtil
        .getSOAPVersion(createSeqMessage.getSOAPEnvelope()));

    IOMRMElement messagePart = createSeqMessage
        .getMessagePart(Sandesha2Constants.MessageParts.CREATE_SEQ);
    CreateSequence cs = (CreateSequence) messagePart;

    CreateSequenceResponse response = new CreateSequenceResponse(factory);

    Identifier identifier = new Identifier(factory);
    identifier.setIndentifer(newSequenceID);

    response.setIdentifier(identifier);

    SequenceOffer offer = cs.getSequenceOffer();
    if (offer != null) {
      String outSequenceId = offer.getIdentifer().getIdentifier();

      if (outSequenceId != null && !"".equals(outSequenceId)) {
View Full Code Here

Examples of org.apache.sandesha2.wsrm.CreateSequence

  public void processMessage(RMMsgContext createSeqRMMsg)
      throws SandeshaException {

    MessageContext createSeqMsg = createSeqRMMsg.getMessageContext();
    CreateSequence createSeqPart = (CreateSequence) createSeqRMMsg
        .getMessagePart(Sandesha2Constants.MessageParts.CREATE_SEQ);
    if (createSeqPart == null)
      throw new SandeshaException(
          "No create sequence part is present in the create sequence message");

    MessageContext outMessage = null;
    try {
      outMessage = Utils.createOutMessageContext(createSeqMsg);
    } catch (AxisFault e) {
      throw new SandeshaException(e.getMessage());
    }

    try {
      String newSequenceId = SequenceManager
          .setupNewSequence(createSeqRMMsg);
      ConfigurationContext context = createSeqRMMsg.getMessageContext()
          .getConfigurationContext();
      if (newSequenceId == null)
        throw new AxisFault(
            "Internal error - Generated sequence id is null");

      RMMsgContext createSeqResponse = RMMsgCreator
          .createCreateSeqResponseMsg(createSeqRMMsg, outMessage,
              newSequenceId);
      CreateSequenceResponse createSeqResPart = (CreateSequenceResponse) createSeqResponse
          .getMessagePart(Sandesha2Constants.MessageParts.CREATE_SEQ_RESPONSE);

      //If an offer is accepted do necessary procesing.
      Accept accept = createSeqResPart.getAccept();
      if (accept != null) {
        SequenceOffer offer = createSeqPart.getSequenceOffer();
        if (offer == null)
          throw new SandeshaException(
              "Internal error - no offer for the response message with Accept");

        //Setting the CreateSequence table entry.
        String incomingSeqId = createSeqResPart.getIdentifier()
            .getIdentifier();
        String outSequenceId = offer.getIdentifer().getIdentifier();
        CreateSeqBean createSeqBean = new CreateSeqBean();
        createSeqBean.setSequenceId(outSequenceId);
        createSeqBean.setInternalSequenceId(newSequenceId);
        createSeqBean.setCreateSeqMsgId(SandeshaUtil.getUUID()); //this
        // is a
        // dummy
        // value.

        StorageManager storageManager = SandeshaUtil
            .getSandeshaStorageManager(context);
        CreateSeqBeanMgr createSeqMgr = storageManager
            .getCreateSeqBeanMgr();

        //Setting sequence properties.
        SequencePropertyBeanMgr seqPropMgr = storageManager
            .getSequencePropretyBeanMgr();
        SequencePropertyBean outSequenceBean = new SequencePropertyBean();
        outSequenceBean
            .setName(Sandesha2Constants.SequenceProperties.OUT_SEQUENCE_ID);
        outSequenceBean.setValue(outSequenceId);
        outSequenceBean.setSequenceId(newSequenceId);
        seqPropMgr.insert(outSequenceBean);

        //Temp sequence id should be set for the server side.
        //If internal sequence id is not set. this implies server side.
        SequencePropertyBean internalSeqBean = seqPropMgr.retrieve(
            outSequenceId,
            Sandesha2Constants.SequenceProperties.INTERNAL_SEQUENCE_ID);
        if (internalSeqBean == null) {
          SequencePropertyBean internalSequenceBean = new SequencePropertyBean();
          internalSequenceBean
              .setName(Sandesha2Constants.SequenceProperties.INTERNAL_SEQUENCE_ID);
          internalSequenceBean.setSequenceId(outSequenceId);
          internalSequenceBean.setValue(newSequenceId);
          seqPropMgr.insert(internalSequenceBean);
        }

      }

      CreateSequence createSeq = (CreateSequence) createSeqRMMsg
          .getMessagePart(Sandesha2Constants.MessageParts.CREATE_SEQ);
      if (createSeq == null)
        throw new AxisFault(
            "Create sequence part not present in the create sequence message");

      EndpointReference acksTo = createSeq.getAcksTo().getAddress()
          .getEpr();
      if (acksTo == null || acksTo.getAddress() == null
          || acksTo.getAddress() == "")
        throw new AxisFault(
            "Acks to not present in the create sequence message");
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.