[wildfly-dev] Reading Mgt Model from a Servlet
Stan Silvert
ssilvert at redhat.com
Tue May 26 18:17:57 EDT 2015
On 5/26/2015 5:51 PM, Jason Greene wrote:
> Nope. Although I would use newCachedThreadPool instead, as the fixed thread pool of 5 is just wasteful.
>
> Keep in mind this API is not something we encourage people to use from deployments, as any management op that acquires a write lock (some sort of modification), will deadlock the server if it used in the initialization path of a deployment. For this reason, we don’t publish it via any simple means
Thanks. I just need the servlet to read a flag that I put into the
owner attribute of the deployment. So I should be OK.
Incidentally, I find that this is something I run into once in awhile.
I need a subsystem to communicate with a deployment's application code.
The other way I've done this is to stuff things into the ServletContext
using a DeploymentUnitProcessor and the JBossWebMetaData.
If anyone knows a third option I'd love to hear it.
>> On May 26, 2015, at 3:51 PM, Stan Silvert <ssilvert at redhat.com> wrote:
>>
>> Some time ago, John Mazzitelli wrote a blog on how to get a local
>> ModelControllerClient from within a servlet.
>> http://management-platform.blogspot.com/2012/07/co-located-management-client-for.html
>>
>> Is there an easier way to do it these days?
>>
>> I need to read the attributes under /deployment=mydeployment.war/. Is
>> there an easier way to do that from the WAR than using a
>> ModelControllerClient?
>>
>> Thanks,
>>
>> Stan
>> _______________________________________________
>> wildfly-dev mailing list
>> wildfly-dev at lists.jboss.org
>> https://lists.jboss.org/mailman/listinfo/wildfly-dev
> --
> Jason T. Greene
> WildFly Lead / JBoss EAP Platform Architect
> JBoss, a division of Red Hat
>
More information about the wildfly-dev
mailing list