/
tracing.dita
121 lines (116 loc) · 7.11 KB
/
tracing.dita
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE topic PUBLIC "-//OASIS//DTD DITA Topic//EN" "topic.dtd">
<topic id="tracing">
<title>Threshold Logging Tracing</title>
<shortdesc id="shortdesc">By collecting and analyzing each operation an SDK performs,
information can be made available to identify problem areas when an operation takes
an unusually long time to complete. For example pin-pointing whether any delay lies with
network issues, rather than a Couchbase Server operation, or if most delays are concentrated
on a particular Server node. (Response Time Observability, a.k.a. Tracing, is Enterprise Edition
only - not available in the Community Edition.)</shortdesc>
<body>
<note type="important">Threshold Logging Tracing is part of the SDK, and will work with both the
Community and Enterprise Editions of Couchbase Server. However, Data Service operation duration is only
available in the Enterprise Edition.</note>
<section id="why_tracing">
<title>Why Tracing?</title>
<p>Tracing is recording details about discrete steps or phases of a request lifecycle,
such as request encoding / decoding, or dispatching to server. These phases are timed
independently, and contain additional contextual information. A single request is typically
made up of multiple tracing points.</p>
</section>
<section id="open_tracing">
<title>Open Tracing</title>
<p><xref href="http://opentracing.io/" scope="external" format="html">OpenTracing</xref> is a
standardised API to structure tracing information in a consistent and predictable manner.
</p>
</section>
<section id="threshold_configuration">
<title>Threshold Configuration Settings</title>
<p>The threshold tracer receives completed spans and verifies if an operation has exceeded the
given threshold for the operation type. Operations that exceed the threshold are periodically
logged with a total count and a sample of the slowest ones. The following are SDK configuration properties.</p>
<table frame="all" rowsep="1" colsep="1" id="threshold-logging-tracer-ref">
<title>Threshold Logging Tracer Properties</title>
<tgroup cols="3">
<colspec colname="name" colnum="1" colwidth="3*"/>
<colspec colname="bname" colnum="2" colwidth="3*"/>
<colspec colname="bname" colnum="3" colwidth="1*"/>
<thead>
<row>
<entry>Property Name</entry>
<entry>Description</entry>
<entry>Default Value</entry>
</row>
</thead>
<tbody>
<row>
<entry><codeph>OperationTracingEnabled</codeph></entry>
<entry>Boolean used to determine tracing is enabled. Defaults to using the
<codeph>ThesholdLoggingTracer</codeph> if enabled. When false a Noop or similar tracing
implementation should be used instead.</entry>
<entry>true</entry>
</row>
<row>
<entry><codeph>OperationTracingServerDurationEnabled</codeph></entry>
<entry>Boolean used to instruct the SDK to try and retrieve duration metrics from the server for KV operations.</entry>
<entry>true</entry>
</row>
<row>
<entry><codeph>ThresholdLoggingTracerInterval</codeph></entry>
<entry>The interval between executions that process the collected operation spans.
Expressed in milliseconds.
</entry>
<entry>10,000 (10 seconds)</entry>
</row>
<row>
<entry><codeph>ThresholdLoggingTracerSampleSize</codeph></entry>
<entry>The maximum number of items to log per service.</entry>
<entry>10</entry>
</row>
<row>
<entry><codeph>ThresholdLoggingTracerKVThreshold</codeph></entry>
<entry>The KV operation operation threshold. Expressed in microseconds.</entry>
<entry>500,000 (500 milliseconds)</entry>
</row>
<row>
<entry><codeph>ThresholdLoggingTracerViewsThreshold</codeph></entry>
<entry>The View query operation threshold. Expressed in microseconds.</entry>
<entry>1,000,000 (1 second)</entry>
</row>
<row>
<entry><codeph>ThresholdLoggingTracerQueryThreshold</codeph></entry>
<entry>The N1QL query operation threshold. Expressed in microseconds.</entry>
<entry>1,000,000 (1 second)</entry>
</row>
<row>
<entry><codeph>ThresholdLoggingTracerSearchThreshold</codeph></entry>
<entry>The FTS query operation threshold. Expressed in microseconds.</entry>
<entry>1,000,000 (1 second)</entry>
</row>
<row>
<entry><codeph>ThresholdLoggingTracerAnalyticsThreshold</codeph></entry>
<entry>The Analytics query operation threshold. Expressed in microseconds.</entry>
<entry>1,000,000 (1 second)</entry>
</row>
<row>
<entry><codeph>OrphanedResponseLoggingEnabled</codeph></entry>
<entry>Boolean used to determine if orphaned response logging is enabled.</entry>
<entry>true</entry>
</row>
<row>
<entry><codeph>OrphanedResponseLoggingInterval</codeph></entry>
<entry>The interval used to flush orphaned response information to the log. Expressed in microseconds.</entry>
<entry>10,000 (10 seconds)</entry>
</row>
<row>
<entry><codeph>OrphanedResponseLoggingSampleSize</codeph></entry>
<entry>The number of sample orphaned responses whose to log additional information for per execution.</entry>
<entry>10</entry>
</row>
</tbody>
</tgroup>
</table>
</section>
</body>
</topic>