[
http://jira.codehaus.org/browse/MNG-3546?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=132144#action_132144
]
David Bernhard commented on MNG-3546:
-------------------------------------
I've noticed this one too - it's to do with the fact that system properties
(and that includes command-line ones) are processed first and then overwritten
by project (pom) ones. I don't see another way of doing this that won't mean
all system properties take preference over pom ones, which is not desirable.
I've solved it locally by extending the resources-plugin so any property on the
command-line that begins with "override." is applied last, i.e.
"-Doverride.foo=bar" becomes "foo=bar" and overrides everything else. It's more
a workaround than a fix though.
> command line cannot overwrite pom properties
> --------------------------------------------
>
> Key: MNG-3546
> URL: http://jira.codehaus.org/browse/MNG-3546
> Project: Maven 2
> Issue Type: Bug
> Components: Command Line
> Affects Versions: 2.0.9
> Reporter: Thomas Diesler
>
> With a pom like this
> <properties>
> <jboss.bind.address>localhost</jboss.bind.address>
> </properties>
> and a command line like this
> mvn -Pjboss422 -Djboss.bind.address=foo clean test-compilecxf.xml
> I get a filtered resource like this
> <jaxws:endpoint id='TestService'
> address='http://localhost:8080/jaxws-cxf-descriptor'
>
> implementor='org.jboss.test.ws.jaxws.cxf.descriptor.DescriptorEndpointImpl'>
>
> <jaxws:invoker>
> <bean class='org.jboss.wsf.stack.cxf.InvokerJSE'/>
> </jaxws:invoker>
>
> </jaxws:endpoint>
> Note, the bind address is localhost
--
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