[PATCH 6/6] Introduce replica local spaces

Konstantin Osipov kostja at tarantool.org
Wed Jun 27 21:24:47 MSK 2018


* Vladimir Davydov <vdavydov.dev at gmail.com> [18/06/13 20:40]:
> This patch introduces a new space option, is_local, which if specified
> on space creation will render all changes done locally to the space
> invisible to other replicas. The option can only be set on space
> creation and cannot be altered.
> 
> Technically, to support this feature, we introduce a new header flag,
> IPROTO_IS_LOCAL, which is set for all rows corresponding to replica
> local spaces both in xlog and in snap. Relay won't send snapshot rows
> that are marked local. As for xlog rows, it will transform them to
> IPROTO_NOP so as to promote vclock on the replica without doing any
> actual data modification.
> 
> The feature is currently supported for memtx spaces only, but it should
> be easy to implement it for vinyl spaces as well.

The patch overall LGTM, except is_local in xrow should be a number
instead for replication group.

The following group identifiers should be reserved:

0 - the default replication group, entire cluster
1 - local space.
2 - shard-local space.

-- 
Konstantin Osipov, Moscow, Russia, +7 903 626 22 32
http://tarantool.io - www.twitter.com/kostja_osipov



More information about the Tarantool-patches mailing list