Skip to content

limit queries of single finders to 2 #2594

@tschniewind

Description

@tschniewind

Enhancement:
Given a repositorys find-method returning a single result or an java.util.Optional should limit the underlying query to 2.

This would help to get the expected Result in case of multiple rows (IncorrectResultSizeDataAccessException) even if the query leads to huge result set.

(We had a case leading to an out of memory exception cause the query found about 50000 rows. Unfortunately we could not use a UniqueConstraint.)

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions