[JBoss JIRA] (TEIID-5543) Configuration Option for default OData format
by Christoph John (Jira)
[ https://issues.jboss.org/browse/TEIID-5543?page=com.atlassian.jira.plugin... ]
Christoph John updated TEIID-5543:
----------------------------------
Description:
It would be great to have a config option to set the default format for odata responses which is chosen if no Accept header was set to request the format.
SapUI5 / OpenUI5 for example sends Accept * / *
Would be great if the admin could decide on the default format in such cases.
See related discussion https://developer.jboss.org/thread/279113
was:
It would be great to have a config option to set the default format for odata responses which is chosen if no Accept header was set to request the format.
SapUI5 / OpenUI5 for example sends Accept */*
Would be great if the admin could decide on the default format in such cases.
See related discussion https://developer.jboss.org/thread/279113
> Configuration Option for default OData format
> ----------------------------------------------
>
> Key: TEIID-5543
> URL: https://issues.jboss.org/browse/TEIID-5543
> Project: Teiid
> Issue Type: Enhancement
> Components: OData
> Affects Versions: 11.2
> Reporter: Christoph John
> Assignee: Steven Hawkins
> Priority: Optional
>
> It would be great to have a config option to set the default format for odata responses which is chosen if no Accept header was set to request the format.
> SapUI5 / OpenUI5 for example sends Accept * / *
> Would be great if the admin could decide on the default format in such cases.
> See related discussion https://developer.jboss.org/thread/279113
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
6 years, 1 month
[JBoss JIRA] (TEIID-5543) Configuration Option for default OData format
by Christoph John (Jira)
Christoph John created TEIID-5543:
-------------------------------------
Summary: Configuration Option for default OData format
Key: TEIID-5543
URL: https://issues.jboss.org/browse/TEIID-5543
Project: Teiid
Issue Type: Enhancement
Components: OData
Affects Versions: 11.2
Reporter: Christoph John
Assignee: Steven Hawkins
It would be great to have a config option to set the default format for odata responses which is chosen if no Accept header was set to request the format.
SapUI5 / OpenUI5 for example sends Accept */*
Would be great if the admin could decide on the default format in such cases.
See related discussion https://developer.jboss.org/thread/279113
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
6 years, 1 month
[JBoss JIRA] (TEIID-5541) Incorrect parsing of xml with XmlTable
by Steven Hawkins (Jira)
[ https://issues.jboss.org/browse/TEIID-5541?page=com.atlassian.jira.plugin... ]
Steven Hawkins updated TEIID-5541:
----------------------------------
Fix Version/s: 11.0.3
11.1.2
12.0
11.2.1
> Incorrect parsing of xml with XmlTable
> --------------------------------------
>
> Key: TEIID-5541
> URL: https://issues.jboss.org/browse/TEIID-5541
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 11.1
> Environment: teiid-11.1.0 (from 01.09.2018) on WildFly Full 11.0.0.Final (WildFly Core 3.0.8.Final)
> Reporter: dalex dalex
> Assignee: Steven Hawkins
> Priority: Blocker
> Fix For: 11.0.3, 11.1.2, 12.0, 11.2.1
>
>
> Running the query:
> {code:sql}
> Begin
> Declare xml xcontent = '<root xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
> <report>
> <data>
> <year xsi:type="decimal">2018</year>
> </data>
> </report>
> <waitSeconds xsi:type="decimal">13</waitSeconds>
> </root>' ;
> Select *
> From
> XmlTable(
> XmlNamespaces ('http://www.w3.org/2001/XMLSchema-instance' as xsi),
> '/root/report/data'
> PASSING xcontent
> Columns
> "year" integer,
> waitSeconds xml Path 'root()/root/waitSeconds',
> waitSecondsStr string Path 'root()/root/waitSeconds'
> )a ;
> End ;;
> {code}
> and having a look at the structure we can see that the value 13 should be returned, while the value is not picked from xml for result.
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
6 years, 1 month
[JBoss JIRA] (TEIID-5541) Incorrect parsing of xml with XmlTable
by Steven Hawkins (Jira)
[ https://issues.jboss.org/browse/TEIID-5541?page=com.atlassian.jira.plugin... ]
Steven Hawkins resolved TEIID-5541.
-----------------------------------
Resolution: Done
It's a little easier to read prior to the downward reduction:
//root
{code}
ancestor-or-self document-node()
descendant element(Q{}root)
{code}
root()/root
{code}
ancestor-or-self element()
descendant element()
childelement(Q{}root)
{code}
Note that the arc when using the root function is looking for an ancestor element - not specifically the document node - and then any descendant. That is what is causing the path map filter to accept all elements.
So there were two choices for a fix here. Either scan the path map arcs for something that looks like this and disable projection or attempt to repair (effectively trying to replace root()/ with //). Or scan the expressions for the root function and disable projection. The latter was simpler to implement. So for now document projection will not be allowed when root() is used.
> Incorrect parsing of xml with XmlTable
> --------------------------------------
>
> Key: TEIID-5541
> URL: https://issues.jboss.org/browse/TEIID-5541
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 11.1
> Environment: teiid-11.1.0 (from 01.09.2018) on WildFly Full 11.0.0.Final (WildFly Core 3.0.8.Final)
> Reporter: dalex dalex
> Assignee: Steven Hawkins
> Priority: Blocker
>
> Running the query:
> {code:sql}
> Begin
> Declare xml xcontent = '<root xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
> <report>
> <data>
> <year xsi:type="decimal">2018</year>
> </data>
> </report>
> <waitSeconds xsi:type="decimal">13</waitSeconds>
> </root>' ;
> Select *
> From
> XmlTable(
> XmlNamespaces ('http://www.w3.org/2001/XMLSchema-instance' as xsi),
> '/root/report/data'
> PASSING xcontent
> Columns
> "year" integer,
> waitSeconds xml Path 'root()/root/waitSeconds',
> waitSecondsStr string Path 'root()/root/waitSeconds'
> )a ;
> End ;;
> {code}
> and having a look at the structure we can see that the value 13 should be returned, while the value is not picked from xml for result.
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
6 years, 1 month
[JBoss JIRA] (TEIID-5542) XMLTable path assumptions
by Steven Hawkins (Jira)
[ https://issues.jboss.org/browse/TEIID-5542?page=com.atlassian.jira.plugin... ]
Steven Hawkins updated TEIID-5542:
----------------------------------
Comment: was deleted
(was: It's a little easier to read prior to the downward reduction:
//root
{code}
ancestor-or-self document-node()
descendant element(Q{}root)
{code}
root()/root
{code}
ancestor-or-self element()
descendant element()
childelement(Q{}root)
{code}
Note that the arc when using the root function is looking for an ancestor element - not specifically the document node - and then any descendant. That is what is causing the path map filter to accept all elements.
So there were two choices for a fix here. Either scan the path map arcs for something that looks like this and disable projection or attempt to repair (effectively trying to replace root()/ with //). Or scan the expressions for the root function and disable projection. The latter was simpler to implement. So for now document projection will not be allowed when root() is used.
)
> XMLTable path assumptions
> -------------------------
>
> Key: TEIID-5542
> URL: https://issues.jboss.org/browse/TEIID-5542
> Project: Teiid
> Issue Type: Quality Risk
> Components: Query Engine
> Reporter: Steven Hawkins
> Assignee: Steven Hawkins
> Priority: Major
> Fix For: 12.0
>
>
> By the spec, and for example with Postgresql, a column PATH that begins with / or // is not relative to the context item. Teiid modeled its initial implementation on Oracle where that is the case. For greater compliance we should add an option to change the handling to be spec compliant.
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
6 years, 1 month
[JBoss JIRA] (TEIID-5542) XMLTable path assumptions
by Steven Hawkins (Jira)
[ https://issues.jboss.org/browse/TEIID-5542?page=com.atlassian.jira.plugin... ]
Steven Hawkins reopened TEIID-5542:
-----------------------------------
> XMLTable path assumptions
> -------------------------
>
> Key: TEIID-5542
> URL: https://issues.jboss.org/browse/TEIID-5542
> Project: Teiid
> Issue Type: Quality Risk
> Components: Query Engine
> Reporter: Steven Hawkins
> Assignee: Steven Hawkins
> Priority: Major
> Fix For: 12.0
>
>
> By the spec, and for example with Postgresql, a column PATH that begins with / or // is not relative to the context item. Teiid modeled its initial implementation on Oracle where that is the case. For greater compliance we should add an option to change the handling to be spec compliant.
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
6 years, 1 month
[JBoss JIRA] (TEIID-5542) XMLTable path assumptions
by Steven Hawkins (Jira)
[ https://issues.jboss.org/browse/TEIID-5542?page=com.atlassian.jira.plugin... ]
Steven Hawkins resolved TEIID-5542.
-----------------------------------
Resolution: Done
It's a little easier to read prior to the downward reduction:
//root
{code}
ancestor-or-self document-node()
descendant element(Q{}root)
{code}
root()/root
{code}
ancestor-or-self element()
descendant element()
childelement(Q{}root)
{code}
Note that the arc when using the root function is looking for an ancestor element - not specifically the document node - and then any descendant. That is what is causing the path map filter to accept all elements.
So there were two choices for a fix here. Either scan the path map arcs for something that looks like this and disable projection or attempt to repair (effectively trying to replace root()/ with //). Or scan the expressions for the root function and disable projection. The latter was simpler to implement. So for now document projection will not be allowed when root() is used.
> XMLTable path assumptions
> -------------------------
>
> Key: TEIID-5542
> URL: https://issues.jboss.org/browse/TEIID-5542
> Project: Teiid
> Issue Type: Quality Risk
> Components: Query Engine
> Reporter: Steven Hawkins
> Assignee: Steven Hawkins
> Priority: Major
> Fix For: 12.0
>
>
> By the spec, and for example with Postgresql, a column PATH that begins with / or // is not relative to the context item. Teiid modeled its initial implementation on Oracle where that is the case. For greater compliance we should add an option to change the handling to be spec compliant.
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
6 years, 1 month
[JBoss JIRA] (TEIID-5541) Incorrect parsing of xml with XmlTable
by Steven Hawkins (Jira)
[ https://issues.jboss.org/browse/TEIID-5541?page=com.atlassian.jira.plugin... ]
Steven Hawkins commented on TEIID-5541:
---------------------------------------
//root creates the path map entry:
{code}
descendantelement(Q{}root)
{code}
root()/root creates the path map entries:
{code}
descendant-or-selfelement()
descendantelement()
childelement(Q{}root)
{code}
In the latter case the path map filter logic will accept all elements, and won't descend to the point of seeing the text of the child node as needed. Still trying to determine if this is a general issue with our path map logic, or if this is specific to the root function.
> Incorrect parsing of xml with XmlTable
> --------------------------------------
>
> Key: TEIID-5541
> URL: https://issues.jboss.org/browse/TEIID-5541
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 11.1
> Environment: teiid-11.1.0 (from 01.09.2018) on WildFly Full 11.0.0.Final (WildFly Core 3.0.8.Final)
> Reporter: dalex dalex
> Assignee: Steven Hawkins
> Priority: Blocker
>
> Running the query:
> {code:sql}
> Begin
> Declare xml xcontent = '<root xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
> <report>
> <data>
> <year xsi:type="decimal">2018</year>
> </data>
> </report>
> <waitSeconds xsi:type="decimal">13</waitSeconds>
> </root>' ;
> Select *
> From
> XmlTable(
> XmlNamespaces ('http://www.w3.org/2001/XMLSchema-instance' as xsi),
> '/root/report/data'
> PASSING xcontent
> Columns
> "year" integer,
> waitSeconds xml Path 'root()/root/waitSeconds',
> waitSecondsStr string Path 'root()/root/waitSeconds'
> )a ;
> End ;;
> {code}
> and having a look at the structure we can see that the value 13 should be returned, while the value is not picked from xml for result.
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
6 years, 1 month