[teiid-issues] [JBoss JIRA] (TEIID-4661) Subsequent queries hang after materialized view TTL expires.

Jan Stastny (JIRA) issues at jboss.org
Fri Mar 24 03:11:00 EDT 2017


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

Jan Stastny commented on TEIID-4661:
------------------------------------

I am using this vdb for testing:
{code:xml|title=teiid4661-vdb.xml}
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<vdb name="teiid4661" version="1">
    <property name="lazy-invalidate" value="true" />
    <model name="loopback" type="PHYSICAL">
        <property name="importer.importKeys" value="true" />
        <property name="importer.importProcedures" value="true" />
        <source name="loopback-source" translator-name="loopback-override" />
        <metadata type="NATIVE,DDL"><![CDATA[
              CREATE FOREIGN TABLE customers (
                   id integer PRIMARY KEY,
                   name varchar(255),
                   salary long);

             CREATE FOREIGN TABLE orders (
                   id integer PRIMARY KEY,
                   name varchar(255));
             ]]>
        </metadata>
    </model>
    <model name="View" type="VIRTUAL">
        <metadata type="DDL"><![CDATA[
            CREATE VIEW Data (
               id integer,
               name string,
               id_1 integer,
               name_1 string,
               salary long
           ) options (materialized true)
           AS
           /*+ cache(ttl:1000) */ select c.id as id, c.name as name, o.id as id_1, o.name as name_1, c.salary as salary from customers c, orders o ;
      ]]>
        </metadata>
    </model>
    <translator name="loopback-override" type="loopback">
        <property name="DelegateName" value="jdbc-simple" />
        <property name="RowCount" value="50" />
        <property name="IncrementRows" value="true" />
    </translator>
</vdb>
{code}
Is my testing approach incorrect? With internal materialization, there is no ttl-driven load running in background, is there? So it is safe to wait longer than ttl for it to expire and expect that next load is triggered only when the view is queried, isn't it?

> Subsequent queries hang after materialized view TTL expires.
> ------------------------------------------------------------
>
>                 Key: TEIID-4661
>                 URL: https://issues.jboss.org/browse/TEIID-4661
>             Project: Teiid
>          Issue Type: Bug
>          Components: Query Engine
>    Affects Versions: 8.12.x
>            Reporter: Colin Mondesir
>            Assignee: Steven Hawkins
>            Priority: Critical
>             Fix For: 9.0.6, 9.1.2, 9.2, 8.12.10.6_3
>
>
> With a VDB using lazy-invalidate in a clustered configuration initially the materialized view is cached correctly but when the TTL expires (10 minutes) and the query is run again the state of the view changes to LOADING and never reverts to "LOADED", so the next query hangs.



--
This message was sent by Atlassian JIRA
(v7.2.3#72005)


More information about the teiid-issues mailing list