[ 
https://issues.apache.org/jira/browse/RATIS-1991?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

huangzhaobo updated RATIS-1991:
-------------------------------
    Description: 
Change the judgment logic:
It is necessary to determine whether the effective is null, rather than 
newValue.

Because the parameter of the {{properties.set}} method is {{{}effective{}}}.
{code:java}
final String effective = reconfigureProperty(property, newValue);
LOG.info("{}: changed property {} to {} (effective {})", name, property, 
newValue, effective);
if (newValue != null) {
  properties.set(property, effective);
} else {
  properties.unset(property);
} {code}

> Optimize the reconfig judgment logic in the ReconfigurationBase class.
> ----------------------------------------------------------------------
>
>                 Key: RATIS-1991
>                 URL: https://issues.apache.org/jira/browse/RATIS-1991
>             Project: Ratis
>          Issue Type: Improvement
>            Reporter: huangzhaobo
>            Priority: Minor
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> Change the judgment logic:
> It is necessary to determine whether the effective is null, rather than 
> newValue.
> Because the parameter of the {{properties.set}} method is {{{}effective{}}}.
> {code:java}
> final String effective = reconfigureProperty(property, newValue);
> LOG.info("{}: changed property {} to {} (effective {})", name, property, 
> newValue, effective);
> if (newValue != null) {
>   properties.set(property, effective);
> } else {
>   properties.unset(property);
> } {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to