Hello Alexey Serbin, Ashwani Raina, Yingchun Lai, Kudu Jenkins,

I'd like you to reexamine a change. Please visit

    http://gerrit.cloudera.org:8080/19463

to look at the new patch set (#2).

Change subject: [tserver] Keep the order of appling the ops same as raft WAL
......................................................................

[tserver] Keep the order of appling the ops same as raft WAL

The order of tablet's write ops(including other raft logs) is in total order
on server-side. Appling them into kudu engine should be same as raft wal.
Currently, appling the ops using 'apply_pool->Submit'(i.e concurrent 
thread-pool),
may cause some ops to go out of order.

For example, 4 logs of 2 ops, we expected:
    replicate 1.1
    commit 1.1
    replicate 1.2
    commit 1.2
or
    replicate 1.1
    replicate 1.2
    commit 1.1
    commit 1.2

A incorrect order is:
    replicate 1.1
    replicate 1.2
    commit 1.2
    commit 1.1

That means 1.2 would become valid before 1.1 in kudu engine, that's not 
expected.
'apply_pool->Submit' cauld cause the incorrect order.

This patch try to fix the problem by using apply_pool_token with SERIAL_MODE
created by apply_pool.

Change-Id: Id040122ab9473d1a8b03a2a1e751454a32b89d87
---
M src/kudu/tablet/ops/op_driver.cc
M src/kudu/tablet/ops/op_driver.h
M src/kudu/tablet/tablet_replica.cc
M src/kudu/tablet/tablet_replica.h
4 files changed, 50 insertions(+), 10 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/63/19463/2
--
To view, visit http://gerrit.cloudera.org:8080/19463
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Id040122ab9473d1a8b03a2a1e751454a32b89d87
Gerrit-Change-Number: 19463
Gerrit-PatchSet: 2
Gerrit-Owner: Yuqi Du <[email protected]>
Gerrit-Reviewer: Alexey Serbin <[email protected]>
Gerrit-Reviewer: Ashwani Raina <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Yingchun Lai <[email protected]>
Gerrit-Reviewer: Yuqi Du <[email protected]>

Reply via email to