Re: Logging problem SOAP based web service
On Fri, Aug 20, 2004 at 02:02:03PM +0300, [EMAIL PROTECTED] wrote: : What are Filters and how they can be used? Google "servlet filter" -- it's available in servlet spec 2.3 and later. Essentially, you can set up a series of these filters to wrap a call to your webapp, based on URI path or file extension. Each filter is called in turn (both for request and response). You can use them to check for things in the request/session/etc and short-circuit the process if something goes awry. :In the below is the simplified example request and what we would like to log is command and user from the request + IP address of the client => bind the request to requestor's IP Address. I missed your original post, but if you're trying to get to the client IP from within the deployed web service -and- using Axis, it's possible. I just dug this out recently myself. Start with MessageContext#getCurrentContext() find the session, cast it to an AxisSession, and get the wrapped HttpSession object out of that. It's a little buried. =) -QM -- software -- http://www.brandxdev.net tech news -- http://www.RoarNetworX.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Logging problem SOAP based web service
Hi, What are Filters and how they can be used? In the below is the simplified example request and what we would like to log is command and user from the request + IP address of the client => bind the request to requestor's IP Address. Can the logging be done by Tomcat? Can we get IP address somehow to our implementation that processes the request, or is there some other way to bind required information into one log-file? http://schemas.xmlsoap.org/soap/envelope/";> thanks, -Timo > -Original Message- > From: ext Tim Funk [mailto:[EMAIL PROTECTED] > Sent: 18 August, 2004 13:46 > To: Tomcat Users List > Subject: Re: Logging problem SOAP based web service > > > You might need to use a Filter to stuff the things you need > to log into the > ServletRequest. Then you can use this: > > http://marc.theaimsgroup.com/?l=tomcat-user&m=109273888725607&w=2 > > -Tim > > [EMAIL PROTECTED] wrote: > > > Hi, > > > > I have a SOAP based web service running on tomcat 4.1.30. > This service should write a log containing client's IP > address and some attributes from SOAP-message body (inside > SOAP envelope). Is this possible somehow? > > > > I suppose Tomcat's access logs cannot read attributes from > SOAP envelope and web service's implementation responding to > request does not know the IP address of the client > (parameters to ws implementation contain Envelope env, > SOAPContext reqCtx, SOAPContext resCtx). Any ideas? > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Logging problem SOAP based web service
On Wed, Aug 18, 2004 at 11:46:19AM +0300, [EMAIL PROTECTED] wrote: : I have a SOAP based web service running on tomcat 4.1.30. This service should : write a log containing client's IP address and some attributes from : SOAP-message body (inside SOAP envelope). Is this possible somehow? What's your SOAP engine? I recall Apache Axis supports "handlers" that wrap a request. Is the IP address available from the MessageContext or one of its member vars? -QM -- software -- http://www.brandxdev.net tech news -- http://www.RoarNetworX.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Logging problem SOAP based web service
You might need to use a Filter to stuff the things you need to log into the ServletRequest. Then you can use this: http://marc.theaimsgroup.com/?l=tomcat-user&m=109273888725607&w=2 -Tim [EMAIL PROTECTED] wrote: Hi, I have a SOAP based web service running on tomcat 4.1.30. This service should write a log containing client's IP address and some attributes from SOAP-message body (inside SOAP envelope). Is this possible somehow? I suppose Tomcat's access logs cannot read attributes from SOAP envelope and web service's implementation responding to request does not know the IP address of the client (parameters to ws implementation contain Envelope env, SOAPContext reqCtx, SOAPContext resCtx). Any ideas? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Logging problem SOAP based web service
Hi, I have a SOAP based web service running on tomcat 4.1.30. This service should write a log containing client's IP address and some attributes from SOAP-message body (inside SOAP envelope). Is this possible somehow? I suppose Tomcat's access logs cannot read attributes from SOAP envelope and web service's implementation responding to request does not know the IP address of the client (parameters to ws implementation contain Envelope env, SOAPContext reqCtx, SOAPContext resCtx). Any ideas? br, Timo - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]