axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "XCV" <xcvisc...@gmail.com>
Subject Re: Re: [axis2]please help me with axis2 handler
Date Fri, 04 Jan 2008 10:23:24 GMT

>
>> OK,i got it! there is method: AxisEngine.resume(msgCtx), it's sound work well to
resume a suspended chain ,but when i stored the messageContext and suspend a handler chain
,then i invoke the method AxisEngine.resume(msgCtx),it seem's not work ? can anybody help
me ?thanks alot!!!
>>   
>Very good.
>What do you mean by it does not work ? did not it come to your handler ?
>
>-Deepal
>
dear Deepal:

thanks a lot for reply!please let me paste my plane code in my handler :


	private int count = 0;
	private MessageContext theSuspendedMessageCtx=null;
    
	public InvocationResponse invoke(MessageContext msgContext)
			throws AxisFault {
		log.info(++count);
		if (count<2){
			theSuspendedMessageCtx=msgContext;
			theSuspendedMessageCtx.pause();
			return InvocationResponse.SUSPEND;
		}
		else {
			if (theSuspendedMessageCtx.isPaused()){
				AxisEngine.resume(theSuspendedMessageCtx);
			}
			return InvocationResponse.CONTINUE;
		}
	}
and it was put in my own userphase in InFlow ,and the whole axis2 has the only userphase with
the only user handler .

and what i want is :when the 1st request in ,just suspend it ;when the 2nd request in ,reply
it and resume the 1st .but the actual result is the 1st is suspend forever,the 2nd is replyed
.the log printed 1 , 2 and an unwanted 3 -that make me puzzled a lot. so i'm really looking
forward you help! thanks a lot !




---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Mime
View raw message