HBASE-23872 [Flakey Test] TestGenerateDelegationToken; Master not initialized after 200000ms
This commit is contained in:
parent
b8194b4902
commit
435b79335e
|
@ -132,6 +132,8 @@ public class ServerManager {
|
|||
public static final int FLUSHEDSEQUENCEID_FLUSHER_INTERVAL_DEFAULT =
|
||||
3 * 60 * 60 * 1000; // 3 hours
|
||||
|
||||
public static final String MAX_CLOCK_SKEW_MS = "hbase.master.maxclockskew";
|
||||
|
||||
private static final Logger LOG = LoggerFactory.getLogger(ServerManager.class);
|
||||
|
||||
// Set if we are to shutdown the cluster.
|
||||
|
@ -179,7 +181,7 @@ public class ServerManager {
|
|||
public ServerManager(final MasterServices master) {
|
||||
this.master = master;
|
||||
Configuration c = master.getConfiguration();
|
||||
maxSkew = c.getLong("hbase.master.maxclockskew", 30000);
|
||||
maxSkew = c.getLong(MAX_CLOCK_SKEW_MS, 30000);
|
||||
warningSkew = c.getLong("hbase.master.warningclockskew", 10000);
|
||||
persistFlushedSequenceId = c.getBoolean(PERSIST_FLUSHEDSEQUENCEID,
|
||||
PERSIST_FLUSHEDSEQUENCEID_DEFAULT);
|
||||
|
|
|
@ -22,6 +22,7 @@ import org.apache.hadoop.fs.Path;
|
|||
import org.apache.hadoop.hbase.HBaseTestingUtility;
|
||||
import org.apache.hadoop.hbase.LocalHBaseCluster;
|
||||
import org.apache.hadoop.hbase.coprocessor.CoprocessorHost;
|
||||
import org.apache.hadoop.hbase.master.ServerManager;
|
||||
import org.apache.hadoop.hbase.security.HBaseKerberosUtils;
|
||||
import org.apache.hadoop.hbase.util.FSUtils;
|
||||
import org.apache.hadoop.minikdc.MiniKdc;
|
||||
|
@ -56,6 +57,9 @@ public class SecureTestCluster {
|
|||
*/
|
||||
@BeforeClass
|
||||
public static void setUp() throws Exception {
|
||||
// Can take a long time for the mini kdc to come up on loaded test cluster. Tolerate this in
|
||||
// test by upping the skew time allowed from 30s to 90s.
|
||||
TEST_UTIL.getConfiguration().setLong(ServerManager.MAX_CLOCK_SKEW_MS, 90000);
|
||||
KDC = TEST_UTIL.setupMiniKdc(KEYTAB_FILE);
|
||||
USERNAME = UserGroupInformation.getLoginUser().getShortUserName();
|
||||
PRINCIPAL = USERNAME + "/" + HOST;
|
||||
|
|
Loading…
Reference in New Issue