maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Paul Benedict (JIRA)" <j...@codehaus.org>
Subject [jira] (MNG-4141) Properties are not propagated reccusivly in the dependency tree
Date Wed, 02 Jul 2014 13:44:40 GMT

     [ https://jira.codehaus.org/browse/MNG-4141?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Paul Benedict updated MNG-4141:
-------------------------------

    Fix Version/s:     (was: Issues to be reviewed for 3.x)

> Properties are not propagated reccusivly in the dependency tree
> ---------------------------------------------------------------
>
>                 Key: MNG-4141
>                 URL: https://jira.codehaus.org/browse/MNG-4141
>             Project: Maven
>          Issue Type: Bug
>    Affects Versions: 2.0.9
>         Environment: Linux and windows
>            Reporter: fabrice
>
> Hi
> I am use to use Maven profile for building my projects. For each profile I declare a
specific classifier properties that will be used by Maven to embed dependencies that match
the profile use to build my main project.
> It works well with type that embed librairies like EAR, WAR.
> I can compile my WAR with a specific profil, this war embed JAR that match the profil
> In the same way my EAR embed the WAR.
> Example :
> ----------------------------------------------------------- the WAR that call a specific
JAR, it is based on classifier mecanism  --------------------------------
> 	<modelVersion>4.0.0</modelVersion>
> 	<groupId>com.toto</groupId>
> 	<artifactId>myWAR</artifactId>
> 	<packaging>war</packaging>
> 	<name>ebeesign-server</name>
> 	<version>1.0.9.0.0</version>
> 	<profiles>
> 		<profile>
> 			<id>env-dev</id>
> 	                <activation>
> 				<activeByDefault>true</activeByDefault>
> 			</activation>
> 			<properties>
> 				<profile.name>dev</profile.name>
> 				<profile.classifier/>
> 			</properties>
> 		</profile>
> 		<profile>
> 			<id>env-preprod</id>
> 			<properties>
> 				<profile.name>preprod</profile.name>
> 				<profile.classifier>${profile.name}</profile.classifier>
> 			</properties>
> 		</profile>
> 	</profiles>
> 	
> 	<build>
> 		<filters>
> 			<filter>src/main/filters/${profile.name}.properties</filter>
> 		</filters>
> 	</build>
>     <dependency>
>       <groupId>com.company</groupId>
>       <artifactId>foo-core</artifactId>
>       <version>1.0.9.0.0</version>
>       <classifier>${profile.classifier}</classifier>
>     </dependency>
> </project>
> -----------------------------------------------------------------------------------------
> the JAR itself need a specific jar that match the profil
> -----------------------------------------------------------------------------------------
> 	<modelVersion>4.0.0</modelVersion>
> 	<groupId>com.toto</groupId>
> 	<artifactId>myJAR</artifactId>
> 	<packaging>jar</packaging>
> 	<version>1.2</version>
> 	<profiles>
> 		<profile>
> 			<id>env-dev</id>
> 	                <activation>
> 				<activeByDefault>true</activeByDefault>
> 			</activation>
> 			<properties>
> 				<profile.name>dev</profile.name>
> 				<profile.classifier/>
> 			</properties>
> 		</profile>
> 		<profile>
> 			<id>env-preprod</id>
> 			<properties>
> 				<profile.name>preprod</profile.name>
> 				<profile.classifier>${profile.name}</profile.classifier>
> 			</properties>
> 		</profile>
> 	
> 	</profiles>
> 	
> 	<build>
> 		<filters>
> 			<filter>src/main/filters/${profile.name}.properties</filter>
> 		</filters>
> 	</build>
>     <dependency>
>       <groupId>com.company</groupId>
>       <artifactId>myJAR2</artifactId>
>       <version>1.0.9.3</version>
>       <classifier>${profile.classifier}</classifier>
>     </dependency>
> </project>
> ------------------------------------
> finally my WAR does not contains JAR2 with the good profile
> When I want a WAR with demo profile I have myJAR with demo profile embeded but myJAR2
with dev profile embeded
> I believed that properties was propagated but in fact not !!!



--
This message was sent by Atlassian JIRA
(v6.1.6#6162)

Mime
View raw message