Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MutexWriter ¶
MutexWriter contains writer with a mutex instance
func (*MutexWriter) CopyFrom ¶
func (mw *MutexWriter) CopyFrom(s io.ReadCloser) error
CopyFrom copies from s to to Writer
func (*MutexWriter) Write ¶
func (mw *MutexWriter) Write(s string) error
Write writes string to Writer
type TailOption ¶
type TailOption func(*tailConfig)
TailOption is a single option for configuring a tailConfig
func WithTailFollow ¶
func WithTailFollow(val bool) TailOption
WithTailFollow creates an Option that sets stream the logs
func WithTailNamespace ¶
func WithTailNamespace(val string) TailOption
WithTailNamespace creates an Option that sets the Kubernetes namespace to use
func WithTailNumberLines ¶
func WithTailNumberLines(val int) TailOption
WithTailNumberLines creates an Option that sets number of lines
type TailOptions ¶
type TailOptions []TailOption
TailOptions is a configuration set defining a tailConfig
func TailOptionDefaults ¶
func TailOptionDefaults() TailOptions
TailOptionDefaults gets the default values for Tail.
func (TailOptions) Extend ¶
func (opts TailOptions) Extend(other TailOptions) TailOptions
Extend creates a new TailOptions with the contents of other overriding the values set in this TailOptions.
func (TailOptions) Follow ¶
func (opts TailOptions) Follow() bool
Follow returns the last set value for Follow or the empty value if not set.
func (TailOptions) Namespace ¶
func (opts TailOptions) Namespace() string
Namespace returns the last set value for Namespace or the empty value if not set.
func (TailOptions) NumberLines ¶
func (opts TailOptions) NumberLines() int
NumberLines returns the last set value for NumberLines or the empty value if not set.
type Tailer ¶
type Tailer interface { // Tail tails the logs from a KF application and writes them to the // writer. Tail(ctx context.Context, appName string, out io.Writer, opts ...TailOption) error }
Tailer reads the logs for a KF application. It should be created via NewTailer().
func NewTailer ¶
func NewTailer(client corev1client.CoreV1Interface) Tailer
NewTailer creates a new Tailer.