-
Notifications
You must be signed in to change notification settings - Fork 439
RATIS-2384. Add Bill of Materials project #1335
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
szetszwo
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@adoroszlai , thanks for working on this! Just have a minor comment inlined.
| <packaging>pom</packaging> | ||
|
|
||
| <properties> | ||
| <ratis.thirdparty.version>1.0.10</ratis.thirdparty.version> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not needed since the child pom can use the properties in the parent pom.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @szetszwo for the review, patch is updated. However, I've checked some other project BOMs and found that inheriting the main module may not be a good idea. Let me double-check.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are right netty bom does not inherit netty main (i.e. io.netty:netty-parent)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed, by ratis-bom inheriting Ratis root POM (ratis), downstream project (Ozone) gets all dependency definitions (e.g. slf4j-simple) from Ratis, which is not desired.
It seems there are two solutions:
- Make
ratis-bomindependent (no parent, at least notratis), and duplicate information likeratis.thirdparty.version. (And the list of Ratis submodules, which is already duplicated in this PR.) - Make
ratis-bomthe parent ofratis, see pattern in Maven docs. This is an additional inheritance layer, but it reduces duplication (including list of submodules).
I think we should now go with (1), since (2) is a bigger change, maybe suitable for Ratis 4.0.
szetszwo
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 the change looks good.
What changes were proposed in this pull request?
Create new submodule
ratis-bom(Bill of Materials) for easier dependency management in projects using Ratis.Before:
After:
https://issues.apache.org/jira/browse/RATIS-2384
How was this patch tested?
CI:
https://github.com/adoroszlai/ratis/actions/runs/21143136602
Also tried it locally by adding
ratis-bomto Ozone aftermvn -DskipTests install.