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

Change BundleService#update() to only return boolean for success #2141

Merged
merged 1 commit into from Apr 26, 2016
Merged

Conversation

@joschi
Copy link
Contributor

@joschi joschi commented Apr 26, 2016

The WriteResult returned by JacksonDBCollection#updateById() doesn't contain the updated object and thus WriteResult#getSavedObject() failed with "No objects to return".
The returned WriteResult does contain the number of changed documents, though, so simply comparing that number with the expected number of updated documents suffices as return value of
BundleService#update().

Fixes #2138

The WriteResult returned by JacksonDBCollection doesn't contain the updated object
and thus WriteResult#getSavedObject() failed with "No objects to return". The returned
WriteResult does contain the number of changed documents, though, so simply comparing
that number with the expected number of updated documents suffices as return value of
BundleService#update().

Fixes #2138
@joschi joschi added this to the 2.0.0 milestone Apr 26, 2016
@bernd bernd self-assigned this Apr 26, 2016
@bernd
Copy link
Member

@bernd bernd commented Apr 26, 2016

LGTM 👍

@bernd bernd merged commit 1e7388f into 2.0 Apr 26, 2016
4 checks passed
4 checks passed
@garybot2
ci-server-integration Jenkins build graylog2-server-integration-pr 864 has succeeded
Details
@garybot2
ci-web-linter Jenkins build graylog-pr-linter-check 352 has succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
@bernd bernd deleted the issue-2138 branch Apr 26, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants