Skip to content

Add project(fields) to findByQuery similar to same method on findById. #1212

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

Merged
merged 1 commit into from
Sep 13, 2021

Conversation

mikereiche
Copy link
Collaborator

Closes #1208.

  • You have read the Spring Data contribution guidelines.
  • There is a ticket in the bug tracker for the project in our JIRA.
  • You use the code formatters provided here and have them applied to your changes. Don’t submit any formatting related changes.
  • You submit test cases (unit or integration tests) that back your changes.
  • You added yourself as author in the headers of the classes you touched. Amend the date range in the Apache license header if needed. For new types, add the license header (copy from another file and set the current year only).

@mikereiche mikereiche requested a review from daschl September 8, 2021 23:37
@mikereiche mikereiche modified the milestone: 4.3 M3 (2021.1.0) Sep 8, 2021

@Override
public FindByQueryWithProjection<T> project(String[] fields) {
// Assert.notNull(fields, "Fields must not be null");
Copy link
Contributor

Choose a reason for hiding this comment

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

should we do a null check here?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yes. And also in ExecutableFindByQueryOperationSupport.project(). Fixed.

@mikereiche mikereiche force-pushed the datacouch_1208_add_project_to_findbyquery branch 2 times, most recently from a5ec021 to dd194bc Compare September 12, 2021 23:57
@mikereiche mikereiche force-pushed the datacouch_1208_add_project_to_findbyquery branch from dd194bc to 2c933eb Compare September 13, 2021 00:14
@mikereiche mikereiche merged commit 4bd82ea into main Sep 13, 2021
@mikereiche mikereiche deleted the datacouch_1208_add_project_to_findbyquery branch October 19, 2021 22:14
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.

Support project() method for CouchbaseTemplate.findByQuery() queries
2 participants