Documentation
¶
Index ¶
- Variables
- func CloseDB()
- func InitDB(cfg *config.MongoConfig)
- func Mongo() *mongo.Collection
- type MockRepo
- func (r *MockRepo) All(_ string, _ bool, _ map[string][]string, _ []string) (pipelines lib.PipelinesResponse, err error)
- func (r *MockRepo) DeletePipeline(_ string, _ string, _ bool) (err error)
- func (r *MockRepo) FindPipeline(_ string, _ string) (pipeline lib.Pipeline, err error)
- func (r *MockRepo) FlowUsage(_ string, _ bool, _ map[string][]string) (statistics []lib.OperatorUsage, err error)
- func (r *MockRepo) InsertPipeline(_ lib.Pipeline) (err error)
- func (r *MockRepo) OperatorUsage(_ string, _ bool, _ map[string][]string) (statistics []lib.OperatorUsage, err error)
- func (r *MockRepo) PipelineUserCount(_ string, _ bool, _ map[string][]string) (statistics []lib.PipelineUserCount, err error)
- func (r *MockRepo) UpdatePipeline(_ lib.Pipeline, _ string) (err error)
- type MongoRepo
- func (r *MongoRepo) All(userId string, admin bool, args map[string][]string, ids []string) (pipelines lib.PipelinesResponse, err error)
- func (r *MongoRepo) DeletePipeline(id string, userId string, admin bool) (err error)
- func (r *MongoRepo) FindPipeline(id string, _ string) (pipeline lib.Pipeline, err error)
- func (r *MongoRepo) FlowUsage() (statistics []lib.FlowUsage, err error)
- func (r *MongoRepo) InsertPipeline(pipeline lib.Pipeline) (err error)
- func (r *MongoRepo) OperatorUsage(_ string, _ bool, _ map[string][]string) (statistics []lib.OperatorUsage, err error)
- func (r *MongoRepo) PipelineUserCount(_ string, _ bool, _ map[string][]string) (statistics []lib.PipelineUserCount, err error)
- func (r *MongoRepo) UpdatePipeline(pipeline lib.Pipeline, _ string) (err error)
- type PipelineRepository
Constants ¶
This section is empty.
Variables ¶
View Source
var CTX mongo.SessionContext
View Source
var DB *mongo.Client
Functions ¶
func InitDB ¶
func InitDB(cfg *config.MongoConfig)
func Mongo ¶
func Mongo() *mongo.Collection
Types ¶
type MockRepo ¶
type MockRepo struct {
}
func NewMockRepo ¶
func NewMockRepo() *MockRepo
func (*MockRepo) DeletePipeline ¶
func (*MockRepo) FindPipeline ¶
func (*MockRepo) OperatorUsage ¶ added in v0.0.23
func (*MockRepo) PipelineUserCount ¶ added in v0.0.23
type MongoRepo ¶
type MongoRepo struct {
}
func NewMongoRepo ¶
func NewMongoRepo() *MongoRepo
func (*MongoRepo) DeletePipeline ¶
func (*MongoRepo) FindPipeline ¶
func (*MongoRepo) InsertPipeline ¶
func (*MongoRepo) OperatorUsage ¶ added in v0.0.22
func (*MongoRepo) PipelineUserCount ¶ added in v0.0.22
type PipelineRepository ¶
type PipelineRepository interface {
InsertPipeline(pipeline lib.Pipeline) (err error)
UpdatePipeline(pipeline lib.Pipeline, userId string) (err error)
All(userId string, admin bool, args map[string][]string, ids []string) (pipelines lib.PipelinesResponse, err error)
FindPipeline(id string, userId string) (pipeline lib.Pipeline, err error)
DeletePipeline(id string, userId string, admin bool) (err error)
PipelineUserCount(userId string, admin bool, args map[string][]string) (statistics []lib.PipelineUserCount, err error)
OperatorUsage(userId string, admin bool, args map[string][]string) (statistics []lib.OperatorUsage, err error)
FlowUsage() (statistics []lib.FlowUsage, err error)
}
Click to show internal directories.
Click to hide internal directories.