use of com.nearinfinity.honeycomb.mysql.QueryKey in project honeycomb by altamiracorp.
the class ScanOperationsIT method testIndexExactScan.
@Test
public void testIndexExactScan() {
ITUtils.insertData(proxy, ROW_COUNT, INDEX_COL_VALUE);
final QueryKey key = ITUtils.createKey(INDEX_COL_VALUE, QueryType.EXACT_KEY);
ITUtils.assertReceivingDifferentRows(proxy, key, ROW_COUNT);
}
use of com.nearinfinity.honeycomb.mysql.QueryKey in project honeycomb by altamiracorp.
the class ScanOperationsIT method testAfterKeyWithNullScan.
@Test
public void testAfterKeyWithNullScan() {
ITUtils.insertNullData(proxy, ROW_COUNT, TestConstants.COLUMN1);
ITUtils.insertData(proxy, ROW_COUNT, INDEX_COL_VALUE);
ITUtils.insertData(proxy, ROW_COUNT, INDEX_COL_VALUE + 1);
final Map<String, ByteBuffer> keyValues = Maps.newHashMap();
keyValues.put(TestConstants.COLUMN1, ITUtils.encodeValue(2));
final QueryKey key = new QueryKey(TestConstants.INDEX2, QueryType.AFTER_KEY, keyValues);
ITUtils.assertReceivingDifferentRows(proxy, key, ROW_COUNT + ROW_COUNT);
}
use of com.nearinfinity.honeycomb.mysql.QueryKey in project honeycomb by altamiracorp.
the class ScanOperationsIT method testIndexFirstScan.
@Test
public void testIndexFirstScan() {
ITUtils.insertNullData(proxy, 2);
ITUtils.insertData(proxy, 1, INDEX_COL_VALUE, TestConstants.FULL_UUID);
ITUtils.insertData(proxy, 1, INDEX_COL_VALUE + 1, TestConstants.ZERO_UUID);
ITUtils.insertData(proxy, ROW_COUNT, INDEX_COL_VALUE + 1);
final QueryKey key = new QueryKey(TestConstants.INDEX1, QueryType.INDEX_FIRST, Maps.<String, ByteBuffer>newHashMap());
ITUtils.assertReceivingDifferentRows(proxy, key, ROW_COUNT + 4);
}
use of com.nearinfinity.honeycomb.mysql.QueryKey in project honeycomb by altamiracorp.
the class ScanOperationsIT method testAfterKeyScan.
@Test
public void testAfterKeyScan() {
ITUtils.insertData(proxy, 1, INDEX_COL_VALUE, TestConstants.FULL_UUID);
ITUtils.insertData(proxy, 1, INDEX_COL_VALUE + 1, TestConstants.ZERO_UUID);
ITUtils.insertData(proxy, ROW_COUNT, INDEX_COL_VALUE + 1);
final QueryKey key = ITUtils.createKey(INDEX_COL_VALUE, QueryType.AFTER_KEY);
ITUtils.assertReceivingDifferentRows(proxy, key, ROW_COUNT + 1);
}
use of com.nearinfinity.honeycomb.mysql.QueryKey in project honeycomb by altamiracorp.
the class ScanOperationsIT method testKeyOrPreviousScan.
@Test
public void testKeyOrPreviousScan() {
ITUtils.insertData(proxy, 1, INDEX_COL_VALUE, TestConstants.FULL_UUID);
ITUtils.insertData(proxy, 1, INDEX_COL_VALUE - 1, TestConstants.ZERO_UUID);
ITUtils.insertData(proxy, ROW_COUNT, INDEX_COL_VALUE - 1);
final QueryKey key = ITUtils.createKey(INDEX_COL_VALUE, QueryType.KEY_OR_PREVIOUS);
ITUtils.assertReceivingDifferentRows(proxy, key, ROW_COUNT + 2);
}
Aggregations