Package org.apache.axis2.context

Examples of org.apache.axis2.context.OperationContext


      secManager.checkProofOfPossession(token, seqHeader, msgCtx);
      secManager.checkProofOfPossession(token, body, msgCtx);
    }
   
    // Store the inbound sequence id, number and lastMessage onto the operation context
    OperationContext opCtx = msgCtx.getOperationContext();
    if(opCtx != null) {
      opCtx.setProperty(Sandesha2Constants.MessageContextProperties.INBOUND_SEQUENCE_ID, sequenceId);
      opCtx.setProperty(Sandesha2Constants.MessageContextProperties.INBOUND_MESSAGE_NUMBER, new Long(msgNo));
      if(lastMessage) opCtx.setProperty(Sandesha2Constants.MessageContextProperties.INBOUND_LAST_MESSAGE, Boolean.TRUE);
    }
   
    // setting acked msg no range
    ConfigurationContext configCtx = rmMsgCtx.getMessageContext().getConfigurationContext();
    if (configCtx == null) {
View Full Code Here


      makeConnectionRMMessage.getMessageContext().setServerSide(false);
     
      // Store properties so that we know which sequence we are polling for. This can be used
      // to match reply sequences up to requests, as well as to help process messagePending
      // headers.
      OperationContext ctx = makeConnectionRMMessage.getMessageContext().getOperationContext();
      ctx.setProperty(Sandesha2Constants.MessageContextProperties.MAKECONNECTION_ENTRY, entry);
     
      makeConnectionRMMessage.setProperty(MessageContext.TRANSPORT_IN,null);
      //storing the MakeConnection message.
      String makeConnectionMsgStoreKey = SandeshaUtil.getUUID();
     
View Full Code Here

    // adding the SANDESHA_LISTENER
    SandeshaListener faultCallback = (SandeshaListener) msgCtx.getOptions().getProperty(
        SandeshaClientConstants.SANDESHA_LISTENER);
    if (faultCallback != null) {
      OperationContext operationContext = msgCtx.getOperationContext();
      if (operationContext != null) {
        operationContext.setProperty(SandeshaClientConstants.SANDESHA_LISTENER, faultCallback);
      }
    }
    if (log.isDebugEnabled())
      log.debug("Exit: CreateSeqMsgProcessor::processOutMessage " + Boolean.FALSE);
    return false;
View Full Code Here

     
      //set the LastMessageAction and the property
      if (outMessageContext.getOptions()==null)
        outMessageContext.setOptions(new Options ());
     
      OperationContext operationContext = outMessageContext.getOperationContext();
      String inboundSequenceId = (String) msgContext.getProperty(Sandesha2Constants.MessageContextProperties.INBOUND_SEQUENCE_ID);
      operationContext.setProperty(Sandesha2Constants.MessageContextProperties.INBOUND_SEQUENCE_ID,
          inboundSequenceId);
     
      Long inboundMSgNo = (Long) msgContext.getProperty(Sandesha2Constants.MessageContextProperties.INBOUND_MESSAGE_NUMBER);
      operationContext.setProperty(Sandesha2Constants.MessageContextProperties.INBOUND_MESSAGE_NUMBER,
          inboundMSgNo);
     
      outMessageContext.getOptions().setAction(Sandesha2Constants.SPEC_2005_02.Actions.ACTION_LAST_MESSAGE);

      //says that the inbound msg of this was a LastMessage - so the new msg will also be a LastMessage
View Full Code Here

        rmMsgCtx.getRMSpecVersion(),
        rmMsgCtx.getMessageContext().getAxisService());
    getMsgContext().setAxisOperation(closeOperation);


    OperationContext opcontext = ContextFactory.createOperationContext(closeOperation, getMsgContext().getServiceContext());
    opcontext.setParent(getMsgContext().getServiceContext());

    getConfigurationContext().registerOperationContext(rmMsgCtx.getMessageId(),opcontext);
    getMsgContext().setOperationContext(opcontext);
   
    CloseSequence closeSequencePart = (CloseSequence) rmMsgCtx
