forked from apache/kudu
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[java client] Implement RPC tracing, part 1
First part of this work is adding the tracing objects and doing the tracing. A second patch will make this information available to users. This patch is using a pretty simple method of just shoving container objects into a list, per RPC. The traces are lightweight and don't try anything fancy. We also introduce the concept of "parent RPC", so that say a Write RPC spawns a GetTableLocations, and the latter will be added to the former so that the call to the master adds traces to both RPCs. This patch isn't adding a nice way to present the traces (like JSON) but here's a simple toString example: RpcTraceFrame{rpcMethod='Write', timestampMs=1477079973547, action=SEND_TO_SERVER, server=3926a6a73e994152be1336beb434154e}, RpcTraceFrame{rpcMethod='Write', timestampMs=1477079973548, action=RECEIVE_FROM_SERVER, server=3926a6a73e994152be1336beb434154e, callStatus=Network error: [Peer 3926a6a73e994152be1336beb434154e] Connection reset on [id: 0xc83743df]} RpcTraceFrame{rpcMethod='Write', timestampMs=1477079973548, action=SLEEP_THEN_RETRY, callStatus=Network error: [Peer 3926a6a73e994152be1336beb434154e] Connection reset on [id: 0xc83743df]}, RpcTraceFrame{rpcMethod='Write', timestampMs=1477079973574, action=QUERY_MASTER}, RpcTraceFrame{rpcMethod='GetTableLocations', timestampMs=1477079973574, action=SEND_TO_SERVER, server=c0d4588690d241c69821ee773eebd185}, RpcTraceFrame{rpcMethod='GetTableLocations', timestampMs=1477079973576, action=RECEIVE_FROM_SERVER, server=c0d4588690d241c69821ee773eebd185, callStatus=OK}, RpcTraceFrame{rpcMethod='Write', timestampMs=1477079973579, action=PICKED_REPLICA}, RpcTraceFrame{rpcMethod='Write', timestampMs=1477079973579, action=SEND_TO_SERVER, server=0353a6d97d6c49f9a727bc1ee6c3393e}, This patch also fixes up some paths where we weren't passing a timeout correctly to an RPC that was created in relation to another RPC (basically paths where the parent RPC had to be set). Change-Id: I69ef56acc071b9f80b34e38c1821df4096f54907 Reviewed-on: http://gerrit.cloudera.org:8080/4781 Reviewed-by: Dan Burkert <[email protected]> Tested-by: Kudu Jenkins
- Loading branch information
Showing
8 changed files
with
387 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.