You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@brooklyn.apache.org by GitBox <gi...@apache.org> on 2019/12/19 23:32:07 UTC

[GitHub] [brooklyn-ui] geomacy opened a new pull request #160: add relativePath to parent for release make

geomacy opened a new pull request #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160
 
 
   This adds back the `relativePath` to the parent in the pom, to allow the `make_release_artifacts.sh` to work. This is required to get https://github.com/apache/brooklyn-dist/pull/150 to work.
   
   Without this commit the script breaks like below (abbreviated):
   
   ```
   [ERROR] [ERROR] Some problems were encountered while processing the POMs:
   [FATAL] Non-resolvable parent POM for org.apache.brooklyn.ui:brooklyn-ui-parent:${revision}: Could not find artifact org.apache.brooklyn:brooklyn-parent:pom:1.0.0 in ...) and 'parent.relativePath' points at wrong local POM @ line 24, column 13
   ````
   
   @ahgittin this undoes the change https://github.com/apache/brooklyn-ui/commit/f6b88085815bb044c782db1344a5536c8730d01f and probably therefore undoes the fix for embedded builds. What do you think of this? Could we merge this and figure out some other fix for those?
   
   
   
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [brooklyn-ui] tbouron commented on issue #160: add relativePath to parent for release make

Posted by GitBox <gi...@apache.org>.
tbouron commented on issue #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160#issuecomment-567959079
 
 
   Maybe this is an issue with our script @ahgittin but in this case, I don't know how to fix this.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [brooklyn-ui] ahgittin commented on issue #160: add relativePath to parent for release make

Posted by GitBox <gi...@apache.org>.
ahgittin commented on issue #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160#issuecomment-567957290
 
 
   thanks @tbouron -- not 100% clear though, even when cutting a new version, we build `brooklyn-server` before `brooklyn-ui`, so `brooklyn-server/parent` should run and its artifact be available even without relative path.  i trust you that this isn't happening, but i'm wondering if that's a sign of something else not working as it should...

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [brooklyn-ui] tbouron edited a comment on issue #160: add relativePath to parent for release make

Posted by GitBox <gi...@apache.org>.
tbouron edited a comment on issue #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160#issuecomment-567870966
 
 
   @geomacy Seems to work by using a property, referenced in `<relativePath>${relative.path}</relativePath>`. By default, the property is set to `../brooklyn-server/parent/pom.xml` but is overridden in the `branded` profile to be empty.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [brooklyn-ui] ahgittin commented on issue #160: add relativePath to parent for release make

Posted by GitBox <gi...@apache.org>.
ahgittin commented on issue #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160#issuecomment-567953269
 
 
   nice answer re properties @tbouron -- maven says
   
   > Properties are not supported in the following XPath elements:
   > `/project(/parent)?/(groupId/artifactId/version)`
   
   pleasantly surprised that `relativePath` allows this!
   
   i confess i don't understand why we need to set the `relativePath` -- it shouldn't be required if the parent is in the local `.m2` repo, nor if the parent is built prior to the project on the same `mvn` run.  both of those should be the case here, right?
   
   if one of you can explain that that would be helpful, meanwhile i'll check whether the `BrooklynUiParentRelativePath` solution is sufficient for downstream projects, and open a PR building on this if so.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [brooklyn-ui] tbouron commented on issue #160: add relativePath to parent for release make

Posted by GitBox <gi...@apache.org>.
tbouron commented on issue #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160#issuecomment-567955148
 
 
   @ahgittin In normal circonstances, it is not needed because as you said, maven is able to fetch the parent pom by the version.
   
   However, when you do change the version when say, you do a release, then the new version (e.g `1.0.0` instead of `1.0.0-SNAPSHOT`) doesn't exist. Maven tries to download it from repositories but canot find it and therefore fails. Whereas if you do have the `<relativePath>` set up, maven falls back to use this during the build, which passes.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [brooklyn-ui] ahgittin commented on issue #160: add relativePath to parent for release make

Posted by GitBox <gi...@apache.org>.
ahgittin commented on issue #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160#issuecomment-567966459
 
 
   > Maven looks for the parent pom first in the reactor of currently building projects
   
   Seems ^ isn't happening so it does need `relativePath` when building a new version.  I suspect our use of `${revision}` is triggering a bug when ^ is resolved.  So +1 to this, and fixing things for downstream subsequently.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [brooklyn-ui] tbouron commented on issue #160: add relativePath to parent for release make

Posted by GitBox <gi...@apache.org>.
tbouron commented on issue #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160#issuecomment-567892302
 
 
   retest this please

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [brooklyn-ui] ahgittin commented on issue #160: add relativePath to parent for release make

Posted by GitBox <gi...@apache.org>.
ahgittin commented on issue #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160#issuecomment-567959949
 
 
   thanks.  i'll see if there's anything that jumps out in the make without `relativePath` but where i've been testing i think your property idea will work and is probably an improvement.  look out for a merge and new PR in a few minutes.
   
   also FYI from the Javadoc for getRelativePath():
   
   > Get the relative path of the parent pom.xml  file within the check
   out. The default value is ../pom.xml. Maven looks for the parent pom
   first in the reactor of currently building projects, then in this
   location on the filesystem, then the local repository, and lastly in
   the remote repo. relativePath allows you to select a different
   location, for example when your structure is flat, or deeper without
   an intermediate parent pom. However, the group ID, artifact ID and
   version are still required, and must match the file in the location
   given or it will revert to the repository for the POM. This feature is
   only for enhancing the development in a local checkout of that
   project.
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [brooklyn-ui] asfgit closed pull request #160: add relativePath to parent for release make

Posted by GitBox <gi...@apache.org>.
asfgit closed pull request #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160
 
 
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [brooklyn-ui] tbouron commented on issue #160: add relativePath to parent for release make

Posted by GitBox <gi...@apache.org>.
tbouron commented on issue #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160#issuecomment-567867335
 
 
   @geomacy I think so. Let me try quickly

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [brooklyn-ui] geomacy commented on issue #160: add relativePath to parent for release make

Posted by GitBox <gi...@apache.org>.
geomacy commented on issue #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160#issuecomment-567866553
 
 
   > @geomacy @ahgittin what about adding back the relative path (because Brooklyn needs it) but adding a profile (something like `branded`) which would set it to empty?
   
   Can you do that with a profile?
   
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [brooklyn-ui] tbouron commented on issue #160: add relativePath to parent for release make

Posted by GitBox <gi...@apache.org>.
tbouron commented on issue #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160#issuecomment-567958917
 
 
   Maybe we do something wrong. What I know is that, with the current state, if you try to follow the release instructions (by changing the version from `1.0.0-SNAPSHOT` to `1.0.0`) the `make_release_artifacts.sh` script fails at the start complaining about this.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [brooklyn-ui] tbouron commented on issue #160: add relativePath to parent for release make

Posted by GitBox <gi...@apache.org>.
tbouron commented on issue #160: add relativePath to parent for release make
URL: https://github.com/apache/brooklyn-ui/pull/160#issuecomment-567870966
 
 
   @geomacy Seems to works by using a property, referenced in `<relativePath>${relative.path</relativePath>. By default, the property is set to ./brooklyn-server/parent/pom.xml` but is overridden in the `branded` profile to be empty.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services