Skip to content

ReplaceById needs change that is in UpsertById in DATACOUCH-625 for immutable entities [DATACOUCH-666] #974

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
spring-projects-issues opened this issue Dec 8, 2020 · 0 comments
Assignees
Labels
type: bug A general bug

Comments

@spring-projects-issues
Copy link

Michael Reiche opened DATACOUCH-666 and commented

The last return should return template.support().applyUpdatedCas(...) instead of 'o'.   If the 'o' is immutable, it won't contain the updated cas.  This was done in DATACOUCH-625 for UpsertById, the same change is needed here in ReplaceById

return template.getCollection(collection).reactive() .replace(converted.getId(), converted.export(), buildReplaceOptions(o)).map(result -> { template.support().applyUpdatedCas(o, result.cas()); return o; });

Referenced from: pull request #288

Backported to: 4.1.3 (2020.0.3), 4.0.7 (Neumann SR7)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug A general bug
Projects
None yet
Development

No branches or pull requests

2 participants