From 2c7ee029f13a4d00eece162bcd672016acdadfad Mon Sep 17 00:00:00 2001 From: Max Siegieda Date: Wed, 24 Oct 2018 11:29:22 +0100 Subject: [PATCH] Add logstream interface and allow cloudwatchlogs to implement it (#294) --- service/batchlogs/batchlogs.go | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 service/batchlogs/batchlogs.go diff --git a/service/batchlogs/batchlogs.go b/service/batchlogs/batchlogs.go new file mode 100644 index 00000000..c2e069af --- /dev/null +++ b/service/batchlogs/batchlogs.go @@ -0,0 +1,13 @@ +package batchlogs + +import ( + "context" + "io" +) + +// batchlogs.Service contains functions for streaming logs in real time from a batch job +type Service interface { + // Stream takes a batch job's log stream name and returns an io.ReadCloser + // containing the bytes of the log updated in real time + Stream(ctx context.Context, logName string) io.ReadCloser +}