axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hughes, Stan" <Thomas.Hug...@nov.com>
Subject RE: Forwarding a web service call...
Date Mon, 04 Sep 2006 14:46:25 GMT
Martin,

 

Thanks for your response, but to be perfectly honest, I didn't
understand a single word of that... I guess I am still a newbie....

 

I am not actually using any of the Axis api for the things I have done
thus far, so, digging into the servlet and such are a little beyond me.

 

Is there not any way I can use a proxy (client) to another system to do
what I want? I was thinking I could go through and change package names
and such to differentiate the client from the actual (server side)
implementation, but, I found this to be fairly difficult as well - not
that I mind difficult. I just need to know what actually works.

 

Thanks again,

 

Stan

 

________________________________

From: Martin Gainty [mailto:mgainty@hotmail.com] 
Sent: Saturday, September 02, 2006 9:19 AM
To: axis-user@ws.apache.org
Subject: Re: Forwarding a web service call...

 

Good Morning Stan--


Far from it ..You're NOT mentally challenged at all..You're asking a
valid question which SHOULD be asked!
As forwarding a response is a challenge I found earlier this week.. I
countered the error by creating a few mutator methods in MessageContext
notably

msgContext.setResponse and msgContext.setRequest to be set from within
AxisServlet as soon (as the msgContext object is acquired)
Later in in your <WebService>Manager Stub class when you acquire the
msgContext object 
you will be able to re-acquire the original response and request objects
via MessageContext accessor methods-
BTW When I originally posted this same question I did get a response
from dims (Apache committer) as well as Luis (from IEEE)

 

I hope this helps your efforts-
Martin--

*********************************************************************
This email message and any files transmitted with it contain
confidential
information intended only for the person(s) to whom this email message
is
addressed.  If you have received this email message in error, please
notify
the sender immediately by telephone or email and destroy the original
message without making a copy.  Thank you.

 


 

	----- Original Message ----- 

	From: Hughes, Stan <mailto:Thomas.Hughes@nov.com>  

	To: axis-user@ws.apache.org 

	Sent: Thursday, August 31, 2006 9:25 PM

	Subject: Forwarding a web service call...

	 

	All,

	 

	I am using axis to run the same set of web services on several
different servers. 

	 

	One of the methods is called "getItem". I am not sure if this
makes sense or not, but, here goes.

	 

	If I call getItem on one server and the item does not exist in
that database, I want the call to be "forwarded" to the next server in
the chain. I tried creating a proxy class and changing the endpoint and
passing the parameters to the next server, but this does not work...

	 

	Here is some sample code:

	 

	<pre>

	public ItemInfo getItem(CredentialsInfo credentials,String
itemId) {

	 

	...

	 

	    "get the item from the current database"

	    If (theItem == null) {

	         CETGServicesProxy proxy = new CETGServicesProxy();

	
proxy.setEndpoint("http://nextserver.com/cetgws/services/CETGServices");

	         ItemInfo item = proxy.getItem(credentials,itemId);

	         return item;

	   }

	...

	</pre>

	 

	Is this possible, or, am I just being mentally challenged?

	 

	Thanks for any help...

	 


Mime
View raw message