rocksdb/db/wide
Levi Tamasi 06ab0a8b40 Add wide-column support to iterators (#10670)
Summary:
The patch extends the iterator API with a new `columns` method which
can be used to retrieve all wide columns for the current key. Similarly to
the `Get` and `GetEntity` APIs, the classic `value` API returns the value
of the default (anonymous) column for wide-column entities, and `columns`
returns an entity with a single default column for plain old key-values.
(The goal here is to maintain the invariant that `value()` is the same as
the value of the default column in `columns()`.) The patch also involves a
smaller refactoring: historically, `value()` was implemented using a bunch
of conditions, that is, the `Slice` to be returned was decided based on the
direction of the iteration, whether a merge had been done etc. when the
method was called; with the patch, the value to be exposed is stored in a
member `Slice value_` when the iterator lands on a new key, and `value()`
simply returns this `Slice`.

Pull Request resolved: https://github.com/facebook/rocksdb/pull/10670

Test Plan: Ran `make check` and a simple blackbox crash test.

Reviewed By: riversand963

Differential Revision: D39475551

Pulled By: ltamasi

fbshipit-source-id: 29e7a6ed9ef340841aab36803b832b7c8f668b0b
2022-09-13 21:01:36 -07:00
..
db_wide_basic_test.cc Add wide-column support to iterators (#10670) 2022-09-13 21:01:36 -07:00
wide_column_serialization.cc Add wide-column support to iterators (#10670) 2022-09-13 21:01:36 -07:00
wide_column_serialization.h Make queries return the value of the default column for wide-column entities (#10483) 2022-08-08 16:10:08 -07:00
wide_column_serialization_test.cc Add API for writing wide-column entities (#10242) 2022-06-25 15:30:47 -07:00
wide_columns.cc Add support for wide-column point lookups (#10540) 2022-08-19 11:51:12 -07:00