Search in sources :

Example 11 with ColumnListsCache

use of org.apache.drill.exec.store.hive.ColumnListsCache in project drill by apache.

the class TestColumnListCache method testPartitionColumnsIndex.

@Test
public void testPartitionColumnsIndex() {
    ColumnListsCache cache = new ColumnListsCache();
    List<FieldSchema> columns = Lists.newArrayList();
    columns.add(new FieldSchema("f1", "int", null));
    columns.add(new FieldSchema("f2", "int", null));
    cache.addOrGet(columns);
    columns.add(new FieldSchema("f3", "int", null));
    assertEquals(1, cache.addOrGet(columns));
}
Also used : FieldSchema(org.apache.hadoop.hive.metastore.api.FieldSchema) ColumnListsCache(org.apache.drill.exec.store.hive.ColumnListsCache) BaseTest(org.apache.drill.test.BaseTest) SlowTest(org.apache.drill.categories.SlowTest) Test(org.junit.Test)

Aggregations

ColumnListsCache (org.apache.drill.exec.store.hive.ColumnListsCache)11 SlowTest (org.apache.drill.categories.SlowTest)10 FieldSchema (org.apache.hadoop.hive.metastore.api.FieldSchema)10 Test (org.junit.Test)10 BaseTest (org.apache.drill.test.BaseTest)5 HiveReadEntry (org.apache.drill.exec.store.hive.HiveReadEntry)1 HiveTableWithColumnCache (org.apache.drill.exec.store.hive.HiveTableWithColumnCache)1 HiveTableWrapper (org.apache.drill.exec.store.hive.HiveTableWrapper)1 Partition (org.apache.hadoop.hive.metastore.api.Partition)1 Table (org.apache.hadoop.hive.metastore.api.Table)1