From 764863d6f5692fde63e4a2f6cdd627cd8eec4e0a Mon Sep 17 00:00:00 2001 From: Dhruv Parthasarathy Date: Thu, 8 Aug 2013 16:40:10 -0700 Subject: [PATCH] made volatile. fixed parens --- server/src/main/java/com/metamx/druid/master/DruidMaster.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/src/main/java/com/metamx/druid/master/DruidMaster.java b/server/src/main/java/com/metamx/druid/master/DruidMaster.java index fde2de38239..6a019a60f04 100644 --- a/server/src/main/java/com/metamx/druid/master/DruidMaster.java +++ b/server/src/main/java/com/metamx/druid/master/DruidMaster.java @@ -95,7 +95,7 @@ public class DruidMaster private final Map loadManagementPeons; private final AtomicReference leaderLatch; - private AtomicReference segmentSettingsAtomicReference; + private volatile AtomicReference segmentSettingsAtomicReference; public DruidMaster( DruidMasterConfig config, @@ -467,7 +467,7 @@ public class DruidMaster serverInventoryView.start(); final List> masterRunnables = Lists.newArrayList(); - segmentSettingsAtomicReference = configManager.watch(MasterSegmentSettings.CONFIG_KEY, MasterSegmentSettings.class,(new MasterSegmentSettings.Builder()).build()); + segmentSettingsAtomicReference = configManager.watch(MasterSegmentSettings.CONFIG_KEY, MasterSegmentSettings.class,new MasterSegmentSettings.Builder().build()); masterRunnables.add(Pair.of(new MasterComputeManagerRunnable(), config.getMasterPeriod())); if (indexingServiceClient != null) {