elek commented on a change in pull request #2136:
URL: https://github.com/apache/ozone/pull/2136#discussion_r620229602
##########
File path:
hadoop-hdds/common/src/main/java/org/apache/hadoop/hdds/client/RatisReplicationConfig.java
##########
@@ -35,6 +35,16 @@ public RatisReplicationConfig(ReplicationFactor
replicationFactor) {
this.replicationFactor = replicationFactor;
}
+ public RatisReplicationConfig(String factorString) {
+ ReplicationFactor factor = null;
+ try {
+ factor = ReplicationFactor.valueOf(Integer.parseInt(factorString));
+ } catch (NumberFormatException ex) {
+ factor = ReplicationFactor.valueOf(factorString);
Review comment:
In general the expected values are `ONE` and `THREE` but this code adds
support to parse `ozone.replication` which can be 1 and 3 today. Long-term it
will enable to use `3:2` in the `ozone.replication` (but we also need to
configure EC as default `replicationType`)
--
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:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]