Teiid Code Analysis - UML Diagrams
- Client
- Transport
- API
- Engine
- Teiid Query Sql API
- org.teiid.dqp.internal.process.RequestWorkItem
- org.teiid.dqp.internal.process.Request
- org.teiid.query.util.CommandContext
- org.teiid.query.optimizer.relational.OptimizerRule
- org.teiid.dqp.internal.process.ThreadReuseExecutor
- org.teiid.query.metadata.QueryMetadataInterface
- org.teiid.query.optimizer.capabilities.CapabilitiesFinder
- org.teiid.query.resolver.CommandResolver
- org.teiid.query.optimizer.CommandPlanner
- org.teiid.query.processor.ProcessorPlan
- org.teiid.query.processor.ProcessorDataManager
- org.teiid.query.processor.relational.AccessNode
- org.teiid.dqp.internal.datamgr.ConnectorWork
Client
org.teiid.client.DQP
- DQP is the client core interface, client own a DQP Proxy to interact with Teiid Server
org.teiid.client.security.ILogon
- ILogon is the interface for Client generoc logon
org.teiid.net.socket.ObjectChannel
- ObjectChannel is the key interface for socket write and read, it has 2 implementation
- OioObjectChannel is client implementation for socket read and write, which it wrapped a Socket client
- ObjectChannelImpl is the server implementation for socket read and write, which it wrapped a Netty Server
org.teiid.net.socket.ServerConnection
- SocketServerConnection - Represents a client connection that maintains session state and allows for service fail over. Implements a sticky random selection policy.
org.teiid.jdbc.ConnectionProfile
Transport
org.teiid.transport.ClientServiceRegistry
API
org.teiid.metadata.AbstractMetadataRecord
Example - Schema
MetadataStore metadataStore = new MetadataStore();
Schema schema = new Schema();
schema.setName("name");
metadataStore.addSchema(schema);
NOTE: A Schema mainly contain Table, Procedure, FunctionMethod.
Example - Table
Table table = new Table();
table.setName("name");
table.setSupportsUpdate(true);
table.setTableType(org.teiid.metadata.Table.Type.Table);
schema.addTable(table);
Example - Column
Table table = new Table();
...
Column column = new Column();
column.setName("name");
column.setRuntimeType(DataTypeManager.DefaultDataTypes.STRING);
column.setSearchType(SearchType.Searchable);
column.setNullType(NullType.Nullable);
column.setPosition(1);
column.setUpdatable(true);
column.setLength(100);
table.addColumn(column);
org.teiid.metadata.MetadataRepository<F,C>
org.teiid.query.metadata.CompositeMetadataStore
- MetadataStore is a sample holder for metadata, which mainly contain Schemas(
org.teiid.metadata.Schema
) and DataTypes(org.teiid.metadata.Datatype
). - CompositeMetadataStore add function of merge MetadataStore together.
Teiid Language API
Refer to link
Engine
Teiid Query Sql API
Refer to link
org.teiid.dqp.internal.process.RequestWorkItem
- RequestWorkItem - Compiles results and other information for the client. There is quite a bit of logic surrounding forming batches to prevent buffer growth, send multiple batches at a time, partial batches, etc. There is also special handling for the update count case, which needs to read the entire result before sending it back to the client.
- AbstractWorkItem - Represents a task that performs work that may take more than one processing pass to complete. During processing the WorkItem may receive events asynchronously through the moreWork method.
org.teiid.dqp.internal.process.Request
org.teiid.query.util.CommandContext
- CommandContext defines the context that a command is processing in. For example, this defines who is processing the command and why. Also, this class (or subclasses) provide a means to pass context-specific information between users of the query processor framework.
org.teiid.query.optimizer.relational.OptimizerRule
org.teiid.dqp.internal.process.ThreadReuseExecutor
org.teiid.query.metadata.QueryMetadataInterface
- QueryMetadataInterface interface defines the way that query components access metadata. Any user of a query component will need to implement this interface. Many of these methods take or return things of type “Object”. Typically, these objects represent a metadata-implementation-specific metadata ID. The interface define several methods:
Object getElementID(String elementName)throws TeiidComponentException, QueryMetadataException;
Object getGroupID(String groupName)throws TeiidComponentException, QueryMetadataException;
Object getModelID(String modelName)throws TeiidComponentException, QueryMetadataException;
Collection getGroupsForPartialName(String partialGroupName)throws TeiidComponentException, QueryMetadataException;
Object getModelID(Object groupOrElementID)throws TeiidComponentException, QueryMetadataException;
String getFullName(Object metadataID)throws TeiidComponentException, QueryMetadataException;
String getName(Object metadataID) throws TeiidComponentException, QueryMetadataException;
List getElementIDsInGroupID(Object groupID)throws TeiidComponentException, QueryMetadataException;
Object getGroupIDForElementID(Object elementID)throws TeiidComponentException, QueryMetadataException;
...
org.teiid.query.optimizer.capabilities.CapabilitiesFinder
The CapabilitiesFinder describes how to find connector capabilities.
org.teiid.query.resolver.CommandResolver
org.teiid.query.optimizer.CommandPlanner
org.teiid.query.processor.ProcessorPlan
- ProcessorPlan - This class represents a processor plan. It is generic in that it abstracts the interface to the plan by the processor, meaning that the actual implementation of the plan or the types of processing done by the plan is not important to the processor.
org.teiid.query.processor.ProcessorDataManager
- TempTableDataManager - A proxy ProcessorDataManager used to handle temporary tables. This isn’t handled as a connector because of the temporary metadata and the create/drop handling (which doesn’t have push down support).
- DataTierManagerImpl - A full ProcessorDataManager implementation that controls access to ConnectorManager and handles system queries.
org.teiid.query.processor.relational.AccessNode
org.teiid.dqp.internal.datamgr.ConnectorWork
- ConnectorWork - Represents a connector execution in batched form.