List Info

Thread: cookies and apache xml-rpc client




cookies and apache xml-rpc client
user name
2006-02-02 09:44:38
I'm running Tomcat 5.5.12 with a very simple web app that
handles
xml-rpc requests from within a servlet.  I use the apache
XmlRpcClient
class to make the request (try/catches removed):

url = new URL("http://lo
calhost:8084/WebServer/Login");
xmlrpc = new XmlRpcClient (url);
XmlRpcRequest req = new
XmlRpcRequest("Login.Login", params);
Integer result = (Integer) xmlrpc.execute (req);

In my servlet, I call request.getSession(), process the
xml-rpc call,
then return the correct value.

When I make the request again, I expected the following code
in my
servlet to get triggered before processing the xml-rpc call:

if(null==request.getSession(false))
    return;

But, it instead processes my Login again.  So, the cookie
either isn't
being sent back to the XmlRpcClient, or the Client isn't
sending it with
the next request. and I have a feeling its the latter.  What
do I need
to do to get the XmlRpcClient to work with cookies?

Thanks
Brian
[1]

about | contact  Other archives ( Real Estate discussion Medical topics )