kudu-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t...@apache.org
Subject [1/5] kudu git commit: Rename Remote Bootstrap: some manual changes
Date Sun, 07 Aug 2016 03:56:49 GMT
Repository: kudu
Updated Branches:
  refs/heads/master 9c82e61f5 -> 647f904b5


Rename Remote Bootstrap: some manual changes

This patch has a bunch more manual fixes to replace "Remote Bootstrap"
terminology with "Tablet Copy". I looked through the previous (automatic)
diff and tried to clean up comments and variable names to be more clear,
as well as find other abbreviated cases like the term 'bootstrap' or 'rb'
which needed to be updated.

This still doesn't do the file renames. That's yet to come.

Change-Id: I9e2860b64e46c5cc021cb8574e6845d7bcb27cce
Reviewed-on: http://gerrit.cloudera.org:8080/3852
Reviewed-by: Mike Percy <mpercy@apache.org>
Tested-by: Kudu Jenkins


Project: http://git-wip-us.apache.org/repos/asf/kudu/repo
Commit: http://git-wip-us.apache.org/repos/asf/kudu/commit/7ee61f84
Tree: http://git-wip-us.apache.org/repos/asf/kudu/tree/7ee61f84
Diff: http://git-wip-us.apache.org/repos/asf/kudu/diff/7ee61f84

Branch: refs/heads/master
Commit: 7ee61f84d71f707f297d6a959fd74dfa1a9dd072
Parents: 9c82e61
Author: Todd Lipcon <todd@apache.org>
Authored: Fri Aug 5 14:52:09 2016 -0700
Committer: Todd Lipcon <todd@apache.org>
Committed: Sun Aug 7 03:56:26 2016 +0000

----------------------------------------------------------------------
 docs/design-docs/README.md                      |  2 +-
 docs/design-docs/raft-config-change.md          | 24 +++++-----
 docs/design-docs/raft-remote-bootstrap.md       | 46 +++++++++----------
 docs/whitepaper/kudu.tex                        |  4 +-
 src/kudu/consensus/consensus.proto              | 10 ++--
 src/kudu/consensus/consensus_peers.cc           | 26 +++++------
 src/kudu/consensus/consensus_peers.h            |  4 +-
 src/kudu/consensus/consensus_queue-test.cc      | 18 ++++----
 src/kudu/consensus/consensus_queue.cc           |  8 ++--
 src/kudu/consensus/consensus_queue.h            |  2 +-
 .../integration-tests/cluster_itest_util.cc     | 14 +++---
 src/kudu/integration-tests/cluster_itest_util.h |  4 +-
 src/kudu/integration-tests/delete_table-test.cc | 44 +++++++++---------
 .../integration-tests/remote_bootstrap-itest.cc | 48 ++++++++++----------
 .../tablet_replacement-itest.cc                 |  4 +-
 src/kudu/tablet/metadata.proto                  |  6 +--
 src/kudu/tablet/tablet_bootstrap.cc             |  2 +-
 src/kudu/tserver/remote_bootstrap_client.cc     | 22 ++++-----
 src/kudu/tserver/remote_bootstrap_client.h      |  2 +-
 src/kudu/tserver/remote_bootstrap_service.cc    |  8 ++--
 src/kudu/tserver/ts_tablet_manager.cc           | 36 +++++++--------
 21 files changed, 167 insertions(+), 167 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/docs/design-docs/README.md
----------------------------------------------------------------------
diff --git a/docs/design-docs/README.md b/docs/design-docs/README.md
index 429ea4f..3943689 100644
--- a/docs/design-docs/README.md
+++ b/docs/design-docs/README.md
@@ -26,7 +26,7 @@ made.
 | [Codegen API and impl. details](codegen.md) | Server | N/A |
 | [Consensus design](consensus.md) | Consensus | N/A |
 | [Raft config change design](raft-config-change.md) | Consensus | N/A |
-| [Raft tablet copy design](raft-remote-bootstrap.md) | Consensus | N/A |
+| [Tablet Copy design](raft-remote-bootstrap.md) | Consensus | N/A |
 | [Master design](master.md) | Master | N/A |
 | [RPC design and impl. details](rpc.md) | RPC | N/A |
 | [Tablet design, impl. details and comparison to other systems](tablet.md) | Tablet | N/A |

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/docs/design-docs/raft-config-change.md
----------------------------------------------------------------------
diff --git a/docs/design-docs/raft-config-change.md b/docs/design-docs/raft-config-change.md
index 899c72d..d598832 100644
--- a/docs/design-docs/raft-config-change.md
+++ b/docs/design-docs/raft-config-change.md
@@ -68,15 +68,15 @@ in [2].
 This process is executed by a driver, which may be a client program or the
 Master. We’ll say the node to be added to the cluster is named `new_node`.
 
-1. Driver initiates execution of tablet copy procedure of `new_node` from
-   the current leader `bootstrap_source` using an RPC call to the `new_node`.
+1. Driver initiates execution of Tablet Copy procedure of `new_node` from
+   the current leader `copy_source` using an RPC call to the `new_node`.
    Tablet Copy runs to completion, which means all data and logs at the
-   time tablet copy was initiated were replicated to `new_node`. Driver
-   polls `new_node` for indication that the tablet copy process is
+   time the Tablet Copy was initiated were replicated to `new_node`. Driver
+   polls `new_node` for indication that the Tablet Copy process is
    complete.
    <br>
-   If the `bootstrap_source` node crashes before tablet copy is complete,
-   the bootstrap fails and the driver must start the entire process over from
+   If the `copy_source` node crashes before Tablet Copy is complete,
+   the copy fails and the driver must start the entire process over from
    the beginning. If the driver or `new_node` crashes and the tablet never
    joins the configuration, the Master should eventually delete the abandoned
    tablet replica from `new_node`.
@@ -95,7 +95,7 @@ Master. We’ll say the node to be added to the cluster is named `new_node`.
 3. As soon as a replica receives the ConfigChangeRequest it applies the
    configuration change in-memory. It does not wait for commitment to apply the
    change. See rationale in [2] section 4.1.
-4. The tablet copy session between `new_node` and `bootstrap_source` is
+4. The Tablet Copy session between `new_node` and `copy_source` is
    closed once the config change to transition the node to `PRE_FOLLOWER` has
    been committed. This implies releasing an anchor on the log. Since
    `new_node` is already a member of the configuration receiving log updates,
@@ -167,8 +167,8 @@ another doc.
 ### Steps:
 
 1. Run a tool to determine the most up-to-date remaining replica.
-2. Tablet Copy additional nodes from the most up-to-date remaining node.
-   Wait for tablet copy to complete on all the nodes.
+2. Use Tablet Copy to create additional replicas from the most up-to-date remaining
+   replica. Wait for Tablet Copy to complete on all the nodes.
 3. Bring all tablet servers hosting the affected tablet offline (TODO: This is
    possible to implement per-tablet but not currently supported)
 4. Run tool to rewrite the ConsensusMetadata file per-tablet server to
@@ -178,7 +178,7 @@ another doc.
 5. Bring the affected tablets / tablet servers back online.
 6. Pray?
 
-## Appendix: Idea to add a new member before it has bootstrapped all data
+## Appendix: Idea to add a new member before it has copied all data
 
 The idea here is to take advantage of the fact that nodes can participate in
 Raft consensus without actually applying operations to their "state machine"
@@ -213,8 +213,8 @@ Next, we demote the dead replica from LVE to L, so it no longer participates in
 voting. For a server that has just failed, it’s preferable to demote to "L" and
 not completely remove from the configuration, because it’s possible (even
 likely!) it would actually restart before the new replica has finished
-bootstrapping. If it does, we have the option of adding it back to the
-configuration and cancelling the bootstrap.
+copying. If it does, we have the option of adding it back to the
+configuration and cancelling the Tablet Copy.
 
 Because we now have three voting replicas, the majority is 2, so we can handle
 a fault of any of the remaining three nodes. After reaching this state, we can

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/docs/design-docs/raft-remote-bootstrap.md
----------------------------------------------------------------------
diff --git a/docs/design-docs/raft-remote-bootstrap.md b/docs/design-docs/raft-remote-bootstrap.md
index 66c11df..c1c20d7 100644
--- a/docs/design-docs/raft-remote-bootstrap.md
+++ b/docs/design-docs/raft-remote-bootstrap.md
@@ -12,19 +12,19 @@ See the License for the specific language governing permissions and
 limitations under the License.
 -->
 
-# Kudu tablet copy design
+# Kudu Tablet Copy design
 
