Conversation
… addresses to OAPNodeChecker
Codecov Report
@@ Coverage Diff @@
## master #5784 +/- ##
============================================
- Coverage 51.64% 44.13% -7.51%
+ Complexity 3486 448 -3038
============================================
Files 1642 1641 -1
Lines 35112 35168 +56
Branches 3833 4454 +621
============================================
- Hits 18133 15521 -2612
- Misses 16081 18726 +2645
- Partials 898 921 +23
Continue to review full report at Codecov.
|
| instance.getAddress().setSelf(true); | ||
| List<RemoteInstance> remoteInstances = new ArrayList<>(20); | ||
| try { | ||
| initHealthChecker(); |
There was a problem hiding this comment.
THREAD_SAFETY_VIOLATION: Unprotected write. Non-private method ZookeeperCoordinator.queryRemoteNodes() indirectly writes to field this.healthChecker outside of synchronization.
Reporting because another access to the same memory occurs on a background thread, although this access may not.
| private final ServiceDiscovery<RemoteInstance> serviceDiscovery; | ||
| private final ServiceCache<RemoteInstance> serviceCache; | ||
| private volatile Address selfAddress; | ||
| @Setter |
There was a problem hiding this comment.
THREAD_SAFETY_VIOLATION: Unprotected write. Non-private method ZookeeperCoordinator.setHealthChecker(...) writes to field this.healthChecker outside of synchronization.
Reporting because another access to the same memory occurs on a background thread, although this access may not.
| private volatile Address selfAddress; | ||
| @Setter | ||
| private HealthCheckMetrics healthChecker; | ||
| private final ModuleDefineHolder manager; |
There was a problem hiding this comment.
Move final to following other final fields in the top of the list.
| private final ServiceDiscovery<RemoteInstance> serviceDiscovery; | ||
| private final ServiceCache<RemoteInstance> serviceCache; | ||
| private volatile Address selfAddress; | ||
| @Setter |
There was a problem hiding this comment.
You don't need the setter I think. Please don't open unnecessary access.
wu-sheng
left a comment
There was a problem hiding this comment.
Two code style issues, please fix them in all implementations. Others look good to me.
|
Greate, will fix now |
|
Done |
CHANGESlog.