diff options
author | Vyr Cossont <VyrCossont@users.noreply.github.com> | 2023-01-05 04:44:31 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-05 13:44:31 +0100 |
commit | 06f979098cec3570231d1eca519bbee9a4754cfe (patch) | |
tree | 9e8c4f044f02607e7a01367ae75863086d2e126b /app/lib/admin/system_check | |
parent | ce74991bb218479f3e9268a909a20f6666511d70 (diff) |
Check OpenSearch compatibility version instead of regular version (#22422)
Fixes #18535.
Diffstat (limited to 'app/lib/admin/system_check')
-rw-r--r-- | app/lib/admin/system_check/elasticsearch_check.rb | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/app/lib/admin/system_check/elasticsearch_check.rb b/app/lib/admin/system_check/elasticsearch_check.rb index a63988224..7f922978f 100644 --- a/app/lib/admin/system_check/elasticsearch_check.rb +++ b/app/lib/admin/system_check/elasticsearch_check.rb @@ -13,7 +13,14 @@ class Admin::SystemCheck::ElasticsearchCheck < Admin::SystemCheck::BaseCheck def message if running_version.present? - Admin::SystemCheck::Message.new(:elasticsearch_version_check, I18n.t('admin.system_checks.elasticsearch_version_check.version_comparison', running_version: running_version, required_version: required_version)) + Admin::SystemCheck::Message.new( + :elasticsearch_version_check, + I18n.t( + 'admin.system_checks.elasticsearch_version_check.version_comparison', + running_version: running_version, + required_version: required_version + ) + ) else Admin::SystemCheck::Message.new(:elasticsearch_running_check) end @@ -23,7 +30,8 @@ class Admin::SystemCheck::ElasticsearchCheck < Admin::SystemCheck::BaseCheck def running_version @running_version ||= begin - Chewy.client.info['version']['number'] + Chewy.client.info['version']['minimum_wire_compatibility_version'] || + Chewy.client.info['version']['number'] rescue Faraday::ConnectionFailed nil end |