View Source Lightning.Runtime.LogAgent (Lightning v2.10.4)

Agent facility to consume STDOUT/STDERR byte by byte.

Since it works on a byte by byte basis, you will need to perform line-splitting yourself.

Usage:

{:ok, log} = LogAgent.start_link()
"foo" = LogAgent.process_chunk(log, {:stdout, "foo"})
"foobar" = LogAgent.process_chunk(log, {:stdout, "bar"})

Summary

Functions

Returns a specification to start this module under a supervisor.

Types

@type logline() ::
  {timestamp :: integer(), type :: :stdout | :stderr, line :: binary()}

Functions

Returns a specification to start this module under a supervisor.

See Supervisor.

Link to this function

process_chunk(agent, arg)

View Source