Documentation
¶
Index ¶
- Constants
- Variables
- func ApiFieldsToModel(apiRepo api.RepositoryRequest, repoConfig *models.RepositoryConfiguration, ...)
- func ApiUpdateFieldsToModel(apiRepo api.RepositoryUpdateRequest, ...)
- func FilteredConvert(yumPkgs []yum.Package, excludeChecksums []string) []models.Rpm
- func FilteredConvertEnvironments(yumEnvironments []yum.Environment, excludedEnvs []string) []models.Environment
- func FilteredConvertPackageGroups(yumPkgGroups []yum.PackageGroup, excludedHashes []string) []models.PackageGroup
- func LoadGpgKey(gpgKey *string) (openpgp.EntityList, error)
- func ModelToApiFields(repoConfig models.RepositoryConfiguration, apiRepo *api.RepositoryResponse)
- func ModelToExportRepoApi(model models.RepositoryConfiguration, resp *api.RepositoryExportResponse)
- func ModelToImportRepoApi(model models.RepositoryConfiguration, warnings []map[string]interface{}, ...)
- func ModuleMdToModuleStreams(moduleMds []yum.ModuleMD) (moduleStreams []models.ModuleStream)
- func ModuleStreamsToCollectionResponse(modules []models.ModuleStream) (response []api.SearchModuleStreams)
- func RepositoryDBErrorToApi(e error, uuid *string) *ce.DaoError
- func SnapshotModelToApi(model models.Snapshot, resp *api.SnapshotResponse)
- func SnapshotsDBToApiError(e error, uuid *string) *ce.DaoError
- func TasksDBToApiError(e error, uuid *string) *ce.DaoError
- func TemplateDBToApiError(e error, uuid *string) *ce.DaoError
- func UuidifyString(possibleUuid string) uuid2.UUID
- func UuidifyStrings(possibleUuids []string) []uuid2.UUID
- func ValidateSignature(ctx context.Context, repo yum.YumRepository, gpgKey *string) error
- type AdminTaskDao
- type DaoRegistry
- type DomainDao
- type EnvironmentDao
- type IntrospectionCount
- type ListRepoFilter
- type MetricsDao
- type MockAdminTaskDao
- type MockDaoRegistry
- type MockDomainDao
- func (_m *MockDomainDao) Delete(ctx context.Context, orgId string, domainName string) error
- func (_m *MockDomainDao) Fetch(ctx context.Context, orgId string) (string, error)
- func (_m *MockDomainDao) FetchOrCreateDomain(ctx context.Context, orgId string) (string, error)
- func (_m *MockDomainDao) List(ctx context.Context) ([]models.Domain, error)
- type MockEnvironmentDao
- func (_m *MockEnvironmentDao) InsertForRepository(ctx context.Context, repoUuid string, environments []yum.Environment) (int64, error)
- func (_m *MockEnvironmentDao) List(ctx context.Context, orgID string, uuidRepo string, limit int, offset int, ...) (api.RepositoryEnvironmentCollectionResponse, int64, error)
- func (_m *MockEnvironmentDao) OrphanCleanup(ctx context.Context) error
- func (_m *MockEnvironmentDao) Search(ctx context.Context, orgID string, request api.ContentUnitSearchRequest) ([]api.SearchEnvironmentResponse, error)
- func (_m *MockEnvironmentDao) SearchSnapshotEnvironments(ctx context.Context, orgId string, request api.SnapshotSearchRpmRequest) ([]api.SearchEnvironmentResponse, error)
- type MockMetricsDao
- func (_m *MockMetricsDao) OrganizationTotal(ctx context.Context) int64
- func (_m *MockMetricsDao) PendingTasksAverageLatency(ctx context.Context) float64
- func (_m *MockMetricsDao) PendingTasksCount(ctx context.Context) int64
- func (_m *MockMetricsDao) PendingTasksOldestTask(ctx context.Context) float64
- func (_m *MockMetricsDao) PublicRepositoriesFailedIntrospectionCount(ctx context.Context) int
- func (_m *MockMetricsDao) RHReposSnapshotNotCompletedInLast36HoursCount(ctx context.Context) int64
- func (_m *MockMetricsDao) RepositoriesCount(ctx context.Context) int
- func (_m *MockMetricsDao) RepositoriesIntrospectionCount(ctx context.Context, hours int, public bool) IntrospectionCount
- func (_m *MockMetricsDao) RepositoryConfigsCount(ctx context.Context) int
- func (_m *MockMetricsDao) TaskPendingTimeAverageByType(ctx context.Context) []TaskTypePendingTimeAverage
- func (_m *MockMetricsDao) TemplatesAgeAverage(ctx context.Context) float64
- func (_m *MockMetricsDao) TemplatesUpdatedInLast24HoursCount(ctx context.Context) int
- func (_m *MockMetricsDao) TemplatesUseDateCount(ctx context.Context) int
- func (_m *MockMetricsDao) TemplatesUseLatestCount(ctx context.Context) int
- type MockModuleStreamDao
- func (_m *MockModuleStreamDao) InsertForRepository(ctx context.Context, repoUuid string, pkgGroups []yum.ModuleMD) (int64, error)
- func (_m *MockModuleStreamDao) OrphanCleanup(ctx context.Context) error
- func (_m *MockModuleStreamDao) SearchRepositoryModuleStreams(ctx context.Context, orgID string, request api.SearchModuleStreamsRequest) ([]api.SearchModuleStreams, error)
- func (_m *MockModuleStreamDao) SearchSnapshotModuleStreams(ctx context.Context, orgID string, ...) ([]api.SearchModuleStreams, error)
- type MockPackageGroupDao
- func (_m *MockPackageGroupDao) InsertForRepository(ctx context.Context, repoUuid string, pkgGroups []yum.PackageGroup) (int64, error)
- func (_m *MockPackageGroupDao) List(ctx context.Context, orgID string, uuidRepo string, limit int, offset int, ...) (api.RepositoryPackageGroupCollectionResponse, int64, error)
- func (_m *MockPackageGroupDao) OrphanCleanup(ctx context.Context) error
- func (_m *MockPackageGroupDao) Search(ctx context.Context, orgID string, request api.ContentUnitSearchRequest) ([]api.SearchPackageGroupResponse, error)
- func (_m *MockPackageGroupDao) SearchSnapshotPackageGroups(ctx context.Context, orgId string, request api.SnapshotSearchRpmRequest) ([]api.SearchPackageGroupResponse, error)
- type MockRepositoryConfigDao
- func (_m *MockRepositoryConfigDao) BulkCreate(ctx context.Context, newRepositories []api.RepositoryRequest) ([]api.RepositoryResponse, []error)
- func (_m *MockRepositoryConfigDao) BulkDelete(ctx context.Context, orgID string, uuids []string) []error
- func (_m *MockRepositoryConfigDao) BulkExport(ctx context.Context, orgID string, reposToExport api.RepositoryExportRequest) ([]api.RepositoryExportResponse, error)
- func (_m *MockRepositoryConfigDao) BulkImport(ctx context.Context, reposToImport []api.RepositoryRequest) ([]api.RepositoryImportResponse, []error)
- func (_m *MockRepositoryConfigDao) Create(ctx context.Context, newRepo api.RepositoryRequest) (api.RepositoryResponse, error)
- func (_m *MockRepositoryConfigDao) Delete(ctx context.Context, orgID string, uuid string) error
- func (_m *MockRepositoryConfigDao) Fetch(ctx context.Context, orgID string, uuid string) (api.RepositoryResponse, error)
- func (_m *MockRepositoryConfigDao) FetchByRepoUuid(ctx context.Context, orgID string, repoUuid string) (api.RepositoryResponse, error)
- func (_m *MockRepositoryConfigDao) FetchWithoutOrgID(ctx context.Context, uuid string) (api.RepositoryResponse, error)
- func (_m *MockRepositoryConfigDao) InternalOnly_FetchRepoConfigsForRepoUUID(ctx context.Context, uuid string) []api.RepositoryResponse
- func (_m *MockRepositoryConfigDao) InternalOnly_IncrementFailedSnapshotCount(ctx context.Context, rcUuid string) error
- func (_m *MockRepositoryConfigDao) InternalOnly_ListReposToSnapshot(ctx context.Context, filter *ListRepoFilter) ([]models.RepositoryConfiguration, error)
- func (_m *MockRepositoryConfigDao) InternalOnly_RefreshRedHatRepo(ctx context.Context, request api.RepositoryRequest, label string, ...) (*api.RepositoryResponse, error)
- func (_m *MockRepositoryConfigDao) InternalOnly_ResetFailedSnapshotCount(ctx context.Context, rcUuid string) error
- func (_m *MockRepositoryConfigDao) List(ctx context.Context, orgID string, paginationData api.PaginationData, ...) (api.RepositoryCollectionResponse, int64, error)
- func (_m *MockRepositoryConfigDao) ListReposWithOutdatedSnapshots(ctx context.Context, olderThanDays int) ([]models.RepositoryConfiguration, error)
- func (_m *MockRepositoryConfigDao) SavePublicRepos(ctx context.Context, urls []string) error
- func (_m *MockRepositoryConfigDao) SoftDelete(ctx context.Context, orgID string, uuid string) error
- func (_m *MockRepositoryConfigDao) Update(ctx context.Context, orgID string, uuid string, ...) (bool, error)
- func (_m *MockRepositoryConfigDao) UpdateLastSnapshot(ctx context.Context, orgID string, repoConfigUUID string, snapUUID string) error
- func (_m *MockRepositoryConfigDao) UpdateLastSnapshotTask(ctx context.Context, taskUUID string, orgID string, repoUUID string) error
- func (_m *MockRepositoryConfigDao) ValidateParameters(ctx context.Context, orgId string, params api.RepositoryValidationRequest, ...) (api.RepositoryValidationResponse, error)
- func (m *MockRepositoryConfigDao) WithContextMock() *MockRepositoryConfigDao
- type MockRepositoryDao
- func (_m *MockRepositoryDao) FetchForUrl(ctx context.Context, url string) (Repository, error)
- func (_m *MockRepositoryDao) FetchRepositoryRPMCount(ctx context.Context, repoUUID string) (int, error)
- func (_m *MockRepositoryDao) ListForIntrospection(ctx context.Context, urls *[]string, force bool) ([]Repository, error)
- func (_m *MockRepositoryDao) ListPublic(ctx context.Context, paginationData api.PaginationData, _a2 api.FilterData) (api.PublicRepositoryCollectionResponse, int64, error)
- func (_m *MockRepositoryDao) OrphanCleanup(ctx context.Context) error
- func (_m *MockRepositoryDao) Update(ctx context.Context, repo RepositoryUpdate) error
- type MockRpmDao
- func (_m *MockRpmDao) DetectRpms(ctx context.Context, orgID string, request api.DetectRpmsRequest) (*api.DetectRpmsResponse, error)
- func (_m *MockRpmDao) InsertForRepository(ctx context.Context, repoUuid string, pkgs []yum.Package) (int64, error)
- func (_m *MockRpmDao) List(ctx context.Context, orgID string, uuidRepo string, limit int, offset int, ...) (api.RepositoryRpmCollectionResponse, int64, error)
- func (_m *MockRpmDao) ListSnapshotErrata(ctx context.Context, orgId string, snapshotUUIDs []string, ...) ([]api.SnapshotErrata, int, error)
- func (_m *MockRpmDao) ListSnapshotRpms(ctx context.Context, orgId string, snapshotUUIDs []string, search string, ...) ([]api.SnapshotRpm, int, error)
- func (_m *MockRpmDao) ListTemplateErrata(ctx context.Context, orgId string, templateUUID string, ...) ([]api.SnapshotErrata, int, error)
- func (_m *MockRpmDao) ListTemplateRpms(ctx context.Context, orgId string, templateUUID string, search string, ...) ([]api.SnapshotRpm, int, error)
- func (_m *MockRpmDao) OrphanCleanup(ctx context.Context) error
- func (_m *MockRpmDao) Search(ctx context.Context, orgID string, request api.ContentUnitSearchRequest) ([]api.SearchRpmResponse, error)
- func (_m *MockRpmDao) SearchSnapshotRpms(ctx context.Context, orgId string, request api.SnapshotSearchRpmRequest) ([]api.SearchRpmResponse, error)
- type MockSnapshotDao
- func (_m *MockSnapshotDao) BulkDelete(ctx context.Context, uuids []string) []error
- func (_m *MockSnapshotDao) ClearDeletedAt(ctx context.Context, snapUUID string) error
- func (_m *MockSnapshotDao) Create(ctx context.Context, snap *models.Snapshot) error
- func (_m *MockSnapshotDao) Delete(ctx context.Context, snapUUID string) error
- func (_m *MockSnapshotDao) Fetch(ctx context.Context, uuid string) (api.SnapshotResponse, error)
- func (_m *MockSnapshotDao) FetchForRepoConfigUUID(ctx context.Context, repoConfigUUID string) ([]models.Snapshot, error)
- func (_m *MockSnapshotDao) FetchLatestSnapshot(ctx context.Context, repoConfigUUID string) (api.SnapshotResponse, error)
- func (_m *MockSnapshotDao) FetchLatestSnapshotModel(ctx context.Context, repoConfigUUID string) (models.Snapshot, error)
- func (_m *MockSnapshotDao) FetchModel(ctx context.Context, uuid string, includeSoftDel bool) (models.Snapshot, error)
- func (_m *MockSnapshotDao) FetchSnapshotByVersionHref(ctx context.Context, repoConfigUUID string, versionHref string) (*api.SnapshotResponse, error)
- func (_m *MockSnapshotDao) FetchSnapshotsByDateAndRepository(ctx context.Context, orgID string, request api.ListSnapshotByDateRequest) (api.ListSnapshotByDateResponse, error)
- func (_m *MockSnapshotDao) FetchSnapshotsModelByDateAndRepository(ctx context.Context, orgID string, request api.ListSnapshotByDateRequest) ([]models.Snapshot, error)
- func (_m *MockSnapshotDao) GetRepositoryConfigurationFile(ctx context.Context, orgID string, snapshotUUID string, isLatest bool) (string, error)
- func (_m *MockSnapshotDao) List(ctx context.Context, orgID string, repoConfigUuid string, ...) (api.SnapshotCollectionResponse, int64, error)
- func (_m *MockSnapshotDao) ListByTemplate(ctx context.Context, orgID string, template api.TemplateResponse, ...) (api.SnapshotCollectionResponse, int64, error)
- func (_m *MockSnapshotDao) SoftDelete(ctx context.Context, snapUUID string) error
- func (m *MockSnapshotDao) WithContextMock() *MockSnapshotDao
- type MockTaskInfoDao
- func (_m *MockTaskInfoDao) Cleanup(ctx context.Context) error
- func (_m *MockTaskInfoDao) Fetch(ctx context.Context, OrgID string, id string) (api.TaskInfoResponse, error)
- func (_m *MockTaskInfoDao) FetchActiveTasks(ctx context.Context, orgID string, objectUUID string, taskTypes ...string) ([]string, error)
- func (_m *MockTaskInfoDao) List(ctx context.Context, OrgID string, pageData api.PaginationData, ...) (api.TaskInfoCollectionResponse, int64, error)
- type MockTemplateDao
- func (_m *MockTemplateDao) ClearDeletedAt(ctx context.Context, orgID string, uuid string) error
- func (_m *MockTemplateDao) Create(ctx context.Context, templateRequest api.TemplateRequest) (api.TemplateResponse, error)
- func (_m *MockTemplateDao) Delete(ctx context.Context, orgID string, uuid string) error
- func (_m *MockTemplateDao) DeleteTemplateRepoConfigs(ctx context.Context, templateUUID string, keepRepoConfigUUIDs []string) error
- func (_m *MockTemplateDao) DeleteTemplateSnapshot(ctx context.Context, snapshotUUID string) error
- func (_m *MockTemplateDao) Fetch(ctx context.Context, orgID string, uuid string, includeSoftDel bool) (api.TemplateResponse, error)
- func (_m *MockTemplateDao) GetDistributionHref(ctx context.Context, templateUUID string, repoConfigUUID string) (string, error)
- func (_m *MockTemplateDao) GetRepoChanges(ctx context.Context, templateUUID string, newRepoConfigUUIDs []string) ([]string, []string, []string, []string, error)
- func (_m *MockTemplateDao) GetRepositoryConfigurationFile(ctx context.Context, orgID string, templateUUID string) (string, error)
- func (_m *MockTemplateDao) InternalOnlyFetchByName(ctx context.Context, name string) (models.Template, error)
- func (_m *MockTemplateDao) InternalOnlyGetTemplatesForRepoConfig(ctx context.Context, repoUUID string, useLatestOnly bool) ([]api.TemplateResponse, error)
- func (_m *MockTemplateDao) List(ctx context.Context, orgID string, includeSoftDel bool, ...) (api.TemplateCollectionResponse, int64, error)
- func (_m *MockTemplateDao) SetEnvironmentCreated(ctx context.Context, templateUUID string) error
- func (_m *MockTemplateDao) SoftDelete(ctx context.Context, orgID string, uuid string) error
- func (_m *MockTemplateDao) Update(ctx context.Context, orgID string, uuid string, ...) (api.TemplateResponse, error)
- func (_m *MockTemplateDao) UpdateDistributionHrefs(ctx context.Context, templateUUID string, repoUUIDs []string, ...) error
- func (_m *MockTemplateDao) UpdateLastError(ctx context.Context, orgID string, templateUUID string, ...) error
- func (_m *MockTemplateDao) UpdateLastUpdateTask(ctx context.Context, taskUUID string, orgID string, templateUUID string) error
- func (_m *MockTemplateDao) UpdateSnapshots(ctx context.Context, templateUUID string, repoUUIDs []string, ...) error
- type ModuleStreamDao
- type PackageGroupDao
- type Repository
- type RepositoryConfigDao
- type RepositoryDao
- type RepositoryUpdate
- type RpmDao
- type SnapshotDao
- type TaskInfoDao
- type TaskTypePendingTimeAverage
- type TemplateDao
- type UploadDao
Constants ¶
const JoinSelectQuery = `` /* 575-byte string literal not displayed */
Variables ¶
var DbInClauseLimit = 60000
Functions ¶
func ApiFieldsToModel ¶
func ApiFieldsToModel(apiRepo api.RepositoryRequest, repoConfig *models.RepositoryConfiguration, repo *models.Repository)
func ApiUpdateFieldsToModel ¶
func ApiUpdateFieldsToModel(apiRepo api.RepositoryUpdateRequest, repoConfig *models.RepositoryConfiguration, repo *models.Repository)
func FilteredConvert ¶
FilteredConvert Given a list of yum.Package objects, it converts them to model.Rpm packages while filtering out any checksums that are in the excludedChecksums parameter
func FilteredConvertEnvironments ¶
func FilteredConvertEnvironments(yumEnvironments []yum.Environment, excludedEnvs []string) []models.Environment
FilteredConvertEnvironments, given a list of yum.Environment objects, converts them to model.Environment while filtering out any envs that are in the excludedEnvs parameter
func FilteredConvertPackageGroups ¶
func FilteredConvertPackageGroups(yumPkgGroups []yum.PackageGroup, excludedHashes []string) []models.PackageGroup
FilteredConvertPackageGroups Given a list of yum.PackageGroup objects, it converts them to model.PackageGroup while filtering out any groups with hashes in the excludedHashes parameter
func LoadGpgKey ¶
func LoadGpgKey(gpgKey *string) (openpgp.EntityList, error)
func ModelToApiFields ¶
func ModelToApiFields(repoConfig models.RepositoryConfiguration, apiRepo *api.RepositoryResponse)
func ModelToExportRepoApi ¶
func ModelToExportRepoApi(model models.RepositoryConfiguration, resp *api.RepositoryExportResponse)
func ModelToImportRepoApi ¶
func ModelToImportRepoApi(model models.RepositoryConfiguration, warnings []map[string]interface{}, resp *api.RepositoryImportResponse)
func ModuleMdToModuleStreams ¶
func ModuleMdToModuleStreams(moduleMds []yum.ModuleMD) (moduleStreams []models.ModuleStream)
func ModuleStreamsToCollectionResponse ¶
func ModuleStreamsToCollectionResponse(modules []models.ModuleStream) (response []api.SearchModuleStreams)
func SnapshotModelToApi ¶
func SnapshotModelToApi(model models.Snapshot, resp *api.SnapshotResponse)
func UuidifyString ¶
func UuidifyStrings ¶
func ValidateSignature ¶
Types ¶
type AdminTaskDao ¶
type AdminTaskDao interface { Fetch(ctx context.Context, id string) (api.AdminTaskInfoResponse, error) List(ctx context.Context, pageData api.PaginationData, filterData api.AdminTaskFilterData) (api.AdminTaskInfoCollectionResponse, int64, error) }
func GetAdminTaskDao ¶
func GetAdminTaskDao(db *gorm.DB, pulpClient pulp_client.PulpClient) AdminTaskDao
type DaoRegistry ¶
type DaoRegistry struct { RepositoryConfig RepositoryConfigDao Rpm RpmDao Repository RepositoryDao Metrics MetricsDao Snapshot SnapshotDao TaskInfo TaskInfoDao AdminTask AdminTaskDao Domain DomainDao PackageGroup PackageGroupDao ModuleStream ModuleStreamDao Environment EnvironmentDao Template TemplateDao Uploads UploadDao }
func GetDaoRegistry ¶
func GetDaoRegistry(db *gorm.DB) *DaoRegistry
type DomainDao ¶
type DomainDao interface { FetchOrCreateDomain(ctx context.Context, orgId string) (string, error) Fetch(ctx context.Context, orgId string) (string, error) List(ctx context.Context) ([]models.Domain, error) Delete(ctx context.Context, orgId string, domainName string) error }
func GetDomainDao ¶
func GetDomainDao(db *gorm.DB, pulpClient pulp_client.PulpGlobalClient, candlepinClient candlepin_client.CandlepinClient) DomainDao
type EnvironmentDao ¶
type EnvironmentDao interface { List(ctx context.Context, orgID string, uuidRepo string, limit int, offset int, search string, sortBy string) (api.RepositoryEnvironmentCollectionResponse, int64, error) Search(ctx context.Context, orgID string, request api.ContentUnitSearchRequest) ([]api.SearchEnvironmentResponse, error) InsertForRepository(ctx context.Context, repoUuid string, environments []yum.Environment) (int64, error) OrphanCleanup(ctx context.Context) error SearchSnapshotEnvironments(ctx context.Context, orgId string, request api.SnapshotSearchRpmRequest) ([]api.SearchEnvironmentResponse, error) }
func GetEnvironmentDao ¶
func GetEnvironmentDao(db *gorm.DB) EnvironmentDao
type IntrospectionCount ¶
type ListRepoFilter ¶
type MetricsDao ¶
type MetricsDao interface { RepositoriesCount(ctx context.Context) int RepositoryConfigsCount(ctx context.Context) int RepositoriesIntrospectionCount(ctx context.Context, hours int, public bool) IntrospectionCount PublicRepositoriesFailedIntrospectionCount(ctx context.Context) int OrganizationTotal(ctx context.Context) int64 PendingTasksAverageLatency(ctx context.Context) float64 PendingTasksCount(ctx context.Context) int64 PendingTasksOldestTask(ctx context.Context) float64 RHReposSnapshotNotCompletedInLast36HoursCount(ctx context.Context) int64 TaskPendingTimeAverageByType(ctx context.Context) []TaskTypePendingTimeAverage TemplatesUseLatestCount(ctx context.Context) int TemplatesUseDateCount(ctx context.Context) int TemplatesUpdatedInLast24HoursCount(ctx context.Context) int TemplatesAgeAverage(ctx context.Context) float64 }
func GetMetricsDao ¶
func GetMetricsDao(db *gorm.DB) MetricsDao
type MockAdminTaskDao ¶
MockAdminTaskDao is an autogenerated mock type for the AdminTaskDao type
func NewMockAdminTaskDao ¶
func NewMockAdminTaskDao(t interface { mock.TestingT Cleanup(func()) }) *MockAdminTaskDao
NewMockAdminTaskDao creates a new instance of MockAdminTaskDao. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockAdminTaskDao) Fetch ¶
func (_m *MockAdminTaskDao) Fetch(ctx context.Context, id string) (api.AdminTaskInfoResponse, error)
Fetch provides a mock function with given fields: ctx, id
func (*MockAdminTaskDao) List ¶
func (_m *MockAdminTaskDao) List(ctx context.Context, pageData api.PaginationData, filterData api.AdminTaskFilterData) (api.AdminTaskInfoCollectionResponse, int64, error)
List provides a mock function with given fields: ctx, pageData, filterData
type MockDaoRegistry ¶
type MockDaoRegistry struct { RepositoryConfig MockRepositoryConfigDao Rpm MockRpmDao Repository MockRepositoryDao Metrics MockMetricsDao Snapshot MockSnapshotDao TaskInfo MockTaskInfoDao AdminTask MockAdminTaskDao Domain MockDomainDao PackageGroup MockPackageGroupDao Environment MockEnvironmentDao Template MockTemplateDao ModuleStream MockModuleStreamDao }
func GetMockDaoRegistry ¶
func GetMockDaoRegistry(t *testing.T) *MockDaoRegistry
func (*MockDaoRegistry) ToDaoRegistry ¶
func (m *MockDaoRegistry) ToDaoRegistry() *DaoRegistry
type MockDomainDao ¶
MockDomainDao is an autogenerated mock type for the DomainDao type
func NewMockDomainDao ¶
func NewMockDomainDao(t interface { mock.TestingT Cleanup(func()) }) *MockDomainDao
NewMockDomainDao creates a new instance of MockDomainDao. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockDomainDao) Delete ¶
Delete provides a mock function with given fields: ctx, orgId, domainName
func (*MockDomainDao) FetchOrCreateDomain ¶
FetchOrCreateDomain provides a mock function with given fields: ctx, orgId
type MockEnvironmentDao ¶
MockEnvironmentDao is an autogenerated mock type for the EnvironmentDao type
func NewMockEnvironmentDao ¶
func NewMockEnvironmentDao(t interface { mock.TestingT Cleanup(func()) }) *MockEnvironmentDao
NewMockEnvironmentDao creates a new instance of MockEnvironmentDao. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockEnvironmentDao) InsertForRepository ¶
func (_m *MockEnvironmentDao) InsertForRepository(ctx context.Context, repoUuid string, environments []yum.Environment) (int64, error)
InsertForRepository provides a mock function with given fields: ctx, repoUuid, environments
func (*MockEnvironmentDao) List ¶
func (_m *MockEnvironmentDao) List(ctx context.Context, orgID string, uuidRepo string, limit int, offset int, search string, sortBy string) (api.RepositoryEnvironmentCollectionResponse, int64, error)
List provides a mock function with given fields: ctx, orgID, uuidRepo, limit, offset, search, sortBy
func (*MockEnvironmentDao) OrphanCleanup ¶
func (_m *MockEnvironmentDao) OrphanCleanup(ctx context.Context) error
OrphanCleanup provides a mock function with given fields: ctx
func (*MockEnvironmentDao) Search ¶
func (_m *MockEnvironmentDao) Search(ctx context.Context, orgID string, request api.ContentUnitSearchRequest) ([]api.SearchEnvironmentResponse, error)
Search provides a mock function with given fields: ctx, orgID, request
func (*MockEnvironmentDao) SearchSnapshotEnvironments ¶
func (_m *MockEnvironmentDao) SearchSnapshotEnvironments(ctx context.Context, orgId string, request api.SnapshotSearchRpmRequest) ([]api.SearchEnvironmentResponse, error)
SearchSnapshotEnvironments provides a mock function with given fields: ctx, orgId, request
type MockMetricsDao ¶
MockMetricsDao is an autogenerated mock type for the MetricsDao type
func NewMockMetricsDao ¶
func NewMockMetricsDao(t interface { mock.TestingT Cleanup(func()) }) *MockMetricsDao
NewMockMetricsDao creates a new instance of MockMetricsDao. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockMetricsDao) OrganizationTotal ¶
func (_m *MockMetricsDao) OrganizationTotal(ctx context.Context) int64
OrganizationTotal provides a mock function with given fields: ctx
func (*MockMetricsDao) PendingTasksAverageLatency ¶
func (_m *MockMetricsDao) PendingTasksAverageLatency(ctx context.Context) float64
PendingTasksAverageLatency provides a mock function with given fields: ctx
func (*MockMetricsDao) PendingTasksCount ¶
func (_m *MockMetricsDao) PendingTasksCount(ctx context.Context) int64
PendingTasksCount provides a mock function with given fields: ctx
func (*MockMetricsDao) PendingTasksOldestTask ¶
func (_m *MockMetricsDao) PendingTasksOldestTask(ctx context.Context) float64
PendingTasksOldestTask provides a mock function with given fields: ctx
func (*MockMetricsDao) PublicRepositoriesFailedIntrospectionCount ¶
func (_m *MockMetricsDao) PublicRepositoriesFailedIntrospectionCount(ctx context.Context) int
PublicRepositoriesFailedIntrospectionCount provides a mock function with given fields: ctx
func (*MockMetricsDao) RHReposSnapshotNotCompletedInLast36HoursCount ¶
func (_m *MockMetricsDao) RHReposSnapshotNotCompletedInLast36HoursCount(ctx context.Context) int64
RHReposSnapshotNotCompletedInLast36HoursCount provides a mock function with given fields: ctx
func (*MockMetricsDao) RepositoriesCount ¶
func (_m *MockMetricsDao) RepositoriesCount(ctx context.Context) int
RepositoriesCount provides a mock function with given fields: ctx
func (*MockMetricsDao) RepositoriesIntrospectionCount ¶
func (_m *MockMetricsDao) RepositoriesIntrospectionCount(ctx context.Context, hours int, public bool) IntrospectionCount
RepositoriesIntrospectionCount provides a mock function with given fields: ctx, hours, public
func (*MockMetricsDao) RepositoryConfigsCount ¶
func (_m *MockMetricsDao) RepositoryConfigsCount(ctx context.Context) int
RepositoryConfigsCount provides a mock function with given fields: ctx
func (*MockMetricsDao) TaskPendingTimeAverageByType ¶
func (_m *MockMetricsDao) TaskPendingTimeAverageByType(ctx context.Context) []TaskTypePendingTimeAverage
TaskPendingTimeAverageByType provides a mock function with given fields: ctx
func (*MockMetricsDao) TemplatesAgeAverage ¶
func (_m *MockMetricsDao) TemplatesAgeAverage(ctx context.Context) float64
TemplatesAgeAverage provides a mock function with given fields: ctx
func (*MockMetricsDao) TemplatesUpdatedInLast24HoursCount ¶
func (_m *MockMetricsDao) TemplatesUpdatedInLast24HoursCount(ctx context.Context) int
TemplatesUpdatedInLast24HoursCount provides a mock function with given fields: ctx
func (*MockMetricsDao) TemplatesUseDateCount ¶
func (_m *MockMetricsDao) TemplatesUseDateCount(ctx context.Context) int
TemplatesUseDateCount provides a mock function with given fields: ctx
func (*MockMetricsDao) TemplatesUseLatestCount ¶
func (_m *MockMetricsDao) TemplatesUseLatestCount(ctx context.Context) int
TemplatesUseLatestCount provides a mock function with given fields: ctx
type MockModuleStreamDao ¶
MockModuleStreamDao is an autogenerated mock type for the ModuleStreamDao type
func NewMockModuleStreamDao ¶
func NewMockModuleStreamDao(t interface { mock.TestingT Cleanup(func()) }) *MockModuleStreamDao
NewMockModuleStreamDao creates a new instance of MockModuleStreamDao. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockModuleStreamDao) InsertForRepository ¶
func (_m *MockModuleStreamDao) InsertForRepository(ctx context.Context, repoUuid string, pkgGroups []yum.ModuleMD) (int64, error)
InsertForRepository provides a mock function with given fields: ctx, repoUuid, pkgGroups
func (*MockModuleStreamDao) OrphanCleanup ¶
func (_m *MockModuleStreamDao) OrphanCleanup(ctx context.Context) error
OrphanCleanup provides a mock function with given fields: ctx
func (*MockModuleStreamDao) SearchRepositoryModuleStreams ¶
func (_m *MockModuleStreamDao) SearchRepositoryModuleStreams(ctx context.Context, orgID string, request api.SearchModuleStreamsRequest) ([]api.SearchModuleStreams, error)
SearchRepositoryModuleStreams provides a mock function with given fields: ctx, orgID, request
func (*MockModuleStreamDao) SearchSnapshotModuleStreams ¶
func (_m *MockModuleStreamDao) SearchSnapshotModuleStreams(ctx context.Context, orgID string, request api.SearchSnapshotModuleStreamsRequest) ([]api.SearchModuleStreams, error)
SearchSnapshotModuleStreams provides a mock function with given fields: ctx, orgID, request
type MockPackageGroupDao ¶
MockPackageGroupDao is an autogenerated mock type for the PackageGroupDao type
func NewMockPackageGroupDao ¶
func NewMockPackageGroupDao(t interface { mock.TestingT Cleanup(func()) }) *MockPackageGroupDao
NewMockPackageGroupDao creates a new instance of MockPackageGroupDao. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockPackageGroupDao) InsertForRepository ¶
func (_m *MockPackageGroupDao) InsertForRepository(ctx context.Context, repoUuid string, pkgGroups []yum.PackageGroup) (int64, error)
InsertForRepository provides a mock function with given fields: ctx, repoUuid, pkgGroups
func (*MockPackageGroupDao) List ¶
func (_m *MockPackageGroupDao) List(ctx context.Context, orgID string, uuidRepo string, limit int, offset int, search string, sortBy string) (api.RepositoryPackageGroupCollectionResponse, int64, error)
List provides a mock function with given fields: ctx, orgID, uuidRepo, limit, offset, search, sortBy
func (*MockPackageGroupDao) OrphanCleanup ¶
func (_m *MockPackageGroupDao) OrphanCleanup(ctx context.Context) error
OrphanCleanup provides a mock function with given fields: ctx
func (*MockPackageGroupDao) Search ¶
func (_m *MockPackageGroupDao) Search(ctx context.Context, orgID string, request api.ContentUnitSearchRequest) ([]api.SearchPackageGroupResponse, error)
Search provides a mock function with given fields: ctx, orgID, request
func (*MockPackageGroupDao) SearchSnapshotPackageGroups ¶
func (_m *MockPackageGroupDao) SearchSnapshotPackageGroups(ctx context.Context, orgId string, request api.SnapshotSearchRpmRequest) ([]api.SearchPackageGroupResponse, error)
SearchSnapshotPackageGroups provides a mock function with given fields: ctx, orgId, request
type MockRepositoryConfigDao ¶
MockRepositoryConfigDao is an autogenerated mock type for the RepositoryConfigDao type
func NewMockRepositoryConfigDao ¶
func NewMockRepositoryConfigDao(t interface { mock.TestingT Cleanup(func()) }) *MockRepositoryConfigDao
NewMockRepositoryConfigDao creates a new instance of MockRepositoryConfigDao. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockRepositoryConfigDao) BulkCreate ¶
func (_m *MockRepositoryConfigDao) BulkCreate(ctx context.Context, newRepositories []api.RepositoryRequest) ([]api.RepositoryResponse, []error)
BulkCreate provides a mock function with given fields: ctx, newRepositories
func (*MockRepositoryConfigDao) BulkDelete ¶
func (_m *MockRepositoryConfigDao) BulkDelete(ctx context.Context, orgID string, uuids []string) []error
BulkDelete provides a mock function with given fields: ctx, orgID, uuids
func (*MockRepositoryConfigDao) BulkExport ¶
func (_m *MockRepositoryConfigDao) BulkExport(ctx context.Context, orgID string, reposToExport api.RepositoryExportRequest) ([]api.RepositoryExportResponse, error)
BulkExport provides a mock function with given fields: ctx, orgID, reposToExport
func (*MockRepositoryConfigDao) BulkImport ¶
func (_m *MockRepositoryConfigDao) BulkImport(ctx context.Context, reposToImport []api.RepositoryRequest) ([]api.RepositoryImportResponse, []error)
BulkImport provides a mock function with given fields: ctx, reposToImport
func (*MockRepositoryConfigDao) Create ¶
func (_m *MockRepositoryConfigDao) Create(ctx context.Context, newRepo api.RepositoryRequest) (api.RepositoryResponse, error)
Create provides a mock function with given fields: ctx, newRepo
func (*MockRepositoryConfigDao) Delete ¶
Delete provides a mock function with given fields: ctx, orgID, uuid
func (*MockRepositoryConfigDao) Fetch ¶
func (_m *MockRepositoryConfigDao) Fetch(ctx context.Context, orgID string, uuid string) (api.RepositoryResponse, error)
Fetch provides a mock function with given fields: ctx, orgID, uuid
func (*MockRepositoryConfigDao) FetchByRepoUuid ¶
func (_m *MockRepositoryConfigDao) FetchByRepoUuid(ctx context.Context, orgID string, repoUuid string) (api.RepositoryResponse, error)
FetchByRepoUuid provides a mock function with given fields: ctx, orgID, repoUuid
func (*MockRepositoryConfigDao) FetchWithoutOrgID ¶
func (_m *MockRepositoryConfigDao) FetchWithoutOrgID(ctx context.Context, uuid string) (api.RepositoryResponse, error)
FetchWithoutOrgID provides a mock function with given fields: ctx, uuid
func (*MockRepositoryConfigDao) InternalOnly_FetchRepoConfigsForRepoUUID ¶
func (_m *MockRepositoryConfigDao) InternalOnly_FetchRepoConfigsForRepoUUID(ctx context.Context, uuid string) []api.RepositoryResponse
InternalOnly_FetchRepoConfigsForRepoUUID provides a mock function with given fields: ctx, uuid
func (*MockRepositoryConfigDao) InternalOnly_IncrementFailedSnapshotCount ¶
func (_m *MockRepositoryConfigDao) InternalOnly_IncrementFailedSnapshotCount(ctx context.Context, rcUuid string) error
InternalOnly_IncrementFailedSnapshotCount provides a mock function with given fields: ctx, rcUuid
func (*MockRepositoryConfigDao) InternalOnly_ListReposToSnapshot ¶
func (_m *MockRepositoryConfigDao) InternalOnly_ListReposToSnapshot(ctx context.Context, filter *ListRepoFilter) ([]models.RepositoryConfiguration, error)
InternalOnly_ListReposToSnapshot provides a mock function with given fields: ctx, filter
func (*MockRepositoryConfigDao) InternalOnly_RefreshRedHatRepo ¶
func (_m *MockRepositoryConfigDao) InternalOnly_RefreshRedHatRepo(ctx context.Context, request api.RepositoryRequest, label string, featureName string) (*api.RepositoryResponse, error)
InternalOnly_RefreshRedHatRepo provides a mock function with given fields: ctx, request, label, featureName
func (*MockRepositoryConfigDao) InternalOnly_ResetFailedSnapshotCount ¶
func (_m *MockRepositoryConfigDao) InternalOnly_ResetFailedSnapshotCount(ctx context.Context, rcUuid string) error
InternalOnly_ResetFailedSnapshotCount provides a mock function with given fields: ctx, rcUuid
func (*MockRepositoryConfigDao) List ¶
func (_m *MockRepositoryConfigDao) List(ctx context.Context, orgID string, paginationData api.PaginationData, filterData api.FilterData) (api.RepositoryCollectionResponse, int64, error)
List provides a mock function with given fields: ctx, orgID, paginationData, filterData
func (*MockRepositoryConfigDao) ListReposWithOutdatedSnapshots ¶
func (_m *MockRepositoryConfigDao) ListReposWithOutdatedSnapshots(ctx context.Context, olderThanDays int) ([]models.RepositoryConfiguration, error)
ListReposWithOutdatedSnapshots provides a mock function with given fields: ctx, olderThanDays
func (*MockRepositoryConfigDao) SavePublicRepos ¶
func (_m *MockRepositoryConfigDao) SavePublicRepos(ctx context.Context, urls []string) error
SavePublicRepos provides a mock function with given fields: ctx, urls
func (*MockRepositoryConfigDao) SoftDelete ¶
SoftDelete provides a mock function with given fields: ctx, orgID, uuid
func (*MockRepositoryConfigDao) Update ¶
func (_m *MockRepositoryConfigDao) Update(ctx context.Context, orgID string, uuid string, repoParams api.RepositoryUpdateRequest) (bool, error)
Update provides a mock function with given fields: ctx, orgID, uuid, repoParams
func (*MockRepositoryConfigDao) UpdateLastSnapshot ¶
func (_m *MockRepositoryConfigDao) UpdateLastSnapshot(ctx context.Context, orgID string, repoConfigUUID string, snapUUID string) error
UpdateLastSnapshot provides a mock function with given fields: ctx, orgID, repoConfigUUID, snapUUID
func (*MockRepositoryConfigDao) UpdateLastSnapshotTask ¶
func (_m *MockRepositoryConfigDao) UpdateLastSnapshotTask(ctx context.Context, taskUUID string, orgID string, repoUUID string) error
UpdateLastSnapshotTask provides a mock function with given fields: ctx, taskUUID, orgID, repoUUID
func (*MockRepositoryConfigDao) ValidateParameters ¶
func (_m *MockRepositoryConfigDao) ValidateParameters(ctx context.Context, orgId string, params api.RepositoryValidationRequest, excludedUUIDS []string) (api.RepositoryValidationResponse, error)
ValidateParameters provides a mock function with given fields: ctx, orgId, params, excludedUUIDS
func (*MockRepositoryConfigDao) WithContextMock ¶
func (m *MockRepositoryConfigDao) WithContextMock() *MockRepositoryConfigDao
type MockRepositoryDao ¶
MockRepositoryDao is an autogenerated mock type for the RepositoryDao type
func NewMockRepositoryDao ¶
func NewMockRepositoryDao(t interface { mock.TestingT Cleanup(func()) }) *MockRepositoryDao
NewMockRepositoryDao creates a new instance of MockRepositoryDao. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockRepositoryDao) FetchForUrl ¶
func (_m *MockRepositoryDao) FetchForUrl(ctx context.Context, url string) (Repository, error)
FetchForUrl provides a mock function with given fields: ctx, url
func (*MockRepositoryDao) FetchRepositoryRPMCount ¶
func (_m *MockRepositoryDao) FetchRepositoryRPMCount(ctx context.Context, repoUUID string) (int, error)
FetchRepositoryRPMCount provides a mock function with given fields: ctx, repoUUID
func (*MockRepositoryDao) ListForIntrospection ¶
func (_m *MockRepositoryDao) ListForIntrospection(ctx context.Context, urls *[]string, force bool) ([]Repository, error)
ListForIntrospection provides a mock function with given fields: ctx, urls, force
func (*MockRepositoryDao) ListPublic ¶
func (_m *MockRepositoryDao) ListPublic(ctx context.Context, paginationData api.PaginationData, _a2 api.FilterData) (api.PublicRepositoryCollectionResponse, int64, error)
ListPublic provides a mock function with given fields: ctx, paginationData, _a2
func (*MockRepositoryDao) OrphanCleanup ¶
func (_m *MockRepositoryDao) OrphanCleanup(ctx context.Context) error
OrphanCleanup provides a mock function with given fields: ctx
func (*MockRepositoryDao) Update ¶
func (_m *MockRepositoryDao) Update(ctx context.Context, repo RepositoryUpdate) error
Update provides a mock function with given fields: ctx, repo
type MockRpmDao ¶
MockRpmDao is an autogenerated mock type for the RpmDao type
func NewMockRpmDao ¶
func NewMockRpmDao(t interface { mock.TestingT Cleanup(func()) }) *MockRpmDao
NewMockRpmDao creates a new instance of MockRpmDao. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockRpmDao) DetectRpms ¶
func (_m *MockRpmDao) DetectRpms(ctx context.Context, orgID string, request api.DetectRpmsRequest) (*api.DetectRpmsResponse, error)
DetectRpms provides a mock function with given fields: ctx, orgID, request
func (*MockRpmDao) InsertForRepository ¶
func (_m *MockRpmDao) InsertForRepository(ctx context.Context, repoUuid string, pkgs []yum.Package) (int64, error)
InsertForRepository provides a mock function with given fields: ctx, repoUuid, pkgs
func (*MockRpmDao) List ¶
func (_m *MockRpmDao) List(ctx context.Context, orgID string, uuidRepo string, limit int, offset int, search string, sortBy string) (api.RepositoryRpmCollectionResponse, int64, error)
List provides a mock function with given fields: ctx, orgID, uuidRepo, limit, offset, search, sortBy
func (*MockRpmDao) ListSnapshotErrata ¶
func (_m *MockRpmDao) ListSnapshotErrata(ctx context.Context, orgId string, snapshotUUIDs []string, filters tangy.ErrataListFilters, pageOpts api.PaginationData) ([]api.SnapshotErrata, int, error)
ListSnapshotErrata provides a mock function with given fields: ctx, orgId, snapshotUUIDs, filters, pageOpts
func (*MockRpmDao) ListSnapshotRpms ¶
func (_m *MockRpmDao) ListSnapshotRpms(ctx context.Context, orgId string, snapshotUUIDs []string, search string, pageOpts api.PaginationData) ([]api.SnapshotRpm, int, error)
ListSnapshotRpms provides a mock function with given fields: ctx, orgId, snapshotUUIDs, search, pageOpts
func (*MockRpmDao) ListTemplateErrata ¶
func (_m *MockRpmDao) ListTemplateErrata(ctx context.Context, orgId string, templateUUID string, filters tangy.ErrataListFilters, pageOpts api.PaginationData) ([]api.SnapshotErrata, int, error)
ListTemplateErrata provides a mock function with given fields: ctx, orgId, templateUUID, filters, pageOpts
func (*MockRpmDao) ListTemplateRpms ¶
func (_m *MockRpmDao) ListTemplateRpms(ctx context.Context, orgId string, templateUUID string, search string, pageOpts api.PaginationData) ([]api.SnapshotRpm, int, error)
ListTemplateRpms provides a mock function with given fields: ctx, orgId, templateUUID, search, pageOpts
func (*MockRpmDao) OrphanCleanup ¶
func (_m *MockRpmDao) OrphanCleanup(ctx context.Context) error
OrphanCleanup provides a mock function with given fields: ctx
func (*MockRpmDao) Search ¶
func (_m *MockRpmDao) Search(ctx context.Context, orgID string, request api.ContentUnitSearchRequest) ([]api.SearchRpmResponse, error)
Search provides a mock function with given fields: ctx, orgID, request
func (*MockRpmDao) SearchSnapshotRpms ¶
func (_m *MockRpmDao) SearchSnapshotRpms(ctx context.Context, orgId string, request api.SnapshotSearchRpmRequest) ([]api.SearchRpmResponse, error)
SearchSnapshotRpms provides a mock function with given fields: ctx, orgId, request
type MockSnapshotDao ¶
MockSnapshotDao is an autogenerated mock type for the SnapshotDao type
func NewMockSnapshotDao ¶
func NewMockSnapshotDao(t interface { mock.TestingT Cleanup(func()) }) *MockSnapshotDao
NewMockSnapshotDao creates a new instance of MockSnapshotDao. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockSnapshotDao) BulkDelete ¶
func (_m *MockSnapshotDao) BulkDelete(ctx context.Context, uuids []string) []error
BulkDelete provides a mock function with given fields: ctx, uuids
func (*MockSnapshotDao) ClearDeletedAt ¶
func (_m *MockSnapshotDao) ClearDeletedAt(ctx context.Context, snapUUID string) error
ClearDeletedAt provides a mock function with given fields: ctx, snapUUID
func (*MockSnapshotDao) Delete ¶
func (_m *MockSnapshotDao) Delete(ctx context.Context, snapUUID string) error
Delete provides a mock function with given fields: ctx, snapUUID
func (*MockSnapshotDao) Fetch ¶
func (_m *MockSnapshotDao) Fetch(ctx context.Context, uuid string) (api.SnapshotResponse, error)
Fetch provides a mock function with given fields: ctx, uuid
func (*MockSnapshotDao) FetchForRepoConfigUUID ¶
func (_m *MockSnapshotDao) FetchForRepoConfigUUID(ctx context.Context, repoConfigUUID string) ([]models.Snapshot, error)
FetchForRepoConfigUUID provides a mock function with given fields: ctx, repoConfigUUID
func (*MockSnapshotDao) FetchLatestSnapshot ¶
func (_m *MockSnapshotDao) FetchLatestSnapshot(ctx context.Context, repoConfigUUID string) (api.SnapshotResponse, error)
FetchLatestSnapshot provides a mock function with given fields: ctx, repoConfigUUID
func (*MockSnapshotDao) FetchLatestSnapshotModel ¶
func (_m *MockSnapshotDao) FetchLatestSnapshotModel(ctx context.Context, repoConfigUUID string) (models.Snapshot, error)
FetchLatestSnapshotModel provides a mock function with given fields: ctx, repoConfigUUID
func (*MockSnapshotDao) FetchModel ¶
func (_m *MockSnapshotDao) FetchModel(ctx context.Context, uuid string, includeSoftDel bool) (models.Snapshot, error)
FetchModel provides a mock function with given fields: ctx, uuid, includeSoftDel
func (*MockSnapshotDao) FetchSnapshotByVersionHref ¶
func (_m *MockSnapshotDao) FetchSnapshotByVersionHref(ctx context.Context, repoConfigUUID string, versionHref string) (*api.SnapshotResponse, error)
FetchSnapshotByVersionHref provides a mock function with given fields: ctx, repoConfigUUID, versionHref
func (*MockSnapshotDao) FetchSnapshotsByDateAndRepository ¶
func (_m *MockSnapshotDao) FetchSnapshotsByDateAndRepository(ctx context.Context, orgID string, request api.ListSnapshotByDateRequest) (api.ListSnapshotByDateResponse, error)
FetchSnapshotsByDateAndRepository provides a mock function with given fields: ctx, orgID, request
func (*MockSnapshotDao) FetchSnapshotsModelByDateAndRepository ¶
func (_m *MockSnapshotDao) FetchSnapshotsModelByDateAndRepository(ctx context.Context, orgID string, request api.ListSnapshotByDateRequest) ([]models.Snapshot, error)
FetchSnapshotsModelByDateAndRepository provides a mock function with given fields: ctx, orgID, request
func (*MockSnapshotDao) GetRepositoryConfigurationFile ¶
func (_m *MockSnapshotDao) GetRepositoryConfigurationFile(ctx context.Context, orgID string, snapshotUUID string, isLatest bool) (string, error)
GetRepositoryConfigurationFile provides a mock function with given fields: ctx, orgID, snapshotUUID, isLatest
func (*MockSnapshotDao) List ¶
func (_m *MockSnapshotDao) List(ctx context.Context, orgID string, repoConfigUuid string, paginationData api.PaginationData, filterData api.FilterData) (api.SnapshotCollectionResponse, int64, error)
List provides a mock function with given fields: ctx, orgID, repoConfigUuid, paginationData, filterData
func (*MockSnapshotDao) ListByTemplate ¶
func (_m *MockSnapshotDao) ListByTemplate(ctx context.Context, orgID string, template api.TemplateResponse, repositorySearch string, paginationData api.PaginationData) (api.SnapshotCollectionResponse, int64, error)
ListByTemplate provides a mock function with given fields: ctx, orgID, template, repositorySearch, paginationData
func (*MockSnapshotDao) SoftDelete ¶
func (_m *MockSnapshotDao) SoftDelete(ctx context.Context, snapUUID string) error
SoftDelete provides a mock function with given fields: ctx, snapUUID
func (*MockSnapshotDao) WithContextMock ¶
func (m *MockSnapshotDao) WithContextMock() *MockSnapshotDao
type MockTaskInfoDao ¶
MockTaskInfoDao is an autogenerated mock type for the TaskInfoDao type
func NewMockTaskInfoDao ¶
func NewMockTaskInfoDao(t interface { mock.TestingT Cleanup(func()) }) *MockTaskInfoDao
NewMockTaskInfoDao creates a new instance of MockTaskInfoDao. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockTaskInfoDao) Cleanup ¶
func (_m *MockTaskInfoDao) Cleanup(ctx context.Context) error
Cleanup provides a mock function with given fields: ctx
func (*MockTaskInfoDao) Fetch ¶
func (_m *MockTaskInfoDao) Fetch(ctx context.Context, OrgID string, id string) (api.TaskInfoResponse, error)
Fetch provides a mock function with given fields: ctx, OrgID, id
func (*MockTaskInfoDao) FetchActiveTasks ¶
func (_m *MockTaskInfoDao) FetchActiveTasks(ctx context.Context, orgID string, objectUUID string, taskTypes ...string) ([]string, error)
FetchActiveTasks provides a mock function with given fields: ctx, orgID, objectUUID, taskTypes
func (*MockTaskInfoDao) List ¶
func (_m *MockTaskInfoDao) List(ctx context.Context, OrgID string, pageData api.PaginationData, filterData api.TaskInfoFilterData) (api.TaskInfoCollectionResponse, int64, error)
List provides a mock function with given fields: ctx, OrgID, pageData, filterData
type MockTemplateDao ¶
MockTemplateDao is an autogenerated mock type for the TemplateDao type
func NewMockTemplateDao ¶
func NewMockTemplateDao(t interface { mock.TestingT Cleanup(func()) }) *MockTemplateDao
NewMockTemplateDao creates a new instance of MockTemplateDao. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockTemplateDao) ClearDeletedAt ¶
ClearDeletedAt provides a mock function with given fields: ctx, orgID, uuid
func (*MockTemplateDao) Create ¶
func (_m *MockTemplateDao) Create(ctx context.Context, templateRequest api.TemplateRequest) (api.TemplateResponse, error)
Create provides a mock function with given fields: ctx, templateRequest
func (*MockTemplateDao) Delete ¶
Delete provides a mock function with given fields: ctx, orgID, uuid
func (*MockTemplateDao) DeleteTemplateRepoConfigs ¶
func (_m *MockTemplateDao) DeleteTemplateRepoConfigs(ctx context.Context, templateUUID string, keepRepoConfigUUIDs []string) error
DeleteTemplateRepoConfigs provides a mock function with given fields: ctx, templateUUID, keepRepoConfigUUIDs
func (*MockTemplateDao) DeleteTemplateSnapshot ¶
func (_m *MockTemplateDao) DeleteTemplateSnapshot(ctx context.Context, snapshotUUID string) error
DeleteTemplateSnapshot provides a mock function with given fields: ctx, snapshotUUID
func (*MockTemplateDao) Fetch ¶
func (_m *MockTemplateDao) Fetch(ctx context.Context, orgID string, uuid string, includeSoftDel bool) (api.TemplateResponse, error)
Fetch provides a mock function with given fields: ctx, orgID, uuid, includeSoftDel
func (*MockTemplateDao) GetDistributionHref ¶
func (_m *MockTemplateDao) GetDistributionHref(ctx context.Context, templateUUID string, repoConfigUUID string) (string, error)
GetDistributionHref provides a mock function with given fields: ctx, templateUUID, repoConfigUUID
func (*MockTemplateDao) GetRepoChanges ¶
func (_m *MockTemplateDao) GetRepoChanges(ctx context.Context, templateUUID string, newRepoConfigUUIDs []string) ([]string, []string, []string, []string, error)
GetRepoChanges provides a mock function with given fields: ctx, templateUUID, newRepoConfigUUIDs
func (*MockTemplateDao) GetRepositoryConfigurationFile ¶
func (_m *MockTemplateDao) GetRepositoryConfigurationFile(ctx context.Context, orgID string, templateUUID string) (string, error)
GetRepositoryConfigurationFile provides a mock function with given fields: ctx, orgID, templateUUID
func (*MockTemplateDao) InternalOnlyFetchByName ¶
func (_m *MockTemplateDao) InternalOnlyFetchByName(ctx context.Context, name string) (models.Template, error)
InternalOnlyFetchByName provides a mock function with given fields: ctx, name
func (*MockTemplateDao) InternalOnlyGetTemplatesForRepoConfig ¶
func (_m *MockTemplateDao) InternalOnlyGetTemplatesForRepoConfig(ctx context.Context, repoUUID string, useLatestOnly bool) ([]api.TemplateResponse, error)
InternalOnlyGetTemplatesForRepoConfig provides a mock function with given fields: ctx, repoUUID, useLatestOnly
func (*MockTemplateDao) List ¶
func (_m *MockTemplateDao) List(ctx context.Context, orgID string, includeSoftDel bool, paginationData api.PaginationData, filterData api.TemplateFilterData) (api.TemplateCollectionResponse, int64, error)
List provides a mock function with given fields: ctx, orgID, includeSoftDel, paginationData, filterData
func (*MockTemplateDao) SetEnvironmentCreated ¶
func (_m *MockTemplateDao) SetEnvironmentCreated(ctx context.Context, templateUUID string) error
SetEnvironmentCreated provides a mock function with given fields: ctx, templateUUID
func (*MockTemplateDao) SoftDelete ¶
SoftDelete provides a mock function with given fields: ctx, orgID, uuid
func (*MockTemplateDao) Update ¶
func (_m *MockTemplateDao) Update(ctx context.Context, orgID string, uuid string, templParams api.TemplateUpdateRequest) (api.TemplateResponse, error)
Update provides a mock function with given fields: ctx, orgID, uuid, templParams
func (*MockTemplateDao) UpdateDistributionHrefs ¶
func (_m *MockTemplateDao) UpdateDistributionHrefs(ctx context.Context, templateUUID string, repoUUIDs []string, snapshots []models.Snapshot, repoDistributionMap map[string]string) error
UpdateDistributionHrefs provides a mock function with given fields: ctx, templateUUID, repoUUIDs, snapshots, repoDistributionMap
func (*MockTemplateDao) UpdateLastError ¶
func (_m *MockTemplateDao) UpdateLastError(ctx context.Context, orgID string, templateUUID string, lastUpdateSnapshotError string) error
UpdateLastError provides a mock function with given fields: ctx, orgID, templateUUID, lastUpdateSnapshotError
func (*MockTemplateDao) UpdateLastUpdateTask ¶
func (_m *MockTemplateDao) UpdateLastUpdateTask(ctx context.Context, taskUUID string, orgID string, templateUUID string) error
UpdateLastUpdateTask provides a mock function with given fields: ctx, taskUUID, orgID, templateUUID
func (*MockTemplateDao) UpdateSnapshots ¶
func (_m *MockTemplateDao) UpdateSnapshots(ctx context.Context, templateUUID string, repoUUIDs []string, snapshots []models.Snapshot) error
UpdateSnapshots provides a mock function with given fields: ctx, templateUUID, repoUUIDs, snapshots
type ModuleStreamDao ¶
type ModuleStreamDao interface { SearchRepositoryModuleStreams(ctx context.Context, orgID string, request api.SearchModuleStreamsRequest) ([]api.SearchModuleStreams, error) SearchSnapshotModuleStreams(ctx context.Context, orgID string, request api.SearchSnapshotModuleStreamsRequest) ([]api.SearchModuleStreams, error) InsertForRepository(ctx context.Context, repoUuid string, pkgGroups []yum.ModuleMD) (int64, error) OrphanCleanup(ctx context.Context) error }
func GetModuleStreamsDao ¶
func GetModuleStreamsDao(db *gorm.DB) ModuleStreamDao
type PackageGroupDao ¶
type PackageGroupDao interface { List(ctx context.Context, orgID string, uuidRepo string, limit int, offset int, search string, sortBy string) (api.RepositoryPackageGroupCollectionResponse, int64, error) Search(ctx context.Context, orgID string, request api.ContentUnitSearchRequest) ([]api.SearchPackageGroupResponse, error) InsertForRepository(ctx context.Context, repoUuid string, pkgGroups []yum.PackageGroup) (int64, error) OrphanCleanup(ctx context.Context) error SearchSnapshotPackageGroups(ctx context.Context, orgId string, request api.SnapshotSearchRpmRequest) ([]api.SearchPackageGroupResponse, error) }
func GetPackageGroupDao ¶
func GetPackageGroupDao(db *gorm.DB) PackageGroupDao
type Repository ¶
type Repository struct { UUID string URL string Public bool RepomdChecksum string LastIntrospectionTime *time.Time LastIntrospectionSuccessTime *time.Time LastIntrospectionUpdateTime *time.Time LastIntrospectionError *string LastIntrospectionStatus string PackageCount int FailedIntrospectionsCount int }
Repository internal (non-user facing) representation of a repository
type RepositoryConfigDao ¶
type RepositoryConfigDao interface { Create(ctx context.Context, newRepo api.RepositoryRequest) (api.RepositoryResponse, error) BulkCreate(ctx context.Context, newRepositories []api.RepositoryRequest) ([]api.RepositoryResponse, []error) Update(ctx context.Context, orgID, uuid string, repoParams api.RepositoryUpdateRequest) (bool, error) Fetch(ctx context.Context, orgID string, uuid string) (api.RepositoryResponse, error) InternalOnly_ListReposToSnapshot(ctx context.Context, filter *ListRepoFilter) ([]models.RepositoryConfiguration, error) ListReposWithOutdatedSnapshots(ctx context.Context, olderThanDays int) ([]models.RepositoryConfiguration, error) List(ctx context.Context, orgID string, paginationData api.PaginationData, filterData api.FilterData) (api.RepositoryCollectionResponse, int64, error) Delete(ctx context.Context, orgID string, uuid string) error SoftDelete(ctx context.Context, orgID string, uuid string) error BulkDelete(ctx context.Context, orgID string, uuids []string) []error SavePublicRepos(ctx context.Context, urls []string) error ValidateParameters(ctx context.Context, orgId string, params api.RepositoryValidationRequest, excludedUUIDS []string) (api.RepositoryValidationResponse, error) FetchByRepoUuid(ctx context.Context, orgID string, repoUuid string) (api.RepositoryResponse, error) InternalOnly_FetchRepoConfigsForRepoUUID(ctx context.Context, uuid string) []api.RepositoryResponse UpdateLastSnapshotTask(ctx context.Context, taskUUID string, orgID string, repoUUID string) error UpdateLastSnapshot(ctx context.Context, orgID string, repoConfigUUID string, snapUUID string) error InternalOnly_RefreshRedHatRepo(ctx context.Context, request api.RepositoryRequest, label string, featureName string) (*api.RepositoryResponse, error) InternalOnly_IncrementFailedSnapshotCount(ctx context.Context, rcUuid string) error InternalOnly_ResetFailedSnapshotCount(ctx context.Context, rcUuid string) error FetchWithoutOrgID(ctx context.Context, uuid string) (api.RepositoryResponse, error) BulkExport(ctx context.Context, orgID string, reposToExport api.RepositoryExportRequest) ([]api.RepositoryExportResponse, error) BulkImport(ctx context.Context, reposToImport []api.RepositoryRequest) ([]api.RepositoryImportResponse, []error) }
func GetRepositoryConfigDao ¶
func GetRepositoryConfigDao(db *gorm.DB, pulpClient pulp_client.PulpClient, fsClient feature_service_client.FeatureServiceClient) RepositoryConfigDao
type RepositoryDao ¶
type RepositoryDao interface { FetchForUrl(ctx context.Context, url string) (Repository, error) ListForIntrospection(ctx context.Context, urls *[]string, force bool) ([]Repository, error) ListPublic(ctx context.Context, paginationData api.PaginationData, _ api.FilterData) (api.PublicRepositoryCollectionResponse, int64, error) Update(ctx context.Context, repo RepositoryUpdate) error FetchRepositoryRPMCount(ctx context.Context, repoUUID string) (int, error) OrphanCleanup(ctx context.Context) error }
func GetRepositoryDao ¶
func GetRepositoryDao(db *gorm.DB) RepositoryDao
type RepositoryUpdate ¶
type RepositoryUpdate struct { UUID string URL *string Public *bool RepomdChecksum *string LastIntrospectionTime *time.Time LastIntrospectionSuccessTime *time.Time LastIntrospectionUpdateTime *time.Time LastIntrospectionError *string LastIntrospectionStatus *string PackageCount *int FailedIntrospectionsCount *int }
RepositoryUpdate internal representation of repository, nil field value means do not change
type RpmDao ¶
type RpmDao interface { List(ctx context.Context, orgID string, uuidRepo string, limit int, offset int, search string, sortBy string) (api.RepositoryRpmCollectionResponse, int64, error) Search(ctx context.Context, orgID string, request api.ContentUnitSearchRequest) ([]api.SearchRpmResponse, error) SearchSnapshotRpms(ctx context.Context, orgId string, request api.SnapshotSearchRpmRequest) ([]api.SearchRpmResponse, error) ListSnapshotRpms(ctx context.Context, orgId string, snapshotUUIDs []string, search string, pageOpts api.PaginationData) ([]api.SnapshotRpm, int, error) DetectRpms(ctx context.Context, orgID string, request api.DetectRpmsRequest) (*api.DetectRpmsResponse, error) ListSnapshotErrata(ctx context.Context, orgId string, snapshotUUIDs []string, filters tangy.ErrataListFilters, pageOpts api.PaginationData) ([]api.SnapshotErrata, int, error) InsertForRepository(ctx context.Context, repoUuid string, pkgs []yum.Package) (int64, error) OrphanCleanup(ctx context.Context) error ListTemplateRpms(ctx context.Context, orgId string, templateUUID string, search string, pageOpts api.PaginationData) ([]api.SnapshotRpm, int, error) ListTemplateErrata(ctx context.Context, orgId string, templateUUID string, filters tangy.ErrataListFilters, pageOpts api.PaginationData) ([]api.SnapshotErrata, int, error) }
type SnapshotDao ¶
type SnapshotDao interface { Create(ctx context.Context, snap *models.Snapshot) error List(ctx context.Context, orgID string, repoConfigUuid string, paginationData api.PaginationData, filterData api.FilterData) (api.SnapshotCollectionResponse, int64, error) ListByTemplate(ctx context.Context, orgID string, template api.TemplateResponse, repositorySearch string, paginationData api.PaginationData) (api.SnapshotCollectionResponse, int64, error) FetchForRepoConfigUUID(ctx context.Context, repoConfigUUID string) ([]models.Snapshot, error) FetchModel(ctx context.Context, uuid string, includeSoftDel bool) (models.Snapshot, error) SoftDelete(ctx context.Context, snapUUID string) error Delete(ctx context.Context, snapUUID string) error BulkDelete(ctx context.Context, uuids []string) []error ClearDeletedAt(ctx context.Context, snapUUID string) error FetchLatestSnapshot(ctx context.Context, repoConfigUUID string) (api.SnapshotResponse, error) FetchLatestSnapshotModel(ctx context.Context, repoConfigUUID string) (models.Snapshot, error) FetchSnapshotsByDateAndRepository(ctx context.Context, orgID string, request api.ListSnapshotByDateRequest) (api.ListSnapshotByDateResponse, error) FetchSnapshotByVersionHref(ctx context.Context, repoConfigUUID string, versionHref string) (*api.SnapshotResponse, error) GetRepositoryConfigurationFile(ctx context.Context, orgID, snapshotUUID string, isLatest bool) (string, error) Fetch(ctx context.Context, uuid string) (api.SnapshotResponse, error) FetchSnapshotsModelByDateAndRepository(ctx context.Context, orgID string, request api.ListSnapshotByDateRequest) ([]models.Snapshot, error) }
func GetSnapshotDao ¶
func GetSnapshotDao(db *gorm.DB) SnapshotDao
type TaskInfoDao ¶
type TaskInfoDao interface { Fetch(ctx context.Context, OrgID string, id string) (api.TaskInfoResponse, error) List(ctx context.Context, OrgID string, pageData api.PaginationData, filterData api.TaskInfoFilterData) (api.TaskInfoCollectionResponse, int64, error) FetchActiveTasks(ctx context.Context, orgID string, objectUUID string, taskTypes ...string) ([]string, error) Cleanup(ctx context.Context) error }
func GetTaskInfoDao ¶
func GetTaskInfoDao(db *gorm.DB) TaskInfoDao
type TemplateDao ¶
type TemplateDao interface { Create(ctx context.Context, templateRequest api.TemplateRequest) (api.TemplateResponse, error) Fetch(ctx context.Context, orgID string, uuid string, includeSoftDel bool) (api.TemplateResponse, error) InternalOnlyFetchByName(ctx context.Context, name string) (models.Template, error) List(ctx context.Context, orgID string, includeSoftDel bool, paginationData api.PaginationData, filterData api.TemplateFilterData) (api.TemplateCollectionResponse, int64, error) SoftDelete(ctx context.Context, orgID string, uuid string) error Delete(ctx context.Context, orgID string, uuid string) error ClearDeletedAt(ctx context.Context, orgID string, uuid string) error Update(ctx context.Context, orgID string, uuid string, templParams api.TemplateUpdateRequest) (api.TemplateResponse, error) GetRepoChanges(ctx context.Context, templateUUID string, newRepoConfigUUIDs []string) ([]string, []string, []string, []string, error) GetDistributionHref(ctx context.Context, templateUUID string, repoConfigUUID string) (string, error) UpdateDistributionHrefs(ctx context.Context, templateUUID string, repoUUIDs []string, snapshots []models.Snapshot, repoDistributionMap map[string]string) error DeleteTemplateRepoConfigs(ctx context.Context, templateUUID string, keepRepoConfigUUIDs []string) error UpdateLastUpdateTask(ctx context.Context, taskUUID string, orgID string, templateUUID string) error UpdateLastError(ctx context.Context, orgID string, templateUUID string, lastUpdateSnapshotError string) error SetEnvironmentCreated(ctx context.Context, templateUUID string) error UpdateSnapshots(ctx context.Context, templateUUID string, repoUUIDs []string, snapshots []models.Snapshot) error DeleteTemplateSnapshot(ctx context.Context, snapshotUUID string) error GetRepositoryConfigurationFile(ctx context.Context, orgID string, templateUUID string) (string, error) InternalOnlyGetTemplatesForRepoConfig(ctx context.Context, repoUUID string, useLatestOnly bool) ([]api.TemplateResponse, error) }
func GetTemplateDao ¶
func GetTemplateDao(db *gorm.DB, pulpClient pulp_client.PulpClient, fsClient feature_service_client.FeatureServiceClient) TemplateDao
type UploadDao ¶
type UploadDao interface { StoreFileUpload(ctx context.Context, orgID string, uploadUUID string, sha256 string, chunkSize int64) error StoreChunkUpload(ctx context.Context, orgID string, uploadUUID string, sha256 string) error GetExistingUploadIDAndCompletedChunks(ctx context.Context, orgID string, sha256 string, chunkSize int64) (string, []string, error) }
func GetUploadDao ¶
func GetUploadDao(db *gorm.DB, pulpClient pulp_client.PulpClient) UploadDao
Source Files
¶
- admin_tasks.go
- admin_tasks_mock.go
- domain_dao_mock.go
- domains.go
- environments.go
- environments_mock.go
- helpers.go
- interfaces.go
- metrics.go
- metrics_mock.go
- mock_helpers.go
- module_streams.go
- modules_streams_mock.go
- package_groups.go
- package_groups_mock.go
- registry_mock.go
- repositories.go
- repositories_mock.go
- repository_configs.go
- repository_configs_mock.go
- rpms.go
- rpms_mock.go
- snapshots.go
- snapshots_mock.go
- task_info.go
- task_info_mock.go
- templates.go
- templates_mock.go
- uploads.go