Does anybody know how can I access the context path (rooth path) of a web service? I am looking for something equivalent to what you would do in a servlet: "getServletContext().getRealPath("/WEB-INF/xxxdirectory")". Thanks, Miki
Koskela, I think I was not clear enough. I want to retrieve the context path (root path) from the web service itself, where this is running (for e.g. for making use of the I/O file system for different resources allocation). So not from the client. In other word how can I read from/create files from the web service from a subdirectory of the WEB-INF for e.g. I this is what you understood initially what does this have to do with SOAP messages transmitted over HTTP ? Miki
Joined: Jan 23, 2002
Ok. I thought you meant context path as in "the concept defined in the Java Servlet specification", which means "http://host ort/myapp/mywebapp" etc... Still, I believe there is no standard way of doing this.
Joined: Jun 23, 2003
Sorry, I've ment the root path of the application (web service). However it feels very strange there is not way to retrieve that. It seems to me very basic. Otherwise I'll just put it in a property file and change it each time the aaplication is deployed in a different location. But this is what I wanted to avoid. Ok, thanks anyway. Miki