Commit 9702dffc authored by Michelle Noorali's avatar Michelle Noorali

ref(repo): change RepoService -> Service

* fixes style errors in #401
parent 28d46246
...@@ -26,7 +26,7 @@ type inmemRepoService struct { ...@@ -26,7 +26,7 @@ type inmemRepoService struct {
} }
// NewInmemRepoService returns a new memory based repository service. // NewInmemRepoService returns a new memory based repository service.
func NewInmemRepoService() RepoService { func NewInmemRepoService() Service {
rs := &inmemRepoService{ rs := &inmemRepoService{
repositories: make(map[string]Repo), repositories: make(map[string]Repo),
} }
......
...@@ -38,19 +38,19 @@ type RepoProvider interface { ...@@ -38,19 +38,19 @@ type RepoProvider interface {
type repoProvider struct { type repoProvider struct {
sync.RWMutex sync.RWMutex
rs RepoService rs Service
cp CredentialProvider cp CredentialProvider
gcsrp GCSRepoProvider gcsrp GCSRepoProvider
repos map[string]ChartRepo repos map[string]ChartRepo
} }
// NewRepoProvider creates a new repository provider. // NewRepoProvider creates a new repository provider.
func NewRepoProvider(rs RepoService, gcsrp GCSRepoProvider, cp CredentialProvider) RepoProvider { func NewRepoProvider(rs Service, gcsrp GCSRepoProvider, cp CredentialProvider) RepoProvider {
return newRepoProvider(rs, gcsrp, cp) return newRepoProvider(rs, gcsrp, cp)
} }
// newRepoProvider creates a new repository provider. // newRepoProvider creates a new repository provider.
func newRepoProvider(rs RepoService, gcsrp GCSRepoProvider, cp CredentialProvider) *repoProvider { func newRepoProvider(rs Service, gcsrp GCSRepoProvider, cp CredentialProvider) *repoProvider {
if rs == nil { if rs == nil {
rs = NewInmemRepoService() rs = NewInmemRepoService()
} }
...@@ -69,7 +69,7 @@ func newRepoProvider(rs RepoService, gcsrp GCSRepoProvider, cp CredentialProvide ...@@ -69,7 +69,7 @@ func newRepoProvider(rs RepoService, gcsrp GCSRepoProvider, cp CredentialProvide
} }
// GetRepoService returns the repository service used by this repository provider. // GetRepoService returns the repository service used by this repository provider.
func (rp *repoProvider) GetRepoService() RepoService { func (rp *repoProvider) GetRepoService() Service {
return rp.rs return rp.rs
} }
......
...@@ -105,9 +105,9 @@ type ObjectStorageRepo interface { ...@@ -105,9 +105,9 @@ type ObjectStorageRepo interface {
GetBucket() string GetBucket() string
} }
// RepoService maintains a list of chart repositories that defines the scope of all // Service maintains a list of chart repositories that defines the scope of all
// repository based operations, such as search and chart reference resolution. // repository based operations, such as search and chart reference resolution.
type RepoService interface { type Service interface {
// List returns the list of all known chart repositories // List returns the list of all known chart repositories
List() ([]Repo, error) List() ([]Repo, error)
// Create adds a known repository to the list // Create adds a known repository to the list
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment