Eclipse整合jboss-5.0.0.GA的時候出現的java.lang.LinkageError錯誤

來源:互聯網
上載者:User
文章目錄
  • Endorsed Standards Classes Deployment

MyEclipse整合JBOSS5.0的時候啟動JBOSS的時候出現了下面的API錯誤資訊:

java.lang.LinkageError: JAXB 2.1 API is being loaded from the bootstrap classloader, but this RI (from jar:file:/E:/java/apache-tomcat-6.0.26/webapps/ejbClient/WEB-INF/lib/jaxb-impl.jar!/com/sun/xml/bind/v2/model/impl/ModelBuilder.class) needs 2.2 API. Use
the endorsed directory mechanism to place jaxb-api.jar in the bootstrap classloader. (See http://java.sun.com/j2se/1.6.0/docs/guide/standards/)
到sun公司的上面的一個網址後解釋資訊如下:

Endorsed Standards Classes Deployment

Classes implementing newer versions of endorsed standards should be placed in JAR files. The system property
java.endorsed.dirs specifies one or more directories that the Java runtime environment will search for such JAR files. If more than one directory path is specified by
java.endorsed.dirs, they must be separated by

File.pathSeparatorChar. If no value is set for
java.endorsed.dirs, then Sun Microsystem's implementation of the Java platform looks for JAR files in a default standard location:

<java-home>\lib\endorsed          [Microsoft Windows]<java-home>/lib/endorsed          [Solaris or Linux]

Here <java-home> refers to the directory where the runtime software is installed (which is the top-level directory of the J2SE Runtime Environment or the
jre directory in the JDK).

The J2SE runtime environment will use classes in such JAR files to override the corresponding classes provided in the Java platform as shipped by Sun.

jboss-5.0.0.GA\lib\endorsed目錄下的jaxb-api.jar這個jar檔案放到JDK的Java\jdk1.6.0\jre\lib這個目錄下的的endorsed目錄中供類載入器載入;操作就是在jre/lib目錄中建立一個endorsed目錄,然後把上面的那個jaxb-api.jar放到這個目錄中,重新啟動jboss就可以解決這個問題了

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

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.