[tarantool-patches] [PATCH v2] memtx: add yields during index build
Serge Petrenko
sergepetrenko at tarantool.org
Tue May 28 18:36:09 MSK 2019
> 23 мая 2019 г., в 18:25, Konstantin Osipov <kostja at tarantool.org> написал(а):
>
> * Serge Petrenko <sergepetrenko at tarantool.org> [19/05/23 17:58]:
>> Memtx index build used to stall event loop for all the build period.
>> Add occasional yields so that the loop is not blocked for too long.
>> Also make index build set on_replace triggers so that concurrent
>> replaces are also correctly handled during the build.
>>
>> Closes #3976
>
> The next piece of the puzzle is we need to understand how this
> replicates.
>
> What would be the order of such a concurrent execution on replica?
>
> I'd assume it would stop the applier until the build is finished,
> is this right, Georgy?
Georgy says that’s right, applier holds the latch until wal write happens,
i.e. during the whole index build process
>
> I think this is the only reasonable and safe thing to do, do you
> have other opinions?
>
> If no, we just need to test it with some timeout injections on
> replica, in particular add a test which breaks replication by
> inserting a conflicting row while the index is being built.
> This test would be useful for both engines, I guess.
>
> --
> Konstantin Osipov, Moscow, Russia
More information about the Tarantool-patches
mailing list