Skip to content
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-4624. Fix set configs from SCMHAConfiguration Object #1739

Merged
merged 1 commit into from Dec 31, 2020

Conversation

amaliujia
Copy link
Contributor

@amaliujia amaliujia commented Dec 26, 2020

What changes were proposed in this pull request?

When setting SCMHAConfigration object to OzoneConfiguration conf.setFromObject(scmhaConfiguration);:

java.lang.IllegalArgumentException: Attempt to get double field "org.apache.hadoop.hdds.scm.ha.SCMHAConfiguration.raftSegmentSize" with illegal data type conversion to long

In reflection, seems that a Double Field cannot be cast to Long at https://github.com/apache/ozone/blob/master/hadoop-hdds/config/src/main/java/org/apache/hadoop/hdds/conf/ConfigurationReflectionUtil.java#L247

What is the link to the Apache JIRA

https://issues.apache.org/jira/browse/HDDS-4624

How was this patch tested?

UT

@amaliujia
Copy link
Contributor Author

R: @nandakumar131 @GlenGeng @ChenSammi

@amaliujia amaliujia changed the title HDDS-4624. Fix set configs in SCMHAConfigration HDDS-4624. Fix set configs from SCMHAConfiguration Object Dec 26, 2020
@GlenGeng-awx
Copy link
Contributor

+1
LGTM. Thanks for the fix!

@ChenSammi ChenSammi merged commit f64a1ce into apache:HDDS-2823 Dec 31, 2020
@amaliujia amaliujia deleted the HDDS-4624 branch December 31, 2020 06:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants