不同的web services框架分别提供了不同的方法让你在服务代码中取httpservlet信息,不过你要找资料,太麻烦,通用的办法可以看我的blog:
http://blog.csdn.net/peihexian/archive/2006/04/21/671437.aspx思路就是写个filter,通过filter就可以得到request等信息了。