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
HDDS-4730. Use separate Ratis admin and client ports #1887
Conversation
@@ -73,6 +74,7 @@ | |||
private String buildDate; | |||
private HddsProtos.NodeOperationalState persistedOpState; | |||
private long persistedOpStateExpiryEpochSec = 0; | |||
private final List<String> features = new ArrayList<>(); |
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.
I might have missed something:
Is there a JIRA or design doc that says what features in Datanode are?
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 just a way to help distinguish newly initialized datanodes from existing ones being restarted with new code version. No further features planned currently.
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! The changes look good to me. I have few minor comments inline.
public static final String SEPARATE_RATIS_PORTS_AVAILABLE = "RatisPorts"; | ||
|
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.
Can we define features in a separate class? We could also define them as enums.
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.
Yes, I can move it to separate class. I'd rather avoid enums, which are more type-safe, but worse for compatibility.
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.
Although not sure if it's worth extracting to another class at this time.
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.
I was suggesting separate class so that in future if new features are defined, it could all be in the same class for better accessibility.
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 @lokeshj1703 for the suggestion. Extracted to separate class. Also changed to using version numbers instead of "features". I think this will be simpler in the long run. Features of the datanode can be mapped at runtime (eg. if version > 0, then we have this "separate ports" feature).
...java/org/apache/hadoop/ozone/container/common/transport/server/ratis/XceiverServerRatis.java
Show resolved
Hide resolved
@elek @bshashikant @lokeshj1703 @amaliujia Thanks for the reviews so far. Do you have any comment on the latest patch, can I merge it? |
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 updating the PR! The changes look good to me. +1.
Thanks all for the review. |
What changes were proposed in this pull request?
Move Datanode's Ratis server-to-server and admin communication to other ports and use separate TLS config.
ozonesecure
cluster.https://issues.apache.org/jira/browse/HDDS-4730
How was this patch tested?
Regular CI:
https://github.com/adoroszlai/hadoop-ozone/actions/runs/531656927