[JBoss JIRA] (TEIID-2381) Expanded source hint support
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-2381?page=com.atlassian.jira.plugin... ]
Steven Hawkins commented on TEIID-2381:
---------------------------------------
Here's what I can glean as a possible set of changes:
1. allow the source hint to appear for any Teiid query/subquery and not just at the root level
2. at the start of optimization associate the hints with each source access as appropriate (which would be an accumulation)
2.a Ideally introduce a syntax to associate source hints with a particular access (such as one side of a non-pushdown self-join). - e.g. SELECT /\*+sh:'foo' oracle[1]:'leading' \*/ or just [1] where the id would come from a numbering of the initial plan tree (not the final processing plan node id). The issue here is that the only access to the initial plan structure is provided through debug logs. The other possibility would be to use a form of the oracle global hint syntax - /\*+sh:'foo' vw.tbl:'leading' \*/ - which would need some way to disambiguate from just simple source names.
2.b the structure of the accumulation would probably just be a list rather than a tree, but that will make it so hints from cousins/siblings in the initial plan hierarchy have awkward relative ordering.
3. allow a higher level hint to specify whether it overrides lower hints
> Expanded source hint support
> ----------------------------
>
> Key: TEIID-2381
> URL: https://issues.jboss.org/browse/TEIID-2381
> Project: Teiid
> Issue Type: Enhancement
> Components: Query Engine
> Reporter: Steven Hawkins
> Assignee: Steven Hawkins
> Attachments: HintsExecutionFactory.java, RandomExecutionFactory.java, RandomNumberStoredProcedureExecution.java, SysviewHintsExecutionTest.java
>
>
> We currently look at the source hint in only the root user query (not in subqueries nor the with clause) and only consider it in a very narrow set of circumstances when it's used in a view.
--
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
11 years, 2 months
[JBoss JIRA] (TEIID-2464) StackOverflow setting a Blob
by Steven Hawkins (JIRA)
Steven Hawkins created TEIID-2464:
-------------------------------------
Summary: StackOverflow setting a Blob
Key: TEIID-2464
URL: https://issues.jboss.org/browse/TEIID-2464
Project: Teiid
Issue Type: Bug
Components: JDBC Driver
Affects Versions: 8.0
Reporter: Steven Hawkins
Assignee: Steven Hawkins
Fix For: 8.4
A regression in TEIID-174 left a recursive call in the PreparedStatement inputstream blob setter.
--
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
11 years, 2 months
[JBoss JIRA] (TEIID-2461) Better determine when to block on the output buffer
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-2461?page=com.atlassian.jira.plugin... ]
Steven Hawkins resolved TEIID-2461.
-----------------------------------
Resolution: Done
Switched the logic to simply slow-down, but not altogether stop processing when the forward-only buffer limit is hit. The slow down is based upon source connections being held (longer delay if nothing is held). This ensures a more timely completion, but will likely see increased disk use.
There is currently no easy approach to determine which resource is more valuable (source connection vs. disk) and whether the client will ever work down the buffer, so holding source connections indefinitely is not a good option.
Other possibilities would be:
- a configurable max size of all tuplebuffers or just the output buffer (to prevent runaway disk consumption)
- encourage the use of a local connection that is using the calling thread (which will always process on demand and not build an output buffer for forward only)
- allow for a synch processing hint / execution mode to allow the user query to request that the query is processed on demand.
> Better determine when to block on the output buffer
> ---------------------------------------------------
>
> Key: TEIID-2461
> URL: https://issues.jboss.org/browse/TEIID-2461
> Project: Teiid
> Issue Type: Quality Risk
> Components: Query Engine
> Reporter: Steven Hawkins
> Assignee: Steven Hawkins
> Fix For: 8.4
>
>
> The output buffer size limitation helps prevent forward only results from unnecessarily consuming resources, but it also may slow down the processing of otherwise already buffered results - which will hold those and other downstream resources unnecessarily. We should examine the plan to see if this is possible before allowing the output buffer to be size limited.
--
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
11 years, 2 months
[JBoss JIRA] (TEIID-2453) Add a string_agg or similarly named aggregate for creating a delimited concat
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-2453?page=com.atlassian.jira.plugin... ]
Steven Hawkins edited comment on TEIID-2453 at 4/10/13 12:49 PM:
-----------------------------------------------------------------
This may be bumped out of the 8.4 release as there are possible workarounds -
If a trailing delimiter can be tolerated (and assuming string values), then use:
SELECT XMLAGG(XMLPARSE(CONTENT col || ',' WELLFORMED)) FROM tbl
XMLSERIALIZE can then be used to retrieve the result as a string (which may truncate), clob, or blob.
If a trailing delimiter is not wanted, then the workaround becomes more complicated:
SELECT XMLAGG(XMLPARSE(CONTENT (CASE WHEN rn = 1 THEN '' ELSE ',' END) || col WELLFORMED) ORDER BY rn) FROM (SELECT col, row_number() over (ORDER BY col NULLS LAST) as rn FROM tbl) X
Here the window function provides a row number to selectively include the delimiter. If a group by clause is needed then the row_number must be computed relative to the grouping using partitioning:
SELECT col2, XMLAGG(XMLPARSE(CONTENT (CASE WHEN rn = 1 THEN '' ELSE ',' END) || col WELLFORMED) ORDER BY rn) FROM (SELECT col, row_number() over (PARTITION BY col2 ORDER BY col NULLS LAST) as rn FROM tbl) X GROUP BY col2
was (Author: shawkins):
This may be bumped out of the 8.4 release as there are possible workarounds -
If a trailing delimiter can be tolerated (and assuming string values), then use:
SELECT XMLAGG(XMLPARSE(CONTENT col || ',' WELLFORMED)) FROM tbl
XMLSERIALIZE can then be used to retrieve the result as a string (which may truncate), clob, or blob.
If a trailing delimiter is not wanted, then the workaround becomes more complicated:
SELECT XMLAGG(XMLPARSE(CONTENT (CASE WHEN rn = 1 THEN '' ELSE ',' END) || col WELLFORMED) ORDER BY rn) FROM (SELECT col, row_number() over (ORDER BY col NULLS LAST) as rn FROM tbl) X
Here the window function provides a row number so that we can selective include the delimiter. If a group by clause is needed then the row_number must be computed relative to the grouping using partitioning:
SELECT col2, XMLAGG(XMLPARSE(CONTENT (CASE WHEN rn = 1 THEN '' ELSE ',' END) || col WELLFORMED) ORDER BY rn) FROM (SELECT col, row_number() over (PARTITION BY col2 ORDER BY col NULLS LAST) as rn FROM tbl) X GROUP BY col2
> Add a string_agg or similarly named aggregate for creating a delimited concat
> -----------------------------------------------------------------------------
>
> Key: TEIID-2453
> URL: https://issues.jboss.org/browse/TEIID-2453
> Project: Teiid
> Issue Type: Enhancement
> Components: Query Engine
> Reporter: Steven Hawkins
> Assignee: Steven Hawkins
> Fix For: 8.4
>
>
> Similar to the pg string_agg (which supports blob/clob) delimited concat, we should offer a built-in aggregate. There is similar support on oracle 11g+ and mysql.
--
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
11 years, 2 months
[JBoss JIRA] (TEIID-2463) filter clause does not work with windowed aggregate
by Steven Hawkins (JIRA)
Steven Hawkins created TEIID-2463:
-------------------------------------
Summary: filter clause does not work with windowed aggregate
Key: TEIID-2463
URL: https://issues.jboss.org/browse/TEIID-2463
Project: Teiid
Issue Type: Quality Risk
Components: Query Engine
Affects Versions: 7.7
Reporter: Steven Hawkins
Assignee: Steven Hawkins
Fix For: 8.4
A filtered window function, such as "row_number() FILTER (WHERE e1 IS NOT NULL) over (order by e1)" will fail in parsing with a class cast exception
--
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
11 years, 2 months
[JBoss JIRA] (TEIID-2453) Add a string_agg or similarly named aggregate for creating a delimited concat
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-2453?page=com.atlassian.jira.plugin... ]
Steven Hawkins updated TEIID-2453:
----------------------------------
Description: Similar to the pg string_agg (which supports blob/clob) delimited concat, we should offer a built-in aggregate. There is similar support on oracle 11g+ and mysql. (was: Similar to the pg string_agg (which supports blob/clob) delimited concat, we should offer a built-in aggregate.)
Affects: Documentation (Ref Guide, User Guide, etc.),Release Notes (was: Documentation (Ref Guide, User Guide, etc.))
This may be bumped out of the 8.4 release as there are possible workarounds -
If a trailing delimiter can be tolerated (and assuming string values), then use:
SELECT XMLAGG(XMLPARSE(CONTENT col || ',' WELLFORMED)) FROM tbl
XMLSERIALIZE can then be used to retrieve the result as a string (which may truncate), clob, or blob.
If a trailing delimiter is not wanted, then the workaround becomes more complicated:
SELECT XMLAGG(XMLPARSE(CONTENT (CASE WHEN rn = 1 THEN '' ELSE ',' END) || col WELLFORMED) ORDER BY rn) FROM (SELECT col, row_number() over (ORDER BY col NULLS LAST) as rn FROM tbl) X
Here the window function provides a row number so that we can selective include the delimiter. If a group by clause is needed then the row_number must be computed relative to the grouping using partitioning:
SELECT col2, XMLAGG(XMLPARSE(CONTENT (CASE WHEN rn = 1 THEN '' ELSE ',' END) || col WELLFORMED) ORDER BY rn) FROM (SELECT col, row_number() over (PARTITION BY col2 ORDER BY col NULLS LAST) as rn FROM tbl) X GROUP BY col2
> Add a string_agg or similarly named aggregate for creating a delimited concat
> -----------------------------------------------------------------------------
>
> Key: TEIID-2453
> URL: https://issues.jboss.org/browse/TEIID-2453
> Project: Teiid
> Issue Type: Enhancement
> Components: Query Engine
> Reporter: Steven Hawkins
> Assignee: Steven Hawkins
> Fix For: 8.4
>
>
> Similar to the pg string_agg (which supports blob/clob) delimited concat, we should offer a built-in aggregate. There is similar support on oracle 11g+ and mysql.
--
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
11 years, 2 months
[JBoss JIRA] (TEIID-2453) Add a string_agg or similarly named aggregate for creating a delimited concat
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-2453?page=com.atlassian.jira.plugin... ]
Steven Hawkins updated TEIID-2453:
----------------------------------
Summary: Add a string_agg or similarly named aggregate for creating a delimited concat (was: Allow textagg to perform simple delimited concat)
Description: Similar to the pg string_agg (which supports blob/clob) delimited concat, we should offer a built-in aggregate. (was: If the text line ending is configurable, then textagg can be used to mimic mysql groupconcat functionality.)
Changing from the original issue, which was a modification to text_agg as the text_agg intent is really tailored toward csv construction and would be unnecessarily complicated by this change.
> Add a string_agg or similarly named aggregate for creating a delimited concat
> -----------------------------------------------------------------------------
>
> Key: TEIID-2453
> URL: https://issues.jboss.org/browse/TEIID-2453
> Project: Teiid
> Issue Type: Enhancement
> Components: Query Engine
> Reporter: Steven Hawkins
> Assignee: Steven Hawkins
> Fix For: 8.4
>
>
> Similar to the pg string_agg (which supports blob/clob) delimited concat, we should offer a built-in aggregate.
--
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
11 years, 2 months
[JBoss JIRA] (TEIID-2462) WS-Security payload flow through "ws" resource adapter
by Ramesh Reddy (JIRA)
Ramesh Reddy created TEIID-2462:
-----------------------------------
Summary: WS-Security payload flow through "ws" resource adapter
Key: TEIID-2462
URL: https://issues.jboss.org/browse/TEIID-2462
Project: Teiid
Issue Type: Feature Request
Components: Misc. Connectors
Reporter: Ramesh Reddy
Assignee: Ramesh Reddy
Fix For: 8.4
Currently only HTTPBasic security credentials flow through the web services resource adapter from the configured security domain, and authorized Subject.
It is important to device a mechanism to enable security credentials flow through web services resource adapter for purposes ws-security. The idea is based on the Subject making resource adapter calls, the credential payload needs to be converted into CXF configuration.
--
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
11 years, 2 months