[JBoss JIRA] (TEIID-3600) DB2 - error getting substring if "from position" is out of range
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-3600?page=com.atlassian.jira.plugin... ]
Steven Hawkins commented on TEIID-3600:
---------------------------------------
I think the resolution here will be to account for the db2 exceptional case, but to otherwise document that there can be difference between empty and null results from the substring function. As needed by customer issues we can address discrepancies. The variety and complexity of the case expressions needed otherwise would be daunting:
Sybase - case when str is null || length is null then null when length = 0 then '' else substr(str, begin, length) end
SQL Server would be slightly different
etc.
> DB2 - error getting substring if "from position" is out of range
> ----------------------------------------------------------------
>
> Key: TEIID-3600
> URL: https://issues.jboss.org/browse/TEIID-3600
> Project: Teiid
> Issue Type: Quality Risk
> Components: Misc. Connectors
> Reporter: Juraj Duráni
> Assignee: Steven Hawkins
> Fix For: 8.12
>
>
> If second argument of a SUBSTRING(x,y,z) function is out of range of first argument an exception is thrown [1]. Source-specific command [2].
> [1]
> Caused by: com.ibm.db2.jcc.am.SqlDataException: DB2 SQL Error: SQLCODE=-138, SQLSTATE=22011, SQLERRMC=null, DRIVER=4.12.55
> at com.ibm.db2.jcc.am.hd.a(hd.java:668)
> at com.ibm.db2.jcc.am.hd.a(hd.java:60)
> ...
> [2]
> SELECT substr(varchar(g_0.TimestampValue), 40, CASE WHEN 0 > (length(varchar(g_0.TimestampValue)) - (40 - 1)) THEN (length(varchar(g_0.TimestampValue)) - (40 - 1)) ELSE 0 END) FROM SmallA AS g_0 WHERE g_0.IntKey = 1
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
8 years, 9 months
[JBoss JIRA] (TEIID-3609) Teiid Connection import: driver field not populated for resource adapters
by Ramesh Reddy (JIRA)
[ https://issues.jboss.org/browse/TEIID-3609?page=com.atlassian.jira.plugin... ]
Ramesh Reddy commented on TEIID-3609:
-------------------------------------
You can not do that. But you can add the connection definition to the existing resource-adapter definition. But you may have to restart the server at the end to activate the connection information you added.
The way the JCA susbsytem designed is not exactly same as the "jdbc" data source susbsystem, where the definition of the driver and connection management are two separate configuration entities and configuring (adding/deleteing) either of them does not require a server restart.
Where as in resource-adapter the definition of resource-adapter and connection information is single construct, if they both done at same time then you do not need to restart of the server before they become active, if you try adding one after another then you have to restart.
> Teiid Connection import: driver field not populated for resource adapters
> -------------------------------------------------------------------------
>
> Key: TEIID-3609
> URL: https://issues.jboss.org/browse/TEIID-3609
> Project: Teiid
> Issue Type: Bug
> Reporter: Andrej Šmigala
> Assignee: Ramesh Reddy
>
> When importing using Teiid Connection, the driver field is not populated for resource adapters when the pool name of the connection definition is the same as the id of the resource adapter itself. Except for the case that there is _another_ resource adapter defined for the same module _without_ any connection definitions.
> In other words, when the following is included in standalone.xml, the driver field is not populated
> {code:xml}
> <resource-adapter id="file">
> <module slot="main" id="org.jboss.teiid.resource-adapter.file"/>
> <transaction-support>NoTransaction</transaction-support>
> <connection-definitions>
> <connection-definition class-name="org.teiid.resource.adapter.file.FileManagedConnectionFactory" jndi-name="java:/file" enabled="true" pool-name="file">
> <config-property name="ParentDirectory">
> /home/
> </config-property>
> </connection-definition>
> </connection-definitions>
> </resource-adapter>
> {code}
> However, everything works as expected when the configuration is changed to this:
> {code:xml}
> <resource-adapter id="file">
> <module slot="main" id="org.jboss.teiid.resource-adapter.file"/>
> <transaction-support>NoTransaction</transaction-support>
> <connection-definitions>
> <connection-definition class-name="org.teiid.resource.adapter.file.FileManagedConnectionFactory" jndi-name="java:/fileDS" enabled="true" pool-name="fileDS">
> <config-property name="ParentDirectory">
> /home/
> </config-property>
> </connection-definition>
> </connection-definitions>
> </resource-adapter>
> {code}
> Or this:
> {code:xml}
> <resource-adapter id="file">
> <module slot="main" id="org.jboss.teiid.resource-adapter.file"/>
> </resource-adapter>
> <resource-adapter id="fileDS">
> <module slot="main" id="org.jboss.teiid.resource-adapter.file"/>
> <transaction-support>NoTransaction</transaction-support>
> <connection-definitions>
> <connection-definition class-name="org.teiid.resource.adapter.file.FileManagedConnectionFactory" jndi-name="java:/fileDS" enabled="true" pool-name="fileDS">
> <config-property name="ParentDirectory">
> /home/
> </config-property>
> </connection-definition>
> </connection-definitions>
> </resource-adapter>
> {code}
> This might be related to TEIIDDES-1895 and is most likely the original cause of TEIIDDES-2563.
> Clicking Next in the import wizard when such a datasource is selected causes the same error as described in TEIIDDES-2563.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
8 years, 9 months
[JBoss JIRA] (TEIID-3609) Teiid Connection import: driver field not populated for resource adapters
by Van Halbert (JIRA)
[ https://issues.jboss.org/browse/TEIID-3609?page=com.atlassian.jira.plugin... ]
Van Halbert commented on TEIID-3609:
------------------------------------
I wonder if EAP has made some changes, I was unable to include (not replace) the first file resource-adapter, getting duplicate error:
13:50:09,305 ERROR [org.jboss.as.controller.management-operation] (ServerService Thread Pool -- 7) JBAS014612: Operation ("add") failed - address: ([
("subsystem" => "resource-adapters"),
("resource-adapter" => "file")
]) - failure description: "JBAS014803: Duplicate resource [
(\"subsystem\" => \"resource-adapters\"),
(\"resource-adapter\" => \"file\")
]"
> Teiid Connection import: driver field not populated for resource adapters
> -------------------------------------------------------------------------
>
> Key: TEIID-3609
> URL: https://issues.jboss.org/browse/TEIID-3609
> Project: Teiid
> Issue Type: Bug
> Reporter: Andrej Šmigala
> Assignee: Ramesh Reddy
>
> When importing using Teiid Connection, the driver field is not populated for resource adapters when the pool name of the connection definition is the same as the id of the resource adapter itself. Except for the case that there is _another_ resource adapter defined for the same module _without_ any connection definitions.
> In other words, when the following is included in standalone.xml, the driver field is not populated
> {code:xml}
> <resource-adapter id="file">
> <module slot="main" id="org.jboss.teiid.resource-adapter.file"/>
> <transaction-support>NoTransaction</transaction-support>
> <connection-definitions>
> <connection-definition class-name="org.teiid.resource.adapter.file.FileManagedConnectionFactory" jndi-name="java:/file" enabled="true" pool-name="file">
> <config-property name="ParentDirectory">
> /home/
> </config-property>
> </connection-definition>
> </connection-definitions>
> </resource-adapter>
> {code}
> However, everything works as expected when the configuration is changed to this:
> {code:xml}
> <resource-adapter id="file">
> <module slot="main" id="org.jboss.teiid.resource-adapter.file"/>
> <transaction-support>NoTransaction</transaction-support>
> <connection-definitions>
> <connection-definition class-name="org.teiid.resource.adapter.file.FileManagedConnectionFactory" jndi-name="java:/fileDS" enabled="true" pool-name="fileDS">
> <config-property name="ParentDirectory">
> /home/
> </config-property>
> </connection-definition>
> </connection-definitions>
> </resource-adapter>
> {code}
> Or this:
> {code:xml}
> <resource-adapter id="file">
> <module slot="main" id="org.jboss.teiid.resource-adapter.file"/>
> </resource-adapter>
> <resource-adapter id="fileDS">
> <module slot="main" id="org.jboss.teiid.resource-adapter.file"/>
> <transaction-support>NoTransaction</transaction-support>
> <connection-definitions>
> <connection-definition class-name="org.teiid.resource.adapter.file.FileManagedConnectionFactory" jndi-name="java:/fileDS" enabled="true" pool-name="fileDS">
> <config-property name="ParentDirectory">
> /home/
> </config-property>
> </connection-definition>
> </connection-definitions>
> </resource-adapter>
> {code}
> This might be related to TEIIDDES-1895 and is most likely the original cause of TEIIDDES-2563.
> Clicking Next in the import wizard when such a datasource is selected causes the same error as described in TEIIDDES-2563.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
8 years, 9 months
[JBoss JIRA] (TEIID-3591) Report user query CPU time
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-3591?page=com.atlassian.jira.plugin... ]
Steven Hawkins resolved TEIID-3591.
-----------------------------------
Resolution: Done
The first cut will just be to report the time main processing thread time and not account for asynch threads or if the connector work is being run serially.
As we increase plan parallelism this will need refinement (possibly logging per work item).
> Report user query CPU time
> --------------------------
>
> Key: TEIID-3591
> URL: https://issues.jboss.org/browse/TEIID-3591
> Project: Teiid
> Issue Type: Enhancement
> Components: Query Engine
> Reporter: Ramesh Reddy
> Assignee: Steven Hawkins
> Fix For: 8.12
>
>
> Just like TEIID-2813 it would useful to be useful to report CPU time for user query overall. This can help determine load on CPU got given user query vs wait time.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
8 years, 9 months
[JBoss JIRA] (TEIID-3609) Teiid Connection import: driver field not populated for resource adapters
by Ramesh Reddy (JIRA)
[ https://issues.jboss.org/browse/TEIID-3609?page=com.atlassian.jira.plugin... ]
Ramesh Reddy resolved TEIID-3609.
---------------------------------
Assignee: Ramesh Reddy
Resolution: Rejected
None of below configuration as is wrong, they all work, but it does change the default behavior with the tools.
The issue is a given "resource-adpater" does let you define multiple connection-definitions. However, every time you add or delete a connection-definition to the resource-adapater, the server needs to be restarted. That how EAP's JCA sub-system is designed.
Now, in Teiid it is very common to have different sources, adding and removing is quite a normal. However, restart each time is not accepted. So, the workaround that has been used is
- use empty resource-adapter definition as "driver" definition to enable data source template definition through Admin API
- Use a duplicated resource-definition with UNIQUE name and ONE connection-definition for every connection definition.
This way server does not need to be restarted when a connection definition is added to the resource-adapter.
> Teiid Connection import: driver field not populated for resource adapters
> -------------------------------------------------------------------------
>
> Key: TEIID-3609
> URL: https://issues.jboss.org/browse/TEIID-3609
> Project: Teiid
> Issue Type: Bug
> Reporter: Andrej Šmigala
> Assignee: Ramesh Reddy
>
> When importing using Teiid Connection, the driver field is not populated for resource adapters when the pool name of the connection definition is the same as the id of the resource adapter itself. Except for the case that there is _another_ resource adapter defined for the same module _without_ any connection definitions.
> In other words, when the following is included in standalone.xml, the driver field is not populated
> {code:xml}
> <resource-adapter id="file">
> <module slot="main" id="org.jboss.teiid.resource-adapter.file"/>
> <transaction-support>NoTransaction</transaction-support>
> <connection-definitions>
> <connection-definition class-name="org.teiid.resource.adapter.file.FileManagedConnectionFactory" jndi-name="java:/file" enabled="true" pool-name="file">
> <config-property name="ParentDirectory">
> /home/
> </config-property>
> </connection-definition>
> </connection-definitions>
> </resource-adapter>
> {code}
> However, everything works as expected when the configuration is changed to this:
> {code:xml}
> <resource-adapter id="file">
> <module slot="main" id="org.jboss.teiid.resource-adapter.file"/>
> <transaction-support>NoTransaction</transaction-support>
> <connection-definitions>
> <connection-definition class-name="org.teiid.resource.adapter.file.FileManagedConnectionFactory" jndi-name="java:/fileDS" enabled="true" pool-name="fileDS">
> <config-property name="ParentDirectory">
> /home/
> </config-property>
> </connection-definition>
> </connection-definitions>
> </resource-adapter>
> {code}
> Or this:
> {code:xml}
> <resource-adapter id="file">
> <module slot="main" id="org.jboss.teiid.resource-adapter.file"/>
> </resource-adapter>
> <resource-adapter id="fileDS">
> <module slot="main" id="org.jboss.teiid.resource-adapter.file"/>
> <transaction-support>NoTransaction</transaction-support>
> <connection-definitions>
> <connection-definition class-name="org.teiid.resource.adapter.file.FileManagedConnectionFactory" jndi-name="java:/fileDS" enabled="true" pool-name="fileDS">
> <config-property name="ParentDirectory">
> /home/
> </config-property>
> </connection-definition>
> </connection-definitions>
> </resource-adapter>
> {code}
> This might be related to TEIIDDES-1895 and is most likely the original cause of TEIIDDES-2563.
> Clicking Next in the import wizard when such a datasource is selected causes the same error as described in TEIIDDES-2563.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
8 years, 9 months