[patches] [schema 1/1] Allow to do not specify tail nullable index columns
v.shpilevoy at tarantool.org
v.shpilevoy at tarantool.org
Thu Jan 25 16:24:31 MSK 2018
I agree, that the feature seems to be strange, but it is requested by a customer. The only hot paths touched here is is_nullable = true comparators, which are not critical.
> 25 янв. 2018 г., в 16:16, Vladimir Davydov <vdavydov.dev at gmail.com> написал(а):
>
> To tell the truth, I'm not quite convinced of the usefulness of this
> feature - I simply fail to see a proper use case for it - but then again
> I don't use Tarantool and so can't be impartial. I guess we should
> question our users whether they need it and what for.
>
> Anyway, I see that this patch touches some hot paths so IMO the first
> thing we should do is run some tests (cbench?) to check if there's a
> performance degradation after it is applied.
>
> Apart from potential performance issues and somewhat intricate
> definition of indexed field constraints, I currently don't see
> any pitfalls this feature can introduce.
>
> On Thu, Jan 25, 2018 at 03:26:15PM +0300, Konstantin Osipov wrote:
>> What's your take on this patch?
>>
>> * Vladislav Shpilevoy <v.shpilevoy at tarantool.org> [18/01/25 13:59]:
>>
>>
>>> If a column is nullable and is the last defined one (via index parts
>>> or space format), it can be omited on insertion. Such absent fields
>>> are treated as NULLs in comparators and are not stored.
>>>
>>> Closes #2988
>>>
>>> Signed-off-by: Vladislav Shpilevoy <v.shpilevoy at tarantool.org>
>>> ---
>>> src/box/tuple_compare.cc | 77 +++++--
>>> src/box/tuple_extract_key.cc | 173 +++++++++++---
>>> src/box/tuple_format.c | 11 +-
>>> src/box/tuple_format.h | 10 +-
>>> src/box/tuple_hash.cc | 32 ++-
>>> src/box/vy_stmt.c | 17 +-
>>> src/box/vy_stmt.h | 2 +-
>>> test/engine/null.result | 526 +++++++++++++++++++++++++++++++++++++++++++
>>> test/engine/null.test.lua | 130 +++++++++++
>>> 9 files changed, 912 insertions(+), 66 deletions(-)
More information about the Tarantool-patches
mailing list