-
-
Notifications
You must be signed in to change notification settings - Fork 586
HV-1767 Reduce the overhead of ConstraintHelper initialization in the predefined scope case #1080
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
Conversation
yrodiere
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.
Looks good to me. Just a few comments about naming, but nothing critical.
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.
annotationClassName or something like that, maybe? It's a bit hard to understand what this field stands for when reading the various methods of this class.
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'd use getBuiltinConstraints, to make the code clearer in places where this getter is called... but it's your call.
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.
Same here, forBuiltinConstraints? Since this won't work with custom constraints.
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.
Some nitpicking (for a change!); I usually see this pattern written that way:
if ( jodaTimeInClassPath == null ) {
jodaTimeInClassPath = isClassPresent( JODA_TIME_CLASS_NAME );
}
return jodaTimeInClassPath.booleanValue();
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.
requiredConstraints or constraintDependencies or something like that? Feel free to ignore, but I had a hard time wrapping my head around this, so a more precise name might help.
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.
This is the technical term in HV but yeah I also thought about changing it to something along the lines of what you suggest so let's do it.
… predefined scope case
|
@yrodiere I addressed your comments. |
https://hibernate.atlassian.net/browse/HV-1767