-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Java] Improve JdbcConsumer errors #39355
Comments
lidavidm
pushed a commit
that referenced
this issue
Jan 8, 2024
### Rationale for this change This helps debug Arrow conversion errors from JDBC by exposing the JdbcFieldInfo for the related column and the ArrowType for the corresponding vector. ### What changes are included in this PR? A new JdbcConsumerException which is thrown by the CompositeJdbcConsumer while consuming data for a specific vector. ### Are these changes tested? N/A ### Are there any user-facing changes? Users can now catch `JdbcConsumerException`s and extract the related ArrowType and JdbcFieldInfo from it for debugging. * Closes: #39355 Authored-by: Diego Fernandez <[email protected]> Signed-off-by: David Li <[email protected]>
clayburn
pushed a commit
to clayburn/arrow
that referenced
this issue
Jan 23, 2024
### Rationale for this change This helps debug Arrow conversion errors from JDBC by exposing the JdbcFieldInfo for the related column and the ArrowType for the corresponding vector. ### What changes are included in this PR? A new JdbcConsumerException which is thrown by the CompositeJdbcConsumer while consuming data for a specific vector. ### Are these changes tested? N/A ### Are there any user-facing changes? Users can now catch `JdbcConsumerException`s and extract the related ArrowType and JdbcFieldInfo from it for debugging. * Closes: apache#39355 Authored-by: Diego Fernandez <[email protected]> Signed-off-by: David Li <[email protected]>
dgreiss
pushed a commit
to dgreiss/arrow
that referenced
this issue
Feb 19, 2024
### Rationale for this change This helps debug Arrow conversion errors from JDBC by exposing the JdbcFieldInfo for the related column and the ArrowType for the corresponding vector. ### What changes are included in this PR? A new JdbcConsumerException which is thrown by the CompositeJdbcConsumer while consuming data for a specific vector. ### Are these changes tested? N/A ### Are there any user-facing changes? Users can now catch `JdbcConsumerException`s and extract the related ArrowType and JdbcFieldInfo from it for debugging. * Closes: apache#39355 Authored-by: Diego Fernandez <[email protected]> Signed-off-by: David Li <[email protected]>
zanmato1984
pushed a commit
to zanmato1984/arrow
that referenced
this issue
Feb 28, 2024
### Rationale for this change This helps debug Arrow conversion errors from JDBC by exposing the JdbcFieldInfo for the related column and the ArrowType for the corresponding vector. ### What changes are included in this PR? A new JdbcConsumerException which is thrown by the CompositeJdbcConsumer while consuming data for a specific vector. ### Are these changes tested? N/A ### Are there any user-facing changes? Users can now catch `JdbcConsumerException`s and extract the related ArrowType and JdbcFieldInfo from it for debugging. * Closes: apache#39355 Authored-by: Diego Fernandez <[email protected]> Signed-off-by: David Li <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the enhancement requested
Currently, when an error occurs while consuming a JDBC ResultSet, it's impossible to debug what might have happened. For example, here's a redacted stack trace:
These types of errors are likely due to an incorrect mapping from
JdbcType
toArrowType
, but at this point there's no insight into that mapping. My proposal is to introduce aJdbcConsumerException
that stores aJdbcFieldInfo
for the ResultSet column andArrowType
for the vector. The easiest way to do this would be in atry/catch
inside theCompositeJdbcConsumer
and then bubble it up inArrowVectorIterator
. Users would then be able to extract that information from the exception to make more informative logs.It would be nice to also store the actual value that caused the exception, but that could potentially expose PII so maybe not the best idea.
I'll make a PR and can discuss further.
Component(s)
Java
The text was updated successfully, but these errors were encountered: