Aaron Mulder wrote:
P.S. What good is all this flexibility when we know we'll have exactly EARs, WARs, EJB JARs, and RARs, and we need to specifically arrange ClassLoaders across them, and there are hardcoded constants for those module types in the J2EE 1.4 API? It's not like you could/would just drop in a new xAR archive/component type.
Expect the unexpected.
We are already deploy services (eg WebContainer) and subservices (WebConnector, RequestLog). So it is not just EARs, WARs, EJB JARs, and RARs. I hope in future to be deploying lots of other subservices like session distributors etc.
If we have an extensible deployment mechanism then it can be extended in all sorts of wonderful (and horrible) ways.
If we don't have an extensible deployment mechanism then we will only ever deploy EARs, WARs, EJB JARs, and RARs.
Besides, I think having separate deployment classes for the different things to deploy is good separation of concerns anyway - even if it was not made extensible.
Note that I don't think that common deployment behaviour can go in an Abstract base class, as we already have AbstractManagedObject that services need to extend. The common deployment behaviour will probly need to go in a DeploymentSupport class or on the DeploymentController itself.
cheers
