This is an automated email from the ASF dual-hosted git repository.

janh pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hbase.git


The following commit(s) were added to refs/heads/master by this push:
     new 20f72f5  HBASE-22186 Removed remaining usages of 
SnapshotDescriptionUtils.SNAPSHOT_TIMEOUT_MILLIS_KEY and 
SnapshotDescriptionUtils.SNAPSHOT_TIMEOUT_MILLIS_DEFAULT
20f72f5 is described below

commit 20f72f5e252233361ee474e58b4a8fef69926b8b
Author: Jan Hentschel <[email protected]>
AuthorDate: Mon Apr 8 09:32:19 2019 +0200

    HBASE-22186 Removed remaining usages of 
SnapshotDescriptionUtils.SNAPSHOT_TIMEOUT_MILLIS_KEY and 
SnapshotDescriptionUtils.SNAPSHOT_TIMEOUT_MILLIS_DEFAULT
---
 .../hadoop/hbase/master/snapshot/SnapshotManager.java |  5 +++--
 .../hbase/snapshot/SnapshotDescriptionUtils.java      | 19 +------------------
 2 files changed, 4 insertions(+), 20 deletions(-)

diff --git 
a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/snapshot/SnapshotManager.java
 
b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/snapshot/SnapshotManager.java
index 05db4ab..936730b 100644
--- 
a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/snapshot/SnapshotManager.java
+++ 
b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/snapshot/SnapshotManager.java
@@ -1169,8 +1169,9 @@ public class SnapshotManager extends 
MasterProcedureManager implements Stoppable
     // get the configuration for the coordinator
     Configuration conf = master.getConfiguration();
     long wakeFrequency = conf.getInt(SNAPSHOT_WAKE_MILLIS_KEY, 
SNAPSHOT_WAKE_MILLIS_DEFAULT);
-    long timeoutMillis = 
Math.max(conf.getLong(SnapshotDescriptionUtils.SNAPSHOT_TIMEOUT_MILLIS_KEY,
-                    SnapshotDescriptionUtils.SNAPSHOT_TIMEOUT_MILLIS_DEFAULT),
+    long timeoutMillis = Math.max(
+            
conf.getLong(SnapshotDescriptionUtils.MASTER_SNAPSHOT_TIMEOUT_MILLIS,
+                    SnapshotDescriptionUtils.DEFAULT_MAX_WAIT_TIME),
             
conf.getLong(SnapshotDescriptionUtils.MASTER_SNAPSHOT_TIMEOUT_MILLIS,
                     SnapshotDescriptionUtils.DEFAULT_MAX_WAIT_TIME));
     int opThreads = conf.getInt(SNAPSHOT_POOL_THREADS_KEY, 
SNAPSHOT_POOL_THREADS_DEFAULT);
diff --git 
a/hbase-server/src/main/java/org/apache/hadoop/hbase/snapshot/SnapshotDescriptionUtils.java
 
b/hbase-server/src/main/java/org/apache/hadoop/hbase/snapshot/SnapshotDescriptionUtils.java
index 5c25526..18d8b76 100644
--- 
a/hbase-server/src/main/java/org/apache/hadoop/hbase/snapshot/SnapshotDescriptionUtils.java
+++ 
b/hbase-server/src/main/java/org/apache/hadoop/hbase/snapshot/SnapshotDescriptionUtils.java
@@ -124,28 +124,11 @@ public final class SnapshotDescriptionUtils {
   /** Default value if no start time is specified */
   public static final long NO_SNAPSHOT_START_TIME_SPECIFIED = 0;
 
-
   public static final String MASTER_SNAPSHOT_TIMEOUT_MILLIS = 
"hbase.snapshot.master.timeout.millis";
 
   /** By default, wait 300 seconds for a snapshot to complete */
   public static final long DEFAULT_MAX_WAIT_TIME = 60000 * 5 ;
 
-
-  /**
-   * By default, check to see if the snapshot is complete (ms)
-   * @deprecated Use {@link #DEFAULT_MAX_WAIT_TIME} instead.
-   * */
-  @Deprecated
-  public static final int SNAPSHOT_TIMEOUT_MILLIS_DEFAULT = 60000 * 5;
-
-  /**
-   * Conf key for # of ms elapsed before injecting a snapshot timeout error 
when waiting for
-   * completion.
-   * @deprecated Use {@link #MASTER_SNAPSHOT_TIMEOUT_MILLIS} instead.
-   */
-  @Deprecated
-  public static final String SNAPSHOT_TIMEOUT_MILLIS_KEY = 
"hbase.snapshot.master.timeoutMillis";
-
   private SnapshotDescriptionUtils() {
     // private constructor for utility class
   }
@@ -165,7 +148,7 @@ public final class SnapshotDescriptionUtils {
       confKey = MASTER_SNAPSHOT_TIMEOUT_MILLIS;
     }
     return Math.max(conf.getLong(confKey, defaultMaxWaitTime),
-        conf.getLong(SNAPSHOT_TIMEOUT_MILLIS_KEY, defaultMaxWaitTime));
+        conf.getLong(MASTER_SNAPSHOT_TIMEOUT_MILLIS, defaultMaxWaitTime));
   }
 
   /**

Reply via email to