[wildfly-dev] Reading Mgt Model from a Servlet

James Livingston jlivings at redhat.com
Tue May 26 18:44:31 EDT 2015


On Tue, 2015-05-26 at 16:51 -0500, Jason Greene wrote:
> 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

It is more than just the initialisation path you need to be worried
about. I'm not sure what the exact rule is, but it wouldn't surprise me
if it is "never block on a management op from any code the container has
called".

For example using a management op from a servlet service method (e.g.
doPost) is dangerous because there may be an op in progress that is
waiting for all servlet processing to finish before it does it's work.

-- 
James "Doc" Livingston <jlivings at redhat.com>
JBoss Support Engineering Group




More information about the wildfly-dev mailing list