Documentation
¶
Index ¶
- type RepositoryStore
- func (s *RepositoryStore) Count(ctx context.Context, orgId uuid.UUID, listParams store.ListParams) (int64, error)
- func (s *RepositoryStore) CountByOrg(ctx context.Context, orgId *uuid.UUID) ([]store.CountByOrgResult, error)
- func (s *RepositoryStore) Create(ctx context.Context, orgId uuid.UUID, resource *domain.Repository, ...) (*domain.Repository, error)
- func (s *RepositoryStore) CreateOrUpdate(ctx context.Context, orgId uuid.UUID, resource *domain.Repository, ...) (*domain.Repository, bool, error)
- func (s *RepositoryStore) Delete(ctx context.Context, orgId uuid.UUID, name string, ...) error
- func (s *RepositoryStore) Get(ctx context.Context, orgId uuid.UUID, name string) (*domain.Repository, error)
- func (s *RepositoryStore) GetDeviceRefs(ctx context.Context, orgId uuid.UUID, name string) (*domain.DeviceList, error)
- func (s *RepositoryStore) GetFleetRefs(ctx context.Context, orgId uuid.UUID, name string) (*domain.FleetList, error)
- func (s *RepositoryStore) GetInternal(ctx context.Context, orgId uuid.UUID, name string) (*model.Repository, error)
- func (s *RepositoryStore) InitialMigration(ctx context.Context) error
- func (s *RepositoryStore) List(ctx context.Context, orgId uuid.UUID, listParams store.ListParams) (*domain.RepositoryList, error)
- func (s *RepositoryStore) ListIgnoreOrg(ctx context.Context) ([]model.Repository, error)
- func (s *RepositoryStore) Update(ctx context.Context, orgId uuid.UUID, resource *domain.Repository, ...) (*domain.Repository, error)
- func (s *RepositoryStore) UpdateStatus(ctx context.Context, orgId uuid.UUID, resource *domain.Repository, ...) (*domain.Repository, error)
- type Store
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RepositoryStore ¶
type RepositoryStore struct {
// contains filtered or unexported fields
}
func (*RepositoryStore) Count ¶
func (s *RepositoryStore) Count(ctx context.Context, orgId uuid.UUID, listParams store.ListParams) (int64, error)
func (*RepositoryStore) CountByOrg ¶
func (s *RepositoryStore) CountByOrg(ctx context.Context, orgId *uuid.UUID) ([]store.CountByOrgResult, error)
CountByOrg returns the count of repositories grouped by org_id.
func (*RepositoryStore) Create ¶
func (s *RepositoryStore) Create(ctx context.Context, orgId uuid.UUID, resource *domain.Repository, eventCallback store.EventCallback) (*domain.Repository, error)
func (*RepositoryStore) CreateOrUpdate ¶
func (s *RepositoryStore) CreateOrUpdate(ctx context.Context, orgId uuid.UUID, resource *domain.Repository, eventCallback store.EventCallback) (*domain.Repository, bool, error)
func (*RepositoryStore) Delete ¶
func (s *RepositoryStore) Delete(ctx context.Context, orgId uuid.UUID, name string, eventCallback store.EventCallback) error
func (*RepositoryStore) Get ¶
func (s *RepositoryStore) Get(ctx context.Context, orgId uuid.UUID, name string) (*domain.Repository, error)
func (*RepositoryStore) GetDeviceRefs ¶
func (s *RepositoryStore) GetDeviceRefs(ctx context.Context, orgId uuid.UUID, name string) (*domain.DeviceList, error)
func (*RepositoryStore) GetFleetRefs ¶
func (*RepositoryStore) GetInternal ¶
func (s *RepositoryStore) GetInternal(ctx context.Context, orgId uuid.UUID, name string) (*model.Repository, error)
func (*RepositoryStore) InitialMigration ¶
func (s *RepositoryStore) InitialMigration(ctx context.Context) error
func (*RepositoryStore) List ¶
func (s *RepositoryStore) List(ctx context.Context, orgId uuid.UUID, listParams store.ListParams) (*domain.RepositoryList, error)
func (*RepositoryStore) ListIgnoreOrg ¶
func (s *RepositoryStore) ListIgnoreOrg(ctx context.Context) ([]model.Repository, error)
func (*RepositoryStore) Update ¶
func (s *RepositoryStore) Update(ctx context.Context, orgId uuid.UUID, resource *domain.Repository, eventCallback store.EventCallback) (*domain.Repository, error)
func (*RepositoryStore) UpdateStatus ¶
func (s *RepositoryStore) UpdateStatus(ctx context.Context, orgId uuid.UUID, resource *domain.Repository, eventCallback store.EventCallback) (*domain.Repository, error)
type Store ¶
type Store interface {
InitialMigration(ctx context.Context) error
Create(ctx context.Context, orgId uuid.UUID, repository *domain.Repository, eventCallback store.EventCallback) (*domain.Repository, error)
Update(ctx context.Context, orgId uuid.UUID, repository *domain.Repository, eventCallback store.EventCallback) (*domain.Repository, error)
CreateOrUpdate(ctx context.Context, orgId uuid.UUID, repository *domain.Repository, eventCallback store.EventCallback) (*domain.Repository, bool, error)
Get(ctx context.Context, orgId uuid.UUID, name string) (*domain.Repository, error)
List(ctx context.Context, orgId uuid.UUID, listParams store.ListParams) (*domain.RepositoryList, error)
Delete(ctx context.Context, orgId uuid.UUID, name string, eventCallback store.EventCallback) error
UpdateStatus(ctx context.Context, orgId uuid.UUID, resource *domain.Repository, eventCallback store.EventCallback) (*domain.Repository, error)
GetFleetRefs(ctx context.Context, orgId uuid.UUID, name string) (*domain.FleetList, error)
GetDeviceRefs(ctx context.Context, orgId uuid.UUID, name string) (*domain.DeviceList, error)
// Used by domain metrics
Count(ctx context.Context, orgId uuid.UUID, listParams store.ListParams) (int64, error)
CountByOrg(ctx context.Context, orgId *uuid.UUID) ([]store.CountByOrgResult, error)
}
func NewRepositoryStore ¶
func NewRepositoryStore(db *gorm.DB, log logrus.FieldLogger) Store
Click to show internal directories.
Click to hide internal directories.