Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4.x MP metrics and health do not honor server.features.observe.observers config, but instead observe.providers.* #8009

Closed
tjquinno opened this issue Nov 15, 2023 · 0 comments · Fixed by #8010
Assignees
Labels
4.x Version 4.x bug Something isn't working config health metrics MP
Milestone

Comments

@tjquinno
Copy link
Member

Environment Details

  • Helidon Version: 4.0.0
  • Helidon SE or Helidon MP MP
  • JDK version:
  • OS:
  • Docker version (if applicable):

Problem Description

In MP apps, metrics and health follow config at the top level (metrics and health) but not config inside server.features.observe.observers.metrics or ...health as SE apps do.

But they do respond to config at observe.providers.xxx.

This seems to be because the constructors for MetricsCdiExtension and HealthCdiExtension incorrectly pass hardcoded strings "observe.providers.metrics" and "observe.providers.health" to the superclass constructor as one of the config paths to consider.

I assume the intended behavior is for the CDI extensions to use either the top-level config for metrics and health or the config nested under server... but the paths do not have the correct prefix and use providers instead of observers.

Steps to reproduce

  1. Build and run the MP QuickStart app without change, then run this command: curl -v http://localhost:8080/health. You get the expected output with status 200
    {"status":"UP","checks":[]}
    because the MP health CDI extension sets the health setting details to true programmatically.
  2. Stop the server, then add the following config:
    server.features.observe.observers.health.details = false
  3. Rebuild and rerun the server. The output is the same because the health CDI observer ignores the config under server.features....
@tjquinno tjquinno added bug Something isn't working MP metrics health config 4.x Version 4.x labels Nov 15, 2023
@tjquinno tjquinno self-assigned this Nov 15, 2023
@tjquinno tjquinno added this to the 4.0.1 milestone Nov 15, 2023
@m0mus m0mus added this to Backlog Aug 12, 2024
@m0mus m0mus moved this to Closed in Backlog Aug 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4.x Version 4.x bug Something isn't working config health metrics MP
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

1 participant