-
Notifications
You must be signed in to change notification settings - Fork 304
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 8 date support in TaskExecution breaks DB2 support #948
Comments
Hello, |
Hello, I'm not sure what's the best way to create a test to reproduce it. We register our Task in SCDF server (this application is also using DB2). The Task is registered as boot3 application, and thus using the BOOT3_ schema tables. This is where it fails, the getTaskExcetion throws an exception in the mapRow function.
|
Thank you for the additional notes. They were helpful! |
@Cuball0 Thanks for reporting the issue! |
The implementation of this commit : a0fda4b
Breaks DB2 LUW support.
The code above was changed into the code below: (rs.getTimestamp("field") -> rs.getObject("field",LocalDateTime.class)
The latter however throws and exception when the column has a is null value (which is the case for START_TIME and END_TIME at the start of a task excecution. Because of this, it's impossible to run spring-cloud tasks anymore that use DB2 as a database.
Simple test to reproduce the problem with DB2 driver
Output :
------ RECORD -------1
Successful retrieved LocalDateTime : 2023-12-22T08:16:50.674910
Successful retrieved Date from Timestamp : 2023-12-22 08:16:50.67491
------ RECORD -------2
Unable to retrieve YOUR_TIMESTAMP_COLUMN via getObject(YOUR_TIMESTAMP_COLUMN, LocalDateTime.class)
Error message: Cannot invoke "java.sql.Timestamp.toLocalDateTime()" because "" is null
Successful retrieved Date from Timestamp : null
The text was updated successfully, but these errors were encountered: