[JBoss JIRA] (TEIID-3996) SAP HANA materialization: MATVIEW_ONERROR_ACTION set to WAIT problem
by RH Bugzilla Integration (JIRA)
[ https://issues.jboss.org/browse/TEIID-3996?page=com.atlassian.jira.plugin... ]
RH Bugzilla Integration updated TEIID-3996:
-------------------------------------------
Bugzilla References: (was: https://bugzilla.redhat.com/show_bug.cgi?id=1311414)
Bugzilla Update: (was: Perform)
> SAP HANA materialization: MATVIEW_ONERROR_ACTION set to WAIT problem
> --------------------------------------------------------------------
>
> Key: TEIID-3996
> URL: https://issues.jboss.org/browse/TEIID-3996
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 8.12.x
> Reporter: Jan Stastny
> Assignee: Steven Hawkins
>
> When using materialization wit SAP HANA datasource, a problem emerges when "teiid_rel:MATVIEW_ONERROR_ACTION" 'WAIT' is defined for the materialized view.
> The query which initiates matview's loading doesn't wait for its completion, thus returns stale data (empty resultset in case of the initial invocation).
> Materialized view definition:
> {code:sql}
> CREATE VIEW external_long_ttl (
> customer_id integer NOT NULL,
> total_amount integer
> ) OPTIONS (
> MATERIALIZED 'TRUE',
> UPDATABLE 'FALSE',
> MATERIALIZED_TABLE 'Source.JSTASTNY.dv_matviews_mat_view',
> "teiid_rel:ALLOW_MATVIEW_MANAGEMENT" 'true',
> "teiid_rel:MATVIEW_STATUS_TABLE" 'Source.JSTASTNY.dv_matviews_statustable',
> "teiid_rel:ON_VDB_START_SCRIPT" 'MERGE INTO dv_matviews_check_table(id,vdb_create) SELECT id, vdb_create+1 FROM dv_matviews_check_table WHERE id=''external_long_ttl'';',
> "teiid_rel:ON_VDB_DROP_SCRIPT" 'MERGE INTO dv_matviews_check_table(id,vdb_drop) SELECT id, vdb_drop+1 FROM dv_matviews_check_table WHERE id=''external_long_ttl'';',
> "teiid_rel:MATVIEW_LOAD_SCRIPT" 'INSERT INTO dv_matviews_mat_view_stage(customer_id,total_amount) SELECT CONVERT(c.id,integer) AS customer_id, CONVERT(SUM(o.amount),integer) AS total_amount FROM dv_matviews_customers c INNER JOIN dv_matviews_orders o ON c.id = o.customer_id GROUP BY c.id;',
> "teiid_rel:MATVIEW_BEFORE_LOAD_SCRIPT" 'exec Source.native(''truncate table dv_matviews_mat_view_stage'');MERGE INTO dv_matviews_check_table(id,before_load) SELECT id, before_load+1 FROM dv_matviews_check_table WHERE id=''external_long_ttl'';',
> "teiid_rel:MATVIEW_AFTER_LOAD_SCRIPT" 'exec Source.native(''RENAME TABLE dv_matviews_mat_view_stage TO dv_matviews_mat_view_temp'');exec Source.native(''RENAME TABLE dv_matviews_mat_view TO dv_matviews_mat_view_stage'');exec Source.native(''RENAME TABLE dv_matviews_mat_view_temp TO dv_matviews_mat_view'');MERGE INTO dv_matviews_check_table(id,after_load) SELECT id, after_load+1 FROM dv_matviews_check_table WHERE id=''external_long_ttl'';',
> "teiid_rel:MATVIEW_ONERROR_ACTION" 'WAIT',
> "teiid_rel:MATVIEW_TTL" 20000
> ) AS SELECT CONVERT(c.id,integer) AS customer_id, CONVERT(SUM(o.amount),integer) AS total_amount FROM dv_matviews_customers c INNER JOIN dv_matviews_orders o ON c.id = o.customer_id GROUP BY c.id;
> {code}
> Query performed:
> {code:sql}
> SELECT * FROM external_long_ttl;
> {code}
> Reproducer:
> {code:java}
> Statement statement = connection.createStatement();
> // invoke initial load, won't return loaded data even though it should
> ResultSet rs1 = statement.executeQuery("SELECT * FROM external_long_ttl;");
> Assert.assertFalse(rs1.next());
> // wait explicitly for the loading to finish
> Thread.sleep(7000);
> // repeat the query, to get the data after load finished
> ResultSet rs2 = statement.executeQuery("SELECT * FROM external_long_ttl;");
> Assert.assertTrue(rs2.next());
> .
> .
> .
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
10 years
[JBoss JIRA] (TEIID-3983) External Materialization MATVIEW_ONERROR_ACTION WAIT problem
by RH Bugzilla Integration (JIRA)
[ https://issues.jboss.org/browse/TEIID-3983?page=com.atlassian.jira.plugin... ]
RH Bugzilla Integration commented on TEIID-3983:
------------------------------------------------
Van Halbert <vhalbert(a)redhat.com> changed the Status of [bug 1311414|https://bugzilla.redhat.com/show_bug.cgi?id=1311414] from NEW to MODIFIED
> External Materialization MATVIEW_ONERROR_ACTION WAIT problem
> ------------------------------------------------------------
>
> Key: TEIID-3983
> URL: https://issues.jboss.org/browse/TEIID-3983
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 8.12.5
> Reporter: Jan Stastny
> Assignee: Steven Hawkins
> Fix For: 9.0, 8.12.5, 8.13.2
>
>
> When using "teiid_rel:MATVIEW_ONERROR_ACTION" 'WAIT' option in materialized view definition, there's problem with blocked request.
> The blocked request is the one, that triggered the materialized view's loading (first query on the defined materialized view). After such request, one can observe, that the query execution doesn't end, but hangs.
> Meanwhile while examining the contents of 'status' table in the underlying database, the LoadNumber column's value increases regularly according to the defined ttl. Moreover the 'LOADSTATE' column changes from LOADING to LOADED in similar manner. The materialized table is populated with correct data. From this I assume, materialization is set up correctly.
> During the wait, when logging set to DEBUG, there appears regularly, apart from the logs about refreshing the mat view, this entry:
> {code:plain}
> [32m09:14:52,151 DEBUG [org.teiid.PROCESSOR] (Worker0_QueryProcessorQueue2695) Request Thread 87XzBpSzkyk4.0 with state PROCESSING
> [32m09:14:52,151 DEBUG [org.teiid.PROCESSOR] (Worker0_QueryProcessorQueue2695) Request Thread 87XzBpSzkyk4.0 - processor blocked
> {code}
> The log appears in 'ttl' determined intervals, each time after materialized table loading related entries.
> The thread mentioned is the one created after the original query execution was initiated.
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
10 years
[JBoss JIRA] (TEIID-4026) Web Admin Console: Invalid attribute in SSL configuration
by RH Bugzilla Integration (JIRA)
[ https://issues.jboss.org/browse/TEIID-4026?page=com.atlassian.jira.plugin... ]
RH Bugzilla Integration updated TEIID-4026:
-------------------------------------------
Bugzilla References: (was: https://bugzilla.redhat.com/show_bug.cgi?id=1315333)
Bugzilla Update: (was: Perform)
> Web Admin Console: Invalid attribute in SSL configuration
> ---------------------------------------------------------
>
> Key: TEIID-4026
> URL: https://issues.jboss.org/browse/TEIID-4026
> Project: Teiid
> Issue Type: Bug
> Components: Build/Kits
> Affects Versions: 8.12.5
> Environment: ER1
> Reporter: Filip Elias
> Assignee: Steven Hawkins
>
> It seems ssl-enable is invalid attribute (ssl can be enabled through attribute 'mode'). I assume it can be removed from menu. Configuration fails when SSL Enabled is checked.
> Error:
> {code}
> Unknown error
> Unexpected HTTP response: 500
> Request
> {
> "operation" => "composite",
> "address" => [],
> "steps" => [{
> "address" => [
> ("subsystem" => "teiid"),
> ("transport" => "embedded")
> ],
> "operation" => "write-attribute",
> "name" => "ssl-enable",
> "value" => true
> }]
> }
> Response
> Internal Server Error
> {
> "outcome" => "failed",
> "result" => {"step-1" => {
> "outcome" => "failed",
> "failure-description" => "JBAS014792: Unknown attribute ssl-enable",
> "rolled-back" => true
> }},
> "failure-description" => {"JBAS014653: Composite operation failed and was rolled back. Steps that failed:" => {"Operation step-1" => "JBAS014792: Unknown attribute ssl-enable"}},
> "rolled-back" => true,
> "response-headers" => {"process-state" => "reload-required"}
> }
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
10 years
[JBoss JIRA] (TEIID-3781) Queries are not killed even if the client sends a cancel request
by RH Bugzilla Integration (JIRA)
[ https://issues.jboss.org/browse/TEIID-3781?page=com.atlassian.jira.plugin... ]
RH Bugzilla Integration commented on TEIID-3781:
------------------------------------------------
Van Halbert <vhalbert(a)redhat.com> changed the Status of [bug 1315378|https://bugzilla.redhat.com/show_bug.cgi?id=1315378] from NEW to ON_QA
> Queries are not killed even if the client sends a cancel request
> ----------------------------------------------------------------
>
> Key: TEIID-3781
> URL: https://issues.jboss.org/browse/TEIID-3781
> Project: Teiid
> Issue Type: Quality Risk
> Components: Query Engine
> Affects Versions: 7.0
> Reporter: Salvatore R
> Assignee: Steven Hawkins
> Fix For: 8.12.1, 8.13
>
>
> I have different behaviors when I try to cancel the following queries:
> {code:sql}
> SELECT COUNT(*)
> FROM
> (SELECT * FROM my.address) as x1,
> (SELECT * FROM my.address) as y1
> {code}
> and
> {code:sql}
> SELECT COUNT(*)
> FROM
> (SELECT * FROM my.address limit 10000) as x1,
> (SELECT * FROM my.address limit 10000) as y1
> {code}
> where "my.address" is a table with around 20000 rows in MySQL.
> The first query is immediately cancelled but the second one continues to run until the end and it is never killed.
> Looking at the generated plans, the main difference is that the first query is fully pushed down to MySQL while the second one is not.
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
10 years
[JBoss JIRA] (TEIID-4057) OData - if PUT fails, next update request fails because table in DB is still locked
by RH Bugzilla Integration (JIRA)
[ https://issues.jboss.org/browse/TEIID-4057?page=com.atlassian.jira.plugin... ]
RH Bugzilla Integration commented on TEIID-4057:
------------------------------------------------
Van Halbert <vhalbert(a)redhat.com> changed the Status of [bug 1316498|https://bugzilla.redhat.com/show_bug.cgi?id=1316498] from NEW to MODIFIED
> OData - if PUT fails, next update request fails because table in DB is still locked
> -----------------------------------------------------------------------------------
>
> Key: TEIID-4057
> URL: https://issues.jboss.org/browse/TEIID-4057
> Project: Teiid
> Issue Type: Sub-task
> Components: OData
> Reporter: Juraj Duráni
> Assignee: Steven Hawkins
> Fix For: 9.0, 8.12.5
>
>
> I can see (from the log) that processing of PUT request is as follows:
> # select record from table
> # delete record
> # parse entity from HTTP request
> # insert new record
> But if e.g. step 3 fails, Teiid cancels transaction and returns error. In my opinion, parsing of the entity should be the first step (or at least right after select).
> What happen here is, that DELETE statement creates transaction and locks the table. But the transaction is not canceled immediately after cancel request \[1\]. This causes that no other query can succeed, because of lock on the table (EAP uses connection pool and does not close connections immediately and therefore open connection has still one transaction in active state).
> *Note:* We use H2 database for testing purpose. But I think that this could happen with any DB. Anyway, parsing of the entity should not be performed after delete.
> \[1\]
> {code:plain}
> 09:35:33,937 DEBUG [org.teiid.TRANSPORT] (New I/O worker #1) Channel closed
> 09:40:31,430 WARN [com.arjuna.ats.arjuna] (Transaction Reaper) ARJUNA012117: TransactionReaper::check timeout for TX 0:ffff7f000001:113c3cbe:56e131a7:e in state RUN
> 09:40:31,438 WARN [com.arjuna.ats.arjuna] (Transaction Reaper Worker 0) ARJUNA012121: TransactionReaper::doCancellations worker Thread[Transaction Reaper Worker 0,5,main] successfully canceled TX 0:ffff7f000001:113c3cbe:56e131a7:e
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
10 years