-
Notifications
You must be signed in to change notification settings - Fork 383
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
[#3190] fix(jdbc-backend): Fix the cast issue when Relational Garbage Collector cleaning fileset version info #3191
Conversation
|
||
public class FilesetMaxVersionPO { | ||
private Long filesetId; | ||
private Long version; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So we change the data type of version
from integer
to Long
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yuqi1129 I don't think it's necessary, generally integer unsigned
is enough, and now when we deserialize to Java, we use Long
encapsulation by default. The problem here is that the return value type of the max()
function after processing version
is different in different databases. In MySQL, here the Long
type is returned; And in H2, the Integer
type is returned. It is enough for us to do this here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
… Collector cleaning fileset version info (#3191) ### What changes were proposed in this pull request? When obtaining the maximum version result of fileset, pass the result into the object to solve the `ClassCastException` problem. ### Why are the changes needed? Fix: #3190 ### How was this patch tested? Add some ITs. --------- Co-authored-by: xiaojiebao <[email protected]>
…arbage Collector cleaning fileset version info (apache#3191) ### What changes were proposed in this pull request? When obtaining the maximum version result of fileset, pass the result into the object to solve the `ClassCastException` problem. ### Why are the changes needed? Fix: apache#3190 ### How was this patch tested? Add some ITs. --------- Co-authored-by: xiaojiebao <[email protected]>
What changes were proposed in this pull request?
When obtaining the maximum version result of fileset, pass the result into the object to solve the
ClassCastException
problem.Why are the changes needed?
Fix: #3190
How was this patch tested?
Add some ITs.