You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Aaron Digulla (JIRA)" <ji...@codehaus.org> on 2007/09/25 16:41:11 UTC

[jira] Created: (MWAR-120) Option containerConfigXML doesn't work

Option containerConfigXML doesn't work
--------------------------------------

                 Key: MWAR-120
                 URL: http://jira.codehaus.org/browse/MWAR-120
             Project: Maven 2.x War Plugin
          Issue Type: Bug
            Reporter: Aaron Digulla
         Attachments: context-bug.zip

The file specified with containerConfigXML is copied to the exploded WAR directory but it will not end up in the final WAR.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MWAR-120) Option containerConfigXML doesn't work

Posted by "Stephane Nicoll (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MWAR-120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_111718 ] 

Stephane Nicoll commented on MWAR-120:
--------------------------------------

Oh I see.  This check is kinda historical actually, I just need to check whether it makes sense to add it or not.

> Option containerConfigXML doesn't work
> --------------------------------------
>
>                 Key: MWAR-120
>                 URL: http://jira.codehaus.org/browse/MWAR-120
>             Project: Maven 2.x War Plugin
>          Issue Type: Bug
>            Reporter: Aaron Digulla
>             Fix For: 2.1-alpha-2
>
>         Attachments: context-bug.zip
>
>
> The file specified with containerConfigXML is copied to the exploded WAR directory but it will not end up in the final WAR.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MWAR-120) Option containerConfigXML doesn't work

Posted by "Aaron Digulla (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MWAR-120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_108226 ] 

Aaron Digulla commented on MWAR-120:
------------------------------------

The affected version is 2.0.2.

What puzzles me is the log output of maven:

