Skip to content

DATACASS-825 - Implements deleteAllById(Iterable<ID> ids). #181

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
wants to merge 3 commits into from

Conversation

schauder
Copy link
Contributor

Merge after DATACMNS-800


Assert.notNull(ids, "The given Iterable of ids must not be null");

ids.forEach(id -> operations.deleteById(id, entityInformation.getJavaType()));
Copy link
Member

Choose a reason for hiding this comment

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

We should use the same semantics as with findAllById(…) regarding the query mechanism to avoid individual database queries for each ID.


Assert.notNull(ids, "The given Iterable of entities must not be null");

return Flux.fromIterable(ids).flatMap(this::deleteById).then();
Copy link
Member

Choose a reason for hiding this comment

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

We should use the same semantics as with findAllById(…) regarding the query mechanism to avoid individual database queries for each ID.

mp911de pushed a commit that referenced this pull request Nov 25, 2020
…eleteAllById(Iterable<ID> ids).

Original pull request: #181.
mp911de added a commit that referenced this pull request Nov 25, 2020
Reoder methods. Remove unused code and imports.

Original pull request: #181.
@mp911de
Copy link
Member

mp911de commented Nov 25, 2020

That's merged and polished now.

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.

2 participants