p-szucs commented on code in PR #6821: URL: https://github.com/apache/hadoop/pull/6821#discussion_r1599505033
########## hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/linux/resources/ResourceHandlerModule.java: ########## @@ -63,35 +63,54 @@ public class ResourceHandlerModule { * as resource metrics functionality. We need to ensure that the same * instance is used for both. */ + private static volatile CGroupsHandler cGroupsV1Handler; Review Comment: Sure, I fixed it ########## hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/linux/resources/ResourceHandlerModule.java: ########## @@ -63,35 +63,54 @@ public class ResourceHandlerModule { * as resource metrics functionality. We need to ensure that the same * instance is used for both. */ + private static volatile CGroupsHandler cGroupsV1Handler; + private static volatile CGroupsHandler cGroupsV2Handler; private static volatile TrafficControlBandwidthHandlerImpl trafficControlBandwidthHandler; private static volatile NetworkPacketTaggingHandlerImpl networkPacketTaggingHandlerImpl; - private static volatile CGroupsHandler cGroupsHandler; private static volatile CGroupsBlkioResourceHandlerImpl cGroupsBlkioResourceHandler; private static volatile MemoryResourceHandler cGroupsMemoryResourceHandler; private static volatile CpuResourceHandler cGroupsCpuResourceHandler; - /** - * Returns an initialized, thread-safe CGroupsHandler instance. - */ - private static CGroupsHandler getInitializedCGroupsHandler(Configuration conf) + private static void initializeCGroupsHandlers(Configuration conf) throws ResourceHandlerException { Review Comment: Fixed the naming here as well. -- 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. To unsubscribe, e-mail: common-issues-unsubscr...@hadoop.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: common-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: common-issues-h...@hadoop.apache.org