-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Wip/6.0 HHH-13877 Make@SortNatural default for SortedSet and SortedMap
#3233
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
Wip/6.0 HHH-13877 Make@SortNatural default for SortedSet and SortedMap
#3233
Conversation
0fed650 to
a0061d3
Compare
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 manually compared to explicit @SortNatural case and found everything is the same(only hadExplicitSort values are different but it is used internally in this method and its main usage is the above code snippet), so removing the above code snippet seems enough to achieve the goal of this PR, unless I were wrong.
@SortNatural or @SortComparator@SortNatural or @SortComparator
|
I need to look through this some more. However, this would be a new feature or improvement since we did not previously support this. New features/improvements ought to have a corresponding Jira - the reason being it will be easier to consolidate all new features and improvements when we get to CRs and eventually Final |
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.
We should also assert that the phones are in fact sorted in proper order.
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.
Updated. Originally I had thought we might end up with testing SortedSet or SortedMap. Testing case enriched enormously.
a05f49f to
337fe8f
Compare
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.
It doesn't make sense to insert testing data with the natural order. Ideally we are supposed to populate big number of data to ensure the order is not maintained not by accident.
337fe8f to
d00d8cb
Compare
@SortNatural or @SortComparator@SortNatural as default for SortedSet and SortedMap
I created a ticket for this: https://hibernate.atlassian.net/browse/HHH-13877 and updated the PR accordingly. |
@SortNatural as default for SortedSet and SortedMap@SortNatural default for SortedSet and SortedMap
sebersole
left a comment
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.
Looked through this some more and approve the changes.
However because of other "code cleanup" type changes a few files here now have completely unnecessary conflicts which is the problem I was pointing out a few weeks ago.
Anyway, please rebase these changes on top of those cosmetic cleanups. Thanks
d00d8cb to
7648230
Compare
A lesson learned. Conflict resolved (mainly from another PR, but yeah, cosmetic code changes break other PRs easily) and force pushed. |
|
Thanks @NathanQingyangXu I'll apply after the checks complete |
https://trello.com/c/up8I5oIi/58-support-for-sorted-set-and-sorted-map-without-sortnatural-or-sortcomparator
https://hibernate.atlassian.net/browse/HHH-13877
testing case added