Skip to content

[9.1](backport #45679) feat: add status reporting to CloudWatch#45843

Merged
Kavindu-Dodan merged 2 commits into9.1from
mergify/bp/9.1/pr-45679
Aug 7, 2025
Merged

[9.1](backport #45679) feat: add status reporting to CloudWatch#45843
Kavindu-Dodan merged 2 commits into9.1from
mergify/bp/9.1/pr-45679

Conversation

@mergify
Copy link
Contributor

@mergify mergify bot commented Aug 7, 2025

Proposed commit message

Adds Status reporting for AWS CloudWatch input. I have introduced following,

  • cwStateReporter : This proxy the status to the actual status reporter. Validate status change from current before conveying status to internal reporter.
  • debugCWStatusReporter: Performs debug logging when context-bound reporter is missing. For example, this happens in standalone mode

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.

Disruptive User Impact

None - Status reports are utilized by the Agent. In standalone mode, logs are added in Debug level

How to test this PR locally

  • Run standalone filebeat with CloudWatch input & debug logs
  • Observe debug logs with CloudWatch input status updated: prefix for status changes

See below log entries from a standalone run,

Startup and configuration

image

Degraded - network connectivity issue

image

Back to running status

image

Related issues

Fixes #44648


This is an automatic backport of pull request #45679 done by Mergify.

* feat: add status reporting to CloudWatch

Signed-off-by: Kavindu Dodanduwa <kavindu.dodanduwa@elastic.co>

* improve status propagation

Signed-off-by: Kavindu Dodanduwa <kavindu.dodanduwa@elastic.co>

* add changelog entry

Signed-off-by: Kavindu Dodanduwa <kavindu.dodanduwa@elastic.co>

* review: sync for reporting

Signed-off-by: Kavindu Dodanduwa <kavindu.dodanduwa@elastic.co>

* review: add error message for degrading statuses

Signed-off-by: Kavindu Dodanduwa <kavindu.dodanduwa@elastic.co>

* review suggestions

Signed-off-by: Kavindu Dodanduwa <kavindu.dodanduwa@elastic.co>

* improve nil handling in error handling

Signed-off-by: Kavindu Dodanduwa <kavindu.dodanduwa@elastic.co>

---------

Signed-off-by: Kavindu Dodanduwa <kavindu.dodanduwa@elastic.co>
(cherry picked from commit b17bbad)
@mergify mergify bot added the backport label Aug 7, 2025
@mergify mergify bot requested a review from a team as a code owner August 7, 2025 18:58
@mergify mergify bot added the backport label Aug 7, 2025
@botelastic botelastic bot added the needs_team Indicates that the issue/PR needs a Team:* label label Aug 7, 2025
@github-actions
Copy link
Contributor

github-actions bot commented Aug 7, 2025

🤖 GitHub comments

Expand to view the GitHub comments

Just comment with:

  • run docs-build : Re-trigger the docs validation. (use unformatted text in the comment!)

@github-actions github-actions bot added the Team:obs-ds-hosted-services Label for the Observability Hosted Services team label Aug 7, 2025
@elasticmachine
Copy link
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 Aug 7, 2025
@Kavindu-Dodan Kavindu-Dodan enabled auto-merge (squash) August 7, 2025 19:23
@Kavindu-Dodan Kavindu-Dodan merged commit eb6cd18 into 9.1 Aug 7, 2025
37 checks passed
@Kavindu-Dodan Kavindu-Dodan deleted the mergify/bp/9.1/pr-45679 branch August 7, 2025 21:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport Team:obs-ds-hosted-services Label for the Observability Hosted Services team

2 participants