Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 7BC3F200B27 for ; Wed, 8 Jun 2016 02:05:47 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 79FC4160A60; Wed, 8 Jun 2016 00:05:47 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 136BC160A5C for ; Wed, 8 Jun 2016 02:05:44 +0200 (CEST) Received: (qmail 12063 invoked by uid 500); 8 Jun 2016 00:05:44 -0000 Mailing-List: contact commits-help@geode.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@geode.incubator.apache.org Delivered-To: mailing list commits@geode.incubator.apache.org Received: (qmail 12053 invoked by uid 99); 8 Jun 2016 00:05:44 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 08 Jun 2016 00:05:44 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id A35B618046E for ; Wed, 8 Jun 2016 00:05:43 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -4.646 X-Spam-Level: X-Spam-Status: No, score=-4.646 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, KAM_LAZY_DOMAIN_SECURITY=1, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-1.426] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id DKEK9o0PScMz for ; Wed, 8 Jun 2016 00:05:07 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with SMTP id 9CD0360E40 for ; Wed, 8 Jun 2016 00:04:40 +0000 (UTC) Received: (qmail 3503 invoked by uid 99); 8 Jun 2016 00:04:39 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 08 Jun 2016 00:04:39 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 74C7EE0200; Wed, 8 Jun 2016 00:04:39 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: klund@apache.org To: commits@geode.incubator.apache.org Date: Wed, 08 Jun 2016 00:05:09 -0000 Message-Id: <5d7d4ecf43694642ab01979d21def71e@git.apache.org> In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [32/90] [abbrv] incubator-geode git commit: GEODE-1377: Initial move of system properties from private to public archived-at: Wed, 08 Jun 2016 00:05:47 -0000 http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EntryExpiryTask.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EntryExpiryTask.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EntryExpiryTask.java index 64b669a..252c9c3 100644 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EntryExpiryTask.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EntryExpiryTask.java @@ -21,21 +21,14 @@ package com.gemstone.gemfire.internal.cache; * EntryExpiryTask represents a timeout event for a region entry. */ -import java.util.concurrent.locks.Lock; - -import org.apache.logging.log4j.Logger; - -import com.gemstone.gemfire.cache.CacheException; -import com.gemstone.gemfire.cache.EntryDestroyedException; -import com.gemstone.gemfire.cache.EntryNotFoundException; -import com.gemstone.gemfire.cache.ExpirationAction; -import com.gemstone.gemfire.cache.ExpirationAttributes; -import com.gemstone.gemfire.cache.Operation; -import com.gemstone.gemfire.cache.Region; -import com.gemstone.gemfire.cache.TimeoutException; +import com.gemstone.gemfire.cache.*; +import com.gemstone.gemfire.distributed.internal.DistributionConfig; import com.gemstone.gemfire.internal.InternalStatisticsDisabledException; import com.gemstone.gemfire.internal.logging.LogService; import com.gemstone.gemfire.internal.offheap.annotations.Released; +import org.apache.logging.log4j.Logger; + +import java.util.concurrent.locks.Lock; public class EntryExpiryTask extends ExpiryTask { @@ -54,7 +47,7 @@ public class EntryExpiryTask extends ExpiryTask { * necessary. */ public static boolean expireSendsEntryAsCallback = - Boolean.getBoolean("gemfire.EXPIRE_SENDS_ENTRY_AS_CALLBACK"); + Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "EXPIRE_SENDS_ENTRY_AS_CALLBACK"); protected EntryExpiryTask(LocalRegion region, RegionEntry re) { super(region); http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EventID.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EventID.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EventID.java index 794d4d7..a9fb7da 100755 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EventID.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EventID.java @@ -16,25 +16,11 @@ */ package com.gemstone.gemfire.internal.cache; -import java.io.ByteArrayInputStream; -import java.io.DataInput; -import java.io.DataInputStream; -import java.io.DataOutput; -import java.io.Externalizable; -import java.io.IOException; -import java.io.ObjectInput; -import java.io.ObjectOutput; -import java.io.Serializable; -import java.nio.ByteBuffer; -import java.util.Arrays; -import java.util.concurrent.atomic.AtomicLong; - -import org.apache.logging.log4j.Logger; - import com.gemstone.gemfire.DataSerializer; import com.gemstone.gemfire.InternalGemFireException; import com.gemstone.gemfire.distributed.DistributedMember; import com.gemstone.gemfire.distributed.DistributedSystem; +import com.gemstone.gemfire.distributed.internal.DistributionConfig; import com.gemstone.gemfire.distributed.internal.membership.InternalDistributedMember; import com.gemstone.gemfire.internal.DataSerializableFixedID; import com.gemstone.gemfire.internal.HeapDataOutputStream; @@ -46,6 +32,12 @@ import com.gemstone.gemfire.internal.i18n.LocalizedStrings; import com.gemstone.gemfire.internal.logging.LogService; import com.gemstone.gemfire.internal.logging.log4j.LogMarker; import com.gemstone.gemfire.internal.util.Breadcrumbs; +import org.apache.logging.log4j.Logger; + +import java.io.*; +import java.nio.ByteBuffer; +import java.util.Arrays; +import java.util.concurrent.atomic.AtomicLong; /** * This class uniquely identifies any Region Operation like create, update @@ -61,7 +53,7 @@ public final class EventID private static final Logger logger = LogService.getLogger(); /** turns on very verbose logging ove membership id bytes */ - private static boolean LOG_ID_BYTES = Boolean.getBoolean("gemfire.log-event-member-id-bytes"); + private static boolean LOG_ID_BYTES = Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "log-event-member-id-bytes"); /** * Uniquely identifies the distributed member VM in which the Event is http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EventTracker.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EventTracker.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EventTracker.java index b4d4620..ee24cf9 100644 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EventTracker.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/EventTracker.java @@ -19,23 +19,11 @@ */ package com.gemstone.gemfire.internal.cache; -import java.io.DataInput; -import java.io.DataOutput; -import java.io.IOException; -import java.util.HashMap; -import java.util.Iterator; -import java.util.LinkedList; -import java.util.List; -import java.util.Map; -import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.ConcurrentMap; - -import org.apache.logging.log4j.Logger; - import com.gemstone.gemfire.DataSerializable; import com.gemstone.gemfire.DataSerializer; import com.gemstone.gemfire.cache.client.PoolFactory; import com.gemstone.gemfire.distributed.DistributedMember; +import com.gemstone.gemfire.distributed.internal.DistributionConfig; import com.gemstone.gemfire.distributed.internal.membership.InternalDistributedMember; import com.gemstone.gemfire.internal.Assert; import com.gemstone.gemfire.internal.SystemTimer.SystemTimerTask; @@ -45,6 +33,14 @@ import com.gemstone.gemfire.internal.cache.versions.VersionTag; import com.gemstone.gemfire.internal.logging.LogService; import com.gemstone.gemfire.internal.logging.log4j.LogMarker; import com.gemstone.gemfire.internal.util.concurrent.StoppableCountDownLatch; +import org.apache.logging.log4j.Logger; + +import java.io.DataInput; +import java.io.DataOutput; +import java.io.IOException; +import java.util.*; +import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.ConcurrentMap; /** * EventTracker tracks the last sequence number for a particular @@ -123,7 +119,7 @@ public class EventTracker * @param cache the cache to schedule tasks with */ public static ExpiryTask startTrackerServices(GemFireCacheImpl cache) { - long expiryTime = Long.getLong("gemfire.messageTrackingTimeout", + long expiryTime = Long.getLong(DistributionConfig.GEMFIRE_PREFIX + "messageTrackingTimeout", PoolFactory.DEFAULT_SUBSCRIPTION_MESSAGE_TRACKING_TIMEOUT / 3).longValue(); ExpiryTask result = new ExpiryTask(cache, expiryTime); cache.getCCPTimer().scheduleAtFixedRate(result, http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/ExpirationScheduler.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/ExpirationScheduler.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/ExpirationScheduler.java index 2bfce5a..754db38 100644 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/ExpirationScheduler.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/ExpirationScheduler.java @@ -16,16 +16,16 @@ */ package com.gemstone.gemfire.internal.cache; -import java.util.concurrent.atomic.AtomicInteger; - -import org.apache.logging.log4j.Logger; - import com.gemstone.gemfire.cache.EntryNotFoundException; +import com.gemstone.gemfire.distributed.internal.DistributionConfig; import com.gemstone.gemfire.distributed.internal.InternalDistributedSystem; import com.gemstone.gemfire.internal.SystemTimer; import com.gemstone.gemfire.internal.i18n.LocalizedStrings; import com.gemstone.gemfire.internal.logging.LogService; import com.gemstone.gemfire.internal.logging.log4j.LocalizedMessage; +import org.apache.logging.log4j.Logger; + +import java.util.concurrent.atomic.AtomicInteger; /** * ExpirationScheduler uses a single instance of java.util.Timer (and @@ -39,7 +39,7 @@ public class ExpirationScheduler private final SystemTimer timer; private final AtomicInteger pendingCancels = new AtomicInteger(); - private static final int MAX_PENDING_CANCELS = Integer.getInteger("gemfire.MAX_PENDING_CANCELS", 10000).intValue(); + private static final int MAX_PENDING_CANCELS = Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "MAX_PENDING_CANCELS", 10000).intValue(); public ExpirationScheduler(InternalDistributedSystem ds) { this.timer = new SystemTimer(ds, true); http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/ExpiryTask.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/ExpiryTask.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/ExpiryTask.java index 54f0b23..3f5b944 100644 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/ExpiryTask.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/ExpiryTask.java @@ -21,22 +21,11 @@ package com.gemstone.gemfire.internal.cache; * ExpiryTask represents a timeout event for expiration */ -import java.util.concurrent.RejectedExecutionException; -import java.util.concurrent.SynchronousQueue; -import java.util.concurrent.ThreadFactory; -import java.util.concurrent.ThreadPoolExecutor; - -import org.apache.logging.log4j.Logger; - import com.gemstone.gemfire.CancelException; import com.gemstone.gemfire.InternalGemFireError; import com.gemstone.gemfire.SystemFailure; -import com.gemstone.gemfire.cache.CacheException; -import com.gemstone.gemfire.cache.CacheWriterException; -import com.gemstone.gemfire.cache.EntryNotFoundException; -import com.gemstone.gemfire.cache.ExpirationAction; -import com.gemstone.gemfire.cache.ExpirationAttributes; -import com.gemstone.gemfire.cache.RegionDestroyedException; +import com.gemstone.gemfire.cache.*; +import com.gemstone.gemfire.distributed.internal.DistributionConfig; import com.gemstone.gemfire.distributed.internal.InternalDistributedSystem; import com.gemstone.gemfire.distributed.internal.PooledExecutorWithDMStats; import com.gemstone.gemfire.internal.SystemTimer; @@ -45,6 +34,12 @@ import com.gemstone.gemfire.internal.logging.LogService; import com.gemstone.gemfire.internal.logging.LoggingThreadGroup; import com.gemstone.gemfire.internal.logging.log4j.LocalizedMessage; import com.gemstone.gemfire.internal.tcp.ConnectionTable; +import org.apache.logging.log4j.Logger; + +import java.util.concurrent.RejectedExecutionException; +import java.util.concurrent.SynchronousQueue; +import java.util.concurrent.ThreadFactory; +import java.util.concurrent.ThreadPoolExecutor; public abstract class ExpiryTask extends SystemTimer.SystemTimerTask { @@ -56,7 +51,7 @@ public abstract class ExpiryTask extends SystemTimer.SystemTimerTask { static { // default to inline expiry to fix bug 37115 - int nThreads = Integer.getInteger("gemfire.EXPIRY_THREADS", 0).intValue(); + int nThreads = Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "EXPIRY_THREADS", 0).intValue(); if (nThreads > 0) { ThreadFactory tf = new ThreadFactory() { private int nextId = 0; http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/FixedPartitionAttributesImpl.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/FixedPartitionAttributesImpl.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/FixedPartitionAttributesImpl.java index d631413..e0b915a 100644 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/FixedPartitionAttributesImpl.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/FixedPartitionAttributesImpl.java @@ -17,13 +17,14 @@ package com.gemstone.gemfire.internal.cache; -import java.io.DataInput; -import java.io.DataOutput; -import java.io.IOException; - import com.gemstone.gemfire.DataSerializable; import com.gemstone.gemfire.DataSerializer; import com.gemstone.gemfire.cache.FixedPartitionAttributes; +import com.gemstone.gemfire.distributed.internal.DistributionConfig; + +import java.io.DataInput; +import java.io.DataOutput; +import java.io.IOException; /** * Internal implementation of {@link FixedPartitionAttributes}. @@ -146,7 +147,7 @@ public class FixedPartitionAttributesImpl extends FixedPartitionAttributes s.append("FixedPartitionAttributes@").append("[partitionName=").append( this.partitionName).append(";isPrimary=").append(this.isPrimary) .append(";numBuckets=").append(this.numBuckets); - if (Boolean.getBoolean("gemfire.PRDebug")) { + if (Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "PRDebug")) { s.append(";startingBucketID= ").append(this.startingBucketID); } s.append("]"); http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/GemFireCacheImpl.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/GemFireCacheImpl.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/GemFireCacheImpl.java index 64b4949..b08c480 100755 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/GemFireCacheImpl.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/GemFireCacheImpl.java @@ -17,110 +17,15 @@ package com.gemstone.gemfire.internal.cache; -import java.io.BufferedReader; -import java.io.ByteArrayInputStream; -import java.io.ByteArrayOutputStream; -import java.io.File; -import java.io.IOException; -import java.io.InputStream; -import java.io.InputStreamReader; -import java.io.OutputStream; -import java.io.OutputStreamWriter; -import java.io.PrintStream; -import java.io.Reader; -import java.io.StringBufferInputStream; -import java.io.StringWriter; -import java.io.Writer; -import java.lang.reflect.Method; -import java.net.InetSocketAddress; -import java.net.URL; -import java.net.UnknownHostException; -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.Date; -import java.util.HashMap; -import java.util.HashSet; -import java.util.Iterator; -import java.util.LinkedHashMap; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Map; -import java.util.Map.Entry; -import java.util.Properties; -import java.util.ServiceLoader; -import java.util.Set; -import java.util.TreeMap; -import java.util.concurrent.ArrayBlockingQueue; -import java.util.concurrent.CancellationException; -import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.ConcurrentMap; -import java.util.concurrent.CopyOnWriteArrayList; -import java.util.concurrent.CopyOnWriteArraySet; -import java.util.concurrent.ExecutionException; -import java.util.concurrent.Executor; -import java.util.concurrent.ExecutorService; -import java.util.concurrent.Executors; -import java.util.concurrent.Future; -import java.util.concurrent.LinkedBlockingQueue; -import java.util.concurrent.RejectedExecutionException; -import java.util.concurrent.ThreadFactory; -import java.util.concurrent.ThreadPoolExecutor; -import java.util.concurrent.TimeUnit; -import java.util.concurrent.atomic.AtomicBoolean; -import java.util.concurrent.atomic.AtomicInteger; -import java.util.concurrent.atomic.AtomicReference; - -import javax.naming.Context; - -import org.apache.logging.log4j.Logger; - -import com.gemstone.gemfire.CancelCriterion; -import com.gemstone.gemfire.CancelException; -import com.gemstone.gemfire.ForcedDisconnectException; -import com.gemstone.gemfire.GemFireCacheException; -import com.gemstone.gemfire.InternalGemFireError; -import com.gemstone.gemfire.LogWriter; -import com.gemstone.gemfire.SystemFailure; +import com.gemstone.gemfire.*; import com.gemstone.gemfire.admin.internal.SystemMemberCacheEventProcessor; -import com.gemstone.gemfire.cache.AttributesFactory; -import com.gemstone.gemfire.cache.Cache; -import com.gemstone.gemfire.cache.CacheClosedException; -import com.gemstone.gemfire.cache.CacheException; -import com.gemstone.gemfire.cache.CacheExistsException; -import com.gemstone.gemfire.cache.CacheRuntimeException; -import com.gemstone.gemfire.cache.CacheTransactionManager; -import com.gemstone.gemfire.cache.CacheWriterException; -import com.gemstone.gemfire.cache.CacheXmlException; -import com.gemstone.gemfire.cache.DataPolicy; -import com.gemstone.gemfire.cache.Declarable; -import com.gemstone.gemfire.cache.DiskStore; -import com.gemstone.gemfire.cache.DiskStoreFactory; -import com.gemstone.gemfire.cache.DynamicRegionFactory; -import com.gemstone.gemfire.cache.EvictionAction; -import com.gemstone.gemfire.cache.EvictionAttributes; -import com.gemstone.gemfire.cache.GatewayException; -import com.gemstone.gemfire.cache.Operation; -import com.gemstone.gemfire.cache.PartitionAttributesFactory; -import com.gemstone.gemfire.cache.Region; -import com.gemstone.gemfire.cache.RegionAttributes; -import com.gemstone.gemfire.cache.RegionDestroyedException; -import com.gemstone.gemfire.cache.RegionExistsException; -import com.gemstone.gemfire.cache.RegionFactory; -import com.gemstone.gemfire.cache.RegionService; -import com.gemstone.gemfire.cache.RegionShortcut; -import com.gemstone.gemfire.cache.Scope; +import com.gemstone.gemfire.cache.*; import com.gemstone.gemfire.cache.TimeoutException; import com.gemstone.gemfire.cache.asyncqueue.AsyncEventQueue; import com.gemstone.gemfire.cache.asyncqueue.AsyncEventQueueFactory; import com.gemstone.gemfire.cache.asyncqueue.internal.AsyncEventQueueFactoryImpl; import com.gemstone.gemfire.cache.asyncqueue.internal.AsyncEventQueueImpl; -import com.gemstone.gemfire.cache.client.ClientCache; -import com.gemstone.gemfire.cache.client.ClientRegionFactory; -import com.gemstone.gemfire.cache.client.ClientRegionShortcut; -import com.gemstone.gemfire.cache.client.Pool; -import com.gemstone.gemfire.cache.client.PoolFactory; -import com.gemstone.gemfire.cache.client.PoolManager; +import com.gemstone.gemfire.cache.client.*; import com.gemstone.gemfire.cache.client.internal.ClientMetadataService; import com.gemstone.gemfire.cache.client.internal.ClientRegionFactoryImpl; import com.gemstone.gemfire.cache.client.internal.PoolImpl; @@ -134,38 +39,17 @@ import com.gemstone.gemfire.cache.query.internal.cq.CqServiceProvider; import com.gemstone.gemfire.cache.server.CacheServer; import com.gemstone.gemfire.cache.snapshot.CacheSnapshotService; import com.gemstone.gemfire.cache.util.GatewayConflictResolver; -import com.gemstone.gemfire.cache.util.ObjectSizer; import com.gemstone.gemfire.cache.wan.GatewayReceiver; import com.gemstone.gemfire.cache.wan.GatewayReceiverFactory; import com.gemstone.gemfire.cache.wan.GatewaySender; import com.gemstone.gemfire.cache.wan.GatewaySenderFactory; -import com.gemstone.gemfire.distributed.DistributedLockService; -import com.gemstone.gemfire.distributed.DistributedMember; -import com.gemstone.gemfire.distributed.DistributedSystem; -import com.gemstone.gemfire.distributed.DistributedSystemDisconnectedException; -import com.gemstone.gemfire.distributed.Locator; -import com.gemstone.gemfire.distributed.internal.DM; -import com.gemstone.gemfire.distributed.internal.DistributionAdvisee; -import com.gemstone.gemfire.distributed.internal.DistributionAdvisor; +import com.gemstone.gemfire.distributed.*; +import com.gemstone.gemfire.distributed.internal.*; import com.gemstone.gemfire.distributed.internal.DistributionAdvisor.Profile; -import com.gemstone.gemfire.distributed.internal.DistributionConfig; -import com.gemstone.gemfire.distributed.internal.DistributionManager; -import com.gemstone.gemfire.distributed.internal.InternalDistributedSystem; -import com.gemstone.gemfire.distributed.internal.InternalLocator; -import com.gemstone.gemfire.distributed.internal.PooledExecutorWithDMStats; -import com.gemstone.gemfire.distributed.internal.ReplyException; -import com.gemstone.gemfire.distributed.internal.ReplyProcessor21; -import com.gemstone.gemfire.distributed.internal.ResourceEvent; -import com.gemstone.gemfire.distributed.internal.ResourceEventsListener; -import com.gemstone.gemfire.distributed.internal.ServerLocation; import com.gemstone.gemfire.distributed.internal.locks.DLockService; import com.gemstone.gemfire.distributed.internal.membership.InternalDistributedMember; import com.gemstone.gemfire.i18n.LogWriterI18n; -import com.gemstone.gemfire.internal.Assert; -import com.gemstone.gemfire.internal.ClassPathLoader; -import com.gemstone.gemfire.internal.JarDeployer; -import com.gemstone.gemfire.internal.SocketCreator; -import com.gemstone.gemfire.internal.SystemTimer; +import com.gemstone.gemfire.internal.*; import com.gemstone.gemfire.internal.cache.control.InternalResourceManager; import com.gemstone.gemfire.internal.cache.control.InternalResourceManager.ResourceType; import com.gemstone.gemfire.internal.cache.control.ResourceAdvisor; @@ -183,12 +67,7 @@ import com.gemstone.gemfire.internal.cache.persistence.PersistentMemberID; import com.gemstone.gemfire.internal.cache.persistence.PersistentMemberManager; import com.gemstone.gemfire.internal.cache.persistence.query.TemporaryResultSetFactory; import com.gemstone.gemfire.internal.cache.snapshot.CacheSnapshotServiceImpl; -import com.gemstone.gemfire.internal.cache.tier.sockets.AcceptorImpl; -import com.gemstone.gemfire.internal.cache.tier.sockets.CacheClientNotifier; -import com.gemstone.gemfire.internal.cache.tier.sockets.CacheClientProxy; -import com.gemstone.gemfire.internal.cache.tier.sockets.ClientHealthMonitor; -import com.gemstone.gemfire.internal.cache.tier.sockets.ClientProxyMembershipID; -import com.gemstone.gemfire.internal.cache.tier.sockets.ServerConnection; +import com.gemstone.gemfire.internal.cache.tier.sockets.*; import com.gemstone.gemfire.internal.cache.wan.AbstractGatewaySender; import com.gemstone.gemfire.internal.cache.wan.GatewaySenderAdvisor; import com.gemstone.gemfire.internal.cache.wan.WANServiceProvider; @@ -228,6 +107,19 @@ import com.gemstone.gemfire.pdx.internal.TypeRegistry; import com.gemstone.gemfire.redis.GemFireRedisServer; import com.sun.jna.Native; import com.sun.jna.Platform; +import org.apache.logging.log4j.Logger; + +import javax.naming.Context; +import java.io.*; +import java.net.InetSocketAddress; +import java.net.URL; +import java.net.UnknownHostException; +import java.util.*; +import java.util.Map.Entry; +import java.util.concurrent.*; +import java.util.concurrent.atomic.AtomicBoolean; +import java.util.concurrent.atomic.AtomicInteger; +import java.util.concurrent.atomic.AtomicReference; // @todo somebody Come up with more reasonable values for {@link #DEFAULT_LOCK_TIMEOUT}, etc. /** @@ -241,12 +133,12 @@ public class GemFireCacheImpl implements InternalCache, ClientCache, HasCachePer // moved *SERIAL_NUMBER stuff to DistributionAdvisor /** The default number of seconds to wait for a distributed lock */ - public static final int DEFAULT_LOCK_TIMEOUT = Integer.getInteger("gemfire.Cache.defaultLockTimeout", 60).intValue(); + public static final int DEFAULT_LOCK_TIMEOUT = Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "Cache.defaultLockTimeout", 60).intValue(); /** * The default duration (in seconds) of a lease on a distributed lock */ - public static final int DEFAULT_LOCK_LEASE = Integer.getInteger("gemfire.Cache.defaultLockLease", 120).intValue(); + public static final int DEFAULT_LOCK_LEASE = Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "Cache.defaultLockLease", 120).intValue(); /** The default "copy on read" attribute value */ public static final boolean DEFAULT_COPY_ON_READ = false; @@ -261,7 +153,7 @@ public class GemFireCacheImpl implements InternalCache, ClientCache, HasCachePer /** * The default amount of time to wait for a netSearch to complete */ - public static final int DEFAULT_SEARCH_TIMEOUT = Integer.getInteger("gemfire.Cache.defaultSearchTimeout", 300).intValue(); + public static final int DEFAULT_SEARCH_TIMEOUT = Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "Cache.defaultSearchTimeout", 300).intValue(); /** * The CacheLifecycleListener s that have been registered in this VM @@ -271,7 +163,7 @@ public class GemFireCacheImpl implements InternalCache, ClientCache, HasCachePer /** * Define gemfire.Cache.ASYNC_EVENT_LISTENERS=true to invoke event listeners in the background */ - private static final boolean ASYNC_EVENT_LISTENERS = Boolean.getBoolean("gemfire.Cache.ASYNC_EVENT_LISTENERS"); + private static final boolean ASYNC_EVENT_LISTENERS = Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "Cache.ASYNC_EVENT_LISTENERS"); /** * If true then when a delta is applied the size of the entry value will be recalculated. If false (the default) then @@ -279,20 +171,21 @@ public class GemFireCacheImpl implements InternalCache, ClientCache, HasCachePer * * @since GemFire hitachi 6.1.2.9 */ - public static boolean DELTAS_RECALCULATE_SIZE = Boolean.getBoolean("gemfire.DELTAS_RECALCULATE_SIZE"); + public static boolean DELTAS_RECALCULATE_SIZE = Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "DELTAS_RECALCULATE_SIZE"); - public static final int EVENT_QUEUE_LIMIT = Integer.getInteger("gemfire.Cache.EVENT_QUEUE_LIMIT", 4096).intValue(); - public static final int EVENT_THREAD_LIMIT = Integer.getInteger("gemfire.Cache.EVENT_THREAD_LIMIT", 16).intValue(); + public static final int EVENT_QUEUE_LIMIT = Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "Cache.EVENT_QUEUE_LIMIT", 4096).intValue(); + public static final int EVENT_THREAD_LIMIT = Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "Cache.EVENT_THREAD_LIMIT", 16).intValue(); /** * System property to limit the max query-execution time. By default its turned off (-1), the time is set in MiliSecs. */ - public static final int MAX_QUERY_EXECUTION_TIME = Integer.getInteger("gemfire.Cache.MAX_QUERY_EXECUTION_TIME", -1).intValue(); + public static final int MAX_QUERY_EXECUTION_TIME = Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "Cache.MAX_QUERY_EXECUTION_TIME", -1).intValue(); /** * System property to disable query monitor even if resource manager is in use */ - public final boolean QUERY_MONITOR_DISABLED_FOR_LOW_MEM = Boolean.getBoolean("gemfire.Cache.DISABLE_QUERY_MONITOR_FOR_LOW_MEMORY"); + public final boolean QUERY_MONITOR_DISABLED_FOR_LOW_MEM = Boolean + .getBoolean(DistributionConfig.GEMFIRE_PREFIX + "Cache.DISABLE_QUERY_MONITOR_FOR_LOW_MEMORY"); /** * Property set to true if resource manager heap percentage is set and query monitor is required @@ -307,7 +200,7 @@ public class GemFireCacheImpl implements InternalCache, ClientCache, HasCachePer /** * True if the user is allowed lock when memory resources appear to be overcommitted. */ - public static final boolean ALLOW_MEMORY_LOCK_WHEN_OVERCOMMITTED = Boolean.getBoolean("gemfire.Cache.ALLOW_MEMORY_OVERCOMMIT"); + public static final boolean ALLOW_MEMORY_LOCK_WHEN_OVERCOMMITTED = Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "Cache.ALLOW_MEMORY_OVERCOMMIT"); //time in ms private static final int FIVE_HOURS = 5 * 60 * 60 * 1000; @@ -550,7 +443,7 @@ public class GemFireCacheImpl implements InternalCache, ClientCache, HasCachePer /** {@link PropertyResolver} to resolve ${} type property strings */ protected static PropertyResolver resolver; - protected static boolean xmlParameterizationEnabled = !Boolean.getBoolean("gemfire.xml.parameterization.disabled"); + protected static boolean xmlParameterizationEnabled = !Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "xml.parameterization.disabled"); public static Runnable internalBeforeApplyChanges; @@ -582,8 +475,8 @@ public class GemFireCacheImpl implements InternalCache, ClientCache, HasCachePer public static final int DEFAULT_CLIENT_FUNCTION_TIMEOUT = 0; private static int clientFunctionTimeout; - - private final static Boolean DISABLE_AUTO_EVICTION = Boolean.getBoolean("gemfire.disableAutoEviction"); + + private final static Boolean DISABLE_AUTO_EVICTION = Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "disableAutoEviction"); static { // this works around jdk bug 6427854, reported in ticket #44434 @@ -1154,8 +1047,8 @@ public class GemFireCacheImpl implements InternalCache, ClientCache, HasCachePer startRedisServer(); startRestAgentServer(this); - - int time = Integer.getInteger("gemfire.CLIENT_FUNCTION_TIMEOUT", + + int time = Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "CLIENT_FUNCTION_TIMEOUT", DEFAULT_CLIENT_FUNCTION_TIMEOUT); clientFunctionTimeout = time >= 0 ? time : DEFAULT_CLIENT_FUNCTION_TIMEOUT; @@ -1611,7 +1504,7 @@ public class GemFireCacheImpl implements InternalCache, ClientCache, HasCachePer /** * Number of threads used to close PRs in shutdownAll. By default is the number of PRs in the cache */ - private static final int shutdownAllPoolSize = Integer.getInteger("gemfire.SHUTDOWN_ALL_POOL_SIZE", -1); + private static final int shutdownAllPoolSize = Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "SHUTDOWN_ALL_POOL_SIZE", -1); void shutdownSubTreeGracefully(Map prSubMap) { for (final PartitionedRegion pr : prSubMap.values()) { @@ -1946,7 +1839,7 @@ public class GemFireCacheImpl implements InternalCache, ClientCache, HasCachePer } } - private final boolean DISABLE_DISCONNECT_DS_ON_CACHE_CLOSE = Boolean.getBoolean("gemfire.DISABLE_DISCONNECT_DS_ON_CACHE_CLOSE"); + private final boolean DISABLE_DISCONNECT_DS_ON_CACHE_CLOSE = Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "DISABLE_DISCONNECT_DS_ON_CACHE_CLOSE"); /** * close the cache http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/InitialImageOperation.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/InitialImageOperation.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/InitialImageOperation.java index b43ba2d..f0836d4 100644 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/InitialImageOperation.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/InitialImageOperation.java @@ -17,35 +17,7 @@ package com.gemstone.gemfire.internal.cache; -import static com.gemstone.gemfire.internal.offheap.annotations.OffHeapIdentifier.ABSTRACT_REGION_ENTRY_FILL_IN_VALUE; - -import java.io.DataInput; -import java.io.DataOutput; -import java.io.Externalizable; -import java.io.IOException; -import java.io.ObjectInput; -import java.io.ObjectOutput; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.Collections; -import java.util.HashMap; -import java.util.HashSet; -import java.util.Iterator; -import java.util.List; -import java.util.Map; -import java.util.Set; -import java.util.concurrent.TimeoutException; -import java.util.concurrent.atomic.AtomicInteger; - -import org.apache.logging.log4j.Logger; - -import com.gemstone.gemfire.CancelException; -import com.gemstone.gemfire.DataSerializable; -import com.gemstone.gemfire.DataSerializer; -import com.gemstone.gemfire.InternalGemFireError; -import com.gemstone.gemfire.InternalGemFireException; -import com.gemstone.gemfire.SystemFailure; +import com.gemstone.gemfire.*; import com.gemstone.gemfire.cache.DiskAccessException; import com.gemstone.gemfire.cache.Operation; import com.gemstone.gemfire.cache.RegionDestroyedException; @@ -53,26 +25,12 @@ import com.gemstone.gemfire.cache.query.internal.CqStateImpl; import com.gemstone.gemfire.cache.query.internal.DefaultQueryService; import com.gemstone.gemfire.cache.query.internal.IndexUpdater; import com.gemstone.gemfire.cache.query.internal.cq.CqService; -import com.gemstone.gemfire.cache.query.internal.cq.InternalCqQuery; import com.gemstone.gemfire.cache.query.internal.cq.ServerCQ; import com.gemstone.gemfire.distributed.DistributedMember; import com.gemstone.gemfire.distributed.DistributedSystem; -import com.gemstone.gemfire.distributed.internal.DM; -import com.gemstone.gemfire.distributed.internal.DistributionManager; -import com.gemstone.gemfire.distributed.internal.DistributionMessage; -import com.gemstone.gemfire.distributed.internal.HighPriorityDistributionMessage; -import com.gemstone.gemfire.distributed.internal.InternalDistributedSystem; -import com.gemstone.gemfire.distributed.internal.MessageWithReply; -import com.gemstone.gemfire.distributed.internal.ReplyException; -import com.gemstone.gemfire.distributed.internal.ReplyMessage; -import com.gemstone.gemfire.distributed.internal.ReplyProcessor21; +import com.gemstone.gemfire.distributed.internal.*; import com.gemstone.gemfire.distributed.internal.membership.InternalDistributedMember; -import com.gemstone.gemfire.internal.Assert; -import com.gemstone.gemfire.internal.ByteArrayDataInput; -import com.gemstone.gemfire.internal.DataSerializableFixedID; -import com.gemstone.gemfire.internal.InternalDataSerializer; -import com.gemstone.gemfire.internal.NullDataOutputStream; -import com.gemstone.gemfire.internal.Version; +import com.gemstone.gemfire.internal.*; import com.gemstone.gemfire.internal.cache.InitialImageFlowControl.FlowControlPermitMessage; import com.gemstone.gemfire.internal.cache.ha.HAContainerWrapper; import com.gemstone.gemfire.internal.cache.persistence.DiskStoreID; @@ -81,13 +39,7 @@ import com.gemstone.gemfire.internal.cache.tier.InterestType; import com.gemstone.gemfire.internal.cache.tier.sockets.CacheClientNotifier; import com.gemstone.gemfire.internal.cache.tier.sockets.CacheClientProxy; import com.gemstone.gemfire.internal.cache.tier.sockets.ClientProxyMembershipID; -import com.gemstone.gemfire.internal.cache.versions.DiskRegionVersionVector; -import com.gemstone.gemfire.internal.cache.versions.DiskVersionTag; -import com.gemstone.gemfire.internal.cache.versions.RegionVersionHolder; -import com.gemstone.gemfire.internal.cache.versions.RegionVersionVector; -import com.gemstone.gemfire.internal.cache.versions.VersionSource; -import com.gemstone.gemfire.internal.cache.versions.VersionStamp; -import com.gemstone.gemfire.internal.cache.versions.VersionTag; +import com.gemstone.gemfire.internal.cache.versions.*; import com.gemstone.gemfire.internal.cache.vmotion.VMotionObserverHolder; import com.gemstone.gemfire.internal.cache.wan.AbstractGatewaySender; import com.gemstone.gemfire.internal.i18n.LocalizedStrings; @@ -96,10 +48,15 @@ import com.gemstone.gemfire.internal.logging.LoggingThreadGroup; import com.gemstone.gemfire.internal.logging.log4j.LocalizedMessage; import com.gemstone.gemfire.internal.logging.log4j.LogMarker; import com.gemstone.gemfire.internal.offheap.annotations.Released; -import com.gemstone.gemfire.internal.offheap.annotations.Retained; import com.gemstone.gemfire.internal.sequencelog.EntryLogger; import com.gemstone.gemfire.internal.sequencelog.RegionLogger; import com.gemstone.gemfire.internal.util.ObjectIntProcedure; +import org.apache.logging.log4j.Logger; + +import java.io.*; +import java.util.*; +import java.util.concurrent.TimeoutException; +import java.util.concurrent.atomic.AtomicInteger; /** * Handles requests for an initial image from a cache peer @@ -123,19 +80,19 @@ public class InitialImageOperation { * Allowed number of in flight GII chunks */ public static int CHUNK_PERMITS = - Integer.getInteger("gemfire.GetInitialImage.CHUNK_PERMITS", 16).intValue(); + Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "GetInitialImage.CHUNK_PERMITS", 16).intValue(); /** * maximum number of unfinished operations to be supported by delta GII */ public static int MAXIMUM_UNFINISHED_OPERATIONS = - Integer.getInteger("gemfire.GetInitialImage.MAXIMUM_UNFINISHED_OPERATIONS", 10000).intValue(); + Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "GetInitialImage.MAXIMUM_UNFINISHED_OPERATIONS", 10000).intValue(); /** * Allowed number GIIs in parallel */ public static int MAX_PARALLEL_GIIS = - Integer.getInteger("gemfire.GetInitialImage.MAX_PARALLEL_GIIS", 5).intValue(); + Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "GetInitialImage.MAX_PARALLEL_GIIS", 5).intValue(); /** * the region we are fetching @@ -4027,8 +3984,8 @@ public class InitialImageOperation { } - public static final boolean TRACE_GII = Boolean.getBoolean("gemfire.GetInitialImage.TRACE_GII"); - public static boolean FORCE_FULL_GII = Boolean.getBoolean("gemfire.GetInitialImage.FORCE_FULL_GII"); + public static final boolean TRACE_GII = Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "GetInitialImage.TRACE_GII"); + public static boolean FORCE_FULL_GII = Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "GetInitialImage.FORCE_FULL_GII"); // test hooks should be applied and waited in strict order as following http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/InlineKeyHelper.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/InlineKeyHelper.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/InlineKeyHelper.java index f146f89..aa98fa6 100644 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/InlineKeyHelper.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/InlineKeyHelper.java @@ -16,12 +16,14 @@ */ package com.gemstone.gemfire.internal.cache; +import com.gemstone.gemfire.distributed.internal.DistributionConfig; + /** * No instances of this class. Just some static method having to do with inline keys. * */ public class InlineKeyHelper { - public static boolean INLINE_REGION_KEYS = !Boolean.getBoolean("gemfire.DISABLE_INLINE_REGION_KEYS"); + public static boolean INLINE_REGION_KEYS = !Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "DISABLE_INLINE_REGION_KEYS"); /** * The maximum number of longs any of region entry subclasses use http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/LocalRegion.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/LocalRegion.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/LocalRegion.java index 8295487..31a0aae 100644 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/LocalRegion.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/LocalRegion.java @@ -17,95 +17,10 @@ package com.gemstone.gemfire.internal.cache; -import static com.gemstone.gemfire.internal.offheap.annotations.OffHeapIdentifier.*; - -import java.io.DataInputStream; -import java.io.DataOutputStream; -import java.io.File; -import java.io.IOException; -import java.io.InputStream; -import java.io.OutputStream; -import java.util.AbstractSet; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.Collections; -import java.util.EnumSet; -import java.util.HashMap; -import java.util.HashSet; -import java.util.Hashtable; -import java.util.Iterator; -import java.util.List; -import java.util.Map; -import java.util.NoSuchElementException; -import java.util.Set; -import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.ConcurrentMap; -import java.util.concurrent.ExecutionException; -import java.util.concurrent.Future; -import java.util.concurrent.RejectedExecutionException; -import java.util.concurrent.Semaphore; -import java.util.concurrent.atomic.AtomicBoolean; -import java.util.concurrent.atomic.AtomicInteger; -import java.util.concurrent.locks.Lock; -import java.util.concurrent.locks.ReentrantLock; -import java.util.regex.Pattern; - -import org.apache.logging.log4j.Logger; - -import com.gemstone.gemfire.CancelCriterion; -import com.gemstone.gemfire.CancelException; -import com.gemstone.gemfire.CopyHelper; -import com.gemstone.gemfire.DataSerializable; -import com.gemstone.gemfire.DataSerializer; -import com.gemstone.gemfire.DeltaSerializationException; -import com.gemstone.gemfire.InternalGemFireError; -import com.gemstone.gemfire.InternalGemFireException; -import com.gemstone.gemfire.LogWriter; -import com.gemstone.gemfire.SystemFailure; +import com.gemstone.gemfire.*; import com.gemstone.gemfire.admin.internal.SystemMemberCacheEventProcessor; -import com.gemstone.gemfire.cache.AttributesMutator; -import com.gemstone.gemfire.cache.Cache; -import com.gemstone.gemfire.cache.CacheClosedException; -import com.gemstone.gemfire.cache.CacheEvent; -import com.gemstone.gemfire.cache.CacheException; -import com.gemstone.gemfire.cache.CacheListener; -import com.gemstone.gemfire.cache.CacheLoader; -import com.gemstone.gemfire.cache.CacheLoaderException; -import com.gemstone.gemfire.cache.CacheRuntimeException; -import com.gemstone.gemfire.cache.CacheStatistics; -import com.gemstone.gemfire.cache.CacheWriter; -import com.gemstone.gemfire.cache.CacheWriterException; -import com.gemstone.gemfire.cache.CustomExpiry; -import com.gemstone.gemfire.cache.DataPolicy; -import com.gemstone.gemfire.cache.DiskAccessException; -import com.gemstone.gemfire.cache.DiskStoreFactory; -import com.gemstone.gemfire.cache.DiskWriteAttributes; -import com.gemstone.gemfire.cache.DiskWriteAttributesFactory; -import com.gemstone.gemfire.cache.EntryDestroyedException; -import com.gemstone.gemfire.cache.EntryExistsException; -import com.gemstone.gemfire.cache.EntryNotFoundException; -import com.gemstone.gemfire.cache.EvictionAttributes; -import com.gemstone.gemfire.cache.ExpirationAttributes; -import com.gemstone.gemfire.cache.FailedSynchronizationException; -import com.gemstone.gemfire.cache.InterestRegistrationEvent; -import com.gemstone.gemfire.cache.InterestResultPolicy; -import com.gemstone.gemfire.cache.LoaderHelper; -import com.gemstone.gemfire.cache.LowMemoryException; -import com.gemstone.gemfire.cache.Operation; -import com.gemstone.gemfire.cache.PartitionedRegionStorageException; -import com.gemstone.gemfire.cache.Region; -import com.gemstone.gemfire.cache.RegionAttributes; -import com.gemstone.gemfire.cache.RegionDestroyedException; -import com.gemstone.gemfire.cache.RegionEvent; -import com.gemstone.gemfire.cache.RegionExistsException; -import com.gemstone.gemfire.cache.RegionMembershipListener; -import com.gemstone.gemfire.cache.RegionReinitializedException; -import com.gemstone.gemfire.cache.Scope; -import com.gemstone.gemfire.cache.StatisticsDisabledException; +import com.gemstone.gemfire.cache.*; import com.gemstone.gemfire.cache.TimeoutException; -import com.gemstone.gemfire.cache.TransactionException; -import com.gemstone.gemfire.cache.TransactionId; import com.gemstone.gemfire.cache.client.PoolManager; import com.gemstone.gemfire.cache.client.ServerOperationException; import com.gemstone.gemfire.cache.client.SubscriptionNotEnabledException; @@ -117,17 +32,7 @@ import com.gemstone.gemfire.cache.control.ResourceManager; import com.gemstone.gemfire.cache.execute.Function; import com.gemstone.gemfire.cache.execute.ResultCollector; import com.gemstone.gemfire.cache.partition.PartitionRegionHelper; -import com.gemstone.gemfire.cache.query.FunctionDomainException; -import com.gemstone.gemfire.cache.query.Index; -import com.gemstone.gemfire.cache.query.IndexMaintenanceException; -import com.gemstone.gemfire.cache.query.IndexType; -import com.gemstone.gemfire.cache.query.MultiIndexCreationException; -import com.gemstone.gemfire.cache.query.NameResolutionException; -import com.gemstone.gemfire.cache.query.QueryException; -import com.gemstone.gemfire.cache.query.QueryInvocationTargetException; -import com.gemstone.gemfire.cache.query.QueryService; -import com.gemstone.gemfire.cache.query.SelectResults; -import com.gemstone.gemfire.cache.query.TypeMismatchException; +import com.gemstone.gemfire.cache.query.*; import com.gemstone.gemfire.cache.query.internal.DefaultQuery; import com.gemstone.gemfire.cache.query.internal.DefaultQueryService; import com.gemstone.gemfire.cache.query.internal.ExecutionContext; @@ -141,19 +46,11 @@ import com.gemstone.gemfire.cache.util.ObjectSizer; import com.gemstone.gemfire.cache.wan.GatewaySender; import com.gemstone.gemfire.distributed.DistributedMember; import com.gemstone.gemfire.distributed.DistributedSystem; -import com.gemstone.gemfire.distributed.internal.DM; -import com.gemstone.gemfire.distributed.internal.DistributionAdvisor; +import com.gemstone.gemfire.distributed.internal.*; import com.gemstone.gemfire.distributed.internal.DistributionAdvisor.Profile; -import com.gemstone.gemfire.distributed.internal.DistributionStats; -import com.gemstone.gemfire.distributed.internal.InternalDistributedSystem; -import com.gemstone.gemfire.distributed.internal.ResourceEvent; import com.gemstone.gemfire.distributed.internal.membership.InternalDistributedMember; -import com.gemstone.gemfire.internal.Assert; -import com.gemstone.gemfire.internal.ClassLoadUtil; -import com.gemstone.gemfire.internal.HeapDataOutputStream; -import com.gemstone.gemfire.internal.InternalStatisticsDisabledException; -import com.gemstone.gemfire.internal.NanoTimer; -import com.gemstone.gemfire.internal.Version; +import com.gemstone.gemfire.i18n.StringId; +import com.gemstone.gemfire.internal.*; import com.gemstone.gemfire.internal.cache.CacheDistributionAdvisor.CacheProfile; import com.gemstone.gemfire.internal.cache.DiskInitFile.DiskRegionFlag; import com.gemstone.gemfire.internal.cache.FilterRoutingInfo.FilterInfo; @@ -164,11 +61,7 @@ import com.gemstone.gemfire.internal.cache.control.InternalResourceManager.Resou import com.gemstone.gemfire.internal.cache.control.MemoryEvent; import com.gemstone.gemfire.internal.cache.control.MemoryThresholds; import com.gemstone.gemfire.internal.cache.control.ResourceListener; -import com.gemstone.gemfire.internal.cache.execute.DistributedRegionFunctionExecutor; -import com.gemstone.gemfire.internal.cache.execute.DistributedRegionFunctionResultSender; -import com.gemstone.gemfire.internal.cache.execute.LocalResultCollector; -import com.gemstone.gemfire.internal.cache.execute.RegionFunctionContextImpl; -import com.gemstone.gemfire.internal.cache.execute.ServerToClientFunctionResultSender; +import com.gemstone.gemfire.internal.cache.execute.*; import com.gemstone.gemfire.internal.cache.ha.ThreadIdentifier; import com.gemstone.gemfire.internal.cache.lru.LRUEntry; import com.gemstone.gemfire.internal.cache.partitioned.RedundancyAlreadyMetException; @@ -179,19 +72,8 @@ import com.gemstone.gemfire.internal.cache.persistence.PersistentMemberID; import com.gemstone.gemfire.internal.cache.persistence.query.IndexMap; import com.gemstone.gemfire.internal.cache.persistence.query.mock.IndexMapImpl; import com.gemstone.gemfire.internal.cache.tier.InterestType; -import com.gemstone.gemfire.internal.cache.tier.sockets.CacheClientNotifier; -import com.gemstone.gemfire.internal.cache.tier.sockets.ClientHealthMonitor; -import com.gemstone.gemfire.internal.cache.tier.sockets.ClientProxyMembershipID; -import com.gemstone.gemfire.internal.cache.tier.sockets.ClientTombstoneMessage; -import com.gemstone.gemfire.internal.cache.tier.sockets.ClientUpdateMessage; -import com.gemstone.gemfire.internal.cache.tier.sockets.HandShake; -import com.gemstone.gemfire.internal.cache.tier.sockets.VersionedObjectList; -import com.gemstone.gemfire.internal.cache.versions.ConcurrentCacheModificationException; -import com.gemstone.gemfire.internal.cache.versions.RegionVersionHolder; -import com.gemstone.gemfire.internal.cache.versions.RegionVersionVector; -import com.gemstone.gemfire.internal.cache.versions.VersionSource; -import com.gemstone.gemfire.internal.cache.versions.VersionStamp; -import com.gemstone.gemfire.internal.cache.versions.VersionTag; +import com.gemstone.gemfire.internal.cache.tier.sockets.*; +import com.gemstone.gemfire.internal.cache.versions.*; import com.gemstone.gemfire.internal.cache.wan.AbstractGatewaySender; import com.gemstone.gemfire.internal.cache.wan.GatewaySenderEventCallbackArgument; import com.gemstone.gemfire.internal.i18n.LocalizedStrings; @@ -208,7 +90,18 @@ import com.gemstone.gemfire.internal.sequencelog.EntryLogger; import com.gemstone.gemfire.internal.util.concurrent.FutureResult; import com.gemstone.gemfire.internal.util.concurrent.StoppableCountDownLatch; import com.gemstone.gemfire.internal.util.concurrent.StoppableReadWriteLock; -import com.gemstone.gemfire.i18n.StringId; +import org.apache.logging.log4j.Logger; + +import java.io.*; +import java.util.*; +import java.util.concurrent.*; +import java.util.concurrent.atomic.AtomicBoolean; +import java.util.concurrent.atomic.AtomicInteger; +import java.util.concurrent.locks.Lock; +import java.util.concurrent.locks.ReentrantLock; +import java.util.regex.Pattern; + +import static com.gemstone.gemfire.internal.offheap.annotations.OffHeapIdentifier.ENTRY_EVENT_NEW_VALUE; /** * Implementation of a local scoped-region. Note that this class has a different @@ -324,8 +217,7 @@ public class LocalRegion extends AbstractRegion Pattern.compile("^import .*", Pattern.CASE_INSENSITIVE | Pattern.UNICODE_CASE | Pattern.DOTALL) }; - - public static final String EXPIRY_MS_PROPERTY = "gemfire.EXPIRY_UNITS_MS"; + public static final String EXPIRY_MS_PROPERTY = DistributionConfig.GEMFIRE_PREFIX + "EXPIRY_UNITS_MS"; /** * Used by unit tests to set expiry to milliseconds instead of the default @@ -3385,7 +3277,7 @@ public class LocalRegion extends AbstractRegion /** * @since GemFire 5.0.2 */ - private final boolean DO_EXPENSIVE_VALIDATIONS = Boolean.getBoolean("gemfire.DO_EXPENSIVE_VALIDATIONS"); + private final boolean DO_EXPENSIVE_VALIDATIONS = Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "DO_EXPENSIVE_VALIDATIONS"); /** * the number of tombstone entries in the RegionMap @@ -3937,7 +3829,7 @@ public class LocalRegion extends AbstractRegion } public void finishRegisterInterest() { - if (Boolean.getBoolean("gemfire.testing.slow-interest-recovery")) { + if (Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "testing.slow-interest-recovery")) { if(logger.isDebugEnabled()) { logger.debug("slowing interest recovery..."); } http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/Oplog.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/Oplog.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/Oplog.java index 42d1dbc..4c04054 100755 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/Oplog.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/Oplog.java @@ -16,71 +16,14 @@ */ package com.gemstone.gemfire.internal.cache; -import it.unimi.dsi.fastutil.ints.Int2ObjectMap; -import it.unimi.dsi.fastutil.ints.Int2ObjectOpenHashMap; -import it.unimi.dsi.fastutil.longs.Long2ObjectMap; -import it.unimi.dsi.fastutil.longs.Long2ObjectOpenHashMap; -import it.unimi.dsi.fastutil.objects.ObjectIterator; - -import java.io.BufferedInputStream; -import java.io.BufferedOutputStream; -import java.io.DataInput; -import java.io.DataInputStream; -import java.io.DataOutput; -import java.io.DataOutputStream; -import java.io.EOFException; -import java.io.File; -import java.io.FileInputStream; -import java.io.FileNotFoundException; -import java.io.FileOutputStream; -import java.io.IOException; -import java.io.InterruptedIOException; -import java.io.SyncFailedException; -import java.nio.ByteBuffer; -import java.nio.channels.ClosedChannelException; -import java.util.Arrays; -import java.util.Collection; -import java.util.Collections; -import java.util.Comparator; -import java.util.HashMap; -import java.util.HashSet; -import java.util.Iterator; -import java.util.List; -import java.util.Map; -import java.util.Map.Entry; -import java.util.Set; -import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.ConcurrentMap; -import java.util.concurrent.atomic.AtomicBoolean; -import java.util.concurrent.atomic.AtomicInteger; -import java.util.concurrent.atomic.AtomicLong; -import java.util.concurrent.locks.Lock; -import java.util.concurrent.locks.ReentrantLock; - -import org.apache.logging.log4j.Logger; - import com.gemstone.gemfire.CancelException; import com.gemstone.gemfire.DataSerializer; import com.gemstone.gemfire.SerializationException; -import com.gemstone.gemfire.cache.CacheClosedException; -import com.gemstone.gemfire.cache.CacheWriterException; -import com.gemstone.gemfire.cache.DiskAccessException; -import com.gemstone.gemfire.cache.EntryDestroyedException; -import com.gemstone.gemfire.cache.EntryEvent; -import com.gemstone.gemfire.cache.EntryNotFoundException; -import com.gemstone.gemfire.cache.RegionDestroyedException; -import com.gemstone.gemfire.cache.TimeoutException; -import com.gemstone.gemfire.cache.UnsupportedVersionException; +import com.gemstone.gemfire.cache.*; import com.gemstone.gemfire.distributed.OplogCancelledException; import com.gemstone.gemfire.distributed.internal.DM; -import com.gemstone.gemfire.internal.Assert; -import com.gemstone.gemfire.internal.ByteArrayDataInput; -import com.gemstone.gemfire.internal.FileUtil; -import com.gemstone.gemfire.internal.HeapDataOutputStream; -import com.gemstone.gemfire.internal.InternalDataSerializer; -import com.gemstone.gemfire.internal.InternalStatisticsDisabledException; -import com.gemstone.gemfire.internal.Sendable; -import com.gemstone.gemfire.internal.Version; +import com.gemstone.gemfire.distributed.internal.DistributionConfig; +import com.gemstone.gemfire.internal.*; import com.gemstone.gemfire.internal.cache.DiskEntry.Helper.Flushable; import com.gemstone.gemfire.internal.cache.DiskEntry.Helper.ValueWrapper; import com.gemstone.gemfire.internal.cache.DiskInitFile.DiskRegionFlag; @@ -89,19 +32,8 @@ import com.gemstone.gemfire.internal.cache.DiskStoreImpl.OplogEntryIdSet; import com.gemstone.gemfire.internal.cache.DistributedRegion.DiskPosition; import com.gemstone.gemfire.internal.cache.lru.EnableLRU; import com.gemstone.gemfire.internal.cache.lru.NewLRUClockHand; -import com.gemstone.gemfire.internal.cache.persistence.BytesAndBits; -import com.gemstone.gemfire.internal.cache.persistence.DiskRecoveryStore; -import com.gemstone.gemfire.internal.cache.persistence.DiskRegionView; -import com.gemstone.gemfire.internal.cache.persistence.DiskStoreID; -import com.gemstone.gemfire.internal.cache.persistence.UninterruptibleFileChannel; -import com.gemstone.gemfire.internal.cache.persistence.UninterruptibleRandomAccessFile; -import com.gemstone.gemfire.internal.cache.versions.CompactVersionHolder; -import com.gemstone.gemfire.internal.cache.versions.RegionVersionHolder; -import com.gemstone.gemfire.internal.cache.versions.RegionVersionVector; -import com.gemstone.gemfire.internal.cache.versions.VersionHolder; -import com.gemstone.gemfire.internal.cache.versions.VersionSource; -import com.gemstone.gemfire.internal.cache.versions.VersionStamp; -import com.gemstone.gemfire.internal.cache.versions.VersionTag; +import com.gemstone.gemfire.internal.cache.persistence.*; +import com.gemstone.gemfire.internal.cache.versions.*; import com.gemstone.gemfire.internal.i18n.LocalizedStrings; import com.gemstone.gemfire.internal.logging.LogService; import com.gemstone.gemfire.internal.logging.log4j.LocalizedMessage; @@ -117,6 +49,25 @@ import com.gemstone.gemfire.internal.util.BlobHelper; import com.gemstone.gemfire.internal.util.IOUtils; import com.gemstone.gemfire.internal.util.TransformUtils; import com.gemstone.gemfire.pdx.internal.PdxWriterImpl; +import it.unimi.dsi.fastutil.ints.Int2ObjectMap; +import it.unimi.dsi.fastutil.ints.Int2ObjectOpenHashMap; +import it.unimi.dsi.fastutil.longs.Long2ObjectMap; +import it.unimi.dsi.fastutil.longs.Long2ObjectOpenHashMap; +import it.unimi.dsi.fastutil.objects.ObjectIterator; +import org.apache.logging.log4j.Logger; + +import java.io.*; +import java.nio.ByteBuffer; +import java.nio.channels.ClosedChannelException; +import java.util.*; +import java.util.Map.Entry; +import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.ConcurrentMap; +import java.util.concurrent.atomic.AtomicBoolean; +import java.util.concurrent.atomic.AtomicInteger; +import java.util.concurrent.atomic.AtomicLong; +import java.util.concurrent.locks.Lock; +import java.util.concurrent.locks.ReentrantLock; /** * Implements an operation log to write to disk. As of prPersistSprint2 this @@ -188,7 +139,7 @@ public final class Oplog implements CompactableOplog, Flushable { * This system property instructs that writes be synchronously written to disk * and not to file system. (Use rwd instead of rw - RandomAccessFile property) */ - private static final boolean SYNC_WRITES = Boolean.getBoolean("gemfire.syncWrites"); + private static final boolean SYNC_WRITES = Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "syncWrites"); /** * The HighWaterMark of recentValues. @@ -5040,7 +4991,7 @@ public final class Oplog implements CompactableOplog, Flushable { } private void setMaxCrfDrfSize() { - int crfPct = Integer.getInteger("gemfire.CRF_MAX_PERCENTAGE", 90); + int crfPct = Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "CRF_MAX_PERCENTAGE", 90); if (crfPct > 100 || crfPct < 0) { crfPct = 90; } http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PRHARedundancyProvider.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PRHARedundancyProvider.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PRHARedundancyProvider.java index 2ec1e3f..f933024 100644 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PRHARedundancyProvider.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PRHARedundancyProvider.java @@ -17,26 +17,6 @@ package com.gemstone.gemfire.internal.cache; -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.Comparator; -import java.util.HashSet; -import java.util.Iterator; -import java.util.List; -import java.util.Map; -import java.util.Set; -import java.util.TreeSet; -import java.util.concurrent.CountDownLatch; -import java.util.concurrent.RejectedExecutionException; -import java.util.concurrent.ScheduledFuture; -import java.util.concurrent.TimeUnit; -import java.util.concurrent.atomic.AtomicBoolean; -import java.util.concurrent.atomic.AtomicInteger; -import java.util.concurrent.atomic.AtomicLong; - -import org.apache.logging.log4j.Logger; - import com.gemstone.gemfire.CancelException; import com.gemstone.gemfire.SystemFailure; import com.gemstone.gemfire.cache.CacheClosedException; @@ -46,39 +26,20 @@ import com.gemstone.gemfire.cache.RegionDestroyedException; import com.gemstone.gemfire.cache.persistence.PartitionOfflineException; import com.gemstone.gemfire.distributed.DistributedMember; import com.gemstone.gemfire.distributed.internal.DM; +import com.gemstone.gemfire.distributed.internal.DistributionConfig; import com.gemstone.gemfire.distributed.internal.LonerDistributionManager; import com.gemstone.gemfire.distributed.internal.MembershipListener; import com.gemstone.gemfire.distributed.internal.membership.InternalDistributedMember; +import com.gemstone.gemfire.i18n.StringId; import com.gemstone.gemfire.internal.Assert; import com.gemstone.gemfire.internal.NanoTimer; import com.gemstone.gemfire.internal.OneTaskOnlyExecutor; import com.gemstone.gemfire.internal.cache.PartitionedRegion.RetryTimeKeeper; import com.gemstone.gemfire.internal.cache.PartitionedRegionDataStore.CreateBucketResult; import com.gemstone.gemfire.internal.cache.control.InternalResourceManager; -import com.gemstone.gemfire.internal.cache.partitioned.Bucket; -import com.gemstone.gemfire.internal.cache.partitioned.BucketBackupMessage; -import com.gemstone.gemfire.internal.cache.partitioned.CreateBucketMessage; -import com.gemstone.gemfire.internal.cache.partitioned.CreateMissingBucketsTask; -import com.gemstone.gemfire.internal.cache.partitioned.EndBucketCreationMessage; -import com.gemstone.gemfire.internal.cache.partitioned.FetchPartitionDetailsMessage; +import com.gemstone.gemfire.internal.cache.partitioned.*; import com.gemstone.gemfire.internal.cache.partitioned.FetchPartitionDetailsMessage.FetchPartitionDetailsResponse; -import com.gemstone.gemfire.internal.cache.partitioned.InternalPRInfo; -import com.gemstone.gemfire.internal.cache.partitioned.InternalPartitionDetails; -import com.gemstone.gemfire.internal.cache.partitioned.LoadProbe; -import com.gemstone.gemfire.internal.cache.partitioned.ManageBackupBucketMessage; -import com.gemstone.gemfire.internal.cache.partitioned.ManageBucketMessage; import com.gemstone.gemfire.internal.cache.partitioned.ManageBucketMessage.NodeResponse; -import com.gemstone.gemfire.internal.cache.partitioned.OfflineMemberDetails; -import com.gemstone.gemfire.internal.cache.partitioned.OfflineMemberDetailsImpl; -import com.gemstone.gemfire.internal.cache.partitioned.PRLoad; -import com.gemstone.gemfire.internal.cache.partitioned.PartitionMemberInfoImpl; -import com.gemstone.gemfire.internal.cache.partitioned.PartitionRegionInfoImpl; -import com.gemstone.gemfire.internal.cache.partitioned.PartitionedRegionObserverAdapter; -import com.gemstone.gemfire.internal.cache.partitioned.PartitionedRegionObserverHolder; -import com.gemstone.gemfire.internal.cache.partitioned.PartitionedRegionRebalanceOp; -import com.gemstone.gemfire.internal.cache.partitioned.RecoveryRunnable; -import com.gemstone.gemfire.internal.cache.partitioned.RedundancyLogger; -import com.gemstone.gemfire.internal.cache.partitioned.RegionAdvisor; import com.gemstone.gemfire.internal.cache.partitioned.RegionAdvisor.PartitionProfile; import com.gemstone.gemfire.internal.cache.partitioned.rebalance.CompositeDirector; import com.gemstone.gemfire.internal.cache.partitioned.rebalance.FPRDirector; @@ -89,7 +50,16 @@ import com.gemstone.gemfire.internal.cache.persistence.PersistentStateListener; import com.gemstone.gemfire.internal.i18n.LocalizedStrings; import com.gemstone.gemfire.internal.logging.LogService; import com.gemstone.gemfire.internal.logging.log4j.LocalizedMessage; -import com.gemstone.gemfire.i18n.StringId; +import org.apache.logging.log4j.Logger; + +import java.util.*; +import java.util.concurrent.CountDownLatch; +import java.util.concurrent.RejectedExecutionException; +import java.util.concurrent.ScheduledFuture; +import java.util.concurrent.TimeUnit; +import java.util.concurrent.atomic.AtomicBoolean; +import java.util.concurrent.atomic.AtomicInteger; +import java.util.concurrent.atomic.AtomicLong; /** * This class provides the redundancy management for partitioned region. It will @@ -104,9 +74,9 @@ import com.gemstone.gemfire.i18n.StringId; public class PRHARedundancyProvider { private static final Logger logger = LogService.getLogger(); - - private static final boolean DISABLE_CREATE_BUCKET_RANDOMNESS - = Boolean.getBoolean("gemfire.DISABLE_CREATE_BUCKET_RANDOMNESS"); + + private static final boolean DISABLE_CREATE_BUCKET_RANDOMNESS + = Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "DISABLE_CREATE_BUCKET_RANDOMNESS"); public static class ArrayListWithClearState extends ArrayList { private static final long serialVersionUID = 1L; @@ -122,7 +92,7 @@ public class PRHARedundancyProvider } public static final String DATASTORE_DISCOVERY_TIMEOUT_PROPERTY_NAME = - "gemfire.partitionedRegionDatastoreDiscoveryTimeout"; + DistributionConfig.GEMFIRE_PREFIX + "partitionedRegionDatastoreDiscoveryTimeout"; static volatile Long DATASTORE_DISCOVERY_TIMEOUT_MILLISECONDS = Long.getLong(DATASTORE_DISCOVERY_TIMEOUT_PROPERTY_NAME); @@ -442,7 +412,7 @@ public class PRHARedundancyProvider } public static final long INSUFFICIENT_LOGGING_THROTTLE_TIME = - TimeUnit.SECONDS.toNanos(Integer.getInteger("gemfire.InsufficientLoggingThrottleTime", 2).intValue()); + TimeUnit.SECONDS.toNanos(Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "InsufficientLoggingThrottleTime", 2).intValue()); public volatile static boolean TEST_MODE = false; //since 6.6, please use the distributed system property enforce-unique-host instead. // public static final boolean ENFORCE_UNIQUE_HOST_STORAGE_ALLOCATION = DistributionConfig.DEFAULT_ENFORCE_UNIQUE_HOST; @@ -1597,7 +1567,7 @@ public class PRHARedundancyProvider if (isStartup) { delay = this.prRegion.getPartitionAttributes().getStartupRecoveryDelay(); - movePrimaries = !Boolean.getBoolean("gemfire.DISABLE_MOVE_PRIMARIES_ON_STARTUP"); + movePrimaries = !Boolean.getBoolean(DistributionConfig.GEMFIRE_PREFIX + "DISABLE_MOVE_PRIMARIES_ON_STARTUP"); } else { delay = this.prRegion.getPartitionAttributes().getRecoveryDelay(); movePrimaries = false; http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PRQueryProcessor.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PRQueryProcessor.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PRQueryProcessor.java index 076c5e8..967a39d 100644 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PRQueryProcessor.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PRQueryProcessor.java @@ -16,42 +16,15 @@ */ package com.gemstone.gemfire.internal.cache; -import java.io.DataInput; -import java.io.DataOutput; -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.Iterator; -import java.util.List; -import java.util.concurrent.Callable; -import java.util.concurrent.ExecutionException; -import java.util.concurrent.ExecutorService; -import java.util.concurrent.Executors; -import java.util.concurrent.Future; -import java.util.concurrent.RejectedExecutionException; -import java.util.concurrent.TimeUnit; -import java.util.concurrent.TimeoutException; - -import org.apache.logging.log4j.Logger; - import com.gemstone.gemfire.InternalGemFireException; import com.gemstone.gemfire.cache.CacheRuntimeException; import com.gemstone.gemfire.cache.RegionDestroyedException; import com.gemstone.gemfire.cache.query.QueryException; import com.gemstone.gemfire.cache.query.QueryInvocationTargetException; -import com.gemstone.gemfire.cache.query.QueryService; import com.gemstone.gemfire.cache.query.SelectResults; -import com.gemstone.gemfire.cache.query.internal.CompiledSelect; -import com.gemstone.gemfire.cache.query.internal.DefaultQuery; -import com.gemstone.gemfire.cache.query.internal.ExecutionContext; -import com.gemstone.gemfire.cache.query.internal.IndexTrackingQueryObserver; -import com.gemstone.gemfire.cache.query.internal.NWayMergeResults; -import com.gemstone.gemfire.cache.query.internal.QueryExecutionContext; -import com.gemstone.gemfire.cache.query.internal.QueryMonitor; -import com.gemstone.gemfire.cache.query.internal.QueryObserver; -import com.gemstone.gemfire.cache.query.internal.QueryObserverHolder; +import com.gemstone.gemfire.cache.query.internal.*; import com.gemstone.gemfire.cache.query.types.ObjectType; +import com.gemstone.gemfire.distributed.internal.DistributionConfig; import com.gemstone.gemfire.internal.Assert; import com.gemstone.gemfire.internal.DataSerializableFixedID; import com.gemstone.gemfire.internal.Version; @@ -59,6 +32,13 @@ import com.gemstone.gemfire.internal.cache.PartitionedRegionQueryEvaluator.PRQue import com.gemstone.gemfire.internal.cache.execute.BucketMovedException; import com.gemstone.gemfire.internal.i18n.LocalizedStrings; import com.gemstone.gemfire.internal.logging.LogService; +import org.apache.logging.log4j.Logger; + +import java.io.DataInput; +import java.io.DataOutput; +import java.io.IOException; +import java.util.*; +import java.util.concurrent.*; /** @@ -78,8 +58,8 @@ public class PRQueryProcessor private static final Logger logger = LogService.getLogger(); final static int BUCKET_QUERY_TIMEOUT = 60; - - public final static int NUM_THREADS = Integer.getInteger("gemfire.PRQueryProcessor.numThreads", 1).intValue(); + + public final static int NUM_THREADS = Integer.getInteger(DistributionConfig.GEMFIRE_PREFIX + "PRQueryProcessor.numThreads", 1).intValue(); /* For Test purpose */ public static int TEST_NUM_THREADS = 0; http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/70612010/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PartitionedRegion.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PartitionedRegion.java b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PartitionedRegion.java index 4165fd7..667c765 100755 --- a/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PartitionedRegion.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/internal/cache/PartitionedRegion.java @@ -17,136 +17,33 @@ package com.gemstone.gemfire.internal.cache; -import java.io.IOException; -import java.io.InputStream; -import java.io.OutputStream; -import java.io.Serializable; -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.Comparator; -import java.util.HashMap; -import java.util.HashSet; -import java.util.Hashtable; -import java.util.Iterator; -import java.util.LinkedList; -import java.util.List; -import java.util.Map; -import java.util.NoSuchElementException; -import java.util.Random; -import java.util.Set; -import java.util.concurrent.Callable; -import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.ConcurrentMap; -import java.util.concurrent.CopyOnWriteArrayList; -import java.util.concurrent.ExecutionException; -import java.util.concurrent.Executors; -import java.util.concurrent.FutureTask; -import java.util.concurrent.ScheduledExecutorService; -import java.util.concurrent.ThreadFactory; -import java.util.concurrent.TimeUnit; -import java.util.concurrent.atomic.AtomicBoolean; -import java.util.concurrent.atomic.AtomicInteger; -import java.util.concurrent.locks.Lock; - -import org.apache.logging.log4j.Logger; - import com.gemstone.gemfire.CancelException; import com.gemstone.gemfire.InternalGemFireException; import com.gemstone.gemfire.StatisticsFactory; import com.gemstone.gemfire.SystemFailure; -import com.gemstone.gemfire.cache.AttributesFactory; -import com.gemstone.gemfire.cache.AttributesMutator; -import com.gemstone.gemfire.cache.Cache; -import com.gemstone.gemfire.cache.CacheClosedException; -import com.gemstone.gemfire.cache.CacheException; -import com.gemstone.gemfire.cache.CacheListener; -import com.gemstone.gemfire.cache.CacheLoader; -import com.gemstone.gemfire.cache.CacheLoaderException; -import com.gemstone.gemfire.cache.CacheStatistics; -import com.gemstone.gemfire.cache.CacheWriter; -import com.gemstone.gemfire.cache.CacheWriterException; -import com.gemstone.gemfire.cache.CustomExpiry; -import com.gemstone.gemfire.cache.DataPolicy; -import com.gemstone.gemfire.cache.DiskAccessException; -import com.gemstone.gemfire.cache.EntryExistsException; -import com.gemstone.gemfire.cache.EntryNotFoundException; -import com.gemstone.gemfire.cache.ExpirationAttributes; -import com.gemstone.gemfire.cache.InterestPolicy; -import com.gemstone.gemfire.cache.InterestRegistrationEvent; -import com.gemstone.gemfire.cache.LoaderHelper; -import com.gemstone.gemfire.cache.LowMemoryException; -import com.gemstone.gemfire.cache.Operation; -import com.gemstone.gemfire.cache.PartitionAttributes; -import com.gemstone.gemfire.cache.PartitionResolver; -import com.gemstone.gemfire.cache.PartitionedRegionDistributionException; -import com.gemstone.gemfire.cache.PartitionedRegionStorageException; -import com.gemstone.gemfire.cache.Region; -import com.gemstone.gemfire.cache.RegionAttributes; -import com.gemstone.gemfire.cache.RegionDestroyedException; -import com.gemstone.gemfire.cache.RegionEvent; -import com.gemstone.gemfire.cache.RegionExistsException; -import com.gemstone.gemfire.cache.RegionMembershipListener; +import com.gemstone.gemfire.cache.*; import com.gemstone.gemfire.cache.TimeoutException; -import com.gemstone.gemfire.cache.TransactionDataNotColocatedException; -import com.gemstone.gemfire.cache.TransactionDataRebalancedException; -import com.gemstone.gemfire.cache.TransactionException; import com.gemstone.gemfire.cache.asyncqueue.internal.AsyncEventQueueImpl; -import com.gemstone.gemfire.cache.execute.EmptyRegionFunctionException; -import com.gemstone.gemfire.cache.execute.Function; -import com.gemstone.gemfire.cache.execute.FunctionContext; -import com.gemstone.gemfire.cache.execute.FunctionException; -import com.gemstone.gemfire.cache.execute.FunctionService; -import com.gemstone.gemfire.cache.execute.ResultCollector; +import com.gemstone.gemfire.cache.execute.*; import com.gemstone.gemfire.cache.partition.PartitionListener; import com.gemstone.gemfire.cache.partition.PartitionNotAvailableException; -import com.gemstone.gemfire.cache.query.FunctionDomainException; -import com.gemstone.gemfire.cache.query.Index; -import com.gemstone.gemfire.cache.query.IndexCreationException; -import com.gemstone.gemfire.cache.query.IndexExistsException; -import com.gemstone.gemfire.cache.query.IndexInvalidException; -import com.gemstone.gemfire.cache.query.IndexNameConflictException; -import com.gemstone.gemfire.cache.query.IndexType; -import com.gemstone.gemfire.cache.query.MultiIndexCreationException; -import com.gemstone.gemfire.cache.query.NameResolutionException; -import com.gemstone.gemfire.cache.query.QueryException; -import com.gemstone.gemfire.cache.query.QueryInvocationTargetException; -import com.gemstone.gemfire.cache.query.SelectResults; -import com.gemstone.gemfire.cache.query.TypeMismatchException; -import com.gemstone.gemfire.cache.query.internal.CompiledSelect; -import com.gemstone.gemfire.cache.query.internal.DefaultQuery; -import com.gemstone.gemfire.cache.query.internal.ExecutionContext; -import com.gemstone.gemfire.cache.query.internal.QCompiler; -import com.gemstone.gemfire.cache.query.internal.QueryExecutor; -import com.gemstone.gemfire.cache.query.internal.ResultsBag; -import com.gemstone.gemfire.cache.query.internal.ResultsCollectionWrapper; -import com.gemstone.gemfire.cache.query.internal.ResultsSet; -import com.gemstone.gemfire.cache.query.internal.index.AbstractIndex; -import com.gemstone.gemfire.cache.query.internal.index.IndexCreationData; -import com.gemstone.gemfire.cache.query.internal.index.IndexManager; -import com.gemstone.gemfire.cache.query.internal.index.IndexUtils; -import com.gemstone.gemfire.cache.query.internal.index.PartitionedIndex; +import com.gemstone.gemfire.cache.query.*; +import com.gemstone.gemfire.cache.query.internal.*; +import com.gemstone.gemfire.cache.query.internal.index.*; import com.gemstone.gemfire.cache.query.internal.types.ObjectTypeImpl; import com.gemstone.gemfire.cache.query.types.ObjectType; import com.gemstone.gemfire.cache.wan.GatewaySender; import com.gemstone.gemfire.distributed.DistributedLockService; import com.gemstone.gemfire.distributed.DistributedMember; import com.gemstone.gemfire.distributed.LockServiceDestroyedException; -import com.gemstone.gemfire.distributed.internal.DM; -import com.gemstone.gemfire.distributed.internal.DistributionAdvisee; -import com.gemstone.gemfire.distributed.internal.DistributionAdvisor; +import com.gemstone.gemfire.distributed.internal.*; import com.gemstone.gemfire.distributed.internal.DistributionAdvisor.Profile; -import com.gemstone.gemfire.distributed.internal.DistributionManager; -import com.gemstone.gemfire.distributed.internal.InternalDistributedSystem; import com.gemstone.gemfire.distributed.internal.InternalDistributedSystem.DisconnectListener; -import com.gemstone.gemfire.distributed.internal.MembershipListener; -import com.gemstone.gemfire.distributed.internal.ProfileListener; -import com.gemstone.gemfire.distributed.internal.ReplyException; -import com.gemstone.gemfire.distributed.internal.ReplyProcessor21; import com.gemstone.gemfire.distributed.internal.locks.DLockRemoteToken; import com.gemstone.gemfire.distributed.internal.locks.DLockService; import com.gemstone.gemfire.distributed.internal.membership.InternalDistributedMember; import com.gemstone.gemfire.distributed.internal.membership.MemberAttributes; +import com.gemstone.gemfire.i18n.StringId; import com.gemstone.gemfire.internal.Assert; import com.gemstone.gemfire.internal.NanoTimer; import com.gemstone.gemfire.internal.SetUtils; @@ -160,63 +57,27 @@ import com.gemstone.gemfire.internal.cache.control.InternalResourceManager; import com.gemstone.gemfire.internal.cache.control.InternalResourceManager.ResourceType; import com.gemstone.gemfire.internal.cache.control.MemoryEvent; import com.gemstone.gemfire.internal.cache.control.MemoryThresholds; -import com.gemstone.gemfire.internal.cache.execute.AbstractExecution; -import com.gemstone.gemfire.internal.cache.execute.FunctionExecutionNodePruner; -import com.gemstone.gemfire.internal.cache.execute.FunctionRemoteContext; -import com.gemstone.gemfire.internal.cache.execute.InternalFunctionInvocationTargetException; -import com.gemstone.gemfire.internal.cache.execute.LocalResultCollector; -import com.gemstone.gemfire.internal.cache.execute.PartitionedRegionFunctionExecutor; -import com.gemstone.gemfire.internal.cache.execute.PartitionedRegionFunctionResultSender; -import com.gemstone.gemfire.internal.cache.execute.PartitionedRegionFunctionResultWaiter; -import com.gemstone.gemfire.internal.cache.execute.RegionFunctionContextImpl; -import com.gemstone.gemfire.internal.cache.execute.ServerToClientFunctionResultSender; +import com.gemstone.gemfire.internal.cache.execute.*; import com.gemstone.gemfire.internal.cache.ha.ThreadIdentifier; import com.gemstone.gemfire.internal.cache.lru.HeapEvictor; import com.gemstone.gemfire.internal.cache.lru.LRUStatistics; -import com.gemstone.gemfire.internal.cache.partitioned.ContainsKeyValueMessage; +import com.gemstone.gemfire.internal.cache.partitioned.*; import com.gemstone.gemfire.internal.cache.partitioned.ContainsKeyValueMessage.ContainsKeyValueResponse; -import com.gemstone.gemfire.internal.cache.partitioned.DestroyMessage; import com.gemstone.gemfire.internal.cache.partitioned.DestroyMessage.DestroyResponse; -import com.gemstone.gemfire.internal.cache.partitioned.DestroyRegionOnDataStoreMessage; -import com.gemstone.gemfire.internal.cache.partitioned.DumpAllPRConfigMessage; -import com.gemstone.gemfire.internal.cache.partitioned.DumpB2NRegion; import com.gemstone.gemfire.internal.cache.partitioned.DumpB2NRegion.DumpB2NResponse; -import com.gemstone.gemfire.internal.cache.partitioned.DumpBucketsMessage; -import com.gemstone.gemfire.internal.cache.partitioned.FetchBulkEntriesMessage; import com.gemstone.gemfire.internal.cache.partitioned.FetchBulkEntriesMessage.FetchBulkEntriesResponse; -import com.gemstone.gemfire.internal.cache.partitioned.FetchEntriesMessage; import com.gemstone.gemfire.internal.cache.partitioned.FetchEntriesMessage.FetchEntriesResponse; -import com.gemstone.gemfire.internal.cache.partitioned.FetchEntryMessage; import com.gemstone.gemfire.internal.cache.partitioned.FetchEntryMessage.FetchEntryResponse; -import com.gemstone.gemfire.internal.cache.partitioned.FetchKeysMessage; import com.gemstone.gemfire.internal.cache.partitioned.FetchKeysMessage.FetchKeysResponse; -import com.gemstone.gemfire.internal.cache.partitioned.GetMessage; import com.gemstone.gemfire.internal.cache.partitioned.GetMessage.GetResponse; -import com.gemstone.gemfire.internal.cache.partitioned.IdentityRequestMessage; import com.gemstone.gemfire.internal.cache.partitioned.IdentityRequestMessage.IdentityResponse; -import com.gemstone.gemfire.internal.cache.partitioned.IdentityUpdateMessage; import com.gemstone.gemfire.internal.cache.partitioned.IdentityUpdateMessage.IdentityUpdateResponse; -import com.gemstone.gemfire.internal.cache.partitioned.IndexCreationMsg; -import com.gemstone.gemfire.internal.cache.partitioned.InterestEventMessage; import com.gemstone.gemfire.internal.cache.partitioned.InterestEventMessage.InterestEventResponse; -import com.gemstone.gemfire.internal.cache.partitioned.InvalidateMessage; import com.gemstone.gemfire.internal.cache.partitioned.InvalidateMessage.InvalidateResponse; -import com.gemstone.gemfire.internal.cache.partitioned.PREntriesIterator; -import com.gemstone.gemfire.internal.cache.partitioned.PRLocallyDestroyedException; -import com.gemstone.gemfire.internal.cache.partitioned.PRSanityCheckMessage; -import com.gemstone.gemfire.internal.cache.partitioned.PRUpdateEntryVersionMessage; import com.gemstone.gemfire.internal.cache.partitioned.PRUpdateEntryVersionMessage.UpdateEntryVersionResponse; import com.gemstone.gemfire.internal.cache.partitioned.PartitionMessage.PartitionResponse; -import com.gemstone.gemfire.internal.cache.partitioned.PartitionedRegionObserver; -import com.gemstone.gemfire.internal.cache.partitioned.PartitionedRegionObserverHolder; -import com.gemstone.gemfire.internal.cache.partitioned.PutAllPRMessage; -import com.gemstone.gemfire.internal.cache.partitioned.PutMessage; import com.gemstone.gemfire.internal.cache.partitioned.PutMessage.PutResult; -import com.gemstone.gemfire.internal.cache.partitioned.RegionAdvisor; import com.gemstone.gemfire.internal.cache.partitioned.RegionAdvisor.PartitionProfile; -import com.gemstone.gemfire.internal.cache.partitioned.RemoveAllPRMessage; -import com.gemstone.gemfire.internal.cache.partitioned.RemoveIndexesMessage; -import com.gemstone.gemfire.internal.cache.partitioned.SizeMessage; import com.gemstone.gemfire.internal.cache.partitioned.SizeMessage.SizeResponse; import com.gemstone.gemfire.internal.cache.persistence.PRPersistentConfig; import com.gemstone.gemfire.internal.cache.tier.InterestType; @@ -245,7 +106,17 @@ import com.gemstone.gemfire.internal.offheap.annotations.Unretained; import com.gemstone.gemfire.internal.sequencelog.RegionLogger; import com.gemstone.gemfire.internal.util.TransformUtils; import com.gemstone.gemfire.internal.util.concurrent.StoppableCountDownLatch; -import com.gemstone.gemfire.i18n.StringId; +import org.apache.logging.log4j.Logger; + +import java.io.IOException; +import java.io.InputStream; +import java.io.OutputStream; +import java.io.Serializable; +import java.util.*; +import java.util.concurrent.*; +import java.util.concurrent.atomic.AtomicBoolean; +import java.util.concurrent.atomic.AtomicInteger; +import java.util.concurrent.locks.Lock; /** * A Region whose total storage is split into chunks of data (partitions) which @@ -257,7 +128,7 @@ public class PartitionedRegion extends LocalRegion implements CacheDistributionAdvisee, QueryExecutor { public static final Random rand = new Random(Long.getLong( - "gemfire.PartitionedRegionRandomSeed", NanoTimer.getTime()).longValue()); + DistributionConfig.GEMFIRE_PREFIX + "PartitionedRegionRandomSeed", NanoTimer.getTime()).longValue()); private static final AtomicInteger SERIAL_NUMBER_GENERATOR = new AtomicInteger(); @@ -266,7 +137,7 @@ public class PartitionedRegion extends LocalRegion implements * Changes scope of replication to secondary bucket to SCOPE.DISTRIBUTED_NO_ACK */ public static final boolean DISABLE_SECONDARY_BUCKET_ACK = Boolean.getBoolean( - "gemfire.disablePartitionedRegionBucketAck"); + DistributionConfig.GEMFIRE_PREFIX + "disablePartitionedRegionBucketAck"); /** * A debug flag used for testing calculation of starting bucket id @@ -681,8 +552,8 @@ public class PartitionedRegion extends LocalRegion implements * */ - static public final String RETRY_TIMEOUT_PROPERTY = - "gemfire.partitionedRegionRetryTimeout"; + static public final String RETRY_TIMEOUT_PROPERTY = + DistributionConfig.GEMFIRE_PREFIX + "partitionedRegionRetryTimeout"; private final PartitionRegionConfigValidator validator ; @@ -740,10 +611,10 @@ public class PartitionedRegion extends LocalRegion implements // No redundancy required for writes this.minimumWriteRedundancy = Integer.getInteger( - "gemfire.mimimumPartitionedRegionWriteRedundancy", 0).intValue(); + DistributionConfig.GEMFIRE_PREFIX + "mimimumPartitionedRegionWriteRedundancy", 0).intValue(); // No redundancy required for reads this.minimumReadRedundancy = Integer.getInteger( - "gemfire.mimimumPartitionedRegionReadRedundancy", 0).intValue(); + DistributionConfig.GEMFIRE_PREFIX + "mimimumPartitionedRegionReadRedundancy", 0).intValue(); this.haveCacheLoader = ra.getCacheLoader() != null; @@ -9633,7 +9504,7 @@ public class PartitionedRegion extends LocalRegion implements /** * Return the primary for the local bucket. Returns null if no primary - * can be found within {@link com.gemstone.gemfire.distributed.internal.DistributionConfig#getMemberTimeout}. + * can be found within {@link DistributionConfig#getMemberTimeout}. * @param bucketId * @return the primary bucket member */