{code}
> mvn war:war -X
...
[DEBUG] Configuring mojo 'org.apache.maven.plugins:maven-war-plugin:2.0.2:war' -
->
[DEBUG]   (f) archiveClasses = false
[DEBUG]   (s) classesDirectory = D:\workspace-3.3\context-bug\target\classes
[DEBUG]   (s) containerConfigXML = D:\workspace-3.3\context-bug\src\main\webapp\
META-INF\context.xml
[DEBUG]   (f) filters = []
[DEBUG]   (f) outputDirectory = D:\workspace-3.3\context-bug\target
[DEBUG]   (f) primaryArtifact = true
[DEBUG]   (s) project = org.apache.maven.project.MavenProject@19d45cce
[DEBUG]   (f) warName = dummy
[DEBUG]   (s) warSourceDirectory = D:\workspace-3.3\context-bug\src\main\webapp
[DEBUG]   (f) warSourceExcludes = WEB-INF/platform/configuration/org.eclipse.osg
i/**,WEB-INF/platform/configuration/org.eclipse.core.runtime/**,WEB-INF/platform
/configuration/org.eclipse.update/**
[DEBUG]   (s) directory = D:\workspace-3.3\context-bug/src/main/webapp
[DEBUG]   (s) filtering = true
[DEBUG]   (s) includes = [*.html, **/*.xml]
[DEBUG]   (s) excludes = [**/alreportbuild.xml, **/tevbuild.xml, **/web.xml, **/
*.jsp, **/org.eclipse.update/**]
[DEBUG]   (f) webResources = [Lorg.apache.maven.model.Resource;@cf66b
[DEBUG]   (s) webappDirectory = D:\workspace-3.3\context-bug\target\context-bug-
0.0.1
[DEBUG]   (f) workDirectory = D:\workspace-3.3\context-bug\target\war\work
[DEBUG] -- end configuration --
[INFO] [war:war]
[INFO] Exploding webapp...
[INFO] Assembling webapp context-bug in D:\workspace-3.3\context-bug\target\cont
ext-bug-0.0.1
[INFO] Copy webapp webResources to D:\workspace-3.3\context-bug\target\context-b
ug-0.0.1
[INFO] Copy webapp webResources to D:\workspace-3.3\context-bug\target\context-b
ug-0.0.1
[INFO] Generating war D:\workspace-3.3\context-bug\target\dummy.war
[INFO] Building war: D:\workspace-3.3\context-bug\target\dummy.war
[DEBUG] adding directory META-INF/
[DEBUG] adding entry META-INF/MANIFEST.MF
[DEBUG] adding directory WEB-INF/
[DEBUG] adding entry WEB-INF/web.xml
[DEBUG] adding directory META-INF/maven/
[DEBUG] adding directory META-INF/maven/context-bug/
[DEBUG] adding directory META-INF/maven/context-bug/context-bug/
[DEBUG] adding entry META-INF/maven/context-bug/context-bug/pom.xml
[DEBUG] adding entry META-INF/maven/context-bug/context-bug/pom.properties
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESSFUL
[INFO] ------------------------------------------------------------------------
{code}

Obviously, the option is recognized, the file is also copied into target/context-bug-0.0.1/META-INF/ but it's ignored when the WAR is built.

> Option containerConfigXML doesn't work
> --------------------------------------
>
>                 Key: MWAR-120
>                 URL: http://jira.codehaus.org/browse/MWAR-120
>             Project: Maven 2.x War Plugin
>          Issue Type: Bug
>            Reporter: Aaron Digulla
>         Attachments: context-bug.zip
>
>
> The file specified with containerConfigXML is copied to the exploded WAR directory but it will not end up in the final WAR.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MWAR-120) Option containerConfigXML doesn't work

Posted by "Stephane Nicoll (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MWAR-120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_108422 ] 

Stephane Nicoll commented on MWAR-120:
--------------------------------------

No that's ok. I can have a look.

> Option containerConfigXML doesn't work
> --------------------------------------
>
>                 Key: MWAR-120
>                 URL: http://jira.codehaus.org/browse/MWAR-120
>             Project: Maven 2.x War Plugin
>          Issue Type: Bug
>            Reporter: Aaron Digulla
>         Attachments: context-bug.zip
>
>
> The file specified with containerConfigXML is copied to the exploded WAR directory but it will not end up in the final WAR.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MWAR-120) Option containerConfigXML doesn't work

Posted by "Stephane Nicoll (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MWAR-120?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Stephane Nicoll updated MWAR-120:
---------------------------------

    Fix Version/s: 2.1-alpha-2

> Option containerConfigXML doesn't work
> --------------------------------------
>
>                 Key: MWAR-120
>                 URL: http://jira.codehaus.org/browse/MWAR-120
>             Project: Maven 2.x War Plugin
>          Issue Type: Bug
>            Reporter: Aaron Digulla
>             Fix For: 2.1-alpha-2
>
>         Attachments: context-bug.zip
>
>
> The file specified with containerConfigXML is copied to the exploded WAR directory but it will not end up in the final WAR.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MWAR-120) Option containerConfigXML doesn't work

Posted by "Aaron Digulla (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MWAR-120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_111177 ] 

Aaron Digulla commented on MWAR-120:
------------------------------------

I think I found it: In the code, you check whether the option is set. If so, you add an ignore pattern for any context.xml which might be in the META-INF directory of the project (i.e. "src\main\webapp\META-INF\context.xml").

In my case, that's the file I tried to add with the option, so it gets mysteriously ignored.

As a fix, I suggest that you check whether the value of the option matches the ignore pattern and if so, don't add the pattern.

> Option containerConfigXML doesn't work
> --------------------------------------
>
>                 Key: MWAR-120
>                 URL: http://jira.codehaus.org/browse/MWAR-120
>             Project: Maven 2.x War Plugin
>          Issue Type: Bug
>            Reporter: Aaron Digulla
>             Fix For: 2.1-alpha-2
>
>         Attachments: context-bug.zip
>
>
> The file specified with containerConfigXML is copied to the exploded WAR directory but it will not end up in the final WAR.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MWAR-120) Option containerConfigXML doesn't work

Posted by "Stephane Nicoll (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MWAR-120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_111719 ] 

Stephane Nicoll commented on MWAR-120:
--------------------------------------

Okay, reproduced.

Note that I have a slightly different behavior in testing harness (which drives me crazy). If you do not provide the containerConfigXml property and you put the file in the right place, it ends up in the generated war.

I don't have this when running the plugin from the command line. Weird ...

> Option containerConfigXML doesn't work
> --------------------------------------
>
>                 Key: MWAR-120
>                 URL: http://jira.codehaus.org/browse/MWAR-120
>             Project: Maven 2.x War Plugin
>          Issue Type: Bug
>            Reporter: Aaron Digulla
>            Assignee: Stephane Nicoll
>             Fix For: 2.1-alpha-2
>
>         Attachments: context-bug.zip
>
>
> The file specified with containerConfigXML is copied to the exploded WAR directory but it will not end up in the final WAR.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Closed: (MWAR-120) Option containerConfigXML doesn't work

Posted by "Stephane Nicoll (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MWAR-120?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Stephane Nicoll closed MWAR-120.
--------------------------------

    Resolution: Fixed

Fixed. This excludes list was actually duplicated with the task responsible for the project's packaging. It should not be there at all.

Thanks for the bug hunting.

> Option containerConfigXML doesn't work
> --------------------------------------
>
>                 Key: MWAR-120
>                 URL: http://jira.codehaus.org/browse/MWAR-120
>             Project: Maven 2.x War Plugin
>          Issue Type: Bug
>            Reporter: Aaron Digulla
>            Assignee: Stephane Nicoll
>             Fix For: 2.1-alpha-2
>
>         Attachments: context-bug.zip
>
>
> The file specified with containerConfigXML is copied to the exploded WAR directory but it will not end up in the final WAR.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MWAR-120) Option containerConfigXML doesn't work

Posted by "Stephane Nicoll (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MWAR-120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_108306 ] 

Stephane Nicoll commented on MWAR-120:
--------------------------------------

Funny. I guess it has something to do with the way plexus build the archive. Thanks for the report

> Option containerConfigXML doesn't work
> --------------------------------------
>
>                 Key: MWAR-120
>                 URL: http://jira.codehaus.org/browse/MWAR-120
>             Project: Maven 2.x War Plugin
>          Issue Type: Bug
>            Reporter: Aaron Digulla
>         Attachments: context-bug.zip
>
>
> The file specified with containerConfigXML is copied to the exploded WAR directory but it will not end up in the final WAR.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MWAR-120) Option containerConfigXML doesn't work

Posted by "Aaron Digulla (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MWAR-120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_108362 ] 

Aaron Digulla commented on MWAR-120:
------------------------------------

Maybe this is a regression because of an update of plexus? I tried to plexus-utils 1.1 and 1.2 (just replaced the version in the pom of the war plugin) but it works with neither version. If you could give me some pointers where the file ought to be included, I can try to debug this if you can't reproduce it.

> Option containerConfigXML doesn't work
> --------------------------------------
>
>                 Key: MWAR-120
>                 URL: http://jira.codehaus.org/browse/MWAR-120
>             Project: Maven 2.x War Plugin
>          Issue Type: Bug
>            Reporter: Aaron Digulla
>         Attachments: context-bug.zip
>
>
> The file specified with containerConfigXML is copied to the exploded WAR directory but it will not end up in the final WAR.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira