Documentation ¶
Index ¶
- type BackupManager
- type BackupRepository
- type BackupService
- func (s BackupService) Create(ctx context.Context, backup *resource.Backup) (*resource.BackupResult, error)
- func (s BackupService) Get(ctx context.Context, backupID resource.BackupID) (*resource.Backup, error)
- func (s BackupService) List(ctx context.Context, tnnt tenant.Tenant, store resource.Store) ([]*resource.Backup, error)
- type DataStore
- type DownstreamRefresher
- type EventHandler
- type ResourceManager
- type ResourceMgr
- func (m *ResourceMgr) Backup(ctx context.Context, details *resource.Backup, resources []*resource.Resource) (*resource.BackupResult, error)
- func (m *ResourceMgr) BatchUpdate(ctx context.Context, store resource.Store, resources []*resource.Resource) error
- func (m *ResourceMgr) CreateResource(ctx context.Context, res *resource.Resource) error
- func (m *ResourceMgr) GetURN(res *resource.Resource) (string, error)
- func (m *ResourceMgr) RegisterDatastore(store resource.Store, dataStore DataStore)
- func (m *ResourceMgr) SyncResource(ctx context.Context, res *resource.Resource) error
- func (m *ResourceMgr) UpdateResource(ctx context.Context, res *resource.Resource) error
- func (m *ResourceMgr) Validate(res *resource.Resource) error
- type ResourceProvider
- type ResourceRepository
- type ResourceService
- func (rs ResourceService) ChangeNamespace(ctx context.Context, datastore resource.Store, resourceFullName string, ...) error
- func (rs ResourceService) Create(ctx context.Context, incoming *resource.Resource) error
- func (rs ResourceService) Deploy(ctx context.Context, tnnt tenant.Tenant, store resource.Store, ...) error
- func (rs ResourceService) Get(ctx context.Context, tnnt tenant.Tenant, store resource.Store, ...) (*resource.Resource, error)
- func (rs ResourceService) GetAll(ctx context.Context, tnnt tenant.Tenant, store resource.Store) ([]*resource.Resource, error)
- func (rs ResourceService) SyncResources(ctx context.Context, tnnt tenant.Tenant, store resource.Store, names []string) (*resource.SyncResponse, error)
- func (rs ResourceService) Update(ctx context.Context, incoming *resource.Resource, logWriter writer.LogWriter) error
- type ResourceStatusRepo
- type TenantDetailsGetter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BackupManager ¶
type BackupRepository ¶
type BackupService ¶
type BackupService struct {
// contains filtered or unexported fields
}
func NewBackupService ¶
func NewBackupService(repo BackupRepository, resources ResourceProvider, manager BackupManager, logger log.Logger) *BackupService
func (BackupService) Create ¶
func (s BackupService) Create(ctx context.Context, backup *resource.Backup) (*resource.BackupResult, error)
type DataStore ¶
type DataStore interface { Create(context.Context, *resource.Resource) error Update(context.Context, *resource.Resource) error BatchUpdate(context.Context, []*resource.Resource) error Validate(*resource.Resource) error GetURN(res *resource.Resource) (string, error) Backup(context.Context, *resource.Backup, []*resource.Resource) (*resource.BackupResult, error) }
type DownstreamRefresher ¶ added in v0.9.0
type EventHandler ¶ added in v0.7.0
type ResourceManager ¶
type ResourceManager interface { CreateResource(ctx context.Context, res *resource.Resource) error UpdateResource(ctx context.Context, res *resource.Resource) error SyncResource(ctx context.Context, res *resource.Resource) error BatchUpdate(ctx context.Context, store resource.Store, resources []*resource.Resource) error Validate(res *resource.Resource) error GetURN(res *resource.Resource) (string, error) }
type ResourceMgr ¶
type ResourceMgr struct {
// contains filtered or unexported fields
}
func NewResourceManager ¶
func NewResourceManager(repo ResourceStatusRepo, logger log.Logger) *ResourceMgr
func (*ResourceMgr) Backup ¶
func (m *ResourceMgr) Backup(ctx context.Context, details *resource.Backup, resources []*resource.Resource) (*resource.BackupResult, error)
func (*ResourceMgr) BatchUpdate ¶
func (*ResourceMgr) CreateResource ¶
func (*ResourceMgr) RegisterDatastore ¶
func (m *ResourceMgr) RegisterDatastore(store resource.Store, dataStore DataStore)
func (*ResourceMgr) SyncResource ¶ added in v0.9.0
func (*ResourceMgr) UpdateResource ¶
type ResourceProvider ¶
type ResourceRepository ¶
type ResourceRepository interface { Create(ctx context.Context, res *resource.Resource) error Update(ctx context.Context, res *resource.Resource) error ChangeNamespace(ctx context.Context, res *resource.Resource, newTenant tenant.Tenant) error ReadByFullName(ctx context.Context, tnnt tenant.Tenant, store resource.Store, fullName string) (*resource.Resource, error) ReadAll(ctx context.Context, tnnt tenant.Tenant, store resource.Store) ([]*resource.Resource, error) GetResources(ctx context.Context, tnnt tenant.Tenant, store resource.Store, names []string) ([]*resource.Resource, error) }
type ResourceService ¶
type ResourceService struct {
// contains filtered or unexported fields
}
func NewResourceService ¶
func NewResourceService( logger log.Logger, repo ResourceRepository, downstreamRefresher DownstreamRefresher, mgr ResourceManager, eventHandler EventHandler, ) *ResourceService
func (ResourceService) ChangeNamespace ¶ added in v0.8.0
func (ResourceService) SyncResources ¶ added in v0.9.0
type ResourceStatusRepo ¶
type TenantDetailsGetter ¶ added in v0.7.0
Click to show internal directories.
Click to hide internal directories.