3 Replies Latest reply on Sep 8, 2011 4:27 AM by Richard Opalka

    JBoss JAX WS Exception (javax.xml.stream.XMLStreamException)

    pushpak1981 Novice

      Hi All,

       

      I have written a JAX WS web service (1.7.1) and deployed it into JBoss 5.1. When the client (Servlet) tries to call the web service some exception is printed on the JBoss console but the service is executed properly.

       

      Below is the Stack trace for the exception. Any hints will be highly appreciated.

       

      Thanks.

       

      20:48:53,986 SEVERE [http] caught throwable

      java.io.IOException

              at com.sun.xml.ws.server.SDDocumentImpl.writeTo(SDDocumentImpl.java:278)

              at com.sun.xml.ws.transport.http.HttpAdapter.publishWSDL(HttpAdapter.java:539)

              at com.sun.xml.ws.transport.http.HttpAdapter.handle(HttpAdapter.java:229)

              at com.sun.xml.ws.transport.http.servlet.ServletAdapter.handle(ServletAdapter.java:135)

              at com.sun.xml.ws.transport.http.servlet.WSServletDelegate.doGet(WSServletDelegate.java:129)

              at com.sun.xml.ws.transport.http.servlet.WSServlet.doGet(WSServlet.java:82)

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

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

              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)

              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

              at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

              at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)

              at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)

              at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)

              at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)

              at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)

              at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)

              at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)

              at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)

              at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)

              at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

              at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)

              at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)

              at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)

              at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

              at java.lang.Thread.run(Thread.java:619)

      Caused by: javax.xml.stream.XMLStreamException

              at com.sun.xml.stream.writers.XMLStreamWriterImpl.close(XMLStreamWriterImpl.java:383)

              at com.sun.xml.ws.server.SDDocumentImpl.writeTo(SDDocumentImpl.java:276)

              ... 27 more

        • 2. Re: JBoss JAX WS Exception (javax.xml.stream.XMLStreamException)
          pushpak1981 Novice

          20:52:25,361 SEVERE [http] caught throwable

          java.io.IOException

                  at com.sun.xml.ws.server.SDDocumentImpl.writeTo(SDDocumentImpl.java:278)

                  at com.sun.xml.ws.transport.http.HttpAdapter.publishWSDL(HttpAdapter.java:539)

                  at com.sun.xml.ws.transport.http.HttpAdapter.handle(HttpAdapter.java:229)

                  at com.sun.xml.ws.transport.http.servlet.ServletAdapter.handle(ServletAdapter.java:135)

                  at com.sun.xml.ws.transport.http.servlet.WSServletDelegate.doGet(WSServletDelegate.java:129)

                  at com.sun.xml.ws.transport.http.servlet.WSServlet.doGet(WSServlet.java:82)

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

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

                  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)

                  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

                  at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

                  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

                  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

                  at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)

                  at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)

                  at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)

                  at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)

                  at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)

                  at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)

                  at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)

                  at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)

                  at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)

                  at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

                  at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)

                  at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)

                  at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)

                  at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

                  at java.lang.Thread.run(Thread.java:619)

          Caused by: com.sun.xml.stream.XMLStreamException2

                  at com.sun.xml.stream.writers.XMLStreamWriterImpl.close(XMLStreamWriterImpl.java:406)

                  at com.sun.xml.ws.server.SDDocumentImpl.writeTo(SDDocumentImpl.java:276)

                  ... 27 more

          Caused by: ClientAbortException:  java.net.SocketException: Connection reset by peer: socket write error

                  at org.apache.catalina.connector.OutputBuffer.doFlush(OutputBuffer.java:348)

                  at org.apache.catalina.connector.OutputBuffer.flush(OutputBuffer.java:314)

                  at org.apache.catalina.connector.CoyoteOutputStream.flush(CoyoteOutputStream.java:98)

                  at com.sun.xml.stream.writers.UTF8OutputStreamWriter.flush(UTF8OutputStreamWriter.java:153)

                  at com.sun.xml.stream.writers.XMLStreamWriterImpl.close(XMLStreamWriterImpl.java:404)

                  ... 28 more

          Caused by: java.net.SocketException: Connection reset by peer: socket write error

                  at java.net.SocketOutputStream.socketWrite0(Native Method)

                  at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92)

                  at java.net.SocketOutputStream.write(SocketOutputStream.java:136)

                  at org.apache.coyote.http11.InternalOutputBuffer.realWriteBytes(InternalOutputBuffer.java:724)

                  at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:449)

                  at org.apache.coyote.http11.InternalOutputBuffer.flush(InternalOutputBuffer.java:299)

                  at org.apache.coyote.http11.Http11Processor.action(Http11Processor.java:950)

                  at org.apache.coyote.Response.action(Response.java:186)

                  at org.apache.catalina.connector.OutputBuffer.doFlush(OutputBuffer.java:343)

                  ... 32 more

          • 3. Re: JBoss JAX WS Exception (javax.xml.stream.XMLStreamException)
            Richard Opalka Master

            Hi,

             

               this part of stack trace indicates your doing something wrong

            ---

            java.io.IOException

                    at com.sun.xml.ws.server.SDDocumentImpl.writeTo(SDDocumentImpl.java:278)

                    at com.sun.xml.ws.transport.http.HttpAdapter.publishWSDL(HttpAdapter.java:539)

                    at com.sun.xml.ws.transport.http.HttpAdapter.handle(HttpAdapter.java:229)

                    at com.sun.xml.ws.transport.http.servlet.ServletAdapter.handle(ServletAdapter.java:135)

                    at com.sun.xml.ws.transport.http.servlet.WSServletDelegate.doGet(WSServletDelegate.java:129)

                    at com.sun.xml.ws.transport.http.servlet.WSServlet.doGet(WSServlet.java:82)

            ---

               It seems you're trying to use Glassfish inside JBoss or you just do something wrong.

            Good starting point for you might be this documentation:

             

            https://docs.jboss.org/author/display/JBWS/JBoss+Web+Services+Documentation

             

            Please consider moving to JBossAS 7.x series as well. JBossAS 6.x series and before are obsolete from community PoV.