Skip to content

Conversation

marko-bekhta
Copy link
Member

https://hibernate.atlassian.net/browse/HHH-19629
https://hibernate.atlassian.net/browse/HHH-19630

cc: @cigaly


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license
and can be relicensed under the terms of the LGPL v2.1 license in the future at the maintainers' discretion.
For more information on licensing, please check here.


@marko-bekhta marko-bekhta requested a review from gavinking July 21, 2025 13:24
@cigaly
Copy link
Contributor

cigaly commented Jul 21, 2025

It is working, with that comment that parameter will be annotated with two Nonnull annotations, but this will not cause any error. And if some purist have problems with that, (s)he can fix it.

@cigaly
Copy link
Contributor

cigaly commented Jul 21, 2025

And if you really want some nitpicking, maybe you can (in typeAsString) move

result = type.toString();

into else branch (when type is DeclaredType result this is redundant call).
Also, you may consider to use collect( Collectors.joining( ",", "<", ">" ) ) instead of concatenating prefix and suffix in separate statements.
Of course, neither of those changes will make big difference.

@marko-bekhta marko-bekhta force-pushed the fix/HHH-19629-Hibernate-Processor-may-fail-when-repository-method-parameter-has-more-than-one-annotation branch from f4a1451 to 774bbfb Compare July 21, 2025 15:00
@marko-bekhta marko-bekhta force-pushed the fix/HHH-19629-Hibernate-Processor-may-fail-when-repository-method-parameter-has-more-than-one-annotation branch from 774bbfb to c345a55 Compare July 22, 2025 09:13
@yrodiere
Copy link
Member

yrodiere commented Oct 6, 2025

Hey @marko-bekhta, do you think you can find the time to wrap this up? :)

@marko-bekhta marko-bekhta force-pushed the fix/HHH-19629-Hibernate-Processor-may-fail-when-repository-method-parameter-has-more-than-one-annotation branch from c345a55 to 9ebeb5d Compare October 6, 2025 19:52
@yrodiere yrodiere changed the title HHH-19629 Hibernate Processor may fail when repository method parameter has more than one annotation (e.g. multiple constraints) / HHH-19630 Hibernate Processor may fail if the return type is a single entity and annotatated with multiple annotations HHH-19629 Hibernate Processor may fail when repository method parameter has more than one annotation (e.g. multiple constraints) / HHH-19630 Hibernate Processor may fail if the return type is a single entity and annotated with multiple annotations Oct 7, 2025
Copy link
Member

@yrodiere yrodiere left a comment

Choose a reason for hiding this comment

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

There are tests, they're passing, and all comments have been addressed. Let's merge :) Thank you!

@yrodiere
Copy link
Member

yrodiere commented Oct 7, 2025

Backporting here: #11072

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.

4 participants