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

Refactor DeclaredQuery to decouple the query definition from its introspected state #3622

Closed
mp911de opened this issue Sep 25, 2024 · 0 comments
Labels
type: enhancement A general enhancement

Comments

@mp911de
Copy link
Member

mp911de commented Sep 25, 2024

Follow-up to #2989.

We should decouple DeclaredQuery properties (query string and native query flavor) from introspection properties (alias, usage of constructor expressions, …) to separate the process from DeclaredQuery creation and introspection so that QueryEnhancerFactory can be provided externally.

@mp911de mp911de added the type: enhancement A general enhancement label Sep 25, 2024
mp911de added a commit that referenced this issue Mar 18, 2025
…ctory` to use.

Introduce QueryEnhancerSelector to EnableJpaRepositories.

Also, split DeclaredQuery into two interfaces to resolve the inner cycle of query introspection while just a value object is being created.

Introduce JpaQueryConfiguration to capture a multitude of configuration elements.

Remove `spring.data.jpa.query.native.parser` option introduced earlier with #2989

Closes #3622
Original pull request: #3527
mp911de pushed a commit that referenced this issue Mar 18, 2025
See #3622
Original pull request: #3527
mp911de added a commit that referenced this issue Mar 18, 2025
Introduce refined names: EntityQuery, TemplatedQuery, ParametrizedQuery, QueryProvider. Return QueryProvider where possible. Introduce rewrite as concept on DeclaredQuery to retain its nature and track the origin of the query rewriting.

Move methods solely used in tests to TestDefaultEntityQuery.

Remove unused methods, fix naming, group DeclaredQuery implementations in DeclaredQueries. Add documentation.

See #3622
Original pull request: #3527
mp911de added a commit that referenced this issue Mar 18, 2025
Introduce refined names: EntityQuery, TemplatedQuery, ParametrizedQuery, QueryProvider. Return QueryProvider where possible. Introduce rewrite as concept on DeclaredQuery to retain its nature and track the origin of the query rewriting.

Move methods solely used in tests to TestDefaultEntityQuery.

Remove unused methods, fix naming, group DeclaredQuery implementations in DeclaredQueries. Add documentation.

See #3622
Original pull request: #3527
@mp911de mp911de added this to the 4.0 M2 (2025.1.0) milestone Mar 18, 2025
@mp911de mp911de closed this as completed Mar 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement A general enhancement
Projects
None yet
1 participant