DataSourceNode¶
DataSourceNode is a PlanNode.
Creating Instance¶
DataSourceNode takes the following to be created:
-
PlanNodeId - DataSource
- Source Alias
- SchemaKStreamFactory
-
isWindowedflag - KsqlConfig
DataSourceNode is created when:
SchemaKStreamFactory¶
DataSourceNode can be given a SchemaKStreamFactory when created. Unless given, DataSourceNode uses SchemaKSourceFactory.
Note
Note the difference in type names, i.e. SchemaKStreamFactory (with Stream inside) vs SchemaKSourceFactory (with Source instead).
The SchemaKStreamFactory is used to create a source SchemaKStream when DataSourceNode is requested for one.
Building SchemaKStream¶
SchemaKStream<?> buildStream(
PlanBuildContext buildContext)
buildStream is part of the PlanNode abstraction.
buildStream requests the given PlanBuildContext to buildNodeContext for the PlanNodeId.
In the end, buildStream requests the SchemaKStreamFactory for a SchemaKStream for the DataSource.