public class MongoStoragePlugin extends AbstractStoragePlugin
context
DEFAULT_WS_NAME
Constructor and Description |
---|
MongoStoragePlugin(MongoStoragePluginConfig mongoConfig,
DrillbitContext context,
String name) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
org.apache.calcite.plan.Convention |
convention() |
com.mongodb.client.MongoClient |
getClient() |
com.mongodb.client.MongoClient |
getClient(List<com.mongodb.ServerAddress> addresses) |
MongoStoragePluginConfig |
getConfig()
Method returns a Jackson serializable object that extends a StoragePluginConfig.
|
Set<? extends org.apache.calcite.plan.RelOptRule> |
getOptimizerRules(OptimizerRulesContext optimizerContext,
PlannerPhase phase)
TODO: Move this method to
StoragePlugin interface in next major version release. |
AbstractGroupScan |
getPhysicalScan(String userName,
JSONOptions selection)
Get the physical scan operator for the particular GroupScan (read) node.
|
void |
registerSchemas(SchemaConfig schemaConfig,
org.apache.calcite.schema.SchemaPlus parent)
Register the schemas provided by this SchemaFactory implementation under the given parent schema.
|
boolean |
supportsRead()
Indicates if Drill can read the table from this format.
|
getContext, getFormatPlugin, getLogicalOptimizerRules, getName, getOptimizerRules, getPhysicalOptimizerRules, getPhysicalScan, getPhysicalScan, getPhysicalScan, getPhysicalScan, getPhysicalScan, start, supportsWrite
public MongoStoragePlugin(MongoStoragePluginConfig mongoConfig, DrillbitContext context, String name)
public MongoStoragePluginConfig getConfig()
StoragePlugin
public void registerSchemas(SchemaConfig schemaConfig, org.apache.calcite.schema.SchemaPlus parent)
SchemaFactory
schemaConfig
- Configuration for schema objects.parent
- Reference to parent schema.public boolean supportsRead()
StoragePlugin
supportsRead
in interface StoragePlugin
supportsRead
in class AbstractStoragePlugin
public AbstractGroupScan getPhysicalScan(String userName, JSONOptions selection) throws IOException
StoragePlugin
getPhysicalScan
in interface StoragePlugin
getPhysicalScan
in class AbstractStoragePlugin
userName
- User whom to impersonate when when reading the contents as part of Scan.selection
- The configured storage engine specific selection.IOException
public Set<? extends org.apache.calcite.plan.RelOptRule> getOptimizerRules(OptimizerRulesContext optimizerContext, PlannerPhase phase)
AbstractStoragePlugin
StoragePlugin
interface in next major version release.getOptimizerRules
in class AbstractStoragePlugin
public org.apache.calcite.plan.Convention convention()
public com.mongodb.client.MongoClient getClient()
public com.mongodb.client.MongoClient getClient(List<com.mongodb.ServerAddress> addresses)
public void close()
close
in interface AutoCloseable
close
in class AbstractStoragePlugin
Copyright © 1970 The Apache Software Foundation. All rights reserved.