use of com.facebook.presto.spi.ConnectorSplitSource in project presto by prestodb.
the class TestRaptorSplitManager method testNoHostForShard.
@Test(expectedExceptions = PrestoException.class, expectedExceptionsMessageRegExp = "No host for shard .* found: \\[\\]")
public void testNoHostForShard() {
deleteShardNodes();
ConnectorTableLayoutResult layout = getOnlyElement(metadata.getTableLayouts(SESSION, tableHandle, Constraint.alwaysTrue(), Optional.empty()));
ConnectorSplitSource splitSource = getSplits(raptorSplitManager, layout);
getSplits(splitSource, 1000);
}
use of com.facebook.presto.spi.ConnectorSplitSource in project presto by prestodb.
the class TestRaptorSplitManager method testNoNodes.
@Test(expectedExceptions = PrestoException.class, expectedExceptionsMessageRegExp = "No nodes available to run query")
public void testNoNodes() {
deleteShardNodes();
RaptorSplitManager raptorSplitManagerWithBackup = new RaptorSplitManager(new RaptorConnectorId("fbraptor"), ImmutableSet::of, shardManager, true);
ConnectorTableLayoutResult layout = getOnlyElement(metadata.getTableLayouts(SESSION, tableHandle, Constraint.alwaysTrue(), Optional.empty()));
ConnectorSplitSource splitSource = getSplits(raptorSplitManagerWithBackup, layout);
getSplits(splitSource, 1000);
}
Aggregations