[teiid-issues] [JBoss JIRA] (TEIID-2578) Provide API to add schema elements at translator layer

Steven Hawkins (JIRA) jira-events at lists.jboss.org
Wed Jul 17 14:35:26 EDT 2013


    [ https://issues.jboss.org/browse/TEIID-2578?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12790457#comment-12790457 ] 

Steven Hawkins commented on TEIID-2578:
---------------------------------------

A little more on this from an email:

Depending upon the point of view TEIID-2578 has 1 or 2 responsibilities.  The primary responsibility is to add (and possibly drop) a table/view/procedure to an existing Teiid schema with the corresponding update to the metadata repository.  This is similar to the "CREATE FOREIGN TEMPORARY TABLE ... " feature except that the actual schema object is modified.  This has implications wrt the visibility of the change and transactions and the caching of system schema entries (in the pg metadata layer for instance).  Drop also requires a lot of book keeping to make sure that we're not breaking existing views or relationships.

The other responsibility at least with tying this to materialization is the corresponding creation on the source of a particular table (procedures would require additional metadata) - but this is really not required by the first feature which is just to manipulate our metadata.  Source creation of course has a lot of considerations in terms of ddl generation, creation of indexes, etc.  

It's conceivable that for materialized views this could be metadata driven to some degree.  We/designer can associate ddl scripts with extension metadata (create-ddl, truncate-ddl, postload-ddl, etc.) on the view that is marked as materialized with the ability to run the ddl via the native procedure.  That coupled with some notion of a state table would give us the ability to control implicit creation of the tables on the source.  Whether we have a corresponding Teiid schema entry for the table is really up to the design of the feature.  Some may want the materialized tables to effectively be hidden (which isn't currently possible as we require a reference to a source table), while others may want direct access even via Teiid for more complicated control over refresh.
                
> Provide API to add schema elements at translator layer
> ------------------------------------------------------
>
>                 Key: TEIID-2578
>                 URL: https://issues.jboss.org/browse/TEIID-2578
>             Project: Teiid
>          Issue Type: Feature Request
>          Components: Query Engine
>            Reporter: Ramesh Reddy
>            Assignee: Ramesh Reddy
>             Fix For: 8.5
>
>
> Currently the translator API is can expose the source schema they represent, however there are no facilities to create the schema elements like
> * table
> * procedure
> the function support is available, but this needs be re-factored under this interface (may be this can be a follow on task)
> Using this feature, query engine should be able to ad-hoc create tables or procedures. The motivation for the feature is to provide a more comprehensive materialization feature.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the teiid-issues mailing list