diff --git a/CHANGELOG.next.asciidoc b/CHANGELOG.next.asciidoc index 25a6b617a63..60f3490ea9e 100644 --- a/CHANGELOG.next.asciidoc +++ b/CHANGELOG.next.asciidoc @@ -147,6 +147,7 @@ https://github.com/elastic/beats/compare/v8.8.1\...main[Check the HEAD diff] - Improve error reporting and fix IPv6 handling of TCP and UDP metric collection. {pull}35996[35996] - Fix handling of NUL-terminated log lines in Fortinet Firewall module. {issue}36026[36026] {pull}36027[36027] - Make redact field configuration recommended in CEL input and log warning if missing. {pull}36008[36008] +- Fix handling of region name configuration in awss3 input {pull}36034[36034] *Heartbeat* diff --git a/x-pack/filebeat/input/awss3/input.go b/x-pack/filebeat/input/awss3/input.go index 4f45f914144..c9812e98308 100644 --- a/x-pack/filebeat/input/awss3/input.go +++ b/x-pack/filebeat/input/awss3/input.go @@ -119,7 +119,7 @@ func (in *s3Input) Run(inputContext v2.Context, pipeline beat.Pipeline) error { if err != nil && in.config.RegionName == "" { return fmt.Errorf("failed to get AWS region from queue_url: %w", err) } - if regionName != in.config.RegionName { + if in.config.RegionName != "" && regionName != in.config.RegionName { inputContext.Logger.Warnf("configured region disagrees with queue_url region: %q != %q: using %[1]q", in.config.RegionName, regionName) regionName = in.config.RegionName