Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ChainedJobEventHandler ¶
type ChainedJobEventHandler struct {
// contains filtered or unexported fields
}
An event handler implementation that chains multiple event handlers, and accepts a context provider to setup up the context once for all handlers.
func NewChainedJobEventHandler ¶
func NewChainedJobEventHandler(contextProvider ContextProvider) *ChainedJobEventHandler
func (*ChainedJobEventHandler) AddHandlers ¶
func (r *ChainedJobEventHandler) AddHandlers(handlers ...JobEventHandler)
func (*ChainedJobEventHandler) HandleJobEvent ¶
type ContextProvider ¶
Interface for a context provider that can be used to generate a context to be used to handle job events.
type JobEventHandler ¶
A job event handler is a component that is notified of events related to jobs.
type JobEventHandlerFunc ¶
function that implements the JobEventHandler interface
func (JobEventHandlerFunc) HandleJobEvent ¶
type Tracer ¶
Tracer is a JobEventHandler that will marshal the received event to a file-based log.
Note that we don't need any mutexes here because writing to an os.File is thread-safe (see https://github.com/rs/zerolog/blob/master/writer.go#L33)
func NewTracer ¶
Returns an eventhandler.Tracer that writes to config.GetEventTracerPath(), or an error if the file can't be opened.
func NewTracerToFile ¶
Returns an eventhandler.Tracer that writes to the specified filename, or an error if the file can't be opened.
func (*Tracer) HandleJobEvent ¶
HandleJobEvent implements JobEventHandler
type TracerContextProvider ¶
type TracerContextProvider struct {
// contains filtered or unexported fields
}
TracerContextProvider is a context provider that generates a context along with tracing information. It also implements JobEventHandler to end the local lifecycle context for a job when it is completed.
func NewTracerContextProvider ¶
func NewTracerContextProvider(nodeID string) *TracerContextProvider
func (*TracerContextProvider) GetContext ¶
func (*TracerContextProvider) HandleJobEvent ¶
func (*TracerContextProvider) Shutdown ¶
func (t *TracerContextProvider) Shutdown() error
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
Package mock_system is a generated GoMock package.
|
Package mock_system is a generated GoMock package. |