ArticleDirectory
- Endorsed standards classes deployment
When myeclipse integrates jboss5.0 and starts JBoss, the following API error message is displayed:
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)
Go to Sun's website and explain the information as follows:
Endorsed standards classes deployment
Classes implementing newer versions of endorsed standards shocould be placed in jar files. The system property
Java. endorsed. dirsSpecifies one or more directories that the Java Runtime Environment will search for such jar files. If more than one directory path is specified
Java. endorsed. dirs, They must be separated
File. pathseparatorchar. If no value is set
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
JREDirectory 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.
SetJboss-5.0.0.GA \ Lib \ endorsedJaxb-api.jar under the directory. This JAR file is placed in the JDK'sJava \ jdk1.6.0 \ JRE \ LibThe endorsed directory under this directory for the class loader to load; the operation is to create an endorsed directory in the JRE/lib directory, and then put the above jaxb-api.jar in this directory, restart JBoss to solve this problem.