- Test connectivity:
/raw_log/schema.md
- Also try
.json
,.fs
,.cpp
.
- Also try
- Number of entries in the log:
/raw_log?sizeonly
- Or
HEAD
instead ofGET
, to get the response in the header.
- Or
- When don't need an infinite stream (i.e., when
-f
is not required from thistail
, ex. from the browser):- TL;DR: Add
&nowait
. - Alternate means of capping the output:
&n=
,&period=
, and&stop_after_bytes=
.
- TL;DR: Add
- When in the browser, add
&array
. This makes the whole output "page" a valid JSON. - A milder version of
&array
is&entries_only
.- Without
&entries_only
or&array
, it's going to be one log entry per line as two tab-separated JSONs. - The first tab-column of the full output is the way to get the true timestamp of the log event.
- Timestamps and periods are generally epoch microseconds (use
date -d "yesterday" +"%s000000"
, with six zeroes at the end, to create one. Unless you're on OS X, in which case sorry.)
- Without
- Reference access patterns:
/raw_log?tail=1&nowait
/raw_log?tail=100&array&nowait
/raw_log?i=1000000&n=100
/raw_log?i=1000000&nowait
/raw_log?i=100&period=100000000&array
/raw_log?since=1473380843835579&stop_after_bytes=10000&array
- JSON formats:
&json=js
for JavaScript-friendly JSONs (no numerical type ID), and&json=fs
for F#-friendly JSONs (see the/raw_log/schema.fs
above).
- Recap for
/raw_log
:- Left boundary:
&i=<index>
|&since=<microseconds timestamp>
|&tail=<index starting from the end>
|&recent=<same as tail but in microseconds instead of indexes>
. - Right boundary:
&n=<count>
|&period=<microseconds range>
|&stop_after_bytes=<bytes>
|&nowait
. - JSON layout:
&json=js
hides type IDs, and&json=fs
is F#-friendly. - Default format is one event per line, as two
'\t'
-separated JSONs:{index,timestamp}
and event body.&entries_only
surpasses the 1st col, and&array
, makes the output one large JSON array of the 2nd col. - Special endpoints:
?sizeonly
for the todal number of entries, and/raw_low/schema.{json,cpp,fs,h}
for the schema.
- Left boundary:
Files
stream
Folders and files
Name | Name | Last commit date | ||
---|---|---|---|---|
parent directory.. | ||||