[ 
https://issues.apache.org/jira/browse/CALCITE-1064?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15185542#comment-15185542
 ] 

Josh Elser commented on CALCITE-1064:
-------------------------------------

Alright, I think I have this working. Apologies, Julian and Jacques, I was down 
a rabbit hole myself :)

I think the fix is as simple as moving the maven-remote-resources-plugin 
"root-resources" entry into the apache-release profile. When it's declared as a 
project plugin, it gets invoked at the generate-resources lifecycle phase which 
causes it to download the SNAPSHOT releases before it actually builds the 
project. However, with the maven-release-plugin, the profile only gets 
activated at the very end, when all of the modules were built and available via 
the Maven reactor.

Need to investigate the output a bit more, but just wanted to report back while 
it was fresh.

> Unnecessary maven-remote-resources-plugin configuration
> -------------------------------------------------------
>
>                 Key: CALCITE-1064
>                 URL: https://issues.apache.org/jira/browse/CALCITE-1064
>             Project: Calcite
>          Issue Type: Bug
>          Components: build
>            Reporter: Josh Elser
>            Assignee: Josh Elser
>            Priority: Minor
>             Fix For: 1.7.0
>
>
> Just got pinged with a question from someone about something I also noticed 
> during 1.6.0-rc1 testing:
> When building from a clean checkout (or deleting the top-level target/ 
> directory), you'll see the calcite build trying to pull down the jars we're 
> trying to build:
> {noformat}
> mvn package
> [INFO] Scanning for projects...
> [INFO] 
> ------------------------------------------------------------------------
> [INFO] Reactor Build Order:
> [INFO]
> [INFO] Calcite
> [INFO] Calcite Avatica
> [INFO] Calcite Avatica Server
> [INFO] Calcite Linq4j
> [INFO] Calcite Core
> [INFO] Calcite Examples
> [INFO] Calcite Example CSV
> [INFO] Calcite Example Function
> [INFO] Calcite MongoDB
> [INFO] Calcite Piglet
> [INFO] Calcite Plus
> [INFO] Calcite Spark
> [INFO] Calcite Splunk
> [INFO] Calcite Ubenchmark
> [INFO]
> [INFO] 
> ------------------------------------------------------------------------
> [INFO] Building Calcite 1.7.0-SNAPSHOT
> [INFO] 
> ------------------------------------------------------------------------
> [INFO]
> [INFO] --- maven-checkstyle-plugin:2.12.1:check (validate) @ calcite ---
> [INFO]
> [INFO] --- git-commit-id-plugin:2.1.9:revision (default) @ calcite ---
> [INFO]
> [INFO] --- maven-remote-resources-plugin:1.5:process (default) @ calcite ---
> [INFO]
> [INFO] --- maven-remote-resources-plugin:1.5:process (root-resources) @ 
> calcite ---
> Downloading: 
> https://repository.apache.org/content/repositories/snapshots/org/apache/calcite/calcite-avatica/1.7.0-SNAPSHOT/maven-metadata.xml
> Downloading: 
> http://conjars.org/repo/org/apache/calcite/calcite-avatica/1.7.0-SNAPSHOT/maven-metadata.xml
> Downloading: 
> http://repository.apache.org/snapshots/org/apache/calcite/calcite-avatica/1.7.0-SNAPSHOT/maven-metadata.xml
> Downloading: 
> https://repository.apache.org/content/repositories/snapshots/org/apache/calcite/calcite-avatica/1.7.0-SNAPSHOT/calcite-avatica-1.7.0-SNAPSHOT.jar
> Downloading: 
> http://conjars.org/repo/org/apache/calcite/calcite-avatica/1.7.0-SNAPSHOT/calcite-avatica-1.7.0-SNAPSHOT.jar
> Downloading: 
> http://repository.apache.org/snapshots/org/apache/calcite/calcite-avatica/1.7.0-SNAPSHOT/calcite-avatica-1.7.0-SNAPSHOT.jar
> Downloading: 
> http://repository.apache.org/snapshots/org/apache/calcite/calcite-linq4j/1.7.0-SNAPSHOT/maven-metadata.xml
> Downloading: 
> http://conjars.org/repo/org/apache/calcite/calcite-linq4j/1.7.0-SNAPSHOT/maven-metadata.xml
> Downloading: 
> https://repository.apache.org/content/repositories/snapshots/org/apache/calcite/calcite-linq4j/1.7.0-SNAPSHOT/maven-metadata.xml
> Downloading: 
> https://repository.apache.org/content/repositories/snapshots/org/apache/calcite/calcite-linq4j/1.7.0-SNAPSHOT/calcite-linq4j-1.7.0-SNAPSHOT.jar
> Downloading: 
> http://conjars.org/repo/org/apache/calcite/calcite-linq4j/1.7.0-SNAPSHOT/calcite-linq4j-1.7.0-SNAPSHOT.jar
> Downloading: 
> http://repository.apache.org/snapshots/org/apache/calcite/calcite-linq4j/1.7.0-SNAPSHOT/calcite-linq4j-1.7.0-SNAPSHOT.jar
> Downloading: 
> https://repository.apache.org/content/repositories/snapshots/org/apache/calcite/calcite-core/1.7.0-SNAPSHOT/maven-metadata.xml
> Downloading: 
> http://conjars.org/repo/org/apache/calcite/calcite-core/1.7.0-SNAPSHOT/maven-metadata.xml
> Downloading: 
> http://repository.apache.org/snapshots/org/apache/calcite/calcite-core/1.7.0-SNAPSHOT/maven-metadata.xml
> Downloading: 
> https://repository.apache.org/content/repositories/snapshots/org/apache/calcite/calcite-core/1.7.0-SNAPSHOT/calcite-core-1.7.0-SNAPSHOT.jar
> Downloading: 
> http://conjars.org/repo/org/apache/calcite/calcite-core/1.7.0-SNAPSHOT/calcite-core-1.7.0-SNAPSHOT.jar
> Downloading: 
> http://repository.apache.org/snapshots/org/apache/calcite/calcite-core/1.7.0-SNAPSHOT/calcite-core-1.7.0-SNAPSHOT.jar
> {noformat}
> It looks like this was introduced in CALCITE-741. The intent of the change 
> isn't necesarily wrong, but I believe this is just trying to work against 
> Maven.
> I think the change to make for Maven to work as it wants is to make a new 
> module dedicated to creating the assembly. That module will depend on the 
> other modules which should properly create the transitive dependency list.
> It's also worth noting that the maven-remote-resources-plugin configuration 
> littered everywhere is duplicative (this is already handled in the Apache 
> parent pom).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to