[
https://issues.jboss.org/browse/TEIID-2906?page=com.atlassian.jira.plugin...
]
Steven Hawkins commented on TEIID-2906:
---------------------------------------
I was wondering if you could fix again that only the exception
message of stack trace bottom layer exception outputs to log when it is not TeiidException
or TeiidRuntimeExceptio.
That would be unpredictable as to whether source sql/values would be present there as it
would be up to the source system exception.
bind variables and sql appear when exception thrown
---------------------------------------------------
Key: TEIID-2906
URL:
https://issues.jboss.org/browse/TEIID-2906
Project: Teiid
Issue Type: Bug
Components: JDBC Connector
Affects Versions: 8.4
Environment: - JDV 6.0.0
Reporter: Hisanobu Okuda
Assignee: Steven Hawkins
Fix For: 8.7
Attachments: PreparedStatementTest.java, test.vdb
When a query causes an exception, bind variables and sql are written in teiid-command.log
and are sent to a client.
teiid-command.log:-
{code}
19:36:19,942 WARN [org.teiid.PROCESSOR] (Worker8_QueryProcessorQueue29) TEIID30020
Processing exception for request 6jFRdyvDG5bU.0
'TEIID30504 New_MySQL: 0 TEIID11008:TEIID11004 Error executing statement(s):
[Prepared Values: ['hokuda'] SQL: SELECT g_0.`USERNAM
E`, g_0.`PASSWORD`, g_0.`USERROLE` FROM `LOGIN`.`USERS` AS g_0 WHERE g_0.`USERNAME` =
?]'. Originally TeiidProcessingException 'Can
not read response from server. Expected to read 4 bytes, read 0 bytes before connection
was unexpectedly lost.' MysqlIO.java:3039.
Enable more detailed logging to see the entire stacktrace.
{code}
printStackTrace() at client side:-
{code}
org.teiid.jdbc.TeiidSQLException: TEIID30504 Remote
org.teiid.core.TeiidProcessingException: TEIID30504 New_MySQL: 0 TEIID11008:TEI
ID11004 Error executing statement(s): [Prepared Values: ['hokuda'] SQL: SELECT
g_0.`USERNAME`, g_0.`PASSWORD`, g_0.`USERROLE` FROM
`LOGIN`.`USERS` AS g_0 WHERE g_0.`USERNAME` = ?]
at org.teiid.jdbc.TeiidSQLException.create(TeiidSQLException.java:135)
at org.teiid.jdbc.TeiidSQLException.create(TeiidSQLException.java:71)
{code}
--
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