You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Alphonsus <am...@uol.com.br> on 2002/09/26 20:09:36 UTC

HTTP status 500 on a SOAP call

    Hi guys,
    I'm sort of new to Java Environment and doing my best to catch up.
Things were going pretty well until I got stuck with this problem:

    I registered a service and when I call it I get back the message below.
I've checked the router using the browser and it gives me the answer the
tutorial says it should. I've done some searching and gone through some
suggestions but it didn't work.

    Hope someone can help.

    TIA,
    Alphonsus.

Caught SOAPException (SOAP-ENV:Protocol):Unsupported response content type
"text/html", must be: "text/xml". Response was:
<html><head><title>Apache Tomcat/4.0.1 - Error
report</title><STYLE><!--H1{font-family : sans-serif,Arial,Tahoma;color :
white;background-color : #0086b2;} BODY{font-family :
sans-serif,Arial,Tahoma;color : black;background-color : white;} B{color :
white;background-color : #0086b2;} HR{color : #0086b2;} --></STYLE>
</head><body><h1>Apache Tomcat/4.0.1 - HTTP Status 500 - Internal Server
Error</h1><HR size="1" noshade><p><b>type</b> Exception
report</p><p><b>message</b> <u>Internal Server
Error</u></p><p><b>description</b> <u>The server encountered an internal
error (Internal Server Error) that prevented it from fulfilling this
request.</u></p><p><b>exception</b> <pre>javax.servlet.ServletException:
Error building response envelope: java.lang.NullPointerException

 at
org.apache.soap.server.http.RPCRouterServlet.doPost(RPCRouterServlet.java:35
3)

 at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)

 at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)




--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: HTTP status 500 on a SOAP call

Posted by Alphonsus <am...@uol.com.br>.

> you've got a NullPointerException at line 35 of RPCRouterServlet. Have a
> look at javadoc or java source for that class. Your request is probably
not
> passing some parameter the servlet requires (as a best guess). Tomcat
> returns an html error report and the soap client is expecting a response
> with a mime type text/xml.
>
> Jon
>
> Error building response envelope: java.lang.NullPointerException
>
>  at
>
org.apache.soap.server.http.RPCRouterServlet.doPost(RPCRouterServlet.java:35
> 3)
>
>  at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
>
>  at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
>
    Thanks for your answer Jon. The registered class couldn't be more simple
(see below).

package javasoap.book.ch4;

/**
 * <p>Title: </p>
 * <p>Description: </p>
 * <p>Copyright: Copyright (c) 2002</p>
 * <p>Company: </p>
 * @author unascribed
 * @version 1.0
 */

public class MethodCounter {
   int _counter;
   public MethodCounter()
   {
      _counter = 0;
   }
   public int getCount()
   {
      return _counter;
   }

   public boolean doSomething()
   {
      _counter += 1;
      return true;
   }
}





--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: HTTP status 500 on a SOAP call

Posted by jon wingfield <jo...@mkodo.com>.
you've got a NullPointerException at line 35 of RPCRouterServlet. Have a
look at javadoc or java source for that class. Your request is probably not
passing some parameter the servlet requires (as a best guess). Tomcat
returns an html error report and the soap client is expecting a response
with a mime type text/xml.

Jon

-----Original Message-----
From: Alphonsus [mailto:amatec@uol.com.br]
Sent: 26 September 2002 19:10
To: 'Tomcat Users List'
Subject: HTTP status 500 on a SOAP call


    Hi guys,
    I'm sort of new to Java Environment and doing my best to catch up.
Things were going pretty well until I got stuck with this problem:

    I registered a service and when I call it I get back the message below.
I've checked the router using the browser and it gives me the answer the
tutorial says it should. I've done some searching and gone through some
suggestions but it didn't work.

    Hope someone can help.

    TIA,
    Alphonsus.

Caught SOAPException (SOAP-ENV:Protocol):Unsupported response content type
"text/html", must be: "text/xml". Response was:
<html><head><title>Apache Tomcat/4.0.1 - Error
report</title><STYLE><!--H1{font-family : sans-serif,Arial,Tahoma;color :
white;background-color : #0086b2;} BODY{font-family :
sans-serif,Arial,Tahoma;color : black;background-color : white;} B{color :
white;background-color : #0086b2;} HR{color : #0086b2;} --></STYLE>
</head><body><h1>Apache Tomcat/4.0.1 - HTTP Status 500 - Internal Server
Error</h1><HR size="1" noshade><p><b>type</b> Exception
report</p><p><b>message</b> <u>Internal Server
Error</u></p><p><b>description</b> <u>The server encountered an internal
error (Internal Server Error) that prevented it from fulfilling this
request.</u></p><p><b>exception</b> <pre>javax.servlet.ServletException:
Error building response envelope: java.lang.NullPointerException

 at
org.apache.soap.server.http.RPCRouterServlet.doPost(RPCRouterServlet.java:35
3)

 at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)

 at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)




--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>