diff options
author | Sami Hiltunen <shiltunen@gitlab.com> | 2021-01-29 19:07:22 +0300 |
---|---|---|
committer | Sami Hiltunen <shiltunen@gitlab.com> | 2021-01-29 19:17:09 +0300 |
commit | eec4599a9eca5f196dc1d1fa1ab2b875166a88a7 (patch) | |
tree | abe34ab47ee65950781f92bedd1ab43d2b218d6d /internal/praefect/config | |
parent | 0d8e8d6873722723e085d94af57778674db5f46f (diff) |
type ElectionStrategy constants correctly
ElectionStrategy constants in Praefect's config are untyped. This
commit types them as ElectionStrategy.
Diffstat (limited to 'internal/praefect/config')
-rw-r--r-- | internal/praefect/config/config.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/internal/praefect/config/config.go b/internal/praefect/config/config.go index a4564ea58..6ae48474b 100644 --- a/internal/praefect/config/config.go +++ b/internal/praefect/config/config.go @@ -31,11 +31,11 @@ func (es ElectionStrategy) validate() error { const ( // ElectionStrategyLocal configures a single node, in-memory election strategy. - ElectionStrategyLocal = "local" + ElectionStrategyLocal ElectionStrategy = "local" // ElectionStrategySQL configures an SQL based strategy that elects a primary for a virtual storage. - ElectionStrategySQL = "sql" + ElectionStrategySQL ElectionStrategy = "sql" // ElectionStrategyPerRepository configures an SQL based strategy that elects different primaries per repository. - ElectionStrategyPerRepository = "per_repository" + ElectionStrategyPerRepository ElectionStrategy = "per_repository" ) type Failover struct { |