Package org.apache.druid.query
Class GlobalTableDataSource
java.lang.Object
org.apache.druid.query.LeafDataSource
org.apache.druid.query.TableDataSource
org.apache.druid.query.GlobalTableDataSource
- All Implemented Interfaces:
Cacheable,DataSource
TableDataSource variant for globally available 'broadcast' segments. If bound to a
JoinableFactory that can create an
IndexedTable using DruidBinders.joinableFactoryBinder, this allows
optimal usage of segments using this DataSource type in join operations (because they are global), and so can be
pushed down to historicals as a JoinDataSource, instead of requiring a subquery join using
InlineDataSource to construct an IndexedTable on the fly on the
broker. Because it is also a TableDataSource, when queried directly, or on the left hand side of a join,
they will be treated as any normal table datasource.-
Field Summary
Fields inherited from interface org.apache.druid.query.DataSource
JOIN_OPERATION_CACHE_ID, NOOP_CACHE_ID, TABLE_DATA_SOURCE_CACHE_ID -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanisCacheable(boolean isBroker) Query results from Broadcast datasources should not be cached on broker https://github.com/apache/druid/issues/10444booleanisGlobal()Decides if this datasource can be accessed globally.toString()Methods inherited from class org.apache.druid.query.TableDataSource
create, equals, getCacheKey, getName, getTableNames, hashCode, isProcessable, withPoliciesMethods inherited from class org.apache.druid.query.LeafDataSource
createSegmentMapFunction, getChildren, withChildren
-
Constructor Details
-
GlobalTableDataSource
-
-
Method Details
-
isGlobal
public boolean isGlobal()Description copied from interface:DataSourceDecides if this datasource can be accessed globally.This means that all servers have a full copy of this datasource.
Examples: inline table, lookup.
- Specified by:
isGlobalin interfaceDataSource- Overrides:
isGlobalin classTableDataSource
-
isCacheable
public boolean isCacheable(boolean isBroker) Query results from Broadcast datasources should not be cached on broker https://github.com/apache/druid/issues/10444- Specified by:
isCacheablein interfaceDataSource- Overrides:
isCacheablein classTableDataSource
-
toString
- Overrides:
toStringin classTableDataSource
-