You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-user@ws.apache.org by Prashant Jain <Pr...@mchp.siemens.de> on 2001/08/03 12:36:55 UTC

java.net.SocketException: Connection aborted by peer

Hi,

I have created a simple servlet called LoginServlet where I want to
extract some data from the incoming SOAP request and then forward the
request to the rpcrouter servlet. On the server side I don't seem to get
any errors but on the client side, I get the following exception:

[SOAPException: faultCode=SOAP-ENV:Client; msg=Connection aborted by
peer: JVM_recv in socket input stream read;
targetException=java.net.SocketException: Connection aborted by peer:
JVM_recv in socket input stream read]
        at
org.apache.soap.transport.http.SOAPHTTPConnection.send(SOAPHTTPConnectio
n.java:328)
        at org.apache.soap.rpc.Call.invoke(Call.java:205)
        ...

When I remove my LoginServlet and the request goes directly to
rpcrouter, everything works fine. I did not change anything on my client
side except for the URL that is invoked by the Call object. I changed
that from rpcrouter to that of my servlet. The only thing that I am
doing in LoginServlet is the following:

public void doPost (HttpServletRequest req, HttpServletResponse res)
    throws ServletException, IOException {
    ServletConfig config = getServletConfig();
    ServletContext context = config.getServletContext ();
    RequestDispatcher dispatcher =
context.getRequestDispatcher("/rpcrouter");
    if (dispatcher != null) {
     try {
         dispatcher.forward (req, res);
         } catch (Exception e) {
             e.printStackTrace ();
         }
      }
  }

I tried both dispatcher.forward() as well as dispatcher.include() and
got the same problem.

I searched the archives and found some others having reported a similar
problem. However, I could not find any solution posted. Is there
something that I am doing wrong or missing?

Thanks,

- Prashant