Regarding in-place update in Memtable

317 views
Skip to first unread message

mahigu...@gmail.com

unread,
Nov 16, 2017, 4:43:03 AM11/16/17
to rocksdb

Hello everyone,

Good Morning !!

I would like to do a in-place update in Memtable. Of-course it is available but it is not doing so, if new value is larger than existing/prev value.

I would like to do it irrespective of newer value size. Literally, the older value should not exist at any cost.

It should be like deleting the existing Node for that key in skiplist(with out tombstone node) and adding the new node with those links.

I have seen some in-place update callbacks that RocksDB provides, but we are restricted to do such kind of operations in callback functions.

I'm not bothered about write latencies, concurrent writes, Memtable Format (SkipList/Hash SkipList etc...) etc... but i should be able to do perfect in-place update.

Please help me in this regard.

PS: I'm ready to use in-memory RocksDb as well, if in-place update is possible there.

Thanks in advance.

Best Regards
- Mahi

Maysam Yabandeh

unread,
Nov 16, 2017, 11:32:28 AM11/16/17
to mahigu...@gmail.com, rocksdb
We are planning to add an option to delete the specified key/seq if it cannot be updated in place, before adding the new one. The space would not be reclaimed though. ETA is in around a month.

Maysam

--
You received this message because you are subscribed to the Google Groups "rocksdb" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rocksdb+unsubscribe@googlegroups.com.
To post to this group, send email to roc...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rocksdb/3b600685-5a0b-4f61-939e-333db1020d73%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Siying Dong

unread,
Nov 16, 2017, 2:02:34 PM11/16/17
to mahigu...@gmail.com, rocksdb

This option should not rely on callback function to do in-place update in memtable. See the comments about the limitation of the feature: https://github.com/facebook/rocksdb/blob/5.9.fb/include/rocksdb/advanced_options.h#L168-L179

--

You received this message because you are subscribed to the Google Groups "rocksdb" group.

To unsubscribe from this group and stop receiving emails from it, send an email to rocksdb+u...@googlegroups.com.

mahigu...@gmail.com

unread,
Nov 17, 2017, 12:37:30 AM11/17/17
to rocksdb
@Maysam Thanks for your response
As far as i understood, if in-place update is not possible, you are mimicking that update as "Delete+Insert".
Here "Delete" part is unclear for me.
Will it delete(unlink) the old Node in skiplist and add new node.
or
Add (tombstone record/node for that key) + (new Node with newer value)

Which one is true? Please clarify me on this, for my better understanding.


On Thursday, November 16, 2017 at 10:02:28 PM UTC+5:30, Maysam Yabandeh wrote:
We are planning to add an option to delete the specified key/seq if it cannot be updated in place, before adding the new one. The space would not be reclaimed though. ETA is in around a month.

Maysam
On Thu, Nov 16, 2017 at 1:43 AM, <mahigu...@gmail.com> wrote:

Hello everyone,

Good Morning !!

I would like to do a in-place update in Memtable. Of-course it is available but it is not doing so, if new value is larger than existing/prev value.

I would like to do it irrespective of newer value size. Literally, the older value should not exist at any cost.

It should be like deleting the existing Node for that key in skiplist(with out tombstone node) and adding the new node with those links.

I have seen some in-place update callbacks that RocksDB provides, but we are restricted to do such kind of operations in callback functions.

I'm not bothered about write latencies, concurrent writes, Memtable Format (SkipList/Hash SkipList etc...) etc... but i should be able to do perfect in-place update.

Please help me in this regard.

PS: I'm ready to use in-memory RocksDb as well, if in-place update is possible there.

Thanks in advance.

Best Regards
- Mahi

--
You received this message because you are subscribed to the Google Groups "rocksdb" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rocksdb+u...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages