Package org.apache.sandesha2.client

Examples of org.apache.sandesha2.client.SandeshaListener


   
    MessageContext msgContext = rmMsgCtx.getMessageContext();
    ConfigurationContext configContext = msgContext .getConfigurationContext();
   
    //setting the Fault callback   
    SandeshaListener faultCallback = (SandeshaListener) msgContext.getOptions().getProperty(SandeshaClientConstants.SANDESHA_LISTENER);
    if (faultCallback!=null) {
      OperationContext operationContext = msgContext.getOperationContext();
      if (operationContext!=null) {
        operationContext.setProperty(SandeshaClientConstants.SANDESHA_LISTENER,faultCallback);
      }
View Full Code Here


  private void finalizeTimedOutSequence (String internalSequenceID, String sequenceID ,MessageContext messageContext) throws SandeshaException {
    ConfigurationContext configurationContext = messageContext.getConfigurationContext();
    SequenceReport report = SandeshaClient.getOutgoingSequenceReport(internalSequenceID ,configurationContext);
    TerminateManager.timeOutSendingSideSequence(configurationContext,internalSequenceID, false);
   
    SandeshaListener listener = (SandeshaListener) messageContext.getProperty(SandeshaClientConstants.SANDESHA_LISTENER);
    if (listener!=null) {
      listener.onTimeOut(report);
    }
  }
View Full Code Here

      log.debug("Enter: FaultManager::manageIncomingFault");
    InvocationResponse response = InvocationResponse.CONTINUE;
    if (log.isErrorEnabled())
      log.error(fault);
   
    SandeshaListener listner = (SandeshaListener) rmMsgCtx.getProperty(SandeshaClientConstants.SANDESHA_LISTENER);
    if (listner!=null)
      listner.onError(fault);
   
    // Get the SOAPVersion
    SOAPFactory factory = (SOAPFactory) rmMsgCtx.getSOAPEnvelope().getOMFactory();   
    String SOAPNamespaceValue = factory.getSoapVersionURI();
   
View Full Code Here

      log.debug("Enter: CreateSeqMsgProcessor::processOutMessage");

    MessageContext msgCtx = rmMsgCtx.getMessageContext();

    // 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);
View Full Code Here

    ConfigurationContext configContext = msgContext.getConfigurationContext();
   
    //Please note: no need to check that RM1.0 annon out-in has a sequence offer, since we actually force an offer in this case
   
    // setting the Fault callback
    SandeshaListener faultCallback = (SandeshaListener) msgContext.getOptions().getProperty(
        SandeshaClientConstants.SANDESHA_LISTENER);
    if (faultCallback != null) {
      OperationContext operationContext = msgContext.getOperationContext();
      if (operationContext != null) {
        operationContext.setProperty(SandeshaClientConstants.SANDESHA_LISTENER, faultCallback);
View Full Code Here

    // Already an active transaction, so don't want a new one
    TerminateManager.timeOutSendingSideSequence(internalSequenceID, storageManager);
   

    if (messageContext != null) {
      SandeshaListener listener = (SandeshaListener) messageContext
          .getProperty(SandeshaClientConstants.SANDESHA_LISTENER);
      if (listener != null) {
        SequenceReport report = SandeshaClient.getOutgoingSequenceReport(internalSequenceID, configurationContext, false);
        listener.onTimeOut(report);
      }
    }
    if (log.isDebugEnabled()) log.debug("Exit: SequenceManager::finalizeTimedOutSequence");
  }
View Full Code Here

    boolean returnValue = false;
   
    MessageContext msgCtx = rmMsgCtx.getMessageContext();

    // 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);
View Full Code Here

  private static void manageIncomingFault (AxisFault fault, MessageContext msgContext) {
 
    if (log.isErrorEnabled())
      log.error(fault);
   
    SandeshaListener listner = (SandeshaListener) msgContext.getProperty(SandeshaClientConstants.SANDESHA_LISTENER);
    if (listner!=null)
      listner.onError(fault);
   
  }
View Full Code Here

    MessageContext msgContext = rmMsgCtx.getMessageContext();
    ConfigurationContext configContext = msgContext.getConfigurationContext();

    // setting the Fault callback
    SandeshaListener faultCallback = (SandeshaListener) msgContext.getOptions().getProperty(
        SandeshaClientConstants.SANDESHA_LISTENER);
    if (faultCallback != null) {
      OperationContext operationContext = msgContext.getOperationContext();
      if (operationContext != null) {
        operationContext.setProperty(SandeshaClientConstants.SANDESHA_LISTENER, faultCallback);
View Full Code Here

    while(System.currentTimeMillis() < limit) {
      Thread.sleep(tickTime); // Try the assertions each tick interval, until they pass or we time out
     
      try {
            //assertions for the out sequence.
        SequenceReport sequenceReport = SandeshaClient.getOutgoingSequenceReport(serviceClient);
        assertEquals(sequenceReport.getSequenceStatus(),SequenceReport.SEQUENCE_STATUS_TERMINATED);
        assertEquals(sequenceReport.getSequenceDirection(),SequenceReport.SEQUENCE_DIRECTION_OUT);
       
        assertTrue(callback1.isErrorReported());
        assertEquals(callback1.getResult(),null);
       
        lastError = null;
View Full Code Here

TOP

Related Classes of org.apache.sandesha2.client.SandeshaListener

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.