HBASE-20021 TestFromClientSideWithCoprocessor is flakey
This commit is contained in:
parent
b7685307e4
commit
69d2becc73
|
@ -139,24 +139,27 @@ public class TestFromClientSide {
|
|||
@Rule
|
||||
public TestName name = new TestName();
|
||||
|
||||
@BeforeClass
|
||||
public static void setUpBeforeClass() throws Exception {
|
||||
protected static final void initialize(Class<?>... cps) throws Exception {
|
||||
// Uncomment the following lines if more verbosity is needed for
|
||||
// debugging (see HBASE-12285 for details).
|
||||
//((Log4JLogger)RpcServer.LOG).getLogger().setLevel(Level.ALL);
|
||||
//((Log4JLogger)RpcClient.LOG).getLogger().setLevel(Level.ALL);
|
||||
//((Log4JLogger)ScannerCallable.LOG).getLogger().setLevel(Level.ALL);
|
||||
// ((Log4JLogger)RpcServer.LOG).getLogger().setLevel(Level.ALL);
|
||||
// ((Log4JLogger)RpcClient.LOG).getLogger().setLevel(Level.ALL);
|
||||
// ((Log4JLogger)ScannerCallable.LOG).getLogger().setLevel(Level.ALL);
|
||||
// make sure that we do not get the same ts twice, see HBASE-19731 for more details.
|
||||
EnvironmentEdgeManager.injectEdge(new NonRepeatedEnvironmentEdge());
|
||||
Configuration conf = TEST_UTIL.getConfiguration();
|
||||
conf.setStrings(CoprocessorHost.REGION_COPROCESSOR_CONF_KEY,
|
||||
MultiRowMutationEndpoint.class.getName());
|
||||
Arrays.stream(cps).map(Class::getName).toArray(String[]::new));
|
||||
conf.setBoolean("hbase.table.sanity.checks", true); // enable for below tests
|
||||
conf.setLong(HConstants.HBASE_CLIENT_SCANNER_TIMEOUT_PERIOD, 6000000);
|
||||
// We need more than one region server in this test
|
||||
TEST_UTIL.startMiniCluster(SLAVES);
|
||||
}
|
||||
|
||||
@BeforeClass
|
||||
public static void setUpBeforeClass() throws Exception {
|
||||
initialize(MultiRowMutationEndpoint.class);
|
||||
}
|
||||
|
||||
@AfterClass
|
||||
public static void tearDownAfterClass() throws Exception {
|
||||
TEST_UTIL.shutdownMiniCluster();
|
||||
|
|
|
@ -17,9 +17,7 @@
|
|||
*/
|
||||
package org.apache.hadoop.hbase.client;
|
||||
|
||||
import org.apache.hadoop.conf.Configuration;
|
||||
import org.apache.hadoop.hbase.HBaseClassTestRule;
|
||||
import org.apache.hadoop.hbase.coprocessor.CoprocessorHost;
|
||||
import org.apache.hadoop.hbase.coprocessor.MultiRowMutationEndpoint;
|
||||
import org.apache.hadoop.hbase.regionserver.NoOpScanPolicyObserver;
|
||||
import org.apache.hadoop.hbase.testclassification.ClientTests;
|
||||
|
@ -29,23 +27,18 @@ import org.junit.ClassRule;
|
|||
import org.junit.experimental.categories.Category;
|
||||
|
||||
/**
|
||||
* Test all client operations with a coprocessor that
|
||||
* just implements the default flush/compact/scan policy.
|
||||
* Test all client operations with a coprocessor that just implements the default flush/compact/scan
|
||||
* policy.
|
||||
*/
|
||||
@Category({LargeTests.class, ClientTests.class})
|
||||
@Category({ LargeTests.class, ClientTests.class })
|
||||
public class TestFromClientSideWithCoprocessor extends TestFromClientSide {
|
||||
|
||||
@ClassRule
|
||||
public static final HBaseClassTestRule CLASS_RULE =
|
||||
HBaseClassTestRule.forClass(TestFromClientSideWithCoprocessor.class);
|
||||
HBaseClassTestRule.forClass(TestFromClientSideWithCoprocessor.class);
|
||||
|
||||
@BeforeClass
|
||||
public static void setUpBeforeClass() throws Exception {
|
||||
Configuration conf = TEST_UTIL.getConfiguration();
|
||||
conf.setStrings(CoprocessorHost.REGION_COPROCESSOR_CONF_KEY,
|
||||
MultiRowMutationEndpoint.class.getName(), NoOpScanPolicyObserver.class.getName());
|
||||
conf.setBoolean("hbase.table.sanity.checks", true); // enable for below tests
|
||||
// We need more than one region server in this test
|
||||
TEST_UTIL.startMiniCluster(SLAVES);
|
||||
initialize(MultiRowMutationEndpoint.class, NoOpScanPolicyObserver.class);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue