You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by GitBox <gi...@apache.org> on 2020/09/30 17:45:23 UTC

[GitHub] [skywalking] muse-dev[bot] commented on a change in pull request #5608: Fix the failure of immutable enum checking

muse-dev[bot] commented on a change in pull request #5608:
URL: https://github.com/apache/skywalking/pull/5608#discussion_r497691902



##########
File path: apm-sniffer/apm-test-tools/src/main/java/org/apache/skywalking/apm/agent/core/context/MockContextSnapshot.java
##########
@@ -26,7 +26,7 @@
 public enum MockContextSnapshot {
     INSTANCE;
 
-    private ContextSnapshot contextSnapshot;
+    private final ContextSnapshot contextSnapshot;

Review comment:
       *ImmutableEnumChecker:*  enums should be immutable: 'MockContextSnapshot' has field 'contextSnapshot' of type 'org.apache.skywalking.apm.agent.core.context.ContextSnapshot', the declaration of type 'org.apache.skywalking.apm.agent.core.context.ContextSnapshot' is not annotated with @com.google.errorprone.annotations.Immutable




----------------------------------------------------------------
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:
users@infra.apache.org