Rookie Mistake (iii) JBoss is incompatible with JDK version, causing webservice call error

Source: Internet
Author: User
Tags soap thread jboss tomcat

Environment:

jdk1.6

Jboss 5.1.0.GA

Problem Description:

The EJB publishing Webserivce has been successful and has been able to access the WSDL file successfully;

Using the Sample/client class Dynamicinvoker test under the AXIS1, the program complains.

Error message:

Client:

Exception in thread "main" Axisfault

FaultCode: {http://schemas.xmlsoap.org/soap/envelope/}server.userexception

Faultsubcode:

FaultString:org.xml.sax.SAXParseException:Premature end of file.

Faultactor:

Faultnode:

Faultdetail:

{http://xml.apache.org/axis/}stacktrace:org.xml.sax.saxparseexception:premature end of file.

At Com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException (Unknown Source)

At Com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError (Unknown Source)

At Com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError (Unknown Source)

At Com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError (Unknown Source)

At Com.sun.org.apache.xerces.internal.impl.xmldocumentscannerimpl$prologdriver.next (Unknown Source)

At Com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next (Unknown Source)

At Com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next (Unknown Source)

At Com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument (Unknown Source)

At Com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse (Unknown Source)

At Com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse (Unknown Source)

At Com.sun.org.apache.xerces.internal.parsers.XMLParser.parse (Unknown Source)

At Com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse (Unknown Source)

Back to the column page: http://www.bianceng.cnhttp://www.bianceng.cn/Programming/Java/

At Com.sun.org.apache.xerces.internal.jaxp.saxparserimpl$jaxpsaxparser.parse (Unknown Source)

At Javax.xml.parsers.SAXParser.parse (Unknown Source)

Server (Jboss) side error message:

ERROR [SOAPFAULTHELPERJAXWS] SOAP Request exception

Java.lang.UnsupportedOperationException:setProperty must be overridden by all subclasses of SoapMessage

At Javax.xml.soap.SOAPMessage.setProperty (Unknown Source)

At Org.jboss.ws.core.soap.soapmessageimpl.<init> (soapmessageimpl.java:87)

At Org.jboss.ws.core.soap.MessageFactoryImpl.createMessage (messagefactoryimpl.java:215)

At Org.jboss.ws.core.soap.MessageFactoryImpl.createMessage (messagefactoryimpl.java:193)

At Org.jboss.wsf.stack.jbws.RequestHandlerImpl.processRequest (requesthandlerimpl.java:455)

At Org.jboss.wsf.stack.jbws.RequestHandlerImpl.handleRequest (requesthandlerimpl.java:295)

At Org.jboss.wsf.stack.jbws.RequestHandlerImpl.doPost (requesthandlerimpl.java:205)

At Org.jboss.wsf.stack.jbws.RequestHandlerImpl.handleHttpRequest (requesthandlerimpl.java:131)

At Org.jboss.wsf.common.servlet.AbstractEndpointServlet.service (abstractendpointservlet.java:85)

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 (Unknown Source)

Solution:

Download the jboss-5.1.0.ga-jdk6 and copy several jar packages under jboss_home\lib\endorsed to java_home\lib\endorsed and jre_home\lib\, respectively. The endorsed directory. Two Lib directory may not have endorsed folder (anyway, I do not), then create a new one.

Jar packages that need to be replicated:

Jbossws-native-jaxrpc.jar

Jbossws-native-jaxws.jar

Jbossws-native-jaxws-ext.jar

Jbossws-native-saaj.jar

Note: You need to place these packages under the JRE from the Eclipse Kai JBoss, and the external jboss requires that the above jar pack be placed under the JDK.

Start to notice only the error of the client, and then based on the error information on the Internet search solutions, but found the information strange, said anything. Later Marjorie a word to remind me, he asked me JBoss newspaper what error, at this time I just remembered and jboss things. Then he sent me a blog that he had a similar error before, and I did it in the way I did, but I found a little problem (from the outside to start JBoss or error). Later, referring to a netizen's blog to solve this problem. This article explains in detail the causes of this error, and interested friends can look at it.

Author: cnblogs Liu Shui

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.