Skip to content

Conversation

@naman47vyas
Copy link
Member

@naman47vyas naman47vyas commented Sep 22, 2025

Summary

This PR reduces unnecessary warning messages during healthcheck failures when running in serverless environments where no monitoring agent is expected.

Changes

  • Conditional warning logging: Only log healthcheck failure warnings when MW_TARGET is not configured, indicating an agent is expected
  • Version updates: Updated OpenTelemetry instrumentation versions from SNAPSHOT to stable releases. SNAPSHOT = BAD
    • muzzle-generation: 2.17.0-alpha-SNAPSHOT2.17.0-alpha
    • muzzle-check: 2.17.0-alpha-SNAPSHOT2.17.0-alpha
    • opentelemetryJavaagent: 2.17.0-SNAPSHOT2.17.0
    • opentelemetryJavaagentAlpha: 2.17.0-alpha-SNAPSHOT2.17.0-alpha

Motivation

In serverless environments, healthcheck failures are expected behavior when no monitoring agent is present. The previous implementation would log warnings even in these expected scenarios, creating unnecessary noise in logs.

Behavior Changes

  • Before: Always logged warnings on healthcheck failures
  • After: Only logs warnings when MW_TARGET is configured but healthcheck still fails
  • Serverless mode: Silently returns true when no target is configured and healthcheck fails due to I/O errors

Testing

  • Verified behavior in serverless environments without MW_TARGET configured
  • Confirmed warnings still appear when MW_TARGET is set but healthcheck fails

Fixes: Reduces log verbosity in serverless deployments while maintaining diagnostic capability for configured environments.

@naman47vyas naman47vyas changed the title feat: reduce verbose healthcheck warnings in serverless mode chore: reduce verbose healthcheck warnings in serverless mode Sep 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants