Unexpected value for setting it should be dash delimited – How to solve this Elasticsearch error

Opster Team

Aug-23, Version: 1.3-1.3

Briefly, this error occurs when the Elasticsearch setting value is not dash-delimited as expected. Elasticsearch uses dash-delimited settings for better readability and organization. If a setting is not dash-delimited, it may cause confusion or errors. To resolve this issue, you should review your Elasticsearch settings and ensure that they are correctly dash-delimited. For example, if you have a setting like “index.number_of_shards”, it should be written as “index-number-of-shards”. Also, ensure that there are no spaces before or after the dashes.

This guide will help you check for common problems that cause the log ” Unexpected value [{}] for setting [{}]; it should be dash delimited ” to appear. To understand the issues related to this log, read the explanation below about the following Elasticsearch concepts: cluster, metadata and settings.

Log Context

Log “Unexpected value [{}] for setting [{}]; it should be dash delimited” classname is MetaDataUpdateSettingsService.java.
We extracted the following from Elasticsearch source code for those seeking an in-depth context :

final int min;
                    final int max;

                    final int dash = autoExpandReplicas.indexOf('-');
                    if (-1 == dash) {
                        logger.warn("Unexpected value [{}] for setting [{}]; it should be dash delimited";
                                autoExpandReplicas; IndexMetaData.SETTING_AUTO_EXPAND_REPLICAS);
                        continue;
                    }
                    final String sMin = autoExpandReplicas.substring(0; dash);
                    try {

 

 [ratemypost]

Opster
Privacy Overview

This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.