Skip to content
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

Maintain insertion order for subschemas of CombinedSchema #522

Merged
merged 3 commits into from
Feb 6, 2025

Conversation

rayokota
Copy link
Contributor

@rayokota rayokota commented Feb 5, 2025

Maintain insertion order for subschemas of CombinedSchema.

This is an alternative to #519 that maintains the subschemas in insertion order.

The subschemas were originally maintained in insertion order, but it was changed due to #405, which ensured that subschemas that were of type CombinedSchema were visited first during validation, and by #498, which tries to maintain a stable order for "equivalent" instances.

This PR simply restores the insertion order, but maintains an internally sorted collection for the two purposes listed above, namely visiting subschemas during validation and equivalence checks during equals/hashCode.

Copy link
Contributor

@erosb erosb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Then let's go ahead with this one :)

@erosb erosb merged commit 2381e48 into everit-org:master Feb 6, 2025
@rayokota
Copy link
Contributor Author

rayokota commented Feb 6, 2025

Thanks again @erosb ! I really appreciate all your efforts! :)

@erosb
Copy link
Contributor

erosb commented Feb 6, 2025

Welcome :) version 1.14.5 is already available on maven central with your fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants