I think the point is to switch the configuration to deployment time. I 
sugest three simple approaches.

a) For apache httpd users (an Apache web server acts as front-end to the 
axis java application): use mod_env to define an environment variable to 
be passed to the web appliation.

b) If your operations team is used to JNDI: create an entry to define 
the service base URI. Most servlet containers allow you to define this 
in web.xml and to override it in the container JNDI directory.

c) Run-time detection: the HttpRequest object may be used to determine 
the service uri. This is highly dependent on the tools available and 
will not be handled automatically by Axis (it hides the servlet context 
from your jws.)

*Saran

Steven Gollery wrote:
> Is there any way for a web service to discover, build, or calculate the 
> url that was used to call it?
> 
> In my system, I need to have one web service send its url and an 
> operation name to another web service. Is there enough information 
> available to a web service, during an invocation of one of its 
> operations, to let the service figure out how it was called?
> 
> Another possibility would be to have that string in a system property 
> somehow. Is there one of the Axis  or Tomcat config files that would let 
> me set system properties that would be available to a web service?
> 
> I've also considered putting this information in a property file, but I 
> haven't been able to find a place to put the file that is on the class 
> path of the running web service, even though I've tried it in every 
> directory under the Axis root. Also, the property file idea just moves 
> the "what url?" question from run-time to deployment time.
> 
> Hopefully this looks more complicated to me than it really is, and 
> someone can think of a way to manage this. Or another idea for how to 
> arrange one web service to tell another one how to call back.
> 
> Thanks,
> 
> Steven Gollery
> [EMAIL PROTECTED]
> 
> 
> 
> 


Reply via email to