diff options
author | Sami Hiltunen <shiltunen@gitlab.com> | 2021-10-11 14:02:00 +0300 |
---|---|---|
committer | Sami Hiltunen <shiltunen@gitlab.com> | 2021-10-14 11:14:32 +0300 |
commit | 4e92e4c5ba434a0f87a92d57f0ed91ba385a8f6f (patch) | |
tree | 554bfa4774dfb321a0741046bee8b4a94ebf41d6 /internal | |
parent | 90efd758df9475d71f4a75f97c1842afa2ae1192 (diff) |
Remove unused type StaticStorageAssignments
StaticStorageAssignments is not used anywhere in Praefect so this
commit removes it.
Diffstat (limited to 'internal')
-rw-r--r-- | internal/praefect/router_per_repository.go | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/internal/praefect/router_per_repository.go b/internal/praefect/router_per_repository.go index bf62f1a80..4cb4da498 100644 --- a/internal/praefect/router_per_repository.go +++ b/internal/praefect/router_per_repository.go @@ -28,18 +28,6 @@ type AssignmentGetter interface { GetHostAssignments(ctx context.Context, virtualStorage, relativePath string) ([]string, error) } -// StaticStorageAssignments is a static assignment of the same storages in a virtual storage for every repository. -type StaticStorageAssignments map[string][]string - -func (st StaticStorageAssignments) GetHostAssignments(ctx context.Context, virtualStorage, relativePath string) ([]string, error) { - storages, ok := st[virtualStorage] - if !ok { - return nil, nodes.ErrVirtualStorageNotExist - } - - return storages, nil -} - // ErrNoSuitableNode is returned when there is not suitable node to serve a request. var ErrNoSuitableNode = errors.New("no suitable node to serve the request") |