Xiang Yang has posted comments on this change. ( http://gerrit.cloudera.org:8080/18828 )
Change subject: IMPALA-11469: (Addendum) Refactor BackendConfig for tests ...................................................................... Patch Set 3: (1 comment) http://gerrit.cloudera.org:8080/#/c/18828/3/fe/src/main/java/org/apache/impala/service/BackendConfig.java File fe/src/main/java/org/apache/impala/service/BackendConfig.java: http://gerrit.cloudera.org:8080/#/c/18828/3/fe/src/main/java/org/apache/impala/service/BackendConfig.java@80 PS3, Line 80: public static void create(TBackendGflags cfg, boolean initialize) { make 'INSTANCE' public and mutable is terrible, especially the assignment is not synchronized. maybe we can add 'synchronized' to decorate the create() method and add 'volatile' to decorate the 'INSTANCE' property like Double-Checked Lock to alleviate the problem? or we can just remove the 'INSTANCE' property, every call should cache a instance by itself. -- To view, visit http://gerrit.cloudera.org:8080/18828 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I802fcbf70808f2127197f720a7247c3d85389d6f Gerrit-Change-Number: 18828 Gerrit-PatchSet: 3 Gerrit-Owner: Michael Smith <[email protected]> Gerrit-Reviewer: Impala Public Jenkins <[email protected]> Gerrit-Reviewer: Joe McDonnell <[email protected]> Gerrit-Reviewer: Michael Smith <[email protected]> Gerrit-Reviewer: Quanlong Huang <[email protected]> Gerrit-Reviewer: Xiang Yang <[email protected]> Gerrit-Comment-Date: Thu, 11 Aug 2022 06:12:06 +0000 Gerrit-HasComments: Yes
