[PATCH v2 04/11] box: open the port before starting local recovery

Vladimir Davydov vdavydov.dev at gmail.com
Thu Jun 14 11:31:54 MSK 2018


On Wed, Jun 13, 2018 at 11:43:42PM +0300, Konstantin Osipov wrote:
> * Vladimir Davydov <vdavydov.dev at gmail.com> [18/06/08 20:38]:
> > In order to find out if the current instance fell too much behind its
> > peers in the cluster and so needs to be re-bootstrapped we need to
> > connect it to remote peers before proceeding to local recovery. The
> > problem is box.cfg.replication may have an entry corresponding to the
> > instance itself so before connecting we have to start listening to
> > incoming connections. So this patch moves the call to box_listen()
> > before recoery is started unless the instance in hot standby mode.
> > It also folds box_bind() into box_listen() as it is no longer needed
> > as a separate function.
> 
> This may actually break some applications, since we now begin
> processing requests before local recovery. 
> 
> But this was bound to happen sometime, we have always had wanted
> to separate networking and the database.
> 
> Plus I expect this to be needed for Vlad's work on new
> require('net.box').listen(), which should forward write requests
> to replica set leader by default.
> 
> OK to push.

Please review patch 3 before I can push this one.



More information about the Tarantool-patches mailing list