MM-34983: Remove check for number of data sources (#17431)

In case of Aurora databases, a single endpoint
might load balance between multiple replicas.
In that case, this check is incorrect. Therefore,
we remove it

https://mattermost.atlassian.net/browse/MM-34983

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
Этот коммит содержится в:
Agniva De Sarker
2021-04-19 20:30:17 +05:30
коммит произвёл GitHub
родитель 9f203bbc96
Коммит 0e0f3f8c2e
2 изменённых файлов: 0 добавлений и 8 удалений

Просмотреть файл

@@ -8162,10 +8162,6 @@
"id": "model.config.is_valid.read_timeout.app_error",
"translation": "Invalid value for read timeout."
},
{
"id": "model.config.is_valid.replica_mismatch.app_error",
"translation": "Number of replica lag queries is more than the number of replicas configured. Must be less than or equal to the number of replicas."
},
{
"id": "model.config.is_valid.restrict_direct_message.app_error",
"translation": "Invalid direct message restriction. Must be 'any', or 'team'."

Просмотреть файл

@@ -3396,10 +3396,6 @@ func (s *SqlSettings) isValid() *AppError {
return NewAppError("Config.IsValid", "model.config.is_valid.sql_max_conn.app_error", nil, "", http.StatusBadRequest)
}
if len(s.ReplicaLagSettings) > len(s.DataSourceReplicas) {
return NewAppError("Config.IsValid", "model.config.is_valid.replica_mismatch.app_error", nil, "", http.StatusBadRequest)
}
return nil
}