📣 极限科技诚招搜索运维工程师(Elasticsearch/Easysearch)- 全职/北京 👉 : 立即申请加入

版本: 8.8-8.9

简而言之,当 Elasticsearch 中存在配置问题,同时设置了端点后缀和辅助端点时,会发生此错误。这是不允许的,因为它可能导致请求路由冲突。要解决此问题,您可以从配置中删除端点后缀或辅助端点。确保一次只设置其中一个。或者,您可以检查应用程序的代码,确保它不会同时设置这两个参数。

日志上下文 #

日志 “Both an endpoint suffix as well as a secondary endpoint were set” 的类名是 AzureStorageSettings.java。我们从 Elasticsearch 源代码中提取了以下内容,供那些寻求深入上下文的人参考:

if (hasEndpointSuffix && hasEndpoint) {
 throw new SettingsException("Both an endpoint suffix as well as a primary endpoint were set");
 }  if (hasEndpointSuffix && hasSecondaryEndpoint) {
 throw new SettingsException("Both an endpoint suffix as well as a secondary endpoint were set");
 }  if (hasEndpoint == false && hasSecondaryEndpoint) {
 throw new SettingsException("A primary endpoint is required when setting a secondary endpoint");
 }