There are some issues with parallel Jersey eager loading in some environments.
Sahoo ask for switch on/off this feature based on domain.xml value.
Unfortunately this is required to be fixed soon. It is affecting testing in some glassfish based distributions. For more details, send email.
New related bug: 16731202
Proposed optional configuration in domain.xml
<administration-interface-config lazy-init="true" />
Enables switching on/off eager initialization of Jersey based admin framework using optional value in domain.xml
This feature is prioritized by HK2 people. For details, please, contact John W. or Sahoo
Only if we want to make this option public.
Any CLI tests
Do not check in this change for 4.0. If it is needed at all (and I strongly question that), wait until the 4.0 branch is created and check it into the trunk.
As for whether this is needed, please provide details about why this is really needed. From looking at the bug referenced above, it looks like the purpose of this would to work around some other bug that hasn't been found yet. Instead, let's find and fix that other bug.
Tom, Martin, Sahoo, please figure out if this is needed for 4.0.1.
As you see in upper comments it will be nice if you or John can mail (or comment) here more details about the core problem for Tom.
Reassigning this to Martin Mare. Every use of GlassFish does not require Jersey (e.g., embedded ejb container or embedde web container, etc.), so I strongly recommend to provide an option to disable initialization of a component unnecessarily. Let's not add to footprint to start fast.
Current state of things are many people including QA is spending time because of bug #16731202. We need to provide a work around so that teams can effectively carry out their tasks.
1. temporarily disable eager loading until the concurrency problem is fixed.
2. continue working with the Jersey and integration teams to get the
concurrency problem fixed.
3. design a different method for triggering eager loading. For example,
one method might be to implement an @Async remote command that will
cause the command framework to be initialized (and Jersey loaded). The
start-domain command could then be modified to invoke that command after
the server has started (since we always want that initialization to
happen if a DAS is started with start-domain). This will allow embedded
environment to optionally choose if they want this to happen.
SVN 61838: Temporary switch off eager loading of admin framework. - Lazy load: First CLI call triggers init.