Skip to content

Specification.where(spec) is deprecated without further notice #3893

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

Closed
albertus82 opened this issue May 17, 2025 · 1 comment
Closed

Specification.where(spec) is deprecated without further notice #3893

albertus82 opened this issue May 17, 2025 · 1 comment
Labels
type: documentation A documentation update

Comments

@albertus82
Copy link

Hi,

I just noticed that static <T> Specification<T> where(@Nullable Specification<T> spec) is deprecated but no information is provided on how to fix the code, so a compiler warning is triggered and apparently there's nothing I can do to fix it. Am I missing something?

Thanks.

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label May 17, 2025
@mp911de mp911de added type: documentation A documentation update and removed status: waiting-for-triage An issue we've not yet triaged labels May 19, 2025
@mp911de
Copy link
Member

mp911de commented May 19, 2025

Thanks for letting us know that the deprecation isn't expressive enough. The where method merely caters for the broken nullability allowance and is replaced by where(PredicateSpecification) in 4.0. Let me add a bit of documentation.

@mp911de mp911de added this to the 3.5.1 (2025.0.1) milestone May 19, 2025
@mp911de mp911de changed the title Specification.where(spec) is deprecated since v3.5.0 without further notice Specification.where(spec) is deprecated without further notice May 19, 2025
mp911de added a commit that referenced this issue May 19, 2025
Also, document the intent to make methods accepting `Specifications` to be non-nullable.

Closes #3893
@mp911de mp911de closed this as completed May 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: documentation A documentation update
Projects
None yet
Development

No branches or pull requests

3 participants