Split constants into exported and non-exported

This commit is contained in:
Sergey Dudoladov 2019-01-02 13:38:46 +01:00
parent 27114701ba
commit cba48ea9dd
1 changed files with 7 additions and 5 deletions

View File

@ -1,11 +1,7 @@
package v1
//Cluster name, cluster status and service name setting
// ClusterStatusUnknown etc : status of a Postgres cluster known to the operator
const (
serviceNameMaxLength = 63
clusterNameMaxLength = serviceNameMaxLength - len("-repl")
serviceNameRegexString = `^[a-z]([-a-z0-9]*[a-z0-9])?$`
ClusterStatusUnknown PostgresStatus = ""
ClusterStatusCreating PostgresStatus = "Creating"
ClusterStatusUpdating PostgresStatus = "Updating"
@ -15,3 +11,9 @@ const (
ClusterStatusRunning PostgresStatus = "Running"
ClusterStatusInvalid PostgresStatus = "Invalid"
)
const (
serviceNameMaxLength = 63
clusterNameMaxLength = serviceNameMaxLength - len("-repl")
serviceNameRegexString = `^[a-z]([-a-z0-9]*[a-z0-9])?$`
)