Define a constant instead of duplicating this literal "total" 8 times.
Open
Easy-Fixed
- Dominant language
- Java
- Stars
- 6.4k
- Forks
- 1.2k
- Avg merge
- 1d 23h
- Merged PRs (30d)
- 115
Description
Code Path:confignode/src/main/java/org/apache/iotdb/confignode/manager/load/LoadManagerMetrics.java
Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.
On the other hand, constants can be referenced from many places, but only need to be updated in a single place.
Contributor guide
Research direction
Open confignode/src/main/java/org/apache/iotdb/confignode/manager/load/LoadManagerMetrics.java and locate the eight duplicated "total" literals. Define one constant and use it for those references; done means the literal is no longer duplicated there and the existing behavior is unchanged.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- database
- Issue type
- Refactor
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 35/100