-Master & tablet copy integration with configuration change
+Master & Tablet Copy integration with configuration change
 
 ## Summary
 
-This document contains information on implementing tablet copy in the
+This document contains information on implementing Tablet Copy in the
 context of Kudu's Raft implementation. Details on Raft config change in Kudu
 can be found in the [Raft config change design doc](raft-config-change.md).
 
 ## Goals
 
-1. Integrate tablet copy to allow for copying over "snapshotted" data and
+1. Integrate Tablet Copy to allow for copying over "snapshotted" data and
    logs to a tablet replica when logs from the "beginning of time" are no
    longer available for replay.
 2. The Master needs to tolerate and facilitate dynamic consensus config change.
@@ -38,24 +38,24 @@ The Master will expose the following operations to admin users:
 1. `AddReplica(tablet_id, TS to_add, Role role)`
 2. `RemoveReplica(tablet_id, TS to_remove)`
 
-### New tablet server tablet copy RPC
+### New tablet server Tablet Copy RPC
 
 Tablet Copy allows a tablet snapshot to be moved to a new server. A
 `StartTabletCopy()` RPC call will be available on each tablet server. When a
 leader determines that a follower needs log entries prior to what is available
 on the leader side, or when it detects that a follower does not host a given
 tablet, it sends the follower an RPC to instruct the follower to initiate
-tablet copy. Optionally, this callback is made idempotent by passing the
+Tablet Copy. Optionally, this callback is made idempotent by passing the
 latest OpId in the follower's log as an argument.
 
-### Management of tablet copy jobs
+### Management of Tablet Copy jobs
 
-Since copying a tablet may involve copying many GB of data, we
-likely need to support operational visibility into ongoing tablet copy
+Since copying a tablet may involve transferring many GB of data, we
+likely need to support operational visibility into ongoing Tablet Copy
 jobs, run them on their own thread pool, support cancellation, etc. TBD to
 enumerate all of this in detail.
 
-## Design & implementation of tablet tablet copy
+## Design & implementation of Tablet Copy
 
 ### Tablet auto-vivification
 
