Documentation ¶
Index ¶
- func New() (storage.ResettableStorage, error)
- type Memory
- func (m *Memory) Close() error
- func (m *Memory) GetFrameworkEvent(_ xcontext.Context, eventQuery *frameworkevent.Query) ([]frameworkevent.Event, error)
- func (m *Memory) GetJobReport(ctx xcontext.Context, jobID types.JobID) (*job.JobReport, error)
- func (m *Memory) GetJobRequest(_ xcontext.Context, jobID types.JobID) (*job.Request, error)
- func (m *Memory) GetTestEvents(_ xcontext.Context, eventQuery *testevent.Query) ([]testevent.Event, error)
- func (m *Memory) ListJobs(_ xcontext.Context, query *storage.JobQuery) ([]types.JobID, error)
- func (m *Memory) Reset() error
- func (m *Memory) StoreFrameworkEvent(_ xcontext.Context, event frameworkevent.Event) error
- func (m *Memory) StoreJobRequest(_ xcontext.Context, request *job.Request) (types.JobID, error)
- func (m *Memory) StoreReport(_ xcontext.Context, report *job.Report) error
- func (m *Memory) StoreTestEvent(_ xcontext.Context, event testevent.Event) error
- func (m *Memory) Version() (uint64, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func New ¶
func New() (storage.ResettableStorage, error)
New create a new Memory events storage backend
Types ¶
type Memory ¶
type Memory struct {
// contains filtered or unexported fields
}
Memory implements a storage engine which stores everything in memory. This storage engine is very inefficient and should be used only for testing purposes.
func (*Memory) GetFrameworkEvent ¶
func (m *Memory) GetFrameworkEvent(_ xcontext.Context, eventQuery *frameworkevent.Query) ([]frameworkevent.Event, error)
GetFrameworkEvent retrieves a framework event from storage
func (*Memory) GetJobReport ¶
GetJobReport returns the report associated to a given job
func (*Memory) GetJobRequest ¶
GetJobRequest retrieves a job request from the in memory list
func (*Memory) GetTestEvents ¶
func (m *Memory) GetTestEvents(_ xcontext.Context, eventQuery *testevent.Query) ([]testevent.Event, error)
GetTestEvents returns all test events that match the given query.
func (*Memory) StoreFrameworkEvent ¶
StoreFrameworkEvent stores a framework event into the database
func (*Memory) StoreJobRequest ¶
StoreJobRequest stores a new job request
func (*Memory) StoreReport ¶
StoreReport stores a report associated to a job. Returns an error if there is already a report associated with this run.
func (*Memory) StoreTestEvent ¶
StoreTestEvent stores a test event into the database