Syntax reference
Every term, operator, and rule. Read the reference →
Trill is how you ask Kinglet for events. A Trill query is a list of terms separated by spaces, and an event matches when it satisfies every term:
level>=warn service:api timeout -healthcheckThat reads as: warnings or worse, from the api service, whose message
contains “timeout” but not “healthcheck”.
The same query works everywhere Kinglet takes a filter:
q parameter on GET /v1/events, /v1/aggregate,
/v1/histogram, and the /v1/stream live tail.| You want | Trill |
|---|---|
| Errors and worse | level>=error |
| One service, one environment | service:checkout env:prod |
| Messages containing a phrase | "connection refused" |
| …but not health checks | "connection refused" -healthcheck |
| A value in the event’s structured fields | field.orderId:A-42 |
| Slow requests | field.durationMs>1000 |
| Anything mentioning a value, message or fields | in:all 864351050000101 |
Terms combine freely, in any order: service:udp level>=warn field.imei:8643….
Every Kinglet event has a message (the text line) and optional fields (a JSON object sent alongside it). Trill searches both, in different ways:
timeout or "conn refused" matches the message, through
the search index when one exists.field.status>=500 target specific keys in fields by
value, numeric comparison, or existence.in:fields or in:all makes free text search the fields’ keys and
values too, for when you don’t know which field holds what you’re after.Field filters and in:fields scan the events in the selected project and time
window instead of using the index. That’s about 0.1 s for a day of a
1M-event project, and a few seconds for two weeks. Narrow the window, or add
service:, level, or message text, to keep them fast.
Syntax reference
Every term, operator, and rule. Read the reference →
Examples
Ready-made queries for debugging, monitors, and clean-up. Browse examples →
The log view
Autocomplete, the live tail, the histogram, and click-to-filter. Use the log view →