How can I use a shared library in a glass shawl to avoid deploying huge libraries?

I need to download about 30 million for my application, since it uses many libraries, a magazine, a web engine, etc.

I think there should be a way to share these libs on a glass fish, but I could not figure it out. I tried putting them in the / lib / ext domain, but it does not work.

So where should I store these libraries and how do I access them? thanks.

+6
java-ee deployment glassfish shared-libraries shared
source share
3 answers

Why does domaindir / lib / ext not work?

from fishing guide:

Additional packages are Java class packages and their own native code that developers can use to extend the functionality of the underlying platform. To use the Java batch package engine, copy the JAR files to dir / lib / ext domain then restart the server.

Why does domaindir / lib work?

To use the Common class loader, copy the JAR files to the domain-dir / lib or as-install / lib directory or copy the .class files (and other necessary files, for example .properties files) to domain-dir / lib / classes, and then restart server. Using the Common class loader makes the application or module available to all applications or modules deployed on servers with the same configuration. However, this availability does not apply to application clients.

+6
source share

One option is to place them in domains/domain1/lib . But in fact, I suggest reading GlassFish, the equivalent of WebSphere "shared libraries" , including comments .

0
source share

If I remember well, you can also specify additional libraries in the classpath through the admin console (in Application Server> JVM settings or something like this). Then you can place them wherever you want.

(I quickly looked at Pascal's link, but I don’t know if what they describe, if so, my apologies for the duplicate answer.)

0
source share

All Articles