Examples of OperationContext


Examples of org.apache.axis2.context.OperationContext

      newMessageContext.setAxisOperation(operation);

      //The message created will basically be used as a outMessage, so setting the AxisMessage accordingly
      newMessageContext.setAxisMessage(operation.getMessage(WSDLConstants.MESSAGE_LABEL_OUT_VALUE));
     
      OperationContext operationContext = new OperationContext(operation, newMessageContext.getServiceContext());
      newMessageContext.setOperationContext(operationContext);
      operationContext.addMessageContext(newMessageContext);

      // adding a blank envelope
      SOAPFactory factory = SOAPAbstractFactory.getSOAPFactory(SandeshaUtil.getSOAPVersion(referenceMessage
          .getEnvelope()));
      newMessageContext.setEnvelope(factory.getDefaultEnvelope());
View Full Code Here

Examples of org.apache.axis2.context.OperationContext

        }
      }
    }
   
    Parameter propertiesFromRefReqMsg = axisModule.getParameter(Sandesha2Constants.propertiesToCopyFromReferenceRequestMessage);
    OperationContext referenceOpCtx = fromMessage.getOperationContext();
    MessageContext referenceRequestMessage = null;
    if (referenceOpCtx!=null)
      referenceRequestMessage=referenceOpCtx.getMessageContext(WSDLConstants.MESSAGE_LABEL_IN_VALUE);
   
    if (propertiesFromRefReqMsg!=null && referenceRequestMessage!=null) {
      String value = (String) propertiesFromRefReqMsg.getValue();
      if (value!=null) {
        value = value.trim();
View Full Code Here

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

Examples of org.apache.axis2.context.OperationContext

      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

Examples of org.apache.axis2.context.OperationContext

    // 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

Examples of org.apache.axis2.context.OperationContext

     
      //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

Examples of org.apache.axis2.context.OperationContext

        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

Examples of org.apache.axis2.context.OperationContext

        // 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

Examples of org.apache.axis2.context.OperationContext

    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

Examples of org.apache.axis2.context.OperationContext

          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
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.