maton function run log list

maton function run log list --function <function-id> [flags]

List the log events one run has produced so far, oldest first.

--since and --until take an RFC3339 timestamp or a duration such as 10m, meaning that long ago. To watch a run that is still going instead of taking a snapshot of it, use maton function run log tail.

See maton function run log --help for the shape of the lines, which is what --filter-pattern matches against.

Options

--filter-pattern <string>
CloudWatch filter pattern
-f, --function <string>
Function ID this resource belongs to (required)
-q, --jq <expression>
Filter JSON output using a jq expression
--json <fields>
Output JSON with the specified fields
-L, --limit <int> (default 0)
Maximum number of events to fetch (0 = no limit)
-r, --run <string>
Run to read (the newest run when omitted)
--since <string>
Start of the window: RFC3339 or a duration like 10m
-t, --template <string>
Format JSON output using a Go template; see "maton help formatting"
--until <string>
End of the window: RFC3339 or a duration like 10m

Options inherited from parent commands

-p, --profile <string>
Profile to use for this invocation (overrides the active profile; also reads MATON_PROFILE)

ALIASES

maton function run logs ls, maton function runs log ls, maton function runs logs ls, maton functions run log ls, maton functions run logs ls, maton functions runs log ls, maton functions runs logs ls, maton function run log ls

JSON Fields

message, timestamp

Examples

# The newest run's logs
$ maton function run log list --function 9f3c1e2a-0b7d-4c11-9d2e-5f6a7b8c9d01

# One specific run, last ten minutes
$ maton function run log list -f 9f3c1e2a-0b7d-4c11-9d2e-5f6a7b8c9d01 --run run_abc123 --since 10m

# Only errors, as NDJSON
$ maton function run log list -f 9f3c1e2a-0b7d-4c11-9d2e-5f6a7b8c9d01 --filter-pattern ERROR --json timestamp,message

See also