You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/var/lib/gems/2.3.0/gems/riak-client-2.4.1/lib/riak/robject.rb:190:in `content': The object is in conflict (has siblings) and cannot be treated singly or saved: #<Riak::RObject {Jira,rubyTest} []> (Riak::Conflict)
from ./jira.rb:14:in `<main>'
However, this is confusing from an API perspective and perhaps something similar to the following in order to handle tombstones and deleted objects directly may be more appropriate:
r=bucket.get("rubyTest", deletedvclock: true)
if r.isTombstone?
r.revive
end
r.data = "test'
r.store
The text was updated successfully, but these errors were encountered:
Basho-JIRA
changed the title
Need clean way to handle deleted objects and tombstones
Need clean way to handle deleted objects and tombstones [JIRA: CLIENTS-965]
Aug 23, 2016
Thank you Mike. I like the suggestion of the tombstone check and revive. I think it would also be clean to use a callback like "on_tombstone { revive }" similar to the on_conflict callback.
I have most of it together already, I just need to write some tests after a
Java client release. If you'd be interested in that part I can push my
changes up.
Ruby Client returns deleted objects as a sibling conflict with no siblings that needs to be resolved in order to restore the object.
ruby --version
ruby 2.3.1p112 (2016-04-26) [x86_64-linux-gnu]
riak-client (2.4.1)
Ubuntu 16.04 4.4.0-34-generic
advanced.config:
The following:
Results in:
However, the sibling count is 0.
Current method to restore the deleted object:
However, this is confusing from an API perspective and perhaps something similar to the following in order to handle tombstones and deleted objects directly may be more appropriate:
The text was updated successfully, but these errors were encountered: