[teiid-issues] [JBoss JIRA] (TEIID-1636) Programmatically configure internal materialized tables

Steven Hawkins (JIRA) jira-events at lists.jboss.org
Mon Sep 10 11:29:33 EDT 2012


     [ https://issues.jboss.org/browse/TEIID-1636?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Steven Hawkins resolved TEIID-1636.
-----------------------------------

    Fix Version/s:     (was: 8.2)
       Resolution: Rejected


Given the simplicity of the workaround and that this change would force the usage of the nocache construct to access the source table, I'm going to reject this for now.

However I will open a new issue to cover setting the mat cache hint via a property so that it can be changed independently of the view definition.
                
> Programmatically configure internal materialized tables
> -------------------------------------------------------
>
>                 Key: TEIID-1636
>                 URL: https://issues.jboss.org/browse/TEIID-1636
>             Project: Teiid
>          Issue Type: Enhancement
>          Components: Query Engine
>    Affects Versions: 7.3
>            Reporter: Mark Addleman
>            Assignee: Steven Hawkins
>            Priority: Optional
>         Attachments: physical_mat.patch
>
>
> I am trying to programatically create a materialized view from the MetadataFactory object.  I have created a table object using addTable() and then I call setMaterialized(true).  I see there are a couple of other related method names in Table (setMaterializedStagedTable and setMaterializedTable).  I assume those are when materializing to an external database.  What I am doing is incorrect, however.  
> When I try to issue a refresh CALL SYSADMIN.refreshMatView(viewname=>'xyz_metadata.property', invalidate=>false), I get the following exception:
> QueryMetadataException]QueryPlan could not be found for physical group chorus_metadata.property
>  	at org.teiid.query.metadata.TransformationMetadata.getVirtualPlan(TransformationMetadata.java:453)
>  	at org.teiid.query.metadata.TempMetadataAdapter.getVirtualPlan(TempMetadataAdapter.java:253)
> 	at org.teiid.query.optimizer.relational.RelationalPlanner.getGlobalTempTableMetadataId(RelationalPlanner.java:1136)
> 	at org.teiid.query.tempdata.TempTableDataManager.handleSystemProcedures(TempTableDataManager.java:320)
> 	at org.teiid.query.tempdata.TempTableDataManager.registerRequest(TempTableDataManager.java:188)
> 	at org.teiid.query.tempdata.TempTableDataManager.registerRequest(TempTableDataManager.java:170)
> 	at org.teiid.query.processor.relational.AccessNode.registerRequest(AccessNode.java:197)
> 	at org.teiid.query.processor.relational.AccessNode.open(AccessNode.java:118)
> 	at org.teiid.query.processor.relational.RelationalNode.open(RelationalNode.java:250)
> 	at org.teiid.query.processor.relational.RelationalPlan.open(RelationalPlan.java:152)
> 	at org.teiid.query.processor.QueryProcessor.nextBatchDirect(QueryProcessor.java:134)
> 	at org.teiid.query.processor.QueryProcessor.nextBatch(QueryProcessor.java:105)
> 	at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:115)
> 	at org.teiid.dqp.internal.process.RequestWorkItem.processMore(RequestWorkItem.java:250)
> 	at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:184)
> 	at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:49)
> 	at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:188)
> 	at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:116)
> 	at org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:290)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
> 	at java.lang.Thread.run(Thread.java:619)
> 13 Jun 2011 17:05:43,663 PDT INFO  [MATVIEWS] Loading materialized view table #MAT_XYZ_METADATA.PROPERTY
> Subsequent calls to the refresh stored procedure yield an NPE else in Teiid code.

--
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