When creating an io. vertx. mutiny. ext. web. client. WebClient, one can provide a WebClientOptions object.
The WebClientOptions allow to set a name and a metric name
However, this name is not used and added as a tag to the exposed Micrometer metrics.
Reason is the logic in io.quarkus.micrometer.runtime.binder.vertx.VertxMeterBinderAdapter#extractClientName
The clientName must be prefixed with an arbitrary String followed by a bar (|).
Otherwise the name is null.
If one sets the metric name as something|my-client-metric, then the resulting name is my-client-metric.
Expected behavior
webClientOptions.setMetricsName("my-web-client");
Setting this option tags the exposed metrics of the webclient with the given name.
Describe the bug
When creating an io. vertx. mutiny. ext. web. client. WebClient, one can provide a
WebClientOptions
object. The WebClientOptions allow to set a name and a metric nameHowever, this name is not used and added as a tag to the exposed Micrometer metrics.
Reason is the logic in
io.quarkus.micrometer.runtime.binder.vertx.VertxMeterBinderAdapter#extractClientName
The clientName must be prefixed with an arbitrary String followed by a bar (|). Otherwise the name is null.If one sets the metric name as
something|my-client-metric
, then the resulting name ismy-client-metric
.Expected behavior
Setting this option tags the exposed metrics of the webclient with the given name.
Actual behavior
1)
The setting is not honored.
2)
The setting results in a metric name of
my-web-client
How to Reproduce?
No response
Output of
uname -a
orver
No response
Output of
java -version
21
Quarkus version or git rev
3.15.1
Build tool (ie. output of
mvnw --version
orgradlew --version
)No response
Additional information
No response