-
1. Re: How to access to the native management API from a deployed application ?
jameslivingston Aug 4, 2013 8:22 PM (in response to sewatech)1 of 1 people found this helpfulYou need to be careful performing management operations from inside a deployment, especially from code run when the deployment starts. If you perform any operations which may block, AS7 would deadlock and WildFly may be the same. Performing a management operation may require taking a lock which is held by the thread performing your deployment.
If you need to perform management operations during deployment startup, consider running them on another thread so that the deployment does stall. That however means those operations may not be finished by the time requests come in, so you may need a filter for web apps (or similar) using a CountDownLatch to block request handling threads until the management ops are finished.
I'm not aware of a way to get a controller client without specifying the host and port, but there may be one.
-
2. Re: How to access to the native management API from a deployed application ?
sewatech Aug 5, 2013 3:32 AM (in response to jameslivingston)Thanks for the advice, James. I'll take care of that.
-
3. Re: How to access to the native management API from a deployed application ?
ctomc Aug 5, 2013 5:36 AM (in response to sewatech)1 of 1 people found this helpfulHi,
you can access mgmt directly from your application.
read http://management-platform.blogspot.com/2012/07/co-located-management-client-for.html for more info.
but same rules that James pointed them out still apply.
--
tomaz
-
4. Re: How to access to the native management API from a deployed application ?
sewatech Aug 5, 2013 11:19 AM (in response to ctomc)Thanks Tomaz.
It's evicient, even if I would have expected something simpler...
BTW, I should try to learn more on ServiceActivator, it could be useful for other stuffs.
Alexis