View Full Code Here

        // it's still there waiting.
        MessageContext msgCtx = manager.retrieveMessageContext(bean.getMessageContextRefKey(), context);

        RequestResponseTransport t = null;
        MessageContext inMsg = null;
        OperationContext op = msgCtx.getOperationContext();
        if (op != null)
          inMsg = op.getMessageContext(WSDLConstants.MESSAGE_LABEL_IN_VALUE);
        if (inMsg != null)
          t = (RequestResponseTransport) inMsg.getProperty(RequestResponseTransport.TRANSPORT_CONTROL);
 
        if((t != null || !t.getStatus().equals(RequestResponseTransportStatus.WAITING))) {
          if(log.isWarnEnabled()) {
View Full Code Here

    AxisOperation terminateOp = SpecSpecificConstants.getWSRMOperation(
        Sandesha2Constants.MessageTypes.TERMINATE_SEQ,
        rmMsgCtx.getRMSpecVersion(),
        getMsgContext().getAxisService());
 
    OperationContext opcontext = ContextFactory.createOperationContext(terminateOp, getMsgContext().getServiceContext());
    opcontext.setParent(getMsgContext().getServiceContext());

    getConfigurationContext().registerOperationContext(rmMsgCtx.getMessageId(),  opcontext);

    getMsgContext().setOperationContext(opcontext);
    getMsgContext().setAxisOperation(terminateOp);
View Full Code Here

          ByteArrayInputStream stream = new ByteArrayInputStream(entry.data);
          ObjectInputStream is = new ObjectInputStream(stream);
          messageContext = (MessageContext) is.readObject();
          messageContext.activate(entry.context);

          OperationContext opCtx = messageContext.getOperationContext();
          if(opCtx != null) {
            MessageContext inMsgCtx = opCtx.getMessageContext(WSDLConstants.MESSAGE_LABEL_IN_VALUE);
            if(inMsgCtx != null) {
              inMsgCtx.setProperty(RequestResponseTransport.TRANSPORT_CONTROL, entry.inTransportControl);
              inMsgCtx.setProperty(MessageContext.TRANSPORT_OUT,               entry.inTransportOut);
              inMsgCtx.setProperty(Constants.OUT_TRANSPORT_INFO,               entry.inTransportOutInfo);
            }
View Full Code Here

       
        SerializedStorageEntry entry = new SerializedStorageEntry();
        entry.data = stream.toByteArray();
        entry.context = msgContext.getConfigurationContext();
       
        OperationContext opCtx = msgContext.getOperationContext();
        if(opCtx != null) {
          MessageContext inMsgCtx = opCtx.getMessageContext(WSDLConstants.MESSAGE_LABEL_IN_VALUE);
          if(inMsgCtx != null) {
            entry.inTransportControl = inMsgCtx.getProperty(RequestResponseTransport.TRANSPORT_CONTROL);
            entry.inTransportOut     = inMsgCtx.getProperty(MessageContext.TRANSPORT_OUT);
            entry.inTransportOutInfo = inMsgCtx.getProperty(Constants.OUT_TRANSPORT_INFO);
          }
View Full Code Here

    String createSeqMsgId = null;
    if (relatesTo != null) {
      createSeqMsgId = relatesTo.getValue();
    } else {
      // Work out the related message from the operation context
      OperationContext context = rmMsgCtx.getMessageContext().getOperationContext();
      MessageContext createSeq = context.getMessageContext(WSDLConstants.MESSAGE_LABEL_OUT_VALUE);
      if(createSeq != null) createSeqMsgId = createSeq.getMessageID();
    }
    if(createSeqMsgId == null) {
      String message = SandeshaMessageHelper.getMessage(SandeshaMessageKeys.relatesToNotAvailable);
      log.error(message);
View Full Code Here

TOP

Related Classes of org.apache.axis2.context.OperationContext

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.