Uploaded image for project: 'Codehaus Cargo'
  1. CARGO-963

Make TomcatLocalInstalledLocalDeployer.shouldCopyWars configurable through Tomcat container configuration


    • Type: Bug
    • Status: Closed (View workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.1.0
    • Component/s: Tomcat
    • Labels:


      AbstractCatalinaStandaloneLocalConfiguration contains hard coded overriding of the default TomcatLocalInstalledLocalDeployer.shouldCopyWars (true) to false.
      And there is no way to "fix" or reconfigure this through container configuration.
      This means that no war files on a local tomcat installation will be copied but only "referenced" through injected context elements in the the server.xml.

      The only exception (providing a temporary workaround) is when a war file contains a custom Tomcat context.xml itself.
      However, having to add one just for this purpose is undesirable.

      This also, by default, causes (maven) cargo:package to produce a "package" which cannot be transported across machines/filesystems as it contains hard file location references outside the package structure itself, which IMO is a serious "bug".

      I've created a fix for the above by making copyWars configurable through a new TomcatPropertySet.COPY_WARS = "cargo.tomcat.copywars" boolean property, which for instance can be used through Maven like:


      I'm a bit hesitant to change the current (overridden to false) behavior (back) to true as it might break existing usages, which is why I created two patches:

      • one to keep the current but IMO undesirable default behavior
      • a second which defaults to copyWars = true (my personal preference)

      If either of the patches is agreed upon I'll also take care of updating the relevant website documentation, e.g. http://cargo.codehaus.org/Tomcat+x.x pages.




            • Assignee:
              atedouma Ate Douma
              atedouma Ate Douma
            • Votes:
              0 Vote for this issue
              0 Start watching this issue


              • Created: