Documentation ¶
Overview ¶
logstream contains functionality for streaming logs for an entire application from Kubernetes. This functionality is based on github.com/stern/stern.
Package logstream is a generated GoMock package.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Impl ¶
type Impl struct { }
Impl is the implementation of logstream.Interface.
type Interface ¶
type Interface interface { // Stream opens a log stream and writes the application's log to the provided writer. // This function will block until the context is cancelled. Stream(ctx context.Context, options Options) error }
Interface is the interface type for streaming application logs.
type MockInterface ¶
type MockInterface struct {
// contains filtered or unexported fields
}
MockInterface is a mock of Interface interface.
func NewMockInterface ¶
func NewMockInterface(ctrl *gomock.Controller) *MockInterface
NewMockInterface creates a new mock instance.
func (*MockInterface) EXPECT ¶
func (m *MockInterface) EXPECT() *MockInterfaceMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockInterfaceMockRecorder ¶
type MockInterfaceMockRecorder struct {
// contains filtered or unexported fields
}
MockInterfaceMockRecorder is the mock recorder for MockInterface.
func (*MockInterfaceMockRecorder) Stream ¶
func (mr *MockInterfaceMockRecorder) Stream(arg0, arg1 any) *MockInterfaceStreamCall
Stream indicates an expected call of Stream.
type MockInterfaceStreamCall ¶ added in v0.35.0
MockInterfaceStreamCall wrap *gomock.Call
func (*MockInterfaceStreamCall) Do ¶ added in v0.35.0
func (c *MockInterfaceStreamCall) Do(f func(context.Context, Options) error) *MockInterfaceStreamCall
Do rewrite *gomock.Call.Do
func (*MockInterfaceStreamCall) DoAndReturn ¶ added in v0.35.0
func (c *MockInterfaceStreamCall) DoAndReturn(f func(context.Context, Options) error) *MockInterfaceStreamCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockInterfaceStreamCall) Return ¶ added in v0.35.0
func (c *MockInterfaceStreamCall) Return(arg0 error) *MockInterfaceStreamCall
Return rewrite *gomock.Call.Return
type Options ¶
type Options struct { // ApplicationName is the name of the application. ApplicationName string // Namespace is the kubernetes namespace of the application. Namespace string // KubeClient is the kubernetes client to use for connection. KubeClient kubernetes.Interface // Out is where output will be written. Out io.Writer }
Options specifies the options for streaming application logs.