[jboss-dev-forums] [JBoss Microcontainer Development POJO Server] - Cleanup path for Structure Deployers
jason.greene@jboss.com
do-not-reply at jboss.com
Wed Oct 21 18:51:18 EDT 2009
The thread seems to start here:
http://lists.jboss.org/pipermail/jboss-cvs-commits/2009-October/109290.html
and here:
http://lists.jboss.org/pipermail/jboss-cvs-commits/2009-October/109293.html
and also here:
http://lists.jboss.org/pipermail/jboss-development/2009-October/014994.html
The fundamental problem is that a structure deployer (WAR/JAR/EAR etc) has no cleanup phase, like other deployers. The only way to achieve this with the current design, is to reuse the cleanup call on DeploymentContext. In the above scenario, a structure deployer needs to get a set of mount points it created added to a DeploymentContext for cleanup. These come from the current VFS api as Closables. However, the structure deployer executes before the DeploymentContext exists, so it must be copied to some intermediary data structure. The patch that was recently applied used ContextInfo on StructureMetaData to pass a Runnable which closed the closables.
Ales mentions in the above threads that ContextInfo should hold no impl details. So the question becomes where else to pass this?
I assume if ContentInfo can't contain a List (or Runnable), then StructureMetaData can't either?
That means a structure deployer, without changes to the SPI can only use StructureContext as the other option, which does not survive long enough to make it into the DeploymentContext. The only way to change that would be to change the AbstractStructuralDeployers, and AbstractStructureBuilder SPIs to support passing an additional object.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4261612#4261612
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4261612
More information about the jboss-dev-forums
mailing list