You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/protocol/extension_logging.md
+80-3
Original file line number
Diff line number
Diff line change
@@ -69,7 +69,7 @@ the `$string` representation of the log setting and the “value” is a `$strin
69
69
`$bool`, or `$number` representation of the setting value. Currently, the
70
70
following log settings are defined:
71
71
72
-
- "log_file" : a `$string`parameter defining the file where the log outputs will be saved. If an empty string is specified, log outputs will stream to the console.
72
+
- "log_file" : a `$string`log file location where the log outputs will be saved. If empty, log outputs are streamed to the console.
73
73
74
74
- "log_info" : a `$boolean` parameter that controls whether the Triton server logs INFO level messages.
75
75
@@ -117,8 +117,14 @@ $log_setting_request =
117
117
}
118
118
```
119
119
120
-
When a `$log_setting` JSON is received (defined above), only the specified
121
-
settings will be updated.
120
+
When a `$log_setting` JSON is received (defined above), only the
121
+
specified settings will be updated. Currently, the following log
122
+
settings (described above) can be updated:
123
+
- "log_info"
124
+
- "log_warning"
125
+
- "log_error"
126
+
- "log_verbose_level"
127
+
- "log_format"
122
128
123
129
### Example Usage
124
130
The logging protocol extension can be invoked using the curl library in the following manner (assuming
@@ -196,3 +202,74 @@ message LogSettingsResponse
196
202
map<string, SettingValue> settings = 1;
197
203
}
198
204
```
205
+
206
+
## Logging Formats
207
+
208
+
The logging extension offers two logging formats. The formats have a
209
+
common set of fields but differ in how the timestamp for a log entry
210
+
is represented. Messages are serialized according to JSON encoding
211
+
rules by default. This behavior can be disabled by setting the
212
+
environment variable TRITON_SERVER_ESCAPE_LOG_MESSAGES to "0" when
213
+
launching the server but can not be changed through the logging
214
+
extension.
215
+
216
+
Log entries can be single-line or multi-line. Multi-line entries have
217
+
a single optional heading followed by the structured representation of
218
+
an object such as a table or protobuf message. Multi-line entries end
if [ "$RESOLVED_DEFAULT_MAX_BATCH_SIZE"!="4" ];then
94
111
echo"*** FAILED: Found default-max-batch-size not equal to the expected default-max-batch-size. Expected: default-max-batch-size,4, Found: $RESOLVED_DEFAULT_MAX_BATCH_SIZE \n"
@@ -117,7 +134,7 @@ for ((i=0; i < ${#POSITIVE_TEST_ARGS[@]}; i++)); do
117
134
if [ "$RESULT_LOG_LINE"!="" ];then
118
135
119
136
# Pick out the logged value of the default-max-batch-size which gets passed into model creation
if [ "$RESOLVED_DEFAULT_MAX_BATCH_SIZE"!="${POSITIVE_TEST_ANSWERS[$i]}" ];then
123
140
echo"*** FAILED: Found default-max-batch-size not equal to the expected default-max-batch-size. Expected: ${POSITIVE_TEST_ANSWERS[$i]}, Found: $RESOLVED_DEFAULT_MAX_BATCH_SIZE \n"
@@ -330,8 +347,8 @@ if [ "$SERVER_PID" == "0" ]; then
330
347
331
348
else
332
349
# Count number of default configs
333
-
BACKEND_CONFIG_MAP=$(grep -a "backend configuration:"$SERVER_LOG -A 1 | grep -v "backend configuration")
0 commit comments