2 Replies Latest reply: Jun 6, 2012 4:23 PM by user10484841 RSS

    Configure external libraries as Glassfish modules

    user10484841
      I have several OSGI bundles and WAR packages which use external libraries:
      <dependencies>       
              <dependency>
                  <groupId>javax</groupId>
                  <artifactId>javaee-web-api</artifactId>
                  <version>6.0</version>
                  <scope>provided</scope>
              </dependency>
              <dependency>
                  <groupId>junit</groupId>
                  <artifactId>junit</artifactId>
                  <version>4.8.2</version>
                  <scope>test</scope>
              </dependency>        
              <dependency>
                  <groupId>org.osgi</groupId>
                  <artifactId>org.osgi.core</artifactId>
                  <version>4.2.0</version>
                  <scope>provided</scope>
              </dependency>
              <dependency>
                  <groupId>org.osgi</groupId>
                  <artifactId>org.osgi.compendium</artifactId>
                  <version>4.2.0</version>
                  <scope>provided</scope>
              </dependency>
              <dependency>
                  <groupId>org.glassfish</groupId>
                  <artifactId>osgi-cdi-api</artifactId>
                  <version>3.1-b41</version>
                  <type>jar</type>
                  <scope>provided</scope>
              </dependency>
      Instead of building the libraries into every OSGI bundle and WAR package is it possible to copy these libraries into /modules directory of the Glassfish server. I suppose that it's possible to use only one copy without any problem?