Home > Documentation > Configuring and administering > Configuring services > Adding JARs to the Geronimo repository |
The server keeps common Java libraries in a repository using the same directory structure and naming conventions prompted by the Apache Maven project. If your Java EE asset depends on a library that is not already in the repository, you can update the repository to include the new library from console or using deployer command, and define the dependency in your Java EE asset's deployment plan.
For adding archives or jars to the repository the Repository Viewer portlet is available by selecting Server > Repository on the Console Navigation menu on the left hand side. The Repository Viewer portlet illustrated in the following figure displays the artifacts installed in the server's repository. The layout of the repository is the same as that used by Apache Maven making it possible to easily copy files over.
Here are the meaning for each field on Repository Viewer portlet:
In order to avoid problems with trying to load the same native library more than once per jvm lifetime, you need to put code that loads native libraries (such as many db drivers) into a classloader plugin that can be shared among all the datasource plugins that need the classes.
To use an artifact in an application, let's take the first one from the list as an example, you will need to add a <dependency> element under <dependencies> in the <environment> element in the application's deployment plan. Here is an excerpt of how a deployment plan would look like:
Besides using the console to add an archive into Geronimo repository, you can do the same thing using command deploy
.
Bookmark this on Delicious Digg this | Privacy Policy - Copyright © 2003-2011, The Apache Software Foundation, Licensed under ASL 2.0. |