in lib/logstash/outputs/opensearch/http_client.rb [208:226]
def calculate_property(uris, property, default, sniff_check)
values = uris.map(&property).uniq
if sniff_check && values.size > 1
raise LogStash::ConfigurationError, "Cannot have multiple values for #{property} in hosts when sniffing is enabled!"
end
uri_value = values.first
default = nil if default.is_a?(String) && default.empty?
uri_value = nil if uri_value.is_a?(String) && uri_value.empty?
if default && uri_value && (default != uri_value)
raise LogStash::ConfigurationError, "Explicit value for '#{property}' was declared, but it is different in one of the URLs given! Please make sure your URLs are inline with explicit values. The URLs have the property set to '#{uri_value}', but it was also set to '#{default}' explicitly"
end
uri_value || default
end