Child pages
  • Global JNDI Plugin
Skip to end of metadata
Go to start of metadata

Setup

Build the global jndi module in the sandbox.
$ svn co https://svn.apache.org/repos/asf/geronimo/sandbox/plugins/global-jndi

$ cd global-jndi

$ mvn install
Add namingLib dir
$ cd $GERONIMO_HOME

$ mkdir namingLib

$ cp ~/.m2/repository/org/apache/geronimo/sandbox/geronimo-global-jndi/1.2-SNAPSHOT/geronimo-global-jndi-1.2-SNAPSHOT.jar namingLib/

$ cp ~/.m2/repository/org/apache/xbean/xbean-naming/COL-SNAPSHOT/xbean-naming-COL-SNAPSHOT.jar namingLib/
Modify naming properties in config.xml

Add the following GBean to the rmi-naming module.

<gbean gbeanInfo="org.apache.geronimo.system.sharedlib.SharedLib" name="org.apache.geronimo.configs/rmi-naming/1.2-SNAPSHOT/car?name=GlobalJndiLibs">
  <attribute name="libDirs">namingLib</attribute>
  <reference name="ServerInfo">
    <pattern>
      <artifactId>j2ee-system</artifactId>
      <name>ServerInfo</name>
    </pattern>
  </reference>
</gbean>

Add the namingFactoryUrlPkgs property to the NamingProperties GBean which makes the JNDI check the new gjndi packages for the java: provider.

<gbean name="NamingProperties">
  <attribute name="namingFactoryUrlPkgs">org.apache.geronimo.gjndi,org.apache.geronimo.naming</attribute>
  <attribute name="namingProviderUrl">rmi://0.0.0.0:1099</attribute>
</gbean>
  • No labels