Documentation ¶
Index ¶
- type Store
- func (s *Store) CreateBuild(ctx context.Context, appName string, build *storage.Object) error
- func (s *Store) DeleteBuild(ctx context.Context, appName, buildID string) (*storage.Object, error)
- func (s *Store) DeleteBuilds(ctx context.Context, appName string) ([]*storage.Object, error)
- func (s *Store) GetBuild(ctx context.Context, appName, buildID string) (*storage.Object, error)
- func (s *Store) GetBuilds(ctx context.Context, appName string) ([]*storage.Object, error)
- func (s *Store) UpdateBuild(ctx context.Context, appName string, build *storage.Object) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
Store is an inprocess storage engine for draft.
func NewStore ¶
func NewStore() *Store
NewStore returns a new inprocess memory Store for storing draft application context.
func (*Store) CreateBuild ¶
CreateBuild creates new storage for the application specified by appName to include build.
If storage already exists for the application, ErrAppStorageExists is returned.
CreateBuild implements storage.Creater.
func (*Store) DeleteBuild ¶
DeleteBuild deletes the draft build given by buildID for the application specified by appName.
DeleteBuild implements storage.Deleter.
func (*Store) DeleteBuilds ¶
DeleteBuilds deletes all draft builds for the application specified by appName.
DeleteBuilds implements storage.Deleter.
func (*Store) GetBuild ¶
GetBuild returns the build associated with buildID for the specified app name.
GetBuild implements storage.Getter.
func (*Store) GetBuilds ¶
GetBuilds returns a slice of builds for the given app name.
GetBuilds implements storage.Getter.
func (*Store) UpdateBuild ¶
UpdateBuild updates the application storage specified by appName to include build.
If build does not exist, a new storage entry is created. Otherwise the existing storage is updated.
UpdateBuild implements storage.Updater.