users@glassfish.java.net

Re: overriding osgi-module with endorsed jar does not work

From: Sahoo <sanjeeb.sahoo_at_oracle.com>
Date: Thu, 01 Dec 2011 03:52:34 +0530

Sorry, you can't put a jar in endorsed to override any jar from modules
dir. Your only option is to update the jar itself.

Thanks,
Sahoo
On Wednesday 30 November 2011 01:56 PM, forums_at_java.net wrote:
> Hi,
>
> I'm trying to use the endorsed mechanism to override a module jar in
> /glassfish/modules. According to the GF docs, it looks like this
> should be
> possible:
>
> [quote=http://docs.oracle.com/cd/E18930_01/html/821-2434/ggrvi.html#gkuhf]
>
> The classpath-prefix was typically used to substitute another package
> for one
> of the GlassFish Server packages, for example if a newer one was
> available.
> This same result can be achieved by using the Java Endorsed Standards
> Override Mechanism or on a per-application basis with the --libraries
> option
> for the deploy subcommand. These are documented in the Oracle GlassFish
> Server 3.1 Application Development Guide.[/quote]
>
> From the Application Development Guide:
> [quote=http://docs.oracle.com/cd/E18930_01/html/821-2418/gchif.html]Endorsed
>
> standards handle changes to classes and APIs that are bundled in the
> JDK but
> are subject to change by external bodies.
> To use the endorsed standards override mechanism, copy the JAR files
> into the
> domain-dir/lib/endorsed directory, then restart the server.[/quote]
>
> The situation is that I have a patched class for
> /modules/weld-integration.jar because of
> http://java.net/jira/browse/GLASSFISH-17464.
> Up to now I always replaced this jar and works flawlessly, but I
> prefer not
> to mess with the default GlassFish installation. It would be better to
> place
> the patched jar somewhere else from a system maintenance point-of-view.
>
> Any ideas?
>
>
> --
>
> [Message sent by forum member 'dj_canard']
>
> View Post: http://forums.java.net/node/869180
>
>