@@ -89,17 +89,17 @@ losing data that was guaranteed to be persisted according to the consensus
 protocol. That situation is described in detail in this [raft-dev mailing list
 thread](https://groups.google.com/d/msg/raft-dev/CL1qWP7a_1w/OfHqmbcbIlAJ).
 
-To safely support deletion and tablet copy, a tablet will have 4 states
+To safely support deletion and Tablet Copy, a tablet will have 4 states
 its data can be in: `DOES_NOT_EXIST` (implicit; just the non-existence of state),
 `DELETED`, `COPYING`, and `READY`. `DOES_NOT_EXIST` just means a tablet with that name
 has never been hosted on the server, `DELETED` means it's tombstoned, `COPYING`
-means it's in the process of tablet copyping, and `READY` means it's in a
+means it's in the process of Tablet Copying, and `READY` means it's in a
 normal, consistent state. More details about Tablet Deletion is in a later
 section.
 
-### Auto-vivifying tablet copy protocol
+### Auto-vivifying Tablet Copy protocol
 
-The tablet copy protocol between the leader and follower is as follows.
+The Tablet Copy protocol between the leader and follower is as follows.
 The leader always starts attempting to heartbeat to the follower:
 
 Leader -> Follower: `AppendEntries(from, to, term, prev_idx, ops[])`
@@ -127,7 +127,7 @@ exist. Roughly:
 ```
 StartTabletCopy(from, to, tablet, current_state, last_opid_in_log = NULL):
   if (to != self.uuid): ERR_INVALID_NAME
-  if (this.tablet.state == COPYING): ERR_ALREADY_BOOTSTRAPPING
+  if (this.tablet.state == COPYING): ERR_ALREADY_INPROGRESS
   if (this.tablet.state != current_state): ERR_ILLEGAL_STATE
   if (this.tablet.state == RUNNING):
     DeleteTablet() # Quarantine the tablet data.
@@ -199,11 +199,11 @@ We can safely implement tablet deletion using the following steps:
    not stripe the WAL. If we were to stripe or multiplex the WAL in the future,
    we could add some kind of tablet-level sequence number, like a generation
    number, that gets incremented at the SuperBlock level when we initiate
-   tablet copy. That should keep us pointed at the relevant entries.
+   Tablet Copy. That should keep us pointed at the relevant entries.
 
-### Follower tablet copy
+### Follower Tablet Copy
 
-Remotely bootstrapping a tablet copies the data from the remote; merges the new
+Tablet Copy copies the data from the remote; merges the new
 and old consensus metadata files (if a local one already existed; otherwise the
 remote metadata is adopted); and writes a replacement SuperBlock.
 
@@ -217,7 +217,7 @@ remote metadata is adopted); and writes a replacement SuperBlock.
 3. Download remote WALs.
 4. Download remote blocks.
 5. Write replacement SuperBlock in `READY` state and fsync it.
-6. Start up the newly bootstrapped tablet.
+6. Start up the new tablet replica.
 
 ### Consensus metadata merge
 
@@ -279,8 +279,8 @@ also rejected (that behavior is already implemented).
 
 ### Failure of a disk with consensus metadata is a catastrophic failure
 
-If we lose a disk with consensus metadata or WALs, and would need to remotely
-bootstrap to recover, it may be impossible to do so safely due to unavoidable
+If we lose a disk with consensus metadata or WALs, and would need to copy a
+new replica to recover, it may be impossible to do so safely due to unavoidable
 consensus amnesia. In such a case, the tablet server must adopt a new UUID and
 fully clear all of its data and state:
 
@@ -315,8 +315,8 @@ possible to do as long as we retain consensus metadata indefinitely, which is
 required for correctness anyway. However this is not a top priority.
 
 One scenario where a `DELETED` tablet may need to vote to make forward progress
-is if a `VOTER` replica falls behind and so starts to tablet copy, crashes
-in the middle of tablet copy, and deletes itself at startup. Once we
+is if a `VOTER` replica falls behind and so starts to Tablet Copy, crashes
+in the middle of Tablet Copy, and deletes itself at startup. Once we
 implement `PRE_VOTER`, and always catch up as a `PRE_VOTER` before becoming a
 `VOTER`, the opportunity for potential problems with `VOTER`s is reduced a lot,
 especially around the initial step of adding a server to the cluster, but still

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/docs/whitepaper/kudu.tex
----------------------------------------------------------------------
diff --git a/docs/whitepaper/kudu.tex b/docs/whitepaper/kudu.tex
index 7cf9e90..f96e0d5 100644
--- a/docs/whitepaper/kudu.tex
+++ b/docs/whitepaper/kudu.tex
@@ -363,7 +363,7 @@ by at most one in each configuration change. In order to grow a 3-replica config
 replicas, two separate configuration changes (3$\rightarrow$4, 4$\rightarrow$5) must be proposed
 and committed.
 
-Kudu implements the addition of new servers through a process called {\em tablet copy}.
+Kudu implements the addition of new servers through a process called {\em Tablet Copy}.
 In our design, in order to add a new replica, we first add it as a new member in the
 Raft configuration, even before notifying the destination server that a new replica will
 be copied to it. When this configuration change has been committed, the current Raft leader
@@ -378,7 +378,7 @@ In our current implementation, new servers are added immediately as {\tt VOTER}
 the disadvantage that, after moving from a 3-server configuration to a 4-server configuration, three
 out of the four servers must acknowledge each operation. Because the new server is in the process of
 copying, it is unable to acknowledge operations. If another server were to crash during the
-snapshot-transfer process, the tablet would become unavailable for writes until the tablet copy
+snapshot-transfer process, the tablet would become unavailable for writes until the Tablet Copy
 finished.
 
 To address this issue, we plan to implement a {\tt PRE\_VOTER} replica state. In this

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/consensus/consensus.proto
----------------------------------------------------------------------
diff --git a/src/kudu/consensus/consensus.proto b/src/kudu/consensus/consensus.proto
index 3c18f84..5091c3c 100644
--- a/src/kudu/consensus/consensus.proto
+++ b/src/kudu/consensus/consensus.proto
@@ -457,10 +457,10 @@ message StartTabletCopyRequestPB {
 
   required bytes tablet_id = 1;
 
-  // Identification for the host we are bootstrapping from.
-  // TODO: Consider renaming these to bootstrap_source_*.
-  required bytes bootstrap_peer_uuid = 2;
-  required HostPortPB bootstrap_peer_addr = 3;
+  // Identification for the host we are copying from.
+  // TODO: Consider renaming these to copy_source_*.
+  required bytes copy_peer_uuid = 2;
+  required HostPortPB copy_peer_addr = 3;
 
   // The caller's term. In the case that the target of this request has a
   // TOMBSTONED replica with a term higher than this one, the request will fail.
@@ -498,6 +498,6 @@ service ConsensusService {
   // Returns the committed Consensus state.
   rpc GetConsensusState(GetConsensusStateRequestPB) returns (GetConsensusStateResponsePB);
 
-  // Instruct this server to remotely bootstrap a tablet from another host.
+  // Instruct this server to copy a tablet from another host.
   rpc StartTabletCopy(StartTabletCopyRequestPB) returns (StartTabletCopyResponsePB);
 }

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/consensus/consensus_peers.cc
----------------------------------------------------------------------
diff --git a/src/kudu/consensus/consensus_peers.cc b/src/kudu/consensus/consensus_peers.cc
index 2d4fa6c..6ab83ce 100644
--- a/src/kudu/consensus/consensus_peers.cc
+++ b/src/kudu/consensus/consensus_peers.cc
@@ -61,10 +61,10 @@ DEFINE_double(fault_crash_after_leader_request_fraction, 0.0,
 TAG_FLAG(fault_crash_on_leader_request_fraction, unsafe);
 
 
-// Allow for disabling tablet copy in unit tests where we want to test
+// Allow for disabling Tablet Copy in unit tests where we want to test
 // certain scenarios without triggering bootstrap of a remote peer.
 DEFINE_bool(enable_tablet_copy, true,
-            "Whether tablet copy will be initiated by the leader when it "
+            "Whether Tablet Copy will be initiated by the leader when it "
             "detects that a follower is out of date or does not have a tablet "
             "replica. For testing purposes only.");
 TAG_FLAG(enable_tablet_copy, unsafe);
@@ -192,7 +192,7 @@ void Peer::SendNextRequest(bool even_if_queue_empty) {
   if (PREDICT_FALSE(needs_tablet_copy)) {
     Status s = SendTabletCopyRequest();
     if (!s.ok()) {
-      LOG_WITH_PREFIX_UNLOCKED(WARNING) << "Unable to generate tablet copy request for peer: "
+      LOG_WITH_PREFIX_UNLOCKED(WARNING) << "Unable to generate Tablet Copy request for peer: "
                                         << s.ToString();
       sem_.Release();
     }
@@ -251,7 +251,7 @@ void Peer::ProcessResponse() {
   }
 
   // Pass through errors we can respond to, like not found, since in that case
-  // we will need to remotely bootstrap. TODO: Handle DELETED response once implemented.
+  // we will need to start a Tablet Copy. TODO: Handle DELETED response once implemented.
   if ((response_.has_error() &&
       response_.error().code() != TabletServerErrorPB::TABLET_NOT_FOUND) ||
       (response_.status().has_error() &&
@@ -297,26 +297,26 @@ void Peer::DoProcessResponse() {
 Status Peer::SendTabletCopyRequest() {
   if (!FLAGS_enable_tablet_copy) {
     failed_attempts_++;
-    return Status::NotSupported("tablet copy is disabled");
+    return Status::NotSupported("Tablet Copy is disabled");
   }
 
-  LOG_WITH_PREFIX_UNLOCKED(INFO) << "Sending request to remotely bootstrap";
-  RETURN_NOT_OK(queue_->GetTabletCopyRequestForPeer(peer_pb_.permanent_uuid(), &rb_request_));
+  LOG_WITH_PREFIX_UNLOCKED(INFO) << "Sending request to start Tablet Copy";
+  RETURN_NOT_OK(queue_->GetTabletCopyRequestForPeer(peer_pb_.permanent_uuid(), &tc_request_));
   controller_.Reset();
-  proxy_->StartTabletCopy(&rb_request_, &rb_response_, &controller_,
-                               boost::bind(&Peer::ProcessTabletCopyResponse, this));
+  proxy_->StartTabletCopy(&tc_request_, &tc_response_, &controller_,
+                          boost::bind(&Peer::ProcessTabletCopyResponse, this));
   return Status::OK();
 }
 
 void Peer::ProcessTabletCopyResponse() {
-  if (controller_.status().ok() && rb_response_.has_error()) {
+  if (controller_.status().ok() && tc_response_.has_error()) {
     // ALREADY_INPROGRESS is expected, so we do not log this error.
-    if (rb_response_.error().code() ==
+    if (tc_response_.error().code() ==
         TabletServerErrorPB::TabletServerErrorPB::ALREADY_INPROGRESS) {
       queue_->NotifyPeerIsResponsiveDespiteError(peer_pb_.permanent_uuid());
     } else {
-      LOG_WITH_PREFIX_UNLOCKED(WARNING) << "Unable to begin tablet copy on peer: "
-                                        << rb_response_.ShortDebugString();
+      LOG_WITH_PREFIX_UNLOCKED(WARNING) << "Unable to begin Tablet Copy on peer: "
+                                        << tc_response_.ShortDebugString();
     }
   }
   sem_.Release();

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/consensus/consensus_peers.h
----------------------------------------------------------------------
diff --git a/src/kudu/consensus/consensus_peers.h b/src/kudu/consensus/consensus_peers.h
index f676c4c..286209b 100644
--- a/src/kudu/consensus/consensus_peers.h
+++ b/src/kudu/consensus/consensus_peers.h
@@ -192,8 +192,8 @@ class Peer {
   ConsensusResponsePB response_;
 
   // The latest tablet copy request and response.
-  StartTabletCopyRequestPB rb_request_;
-  StartTabletCopyResponsePB rb_response_;
+  StartTabletCopyRequestPB tc_request_;
+  StartTabletCopyResponsePB tc_response_;
 
   // Reference-counted pointers to any ReplicateMsgs which are in-flight to the peer. We
   // may have loaded these messages from the LogCache, in which case we are potentially

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/consensus/consensus_queue-test.cc
----------------------------------------------------------------------
diff --git a/src/kudu/consensus/consensus_queue-test.cc b/src/kudu/consensus/consensus_queue-test.cc
index 204f65f..9f7a20c 100644
--- a/src/kudu/consensus/consensus_queue-test.cc
+++ b/src/kudu/consensus/consensus_queue-test.cc
@@ -774,7 +774,7 @@ TEST_F(ConsensusQueueTest, TestOnlyAdvancesWatermarkWhenPeerHasAPrefixOfOurLog)
   request.mutable_ops()->ExtractSubrange(0, request.ops().size(), nullptr);
 }
 
-// Test that tablet copy is triggered when a "tablet not found" error occurs.
+// Test that Tablet Copy is triggered when a "tablet not found" error occurs.
 TEST_F(ConsensusQueueTest, TestTriggerTabletCopyIfTabletNotFound) {
   queue_->Init(MinimumOpId());
   queue_->SetLeaderMode(MinimumOpId(), MinimumOpId().term(), BuildRaftConfigPBForTests(3));
@@ -797,22 +797,22 @@ TEST_F(ConsensusQueueTest, TestTriggerTabletCopyIfTabletNotFound) {
   bool more_pending = false;
   queue_->ResponseFromPeer(kPeerUuid, response, &more_pending);
 
-  // If the peer needs tablet copy, more_pending should be set to true.
+  // If the peer needs Tablet Copy, more_pending should be set to true.
   ASSERT_TRUE(more_pending);
 
-  // On the next request, we should find out that the queue wants us to remotely bootstrap.
+  // On the next request, we should find out that the queue wants us to initiate Tablet Copy.
   request.Clear();
   ASSERT_OK(queue_->RequestForPeer(kPeerUuid, &request, &refs, &needs_tablet_copy));
   ASSERT_TRUE(needs_tablet_copy);
 
-  StartTabletCopyRequestPB rb_req;
-  ASSERT_OK(queue_->GetTabletCopyRequestForPeer(kPeerUuid, &rb_req));
+  StartTabletCopyRequestPB tc_req;
+  ASSERT_OK(queue_->GetTabletCopyRequestForPeer(kPeerUuid, &tc_req));
 
-  ASSERT_TRUE(rb_req.IsInitialized()) << rb_req.ShortDebugString();
-  ASSERT_EQ(kTestTablet, rb_req.tablet_id());
-  ASSERT_EQ(kLeaderUuid, rb_req.bootstrap_peer_uuid());
+  ASSERT_TRUE(tc_req.IsInitialized()) << tc_req.ShortDebugString();
+  ASSERT_EQ(kTestTablet, tc_req.tablet_id());
+  ASSERT_EQ(kLeaderUuid, tc_req.copy_peer_uuid());
   ASSERT_EQ(FakeRaftPeerPB(kLeaderUuid).last_known_addr().ShortDebugString(),
-            rb_req.bootstrap_peer_addr().ShortDebugString());
+            tc_req.copy_peer_addr().ShortDebugString());
 }
 
 }  // namespace consensus

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/consensus/consensus_queue.cc
----------------------------------------------------------------------
diff --git a/src/kudu/consensus/consensus_queue.cc b/src/kudu/consensus/consensus_queue.cc
index 83039a5..e32b153 100644
--- a/src/kudu/consensus/consensus_queue.cc
+++ b/src/kudu/consensus/consensus_queue.cc
@@ -401,13 +401,13 @@ Status PeerMessageQueue::GetTabletCopyRequestForPeer(const string& uuid,
   }
 
   if (PREDICT_FALSE(!peer->needs_tablet_copy)) {
-    return Status::IllegalState("Peer does not need to remotely bootstrap", uuid);
+    return Status::IllegalState("Peer does not need to initiate Tablet Copy", uuid);
   }
   req->Clear();
   req->set_dest_uuid(uuid);
   req->set_tablet_id(tablet_id_);
-  req->set_bootstrap_peer_uuid(local_peer_pb_.permanent_uuid());
-  *req->mutable_bootstrap_peer_addr() = local_peer_pb_.last_known_addr();
+  req->set_copy_peer_uuid(local_peer_pb_.permanent_uuid());
+  *req->mutable_copy_peer_addr() = local_peer_pb_.last_known_addr();
   req->set_caller_term(queue_state_.current_term);
   peer->needs_tablet_copy = false; // Now reset the flag.
   return Status::OK();
@@ -493,7 +493,7 @@ void PeerMessageQueue::ResponseFromPeer(const std::string& peer_uuid,
       return;
     }
 
-    // Remotely bootstrap the peer if the tablet is not found or deleted.
+    // Initiate Tablet Copy on the peer if the tablet is not found or deleted.
     if (response.has_error()) {
       // We only let special types of errors through to this point from the peer.
       CHECK_EQ(tserver::TabletServerErrorPB::TABLET_NOT_FOUND, response.error().code())

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/consensus/consensus_queue.h
----------------------------------------------------------------------
diff --git a/src/kudu/consensus/consensus_queue.h b/src/kudu/consensus/consensus_queue.h
index bba6d41..590adf5 100644
--- a/src/kudu/consensus/consensus_queue.h
+++ b/src/kudu/consensus/consensus_queue.h
@@ -196,7 +196,7 @@ class PeerMessageQueue {
                                 bool* needs_tablet_copy);
 
   // Fill in a StartTabletCopyRequest for the specified peer.
-  // If that peer should not remotely bootstrap, returns a non-OK status.
+  // If that peer should not initiate Tablet Copy, returns a non-OK status.
   // On success, also internally resets peer->needs_tablet_copy to false.
   virtual Status GetTabletCopyRequestForPeer(const std::string& uuid,
                                                   StartTabletCopyRequestPB* req);

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/integration-tests/cluster_itest_util.cc
----------------------------------------------------------------------
diff --git a/src/kudu/integration-tests/cluster_itest_util.cc b/src/kudu/integration-tests/cluster_itest_util.cc
index e9306c6..9254c88 100644
--- a/src/kudu/integration-tests/cluster_itest_util.cc
+++ b/src/kudu/integration-tests/cluster_itest_util.cc
@@ -775,11 +775,11 @@ Status DeleteTablet(const TServerDetails* ts,
 }
 
 Status StartTabletCopy(const TServerDetails* ts,
-                            const string& tablet_id,
-                            const string& bootstrap_source_uuid,
-                            const HostPort& bootstrap_source_addr,
-                            int64_t caller_term,
-                            const MonoDelta& timeout) {
+                       const string& tablet_id,
+                       const string& copy_source_uuid,
+                       const HostPort& copy_source_addr,
+                       int64_t caller_term,
+                       const MonoDelta& timeout) {
   consensus::StartTabletCopyRequestPB req;
   consensus::StartTabletCopyResponsePB resp;
   RpcController rpc;
@@ -787,8 +787,8 @@ Status StartTabletCopy(const TServerDetails* ts,
 
   req.set_dest_uuid(ts->uuid());
   req.set_tablet_id(tablet_id);
-  req.set_bootstrap_peer_uuid(bootstrap_source_uuid);
-  RETURN_NOT_OK(HostPortToPB(bootstrap_source_addr, req.mutable_bootstrap_peer_addr()));
+  req.set_copy_peer_uuid(copy_source_uuid);
+  RETURN_NOT_OK(HostPortToPB(copy_source_addr, req.mutable_copy_peer_addr()));
   req.set_caller_term(caller_term);
 
   RETURN_NOT_OK(ts->consensus_proxy->StartTabletCopy(req, &resp, &rpc));

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/integration-tests/cluster_itest_util.h
----------------------------------------------------------------------
diff --git a/src/kudu/integration-tests/cluster_itest_util.h b/src/kudu/integration-tests/cluster_itest_util.h
index 5ba3a8d..00f2229 100644
--- a/src/kudu/integration-tests/cluster_itest_util.h
+++ b/src/kudu/integration-tests/cluster_itest_util.h
@@ -292,8 +292,8 @@ Status DeleteTablet(const TServerDetails* ts,
 // source.
 Status StartTabletCopy(const TServerDetails* ts,
                             const std::string& tablet_id,
-                            const std::string& bootstrap_source_uuid,
-                            const HostPort& bootstrap_source_addr,
+                            const std::string& copy_source_uuid,
+                            const HostPort& copy_source_addr,
                             int64_t caller_term,
                             const MonoDelta& timeout);
 

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/integration-tests/delete_table-test.cc
----------------------------------------------------------------------
diff --git a/src/kudu/integration-tests/delete_table-test.cc b/src/kudu/integration-tests/delete_table-test.cc
index 272efed..e23647a 100644
--- a/src/kudu/integration-tests/delete_table-test.cc
+++ b/src/kudu/integration-tests/delete_table-test.cc
@@ -115,7 +115,7 @@ class DeleteTableTest : public ExternalMiniClusterITestBase {
 
   // Repeatedly try to delete the tablet, retrying on failure up to the
   // specified timeout. Deletion can fail when other operations, such as
-  // bootstrap, are running.
+  // bootstrap or tablet copy, are running.
   void DeleteTabletWithRetries(const TServerDetails* ts, const string& tablet_id,
                                TabletDataState delete_type, const MonoDelta& timeout);
 };
@@ -413,13 +413,13 @@ TEST_F(DeleteTableTest, TestDeleteTableWithConcurrentWrites) {
 }
 
 // Test that a tablet replica is automatically tombstoned on startup if a local
-// crash occurs in the middle of tablet copy.
+// crash occurs in the middle of Tablet Copy.
 TEST_F(DeleteTableTest, TestAutoTombstoneAfterCrashDuringTabletCopy) {
   NO_FATALS(StartCluster());
   const MonoDelta timeout = MonoDelta::FromSeconds(10);
   const int kTsIndex = 0; // We'll test with the first TS.
 
-  // We'll do a config change to tablet copy a replica here later. For
+  // We'll do a config change to Tablet Copy a replica here later. For
   // now, shut it down.
   LOG(INFO) << "Shutting down TS " << cluster_->tablet_server(kTsIndex)->uuid();
   cluster_->tablet_server(kTsIndex)->Shutdown();
@@ -442,12 +442,12 @@ TEST_F(DeleteTableTest, TestAutoTombstoneAfterCrashDuringTabletCopy) {
   }
   workload.StopAndJoin();
 
-  // Enable a fault crash when tablet copy occurs on TS 0.
+  // Enable a fault crash when Tablet Copy occurs on TS 0.
   ASSERT_OK(cluster_->tablet_server(kTsIndex)->Restart());
-  const string& kFaultFlag = "fault_crash_after_rb_files_fetched";
+  const string& kFaultFlag = "fault_crash_after_tc_files_fetched";
   ASSERT_OK(cluster_->SetFlag(cluster_->tablet_server(kTsIndex), kFaultFlag, "1.0"));
 
-  // Figure out the tablet id to tablet copy.
+  // Figure out the tablet id to Tablet Copy.
   vector<string> tablets = inspect_->ListTabletsOnTS(1);
   ASSERT_EQ(1, tablets.size());
   const string& tablet_id = tablets[0];
@@ -462,12 +462,12 @@ TEST_F(DeleteTableTest, TestAutoTombstoneAfterCrashDuringTabletCopy) {
   // The superblock should be in TABLET_DATA_COPYING state on disk.
   NO_FATALS(inspect_->CheckTabletDataStateOnTS(kTsIndex, tablet_id, { TABLET_DATA_COPYING }));
 
-  // Kill the other tablet servers so the leader doesn't try to remote
-  // bootstrap it again during our verification here.
+  // Kill the other tablet servers so the leader doesn't try to Tablet Copy
+  // it again during our verification here.
   cluster_->tablet_server(1)->Shutdown();
   cluster_->tablet_server(2)->Shutdown();
 
-  // Now we restart the TS. It will clean up the failed tablet copy and
+  // Now we restart the TS. It will clean up the failed Tablet Copy and
   // convert it to TABLET_DATA_TOMBSTONED. It crashed, so we have to call
   // Shutdown() then Restart() to bring it back up.
   cluster_->tablet_server(kTsIndex)->Shutdown();
@@ -476,8 +476,8 @@ TEST_F(DeleteTableTest, TestAutoTombstoneAfterCrashDuringTabletCopy) {
 }
 
 // Test that a tablet replica automatically tombstones itself if the remote
-// bootstrap source server fails in the middle of the tablet copy process.
-// Also test that we can remotely bootstrap a tombstoned tablet.
+// server fails in the middle of the Tablet Copy process.
+// Also test that we can Copy Tablet over a tombstoned tablet.
 TEST_F(DeleteTableTest, TestAutoTombstoneAfterTabletCopyRemoteFails) {
   vector<string> ts_flags = {
       "--enable_leader_failure_detection=false",  // Make test deterministic.
@@ -490,7 +490,7 @@ TEST_F(DeleteTableTest, TestAutoTombstoneAfterTabletCopyRemoteFails) {
   const MonoDelta kTimeout = MonoDelta::FromSeconds(20);
   const int kTsIndex = 0; // We'll test with the first TS.
 
-  // We'll do a config change to tablet copy a replica here later. For
+  // We'll do a config change to Tablet Copy a replica here later. For
   // now, shut down TS-0.
   LOG(INFO) << "Shutting down TS " << cluster_->tablet_server(kTsIndex)->uuid();
   cluster_->tablet_server(kTsIndex)->Shutdown();
@@ -533,8 +533,8 @@ TEST_F(DeleteTableTest, TestAutoTombstoneAfterTabletCopyRemoteFails) {
   ASSERT_OK(inspect_->WaitForMinFilesInTabletWalDirOnTS(kLeaderIndex, tablet_id, 3));
   workload.StopAndJoin();
 
-  // Cause the leader to crash when a follower tries to remotely bootstrap from it.
-  const string& fault_flag = "fault_crash_on_handle_rb_fetch_data";
+  // Cause the leader to crash when a follower tries to initiate Tablet Copy from it.
+  const string& fault_flag = "fault_crash_on_handle_tc_fetch_data";
   ASSERT_OK(cluster_->SetFlag(cluster_->tablet_server(kLeaderIndex), fault_flag, "1.0"));
 
   // Add TS-0 as a new member to the config and wait for the leader to crash.
@@ -552,7 +552,7 @@ TEST_F(DeleteTableTest, TestAutoTombstoneAfterTabletCopyRemoteFails) {
   NO_FATALS(WaitForTabletTombstonedOnTS(kTsIndex, tablet_id, CMETA_NOT_EXPECTED));
 
   // Now bring the other replicas back, re-elect the previous leader (TS-1),
-  // and wait for the leader to tablet copy the tombstoned replica. This
+  // and wait for the leader to Tablet Copy the tombstoned replica. This
   // will have replaced a tablet with no consensus metadata.
   ASSERT_OK(cluster_->tablet_server(1)->Restart());
   ASSERT_OK(cluster_->tablet_server(2)->Restart());
@@ -573,7 +573,7 @@ TEST_F(DeleteTableTest, TestAutoTombstoneAfterTabletCopyRemoteFails) {
   ASSERT_OK(itest::DeleteTablet(ts, tablet_id, TABLET_DATA_TOMBSTONED, boost::none, kTimeout));
   NO_FATALS(WaitForTabletTombstonedOnTS(kTsIndex, tablet_id, CMETA_NOT_EXPECTED));
 
-  // Bring them back again, let them yet again bootstrap our tombstoned replica.
+  // Bring them back again, let them yet again Copy a new replica on top of our tombstoned replica.
   // This time, the leader will have replaced a tablet with consensus metadata.
   ASSERT_OK(cluster_->tablet_server(1)->Resume());
   ASSERT_OK(cluster_->tablet_server(2)->Resume());
@@ -584,7 +584,7 @@ TEST_F(DeleteTableTest, TestAutoTombstoneAfterTabletCopyRemoteFails) {
                             workload.rows_inserted()));
 }
 
-// Test for correct tablet copy merge of consensus metadata.
+// Test for correct Tablet Copy merge of consensus metadata.
 TEST_F(DeleteTableTest, TestMergeConsensusMetadata) {
   // Enable manual leader selection.
   vector<string> ts_flags, master_flags;
@@ -598,7 +598,7 @@ TEST_F(DeleteTableTest, TestMergeConsensusMetadata) {
   workload.Setup();
   ASSERT_OK(inspect_->WaitForReplicaCount(3));
 
-  // Figure out the tablet id to tablet copy.
+  // Figure out the tablet id to Tablet Copy.
   vector<string> tablets = inspect_->ListTabletsOnTS(1);
   ASSERT_EQ(1, tablets.size());
   const string& tablet_id = tablets[0];
@@ -658,7 +658,7 @@ TEST_F(DeleteTableTest, TestMergeConsensusMetadata) {
   ASSERT_OK(itest::WaitUntilLeader(leader, tablet_id, timeout));
 
   // Bring our special little guy back up.
-  // Wait until he gets tablet copyped.
+  // Wait until he gets Tablet Copied.
   LOG(INFO) << "Bringing TS " << cluster_->tablet_server(kTsIndex)->uuid()
             << " back up...";
   ASSERT_OK(cluster_->tablet_server(kTsIndex)->Restart());
@@ -672,7 +672,7 @@ TEST_F(DeleteTableTest, TestMergeConsensusMetadata) {
   // Now do the same thing as above, where we tombstone TS 0 then trigger a new
   // term (term 3) on the other machines. TS 0 will get copied
   // again, but this time the vote record on TS 0 for term 2 should not be
-  // retained after tablet copy occurs.
+  // retained after Tablet Copy occurs.
   cluster_->tablet_server(1)->Shutdown();
   cluster_->tablet_server(2)->Shutdown();
 
@@ -811,7 +811,7 @@ TEST_F(DeleteTableTest, TestOrphanedBlocksClearedOnDelete) {
       << "Timed out waiting for rowset flush on TS " << follower_ts->uuid() << ": "
       << "Superblock:\n" << superblock_pb.DebugString();
 
-  // Shut down the leader so it doesn't try to bootstrap our follower later.
+  // Shut down the leader so it doesn't try to copy a new replica to our follower later.
   workload.StopAndJoin();
   cluster_->tablet_server(kLeaderIndex)->Shutdown();
 
@@ -1047,7 +1047,7 @@ TEST_P(DeleteTableTombstonedParamTest, TestTabletTombstone) {
   workload.StopAndJoin();
 
   // Shut down the master and the other tablet servers so they don't interfere
-  // by attempting to create tablets or tablet copy while we delete tablets.
+  // by attempting to create or copy tablets while we delete tablets.
   cluster_->master()->Shutdown();
   cluster_->tablet_server(1)->Shutdown();
   cluster_->tablet_server(2)->Shutdown();

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/integration-tests/remote_bootstrap-itest.cc
----------------------------------------------------------------------
diff --git a/src/kudu/integration-tests/remote_bootstrap-itest.cc b/src/kudu/integration-tests/remote_bootstrap-itest.cc
index 0ada5fc..ec854bc 100644
--- a/src/kudu/integration-tests/remote_bootstrap-itest.cc
+++ b/src/kudu/integration-tests/remote_bootstrap-itest.cc
@@ -127,9 +127,9 @@ void TabletCopyITest::StartCluster(const vector<string>& extra_tserver_flags,
   ASSERT_OK(cluster_->CreateClient(builder, &client_));
 }
 
-// If a rogue (a.k.a. zombie) leader tries to tablet copy a tombstoned
-// tablet, make sure its term isn't older than the latest term we observed.
-// If it is older, make sure we reject the request, to avoid allowing old
+// If a rogue (a.k.a. zombie) leader tries to replace a tombstoned
+// tablet via Tablet Copy, make sure its term isn't older than the latest term
+// we observed. If it is older, make sure we reject the request, to avoid allowing old
 // leaders to create a parallel universe. This is possible because config
 // change could cause nodes to move around. The term check is reasonable
 // because only one node can be elected leader for a given term.
@@ -177,7 +177,7 @@ TEST_F(TabletCopyITest, TestRejectRogueLeader) {
 
   ASSERT_OK(WaitForServersToAgree(timeout, ts_map_, tablet_id, workload.batches_completed()));
 
-  // Come out of the blue and try to remotely bootstrap a running server while
+  // Come out of the blue and try to initiate Tablet Copy from a running server while
   // specifying an old term. That running server should reject the request.
   // We are essentially masquerading as a rogue leader here.
   Status s = itest::StartTabletCopy(ts, tablet_id, zombie_leader_uuid,
@@ -227,7 +227,7 @@ TEST_F(TabletCopyITest, TestRejectRogueLeader) {
   // Force the rogue leader to step down.
   // Then, send a tablet copy start request from a "fake" leader that
   // sends an up-to-date term in the RB request but the actual term stored
-  // in the bootstrap source's consensus metadata would still be old.
+  // in the copy source's consensus metadata would still be old.
   LOG(INFO) << "Forcing rogue leader T " << tablet_id << " P " << zombie_leader_uuid
             << " to step down...";
   ASSERT_OK(itest::LeaderStepDown(ts_map_[zombie_leader_uuid], tablet_id, timeout));
@@ -252,10 +252,10 @@ TEST_F(TabletCopyITest, TestRejectRogueLeader) {
 }
 
 // Start tablet copy session and delete the tablet in the middle.
-// It should actually be possible to complete bootstrap in such a case, because
-// when a tablet copy session is started on the "source" server, all of
+// It should actually be possible to complete copying in such a case, because
+// when a Tablet Copy session is started on the "source" server, all of
 // the relevant files are either read or opened, meaning that an in-progress
-// tablet copy can complete even after a tablet is officially "deleted" on
+// Tablet Copy can complete even after a tablet is officially "deleted" on
 // the source server. This is also a regression test for KUDU-1009.
 TEST_F(TabletCopyITest, TestDeleteTabletDuringTabletCopy) {
   MonoDelta timeout = MonoDelta::FromSeconds(10);
@@ -292,20 +292,20 @@ TEST_F(TabletCopyITest, TestDeleteTabletDuringTabletCopy) {
 
   {
     // Start up a TabletCopyClient and open a tablet copy session.
-    TabletCopyClient rb_client(tablet_id, fs_manager.get(),
+    TabletCopyClient tc_client(tablet_id, fs_manager.get(),
                                     cluster_->messenger());
     scoped_refptr<tablet::TabletMetadata> meta;
-    ASSERT_OK(rb_client.Start(cluster_->tablet_server(kTsIndex)->bound_rpc_hostport(),
+    ASSERT_OK(tc_client.Start(cluster_->tablet_server(kTsIndex)->bound_rpc_hostport(),
                               &meta));
 
     // Tombstone the tablet on the remote!
     ASSERT_OK(itest::DeleteTablet(ts, tablet_id,
                                   TABLET_DATA_TOMBSTONED, boost::none, timeout));
 
-    // Now finish bootstrapping!
+    // Now finish copying!
     tablet::TabletStatusListener listener(meta);
-    ASSERT_OK(rb_client.FetchAll(&listener));
-    ASSERT_OK(rb_client.Finish());
+    ASSERT_OK(tc_client.FetchAll(&listener));
+    ASSERT_OK(tc_client.Finish());
 
     // Run destructor, which closes the remote session.
   }
@@ -314,7 +314,7 @@ TEST_F(TabletCopyITest, TestDeleteTabletDuringTabletCopy) {
   ASSERT_TRUE(cluster_->tablet_server(kTsIndex)->IsProcessAlive());
 }
 
-// This test ensures that a leader can remote-bootstrap a tombstoned replica
+// This test ensures that a leader can Tablet Copy on top of a tombstoned replica
 // that has a higher term recorded in the replica's consensus metadata if the
 // replica's last-logged opid has the same term (or less) as the leader serving
 // as the tablet copy source. When a tablet is tombstoned, its last-logged
@@ -392,8 +392,8 @@ TEST_F(TabletCopyITest, TestTabletCopyFollowerWithHigherTerm) {
 
 // Test that multiple concurrent tablet copys do not cause problems.
 // This is a regression test for KUDU-951, in which concurrent sessions on
-// multiple tablets between the same tablet copy client host and remote
-// bootstrap source host could corrupt each other.
+// multiple tablets between the same tablet copy client host and source host
+// could corrupt each other.
 TEST_F(TabletCopyITest, TestConcurrentTabletCopys) {
   if (!AllowSlowTests()) {
     LOG(INFO) << "Skipping test in fast-test mode.";
@@ -483,7 +483,7 @@ TEST_F(TabletCopyITest, TestConcurrentTabletCopys) {
                                   MonoDelta::FromSeconds(10)));
   }
 
-  // Unpause the leader TS and wait for it to remotely bootstrap the tombstoned
+  // Unpause the leader TS and wait for it to initiate Tablet Copy and replace the tombstoned
   // tablets, in parallel.
   ASSERT_OK(cluster_->tablet_server(kLeaderIndex)->Resume());
   for (const string& tablet_id : tablet_ids) {
@@ -688,9 +688,9 @@ TEST_F(TabletCopyITest, TestDisableTabletCopy_NoTightLoopWhenTabletDeleted) {
   EXPECT_LT(num_logs_per_second, 20);
 }
 
-// Test that if a tablet copy is taking a long time but the client peer is still responsive,
+// Test that if a Tablet Copy is taking a long time but the client peer is still responsive,
 // the leader won't mark it as failed.
-TEST_F(TabletCopyITest, TestSlowBootstrapDoesntFail) {
+TEST_F(TabletCopyITest, TestSlowCopyDoesntFail) {
   MonoDelta timeout = MonoDelta::FromSeconds(30);
   vector<string> ts_flags, master_flags;
   ts_flags.push_back("--enable_leader_failure_detection=false");
@@ -745,14 +745,14 @@ TEST_F(TabletCopyITest, TestSlowBootstrapDoesntFail) {
                             workload.rows_inserted()));
 }
 
-// Attempting to start tablet copy on a tablet that was deleted with
+// Attempting to start Tablet Copy on a tablet that was deleted with
 // TABLET_DATA_DELETED should fail. This behavior helps avoid thrashing when
 // a follower tablet is deleted and the leader notices before it has processed
 // its own DeleteTablet RPC, thinking that it needs to bring its follower back.
-TEST_F(TabletCopyITest, TestTabletCopypingDeletedTabletFails) {
-  // Delete the leader with TABLET_DATA_DELETED
-  // Attempt to manually bootstrap the leader from a follower
-  // Should get an error saying it's illegal
+TEST_F(TabletCopyITest, TestTabletCopyingDeletedTabletFails) {
+  // Delete the leader with TABLET_DATA_DELETED.
+  // Attempt to manually copy a replica to the leader from a follower.
+  // Should get an error saying it's illegal.
 
   MonoDelta kTimeout = MonoDelta::FromSeconds(30);
   NO_FATALS(StartCluster({"--enable_leader_failure_detection=false"},

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/integration-tests/tablet_replacement-itest.cc
----------------------------------------------------------------------
diff --git a/src/kudu/integration-tests/tablet_replacement-itest.cc b/src/kudu/integration-tests/tablet_replacement-itest.cc
index e12cdef..6962762 100644
--- a/src/kudu/integration-tests/tablet_replacement-itest.cc
+++ b/src/kudu/integration-tests/tablet_replacement-itest.cc
@@ -222,7 +222,7 @@ TEST_F(TabletReplacementITest, TestEvictAndReplaceDeadFollower) {
 // initiating a tablet copy to a follower. The follower will not have the
 // COMMIT for the write operation, so will ignore COMMIT messages for the
 // applied config change operations. At startup time, the newly
-// remotely-bootstrapped tablet should detect that these config change
+// copied tablet should detect that these config change
 // operations have already been applied and skip them.
 TEST_F(TabletReplacementITest, TestRemoteBoostrapWithPendingConfigChangeCommits) {
   if (!AllowSlowTests()) {
@@ -274,7 +274,7 @@ TEST_F(TabletReplacementITest, TestRemoteBoostrapWithPendingConfigChangeCommits)
 
   // Kick off an async insert, which will be delayed for 5 seconds. This is
   // normally enough time to evict a replica, tombstone it, add it back, and
-  // remotely bootstrap it when the log is only a few entries.
+  // Tablet Copy a new replica to it when the log is only a few entries.
   tserver::WriteRequestPB req;
   tserver::WriteResponsePB resp;
   CountDownLatch latch(1);

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/tablet/metadata.proto
----------------------------------------------------------------------
diff --git a/src/kudu/tablet/metadata.proto b/src/kudu/tablet/metadata.proto
index 5fae07a..fc9b9dc 100644
--- a/src/kudu/tablet/metadata.proto
+++ b/src/kudu/tablet/metadata.proto
@@ -53,9 +53,9 @@ enum TabletDataState {
   TABLET_DATA_UNKNOWN = 999;
 
   // The tablet is set to TABLET_DATA_COPYING state when in the middle of
-  // tablet copy while copying data files from a remote peer. If a tablet
-  // server crashes with a tablet in this state, the tablet must be deleted and
-  // the tablet copy process must be restarted for that tablet.
+  // copying data files from a remote peer. If a tablet server crashes with
+  // a tablet in this state, the tablet must be deleted and
+  // the Tablet Copy process must be restarted for that tablet.
   TABLET_DATA_COPYING = 0;
 
   // Fresh empty tablets and successfully copied tablets are set to the

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/tablet/tablet_bootstrap.cc
----------------------------------------------------------------------
diff --git a/src/kudu/tablet/tablet_bootstrap.cc b/src/kudu/tablet/tablet_bootstrap.cc
index 300ac75..abc8813 100644
--- a/src/kudu/tablet/tablet_bootstrap.cc
+++ b/src/kudu/tablet/tablet_bootstrap.cc
@@ -154,7 +154,7 @@ class FlushedStoresSnapshot {
 //
 // NOTE: this does not handle pulling data from other replicas in the cluster. That
 // is handled by the 'TabletCopy' classes, which copy blocks and metadata locally
-// before invoking this local bootstrap functionality.
+// before invoking this local bootstrap functionality to start the tablet.
 //
 // TODO Because the table that is being rebuilt is never flushed/compacted, consensus
 // is only set on the tablet after bootstrap, when we get to flushes/compactions though

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/tserver/remote_bootstrap_client.cc
----------------------------------------------------------------------
diff --git a/src/kudu/tserver/remote_bootstrap_client.cc b/src/kudu/tserver/remote_bootstrap_client.cc
index 85b3942..a7cdde1 100644
--- a/src/kudu/tserver/remote_bootstrap_client.cc
+++ b/src/kudu/tserver/remote_bootstrap_client.cc
@@ -146,20 +146,20 @@ Status TabletCopyClient::SetTabletToReplace(const scoped_refptr<TabletMetadata>&
   return Status::OK();
 }
 
-Status TabletCopyClient::Start(const HostPort& bootstrap_source_addr,
+Status TabletCopyClient::Start(const HostPort& copy_source_addr,
                                     scoped_refptr<TabletMetadata>* meta) {
   CHECK(!started_);
   start_time_micros_ = GetCurrentTimeMicros();
 
   Sockaddr addr;
-  RETURN_NOT_OK(SockaddrFromHostPort(bootstrap_source_addr, &addr));
+  RETURN_NOT_OK(SockaddrFromHostPort(copy_source_addr, &addr));
   if (addr.IsWildcard()) {
     return Status::InvalidArgument("Invalid wildcard address to tablet copy from",
                                    Substitute("$0 (resolved to $1)",
-                                              bootstrap_source_addr.host(), addr.host()));
+                                              copy_source_addr.host(), addr.host()));
   }
   LOG_WITH_PREFIX(INFO) << "Beginning tablet copy session"
-                        << " from remote peer at address " << bootstrap_source_addr.ToString();
+                        << " from remote peer at address " << copy_source_addr.ToString();
 
   // Set up an RPC proxy for the TabletCopyService.
   proxy_.reset(new TabletCopyServiceProxy(messenger_, addr));
@@ -177,10 +177,10 @@ Status TabletCopyClient::Start(const HostPort& bootstrap_source_addr,
   RETURN_NOT_OK_UNWIND_PREPEND(proxy_->BeginTabletCopySession(req, &resp, &controller),
                                controller,
                                "Unable to begin tablet copy session");
-  string bootstrap_peer_uuid = resp.has_responder_uuid()
+  string copy_peer_uuid = resp.has_responder_uuid()
       ? resp.responder_uuid() : "(unknown uuid)";
   if (resp.superblock().tablet_data_state() != tablet::TABLET_DATA_READY) {
-    Status s = Status::IllegalState("Remote peer (" + bootstrap_peer_uuid + ")" +
+    Status s = Status::IllegalState("Remote peer (" + copy_peer_uuid + ")" +
                                     " is currently copying itself!",
                                     resp.superblock().ShortDebugString());
     LOG_WITH_PREFIX(WARNING) << s.ToString();
@@ -199,21 +199,21 @@ Status TabletCopyClient::Start(const HostPort& bootstrap_source_addr,
                         "Cannot deserialize schema from remote superblock");
 
   if (replace_tombstoned_tablet_) {
-    // Also validate the term of the bootstrap source peer, in case they are
+    // Also validate the term of the source peer, in case they are
     // different. This is a sanity check that protects us in case a bug or
-    // misconfiguration causes us to attempt to bootstrap from an out-of-date
+    // misconfiguration causes us to attempt to copy from an out-of-date
     // source peer, even after passing the term check from the caller in
     // SetTabletToReplace().
     int64_t last_logged_term = meta_->tombstone_last_logged_opid().term();
     if (last_logged_term > remote_committed_cstate_->current_term()) {
       return Status::InvalidArgument(
-          Substitute("Tablet $0: Bootstrap source has term $1 but "
+          Substitute("Tablet $0: source peer has term $1 but "
                      "tombstoned replica has last-logged opid with higher term $2. "
                       "Refusing tablet copy from source peer $3",
                       tablet_id_,
                       remote_committed_cstate_->current_term(),
                       last_logged_term,
-                      bootstrap_peer_uuid));
+                      copy_peer_uuid));
     }
 
     // This will flush to disk, but we set the data state to COPYING above.
@@ -337,7 +337,7 @@ Status TabletCopyClient::DownloadWALs() {
   CHECK(started_);
 
   // Delete and recreate WAL dir if it already exists, to ensure stray files are
-  // not kept from previous bootstraps and runs.
+  // not kept from previous copies and runs.
   string path = fs_manager_->GetTabletWalDir(tablet_id_);
   if (fs_manager_->env()->FileExists(path)) {
     RETURN_NOT_OK(fs_manager_->env()->DeleteRecursively(path));

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/tserver/remote_bootstrap_client.h
----------------------------------------------------------------------
diff --git a/src/kudu/tserver/remote_bootstrap_client.h b/src/kudu/tserver/remote_bootstrap_client.h
index e475ef1..01253ee 100644
--- a/src/kudu/tserver/remote_bootstrap_client.h
+++ b/src/kudu/tserver/remote_bootstrap_client.h
@@ -94,7 +94,7 @@ class TabletCopyClient {
   // in progress. If the 'metadata' pointer is passed as NULL, it is ignored,
   // otherwise the TabletMetadata object resulting from the initial remote
   // bootstrap response is returned.
-  Status Start(const HostPort& bootstrap_source_addr,
+  Status Start(const HostPort& copy_source_addr,
                scoped_refptr<tablet::TabletMetadata>* metadata);
 
   // Runs a "full" tablet copy, copying the physical layout of a tablet

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/tserver/remote_bootstrap_service.cc
----------------------------------------------------------------------
diff --git a/src/kudu/tserver/remote_bootstrap_service.cc b/src/kudu/tserver/remote_bootstrap_service.cc
index f5bd2ae..1d7104c 100644
--- a/src/kudu/tserver/remote_bootstrap_service.cc
+++ b/src/kudu/tserver/remote_bootstrap_service.cc
@@ -60,11 +60,11 @@ DEFINE_uint64(tablet_copy_timeout_poll_period_ms, 10000,
               "tablet copy sessions, in millis");
 TAG_FLAG(tablet_copy_timeout_poll_period_ms, hidden);
 
-DEFINE_double(fault_crash_on_handle_rb_fetch_data, 0.0,
+DEFINE_double(fault_crash_on_handle_tc_fetch_data, 0.0,
               "Fraction of the time when the tablet will crash while "
               "servicing a TabletCopyService FetchData() RPC call. "
               "(For testing only!)");
-TAG_FLAG(fault_crash_on_handle_rb_fetch_data, unsafe);
+TAG_FLAG(fault_crash_on_handle_tc_fetch_data, unsafe);
 
 namespace kudu {
 namespace tserver {
@@ -96,7 +96,7 @@ TabletCopyServiceImpl::TabletCopyServiceImpl(
       fs_manager_(CHECK_NOTNULL(fs_manager)),
       tablet_peer_lookup_(CHECK_NOTNULL(tablet_peer_lookup)),
       shutdown_latch_(1) {
-  CHECK_OK(Thread::Create("remote-bootstrap", "rb-session-exp",
+  CHECK_OK(Thread::Create("tablet-copy", "tc-session-exp",
                           &TabletCopyServiceImpl::EndExpiredSessions, this,
                           &session_expiration_thread_));
 }
@@ -197,7 +197,7 @@ void TabletCopyServiceImpl::FetchData(const FetchDataRequestPB* req,
     ResetSessionExpirationUnlocked(session_id);
   }
 
-  MAYBE_FAULT(FLAGS_fault_crash_on_handle_rb_fetch_data);
+  MAYBE_FAULT(FLAGS_fault_crash_on_handle_tc_fetch_data);
 
   uint64_t offset = req->offset();
   int64_t client_maxlen = req->max_length();

http://git-wip-us.apache.org/repos/asf/kudu/blob/7ee61f84/src/kudu/tserver/ts_tablet_manager.cc
----------------------------------------------------------------------
diff --git a/src/kudu/tserver/ts_tablet_manager.cc b/src/kudu/tserver/ts_tablet_manager.cc
index 402f6cb..14558c5 100644
--- a/src/kudu/tserver/ts_tablet_manager.cc
+++ b/src/kudu/tserver/ts_tablet_manager.cc
@@ -89,12 +89,12 @@ DEFINE_double(fault_crash_after_cmeta_deleted, 0.0,
               "(For testing only!)");
 TAG_FLAG(fault_crash_after_cmeta_deleted, unsafe);
 
-DEFINE_double(fault_crash_after_rb_files_fetched, 0.0,
+DEFINE_double(fault_crash_after_tc_files_fetched, 0.0,
               "Fraction of the time when the tablet will crash immediately "
               "after fetching the files during a tablet copy but before "
               "marking the superblock as TABLET_DATA_READY. "
               "(For testing only!)");
-TAG_FLAG(fault_crash_after_rb_files_fetched, unsafe);
+TAG_FLAG(fault_crash_after_tc_files_fetched, unsafe);
 
 namespace kudu {
 namespace tserver {
@@ -338,9 +338,9 @@ Status TSTabletManager::StartTabletCopy(
     const StartTabletCopyRequestPB& req,
     boost::optional<TabletServerErrorPB::Code>* error_code) {
   const string& tablet_id = req.tablet_id();
-  const string& bootstrap_source_uuid = req.bootstrap_peer_uuid();
-  HostPort bootstrap_source_addr;
-  RETURN_NOT_OK(HostPortFromPB(req.bootstrap_peer_addr(), &bootstrap_source_addr));
+  const string& copy_source_uuid = req.copy_peer_uuid();
+  HostPort copy_source_addr;
+  RETURN_NOT_OK(HostPortFromPB(req.copy_peer_addr(), &copy_source_addr));
   int64_t leader_term = req.caller_term();
 
   const string kLogPrefix = LogPrefix(tablet_id);
@@ -355,7 +355,7 @@ Status TSTabletManager::StartTabletCopy(
       meta = old_tablet_peer->tablet_metadata();
       replacing_tablet = true;
     }
-    Status ret = StartTabletStateTransitionUnlocked(tablet_id, "tablet copyping tablet",
+    Status ret = StartTabletStateTransitionUnlocked(tablet_id, "copying tablet",
                                                     &deleter);
     if (!ret.ok()) {
       *error_code = TabletServerErrorPB::ALREADY_INPROGRESS;
@@ -410,18 +410,18 @@ Status TSTabletManager::StartTabletCopy(
   }
 
   string init_msg = kLogPrefix + Substitute("Initiating tablet copy from Peer $0 ($1)",
-                                            bootstrap_source_uuid,
-                                            bootstrap_source_addr.ToString());
+                                            copy_source_uuid,
+                                            copy_source_addr.ToString());
   LOG(INFO) << init_msg;
   TRACE(init_msg);
 
-  TabletCopyClient rb_client(tablet_id, fs_manager_, server_->messenger());
+  TabletCopyClient tc_client(tablet_id, fs_manager_, server_->messenger());
 
   // Download and persist the remote superblock in TABLET_DATA_COPYING state.
   if (replacing_tablet) {
-    RETURN_NOT_OK(rb_client.SetTabletToReplace(meta, leader_term));
+    RETURN_NOT_OK(tc_client.SetTabletToReplace(meta, leader_term));
   }
-  RETURN_NOT_OK(rb_client.Start(bootstrap_source_addr, &meta));
+  RETURN_NOT_OK(tc_client.Start(copy_source_addr, &meta));
 
   // From this point onward, the superblock is persisted in TABLET_DATA_COPYING
   // state, and we need to tombtone the tablet if additional steps prior to
@@ -430,18 +430,18 @@ Status TSTabletManager::StartTabletCopy(
   // Registering a non-initialized TabletPeer offers visibility through the Web UI.
   RegisterTabletPeerMode mode = replacing_tablet ? REPLACEMENT_PEER : NEW_PEER;
   scoped_refptr<TabletPeer> tablet_peer = CreateAndRegisterTabletPeer(meta, mode);
-  string peer_str = bootstrap_source_uuid + " (" + bootstrap_source_addr.ToString() + ")";
+  string peer_str = copy_source_uuid + " (" + copy_source_addr.ToString() + ")";
 
   // Download all of the remote files.
-  TOMBSTONE_NOT_OK(rb_client.FetchAll(tablet_peer->status_listener()), meta,
+  TOMBSTONE_NOT_OK(tc_client.FetchAll(tablet_peer->status_listener()), meta,
                    "Tablet Copy: Unable to fetch data from remote peer " +
-                   bootstrap_source_uuid + " (" + bootstrap_source_addr.ToString() + ")");
+                   copy_source_uuid + " (" + copy_source_addr.ToString() + ")");
 
-  MAYBE_FAULT(FLAGS_fault_crash_after_rb_files_fetched);
+  MAYBE_FAULT(FLAGS_fault_crash_after_tc_files_fetched);
 
   // Write out the last files to make the new replica visible and update the
   // TabletDataState in the superblock to TABLET_DATA_READY.
-  TOMBSTONE_NOT_OK(rb_client.Finish(), meta, "Tablet Copy: Failure calling Finish()");
+  TOMBSTONE_NOT_OK(tc_client.Finish(), meta, "Tablet Copy: Failure calling Finish()");
 
   // We run this asynchronously. We don't tombstone the tablet if this fails,
   // because if we were to fail to open the tablet, on next startup, it's in a
@@ -585,7 +585,7 @@ Status TSTabletManager::StartTabletStateTransitionUnlocked(
     //
     // If the tablet was permanently deleted, we should not allow it to
     // transition back to "liveness" because that can result in flapping back
-    // and forth between deletion and tablet copyping.
+    // and forth between deletion and tablet copying.
     return Status::IllegalState(
         Substitute("Tablet $0 was permanently deleted. Cannot transition from state $1.",
                    tablet_id, TabletDataState_Name(TABLET_DATA_DELETED)));
@@ -885,7 +885,7 @@ Status TSTabletManager::HandleNonReadyTabletOnStartup(const scoped_refptr<Tablet
       << TabletDataState_Name(data_state) << " (" << data_state << ")";
 
   if (data_state == TABLET_DATA_COPYING) {
-    // We tombstone tablets that failed to remotely bootstrap.
+    // We tombstone tablets that failed to copy.
     data_state = TABLET_DATA_TOMBSTONED;
   }
 


Mime
View raw message