Skip to content

Document set-up of observability in code, for example to change the endpoint location #8631

@tjquinno

Description

@tjquinno

Environment Details

  • Helidon Version: 4.x
  • Helidon SE or Helidon MP SE
  • JDK version:
  • OS:
  • Docker version (if applicable):

Problem Description

With the introduction of observability into Helidon 4, the doc now does not show how to control the settings programmatically for metics, health, etc.

For example, there is no illustration of how to change the endpoint address.

From an internal Slack thread courtesy of @romain-grecourt

WebServer.builder()
        .port(8080)
        .addFeature(ObserveFeature.builder()
                            .addObserver(MetricsObserver.builder()
                                                 .endpoint("/metrics")
                                                 .build())
                            .build())
        .build()
        .start();

Metadata

Metadata

Assignees

Type

No type

Projects

Status

In Progress

Relationships

None yet

Development

No branches or pull requests

Issue actions