On Wed, May 4, 2011 at 9:11 AM, Sahoo <sanjeeb.sahoo_at_oracle.com> wrote:
> If you don't want every application to see every jar that Hobernate uses,
> there is a better solution which will allow you to install multiple versions
> of Hibernate in GlassFish and yet share it by different applications. Do the
> following:
>
> copy hobernate and its dependencies into a directory called
> domain1/lib/applib/hibernate-xxx/
> create an empty jar in domain1/lib/applib/hibernate-latest.jar with
> MANIFEST.MF having Class-Path entry set to all hibernate jars. e.g., it may
> look like this:
> Class-Path: hibernate-xxx/foo.jar hibernate-xxx/bar.jar ...
>
> From each that uses this version of hibernate, specify --library
> hibernate-xxx.jar while deploying.
>
Last dumb question: is there an asadmin command to install a library under
applib? (It just now dawned on me this is all section EE.8.2.2 of the Java
EE specification...duh.) I looked at the output of asadmin
list-commandsbut didn't see anything obvious.
Is a restart required, or can I copy libraries into applib and then have the
--library option to the deploy subcommand recognize them?
Best,
Laird