dev@glassfish.java.net

Re: Maven-built deployment plans confuse DeploymentPlanArchive and break asadmin deploy --deploymentplan.

From: Owen Jacobson <owen.jacobson_at_grimoire.ca>
Date: Thu, 2 Sep 2010 22:59:13 -0400

On 2010-09-02, at 10:46 PM, Hong Zhang wrote:

> Hi, Owen
>> I explored a couple of alternatives for addressing this, without reaching a satisfying solution. Attached are two patches to deployment/common (against the 3.0.1-b22 tag).
>>
>> deployment-plan-archive-ignores-meta-inf.patch is probably the better of the two alternatives: the patch causes DeploymentPlanArchive.entries() to skip the deployment plan JAR's META-INF dir entirely, which prevents any files there from being copied to the deployed application. This is a very simple solution, and it appears to work well with the simple cases, but I'd worry about people relying on deployment plans to place important runtime configuration in their application (SPI services/ entries, extra Spring XML files, config files, &c) having their use cases broken.
> Thanks for working on this and providing the patches! I also like the first patch better, it's very simple and addressed the problem. As the deployment plan is only intended to provide vendor specific deployment descriptors and not other runtime configuration files, I think it's fine to ignore the META-INF directory here.
>
> If you agree, I will apply your first patch and check in after running the necessary tests.

Go for it. I'm happy for my code to be included in Glassfish.

-o