Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsErrNotFound ¶
IsErrNotFound returs true if err is type of ErrNotFound, false otherwise.
Types ¶
type DecodeError ¶
type DecodeError struct {
ID string
}
DecodeError represents a service impossible to decode.
func (*DecodeError) Error ¶
func (e *DecodeError) Error() string
type ErrNotFound ¶
type ErrNotFound struct {
ID string
}
ErrNotFound is an not found error.
func (*ErrNotFound) Error ¶
func (e *ErrNotFound) Error() string
type ExecutionDB ¶ added in v0.4.0
type ExecutionDB interface {
Find(executionID string) (*execution.Execution, error)
Save(execution *execution.Execution) error
Close() error
}
ExecutionDB exposes all the functionalities
type LevelDBExecutionDB ¶ added in v0.4.0
type LevelDBExecutionDB struct {
// contains filtered or unexported fields
}
LevelDBExecutionDB is a concrete implementation of the DB interface
func NewExecutionDB ¶ added in v0.4.0
func NewExecutionDB(path string) (*LevelDBExecutionDB, error)
NewExecutionDB creates a new DB instance
func (*LevelDBExecutionDB) Close ¶ added in v0.4.0
func (db *LevelDBExecutionDB) Close() error
Close closes database.
type LevelDBServiceDB ¶ added in v0.4.0
type LevelDBServiceDB struct {
// contains filtered or unexported fields
}
LevelDBServiceDB is a database for storing service definition.
func NewServiceDB ¶
func NewServiceDB(path string) (*LevelDBServiceDB, error)
NewServiceDB returns the database which is located under given path.
func (*LevelDBServiceDB) All ¶ added in v0.4.0
func (d *LevelDBServiceDB) All() ([]*service.Service, error)
All returns every service in database.
func (*LevelDBServiceDB) Close ¶ added in v0.4.0
func (d *LevelDBServiceDB) Close() error
Close closes database.
func (*LevelDBServiceDB) Delete ¶ added in v0.4.0
func (d *LevelDBServiceDB) Delete(id string) error
Delete deletes service from database.
Click to show internal directories.
Click to hide internal directories.