From: Vladimir Davydov <vdavydov.dev@gmail.com> To: Georgy Kirichenko <georgy@tarantool.org> Cc: tarantool-patches@freelists.org Subject: Re: [tarantool-patches] [PATCH v2 1/3] Applier gets rid of a xstream Date: Thu, 7 Mar 2019 12:31:04 +0300 [thread overview] Message-ID: <20190307093104.5al4drqbmayyiufq@esperanza> (raw) In-Reply-To: <166b45adc75c0753d36ea473d57ac452548fbbec.1551902962.git.georgy@tarantool.org> On Wed, Mar 06, 2019 at 11:16:15PM +0300, Georgy Kirichenko wrote: > Remove xstream dependency and use direct box interface to apply all > replication rows. This is refactoring before transactional replication. > > Needed for: #2798 > --- > src/box/applier.cc | 69 ++++++++++++++++++++++++++++++++++++++-------- > src/box/applier.h | 9 +----- > src/box/box.cc | 68 ++++++++------------------------------------- > 3 files changed, 69 insertions(+), 77 deletions(-) Pushed to 2.1 with the following minor changes: diff --git a/src/box/applier.cc b/src/box/applier.cc index a687d2be..94c07aac 100644 --- a/src/box/applier.cc +++ b/src/box/applier.cc @@ -201,11 +201,8 @@ apply_row(struct xrow_header *row) struct request request; if (xrow_decode_dml(row, &request, dml_request_key_map(row->type)) != 0) return -1; - if (request.type == IPROTO_NOP) { - if (process_nop(&request) != 0) - return -1; - return 0; - } + if (request.type == IPROTO_NOP) + return process_nop(&request); struct space *space = space_cache_find(request.space_id); if (space == NULL) return -1; diff --git a/src/box/box.cc b/src/box/box.cc index 45beefb9..f7ce33aa 100644 --- a/src/box/box.cc +++ b/src/box/box.cc @@ -307,9 +307,9 @@ apply_wal_row(struct xstream *stream, struct xrow_header *row) struct wal_stream *xstream = container_of(stream, struct wal_stream, base); /** - * Yield once in a while, but not too often, - * mostly to allow signal handling to take place. - */ + * Yield once in a while, but not too often, + * mostly to allow signal handling to take place. + */ if (++xstream->rows % xstream->yield == 0) fiber_sleep(0); }
next prev parent reply other threads:[~2019-03-07 9:31 UTC|newest] Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top 2019-03-06 20:16 [tarantool-patches] [PATCH v2 0/3] Transaction boundaries for applier Georgy Kirichenko 2019-03-06 20:16 ` [tarantool-patches] [PATCH v2 1/3] Applier gets rid of a xstream Georgy Kirichenko 2019-03-07 9:31 ` Vladimir Davydov [this message] 2019-03-06 20:16 ` [tarantool-patches] [PATCH v2 2/3] Put all new rows to the end of journal request Georgy Kirichenko 2019-03-07 9:46 ` Vladimir Davydov 2019-03-07 10:38 ` [tarantool-patches] " Konstantin Osipov 2019-03-07 10:53 ` Vladimir Davydov 2019-03-07 11:22 ` Konstantin Osipov 2019-03-06 20:16 ` [tarantool-patches] [PATCH v2 3/3] Transaction support for applier Georgy Kirichenko 2019-03-07 10:38 ` Vladimir Davydov 2019-03-07 10:40 ` [tarantool-patches] " Konstantin Osipov
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20190307093104.5al4drqbmayyiufq@esperanza \ --to=vdavydov.dev@gmail.com \ --cc=georgy@tarantool.org \ --cc=tarantool-patches@freelists.org \ --subject='Re: [tarantool-patches] [PATCH v2 1/3] Applier gets rid of a xstream' \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox