Skip to content

[8.19](backport #43657) [Chore] Replace global logger with local logger instance #3#44703

Merged
khushijain21 merged 6 commits into8.19from
mergify/bp/8.19/pr-43657
Jun 9, 2025
Merged

[8.19](backport #43657) [Chore] Replace global logger with local logger instance #3#44703
khushijain21 merged 6 commits into8.19from
mergify/bp/8.19/pr-43657

Conversation

@mergify
Copy link
Copy Markdown
Contributor

@mergify mergify bot commented Jun 9, 2025

Proposed commit message

This PR replaces global logger instances with local loggers in beats code.

Checklist

  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have made corresponding change to the default configuration files
  • I have added tests that prove my fix is effective or that my feature works
  • I have added an entry in CHANGELOG.next.asciidoc or CHANGELOG-developer.next.asciidoc.

How to test this PR locally

Run this test in x-pack/filebeat/fbreceiver

go test -run ^TestMultipleReceivers$ ./x-pack/filebeat/fbreceiver -v

Related issues


This is an automatic backport of pull request #43657 done by [Mergify](https://mergify.com).

* [Chore] Replace global logger with local logger instance #3

(cherry picked from commit e2264dc)

# Conflicts:
#	filebeat/input/container/input.go
#	filebeat/input/log/input.go
#	x-pack/filebeat/input/gcppubsub/input.go
@mergify mergify bot added backport conflicts There is a conflict in the backported pull request labels Jun 9, 2025
@mergify mergify bot requested review from a team as code owners June 9, 2025 07:45
@mergify mergify bot added the backport label Jun 9, 2025
@mergify mergify bot requested review from a team as code owners June 9, 2025 07:45
@mergify mergify bot added the conflicts There is a conflict in the backported pull request label Jun 9, 2025
@mergify
Copy link
Copy Markdown
Contributor Author

mergify bot commented Jun 9, 2025

Cherry-pick of e2264dc has failed:

On branch mergify/bp/8.19/pr-43657
Your branch is up to date with 'origin/8.19'.

You are currently cherry-picking commit e2264dc60.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   filebeat/autodiscover/builder/hints/logs.go
	modified:   filebeat/autodiscover/builder/hints/logs_test.go
	modified:   filebeat/beater/filebeat.go
	modified:   filebeat/channel/runner.go
	modified:   filebeat/channel/runner_test.go
	modified:   filebeat/fileset/factory.go
	modified:   filebeat/fileset/modules.go
	modified:   filebeat/fileset/modules_integration_test.go
	modified:   filebeat/fileset/modules_test.go
	modified:   filebeat/input/input.go
	modified:   filebeat/input/inputtest/input.go
	modified:   filebeat/input/log/input_test.go
	modified:   filebeat/input/mqtt/input.go
	modified:   filebeat/input/mqtt/input_test.go
	modified:   filebeat/input/mqtt/mqtt_integration_test.go
	modified:   filebeat/input/redis/input.go
	modified:   filebeat/input/redis/redis_integration_test.go
	modified:   filebeat/input/registry.go
	modified:   filebeat/input/registry_test.go
	modified:   filebeat/input/runnerfactory.go
	modified:   filebeat/input/stdin/input.go
	modified:   filebeat/input/syslog/input.go
	modified:   filebeat/registrar/migrate.go
	modified:   heartbeat/autodiscover/builder/hints/monitors.go
	modified:   heartbeat/monitors/factory.go
	modified:   libbeat/autodiscover/builder.go
	modified:   libbeat/autodiscover/builder_test.go
	modified:   libbeat/autodiscover/providers/kubernetes/config_test.go
	modified:   libbeat/processors/actions/append_test.go
	modified:   libbeat/processors/actions/copy_fields_test.go
	modified:   libbeat/processors/actions/decode_base64_field_test.go
	modified:   libbeat/publisher/pipeline/client_test.go
	modified:   libbeat/publisher/pipeline/consumer_test.go
	modified:   libbeat/publisher/pipeline/controller.go
	modified:   libbeat/publisher/pipeline/controller_test.go
	modified:   libbeat/publisher/pipeline/stress/gen.go
	modified:   libbeat/publisher/pipeline/stress/run.go
	modified:   libbeat/publisher/pipeline/stress/stress_test.go
	modified:   libbeat/publisher/processing/default.go
	modified:   libbeat/publisher/processing/processors.go
	modified:   libbeat/publisher/queue/diskqueue/acks_test.go
	modified:   libbeat/publisher/queue/diskqueue/benchmark_test.go
	modified:   libbeat/publisher/queue/diskqueue/core_loop_test.go
	modified:   libbeat/publisher/queue/diskqueue/queue_test.go
	modified:   libbeat/publisher/queue/memqueue/runloop_test.go
	modified:   libbeat/scripts/cmd/stress_pipeline/main.go
	modified:   libbeat/statestore/backend/memlog/memlog_test.go
	modified:   libbeat/statestore/backend/memlog/store.go
	modified:   libbeat/statestore/backend/memlog/store_test.go
	modified:   libbeat/statestore/storetest/storetest_test.go
	modified:   metricbeat/autodiscover/builder/hints/metrics.go
	modified:   metricbeat/mb/module/connector.go
	modified:   metricbeat/mb/registry.go
	modified:   winlogbeat/beater/eventlogger.go
	modified:   x-pack/filebeat/input/cometd/cometd_integration_test.go
	modified:   x-pack/filebeat/input/cometd/input.go
	modified:   x-pack/filebeat/input/cometd/input_test.go
	modified:   x-pack/filebeat/input/gcppubsub/pubsub_test.go
	modified:   x-pack/osquerybeat/internal/pub/publisher.go

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   filebeat/input/container/input.go
	both modified:   filebeat/input/log/input.go
	both modified:   x-pack/filebeat/input/gcppubsub/input.go

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally

@botelastic botelastic bot added the needs_team Indicates that the issue/PR needs a Team:* label label Jun 9, 2025
@mergify mergify bot requested review from AndersonQ, VihasMakwana, michel-laterman and pkoutsovasilis and removed request for a team June 9, 2025 07:45
@github-actions github-actions bot added Team:obs-ds-hosted-services Label for the Observability Hosted Services team Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team Team:Elastic-Agent-Data-Plane Label for the Agent Data Plane team Team:Obs-InfraObs Label for the Observability Infrastructure Monitoring team Team:Security-Service Integrations Security Service Integrations Team Team:Security-Windows Platform Windows Platform Team in Security Solution Team:Security-Deployment and Devices Deployment and Devices Team in Security Solution labels Jun 9, 2025
@elasticmachine
Copy link
Copy Markdown
Contributor

Pinging @elastic/elastic-agent-control-plane (Team:Elastic-Agent-Control-Plane)

@elasticmachine
Copy link
Copy Markdown
Contributor

Pinging @elastic/obs-ds-hosted-services (Team:obs-ds-hosted-services)

@botelastic botelastic bot removed the needs_team Indicates that the issue/PR needs a Team:* label label Jun 9, 2025
@elasticmachine
Copy link
Copy Markdown
Contributor

Pinging @elastic/elastic-agent-data-plane (Team:Elastic-Agent-Data-Plane)

@elasticmachine
Copy link
Copy Markdown
Contributor

Pinging @elastic/sec-windows-platform (Team:Security-Windows Platform)

@elasticmachine
Copy link
Copy Markdown
Contributor

Pinging @elastic/security-service-integrations (Team:Security-Service Integrations)

@elasticmachine
Copy link
Copy Markdown
Contributor

Pinging @elastic/sec-deployment-and-devices (Team:Security-Deployment and Devices)

@mergify
Copy link
Copy Markdown
Contributor Author

mergify bot commented Jun 9, 2025

This pull request has not been merged yet. Could you please review and merge it @khushijain21? 🙏

* [Chore] Replace global logger with local logger instance #3
@khushijain21 khushijain21 enabled auto-merge (squash) June 9, 2025 08:02
@khushijain21 khushijain21 merged commit faac993 into 8.19 Jun 9, 2025
243 of 244 checks passed
@khushijain21 khushijain21 deleted the mergify/bp/8.19/pr-43657 branch June 9, 2025 11:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport conflicts There is a conflict in the backported pull request Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team Team:Elastic-Agent-Data-Plane Label for the Agent Data Plane team Team:obs-ds-hosted-services Label for the Observability Hosted Services team Team:Obs-InfraObs Label for the Observability Infrastructure Monitoring team Team:Security-Deployment and Devices Deployment and Devices Team in Security Solution Team:Security-Service Integrations Security Service Integrations Team Team:Security-Windows Platform Windows Platform Team in Security Solution

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants