Search in sources :

Example 1 with DocSchemaInfoFactory

use of io.crate.metadata.doc.DocSchemaInfoFactory in project crate by crate.

the class SysShardsExpressionsTest method prepare.

@Before
public void prepare() throws Exception {
    ClusterService clusterService = new NoopClusterService();
    indexShard = mockIndexShard();
    schemas = new Schemas(Settings.EMPTY, ImmutableMap.of("sys", new SysSchemaInfo(clusterService)), clusterService, new DocSchemaInfoFactory(new TestingDocTableInfoFactory(Collections.emptyMap())));
    ShardReferenceResolver shardRefResolver = new ShardReferenceResolver(clusterService, schemas, indexShard);
    resolver = new RecoveryShardReferenceResolver(shardRefResolver, indexShard);
}
Also used : SysSchemaInfo(io.crate.metadata.sys.SysSchemaInfo) RecoveryShardReferenceResolver(io.crate.metadata.shard.RecoveryShardReferenceResolver) NoopClusterService(org.elasticsearch.test.cluster.NoopClusterService) ClusterService(org.elasticsearch.cluster.ClusterService) DocSchemaInfoFactory(io.crate.metadata.doc.DocSchemaInfoFactory) TestingDocTableInfoFactory(io.crate.metadata.doc.TestingDocTableInfoFactory) NoopClusterService(org.elasticsearch.test.cluster.NoopClusterService) ShardReferenceResolver(io.crate.metadata.shard.ShardReferenceResolver) RecoveryShardReferenceResolver(io.crate.metadata.shard.RecoveryShardReferenceResolver) Before(org.junit.Before)

Aggregations

DocSchemaInfoFactory (io.crate.metadata.doc.DocSchemaInfoFactory)1 TestingDocTableInfoFactory (io.crate.metadata.doc.TestingDocTableInfoFactory)1 RecoveryShardReferenceResolver (io.crate.metadata.shard.RecoveryShardReferenceResolver)1 ShardReferenceResolver (io.crate.metadata.shard.ShardReferenceResolver)1 SysSchemaInfo (io.crate.metadata.sys.SysSchemaInfo)1 ClusterService (org.elasticsearch.cluster.ClusterService)1 NoopClusterService (org.elasticsearch.test.cluster.NoopClusterService)1 Before (org.junit.Before)1