431 questions
0
votes
0
answers
13
views
spring kafka getting metrics to for messages published
i have set up the following config in my spring 3.3 (micrometer 1.12.5, kafka 3.2.4) application
DefaultKafkaProducerFactory<String, Car> objectObjectDefaultKafkaProducerFactory = new ...
0
votes
0
answers
17
views
Datasource Micrometer not working with opentelemetry zero-code instrumentation
I am using the zero-code instrumentation Java agent in order to export traces from my Spring Boot app to Jager in otlp format. So far so good, but i need more than the autoconfiguration provided by ...
0
votes
0
answers
22
views
Custom WebClient Metrics Tag From The MDC
I am trying to add a custom tag to the http.client.requests WebClient metrics that are provided by Spring Boot. I have a value that I have placed in the MDC which I want to use for this custom tag. My ...
0
votes
0
answers
45
views
Error creating bean with name 'meterRegistryPostProcessor'
Context:
I'm facing an error while deploying the shade jar on lambda. The jar was is working on Spring Boot 2.6.8 but not on Spring Boot 2.7.18.
Error:
Error creating bean with name 'org....
0
votes
1
answer
24
views
Extend annotation io.micrometer.core.annotation.Timed
I'm using @Timed in Spring Boot app for collecting metrics from methods and it works:
@Timed(percentiles = {0.95, 0.99}, histogram = true, extraTags = {"slice", "client"})
Since I'...
-3
votes
1
answer
50
views
How to add information about topic to metrics of Spring Kafka Template?
I have metric "spring_kafka_template_seconds_count" but there are no topic information. I use 2.8.11 spring-kafka version. In doc https://docs.spring.io/spring-kafka/reference/kafka/...
0
votes
0
answers
61
views
SpringBoot 3 application does not creating traceId and spanId when micrometer dependency is referred from another project
I'm trying to generate traceId and spanId in my application. However I've kept io.micrometer dependency in another common module (which does not have main). when I use common-modules jar in my ...
0
votes
1
answer
76
views
Micrometer counter into Grafana chart
Hi I have the counter that increments with the tags job.id and processing.status
Counter counter = Counter.builder("ri.procession.job.count")
.tag("job....
0
votes
0
answers
67
views
Spring Boot Prometheus endpoint doesn't display metrics from global registry
Working on a project that uses Micrometer/Spring boot for tracking some metrics, e.g. JVM which works fine. Trying to add/track reactor netty metrics that use Micrometer's global registry. Spring Boot ...
1
vote
0
answers
118
views
Micrometer and Spring WebClient Logs Missing Trace ID in subscribe and onStatus Methods
I'm experiencing an issue with logging in a Spring Boot application where the trace ID is not appearing in the logs generated inside the subscribe and onStatus methods of a WebClient call. I have ...
1
vote
1
answer
208
views
404 error when accessing actuator/prometheus endpoint
In my spring boot application. I added following dependencies:
spring-boot-starter-actuator
micrometer-registry-prometheus
In application.properties file I added following code:
management.endpoint....
0
votes
0
answers
29
views
Log W3C's parentId in Spring Boot 3 with micrometer/brave bridge [duplicate]
We're currently implementing W3C tracing and a requirement is that we log the span ID, trace ID and parent ID. Logging span and trace is easily done with
pattern="Micrometer Trace ID[%X{traceId}] ...
0
votes
1
answer
35
views
What is the difference between getAsyncExecutor and threadPoolTaskScheduler in Spring MVC ASyncConfigurer?
Could someone please tell me the difference between getAsyncExecutor and threadPoolTaskScheduler, as explained in the spring async-instrumentation document?
I created the config below, as mentioned in ...
1
vote
0
answers
268
views
SpringBoot 2 to SpringBoot 3.3.3 upgrade - breaking changes in metrics
I want to upgrade SpringBoot application from 2.x to latest version(3.3.3).
First of all I am aware of the changes introduced to metrics with SpringBoot 3.0.
Under Spring 2.x I had http.server....
0
votes
1
answer
29
views
How to overwrite @TimedAspect from micrometer.core for WebFlux
TimedAspect catches errors by try/catch that doesn't work in Mono/Flux world. (success calls are okey)
Or how i can fix, for catching errors in WebFlux + GraphQl with my own attributes in metrics (for ...
0
votes
0
answers
74
views
Set new trace Id for each loop iteration instead of using existing trace id
I have a spring boot 3.1.x application with dependency on micrometer-tracing and micrometer-tracing-bridge-otel libraries.
There is a service bean that sends multiple http requests to a different ...
0
votes
0
answers
64
views
Configure Spring Boot to expose all Actuator endpoints on one port while serving Micrometer metrics on a different port
I'm working on a Spring Boot application where I want to achieve the following:
All Actuator endpoints (like /actuator/health, /actuator/info, etc.) should be exposed on the default application port (...
0
votes
1
answer
165
views
Spring micrometer observe aspect dynamic tags
I am exploring using @observed aspect for method level simpler instrumentation code. This sample blog for the Observe API shows an example
https://spring.io/blog/2022/10/12/observability-with-spring-...
0
votes
1
answer
422
views
Spring boot 3 open telemetry how does the trace id propagation takes place
I am trying to implement observations and monitoring in my local application.
I have a question that how is the trace id propagated from one application to another application. specifically how or ...
1
vote
1
answer
411
views
WebClient micrometer trace propagation is not working
Spring boot version 3.3.2
When using WebClient with each request to another microservice new traceId is created:
api-gateway service -> order-service
same traceID for api gateway and order service
...
0
votes
0
answers
65
views
Micrometer metric max equals zero when sum is higher than zero
In our project we measure time for outgoing calls to other grpc servers, but I met a situation when a metric _max is zero, but the same metric for _sum is higher than zero.
@Slf4j
@...
0
votes
0
answers
24
views
cant see all the traces using io.micrometer and io.zipkin.reporter2 @Observed
management.endpoints.web.exposure.include=* management.endpoint.health.show-details=always management.tracing.sampling.probability=1.0
those are set firstly,
now problem is can see traces from one ...
0
votes
1
answer
247
views
How can I propagate a dynamic header downstream with micrometer tracing?
I have:
Spring Boot 3.3.+
io.micrometer:micrometer-tracing-bridge-brave
Currently, we can set management.tracing.baggage.remote-fields=f-user and expect that the header f-user will be propagated ...
1
vote
1
answer
297
views
Micrometer 1.13.0: Incorrect Metric Name Declaration
I'm encountering an issue with Micrometer 1.13.0 where one of the metric name declarations is outputted incorrectly. Instead of the expected # TYPE jvm_info gauge, it outputs # TYPE jvm info. This ...
0
votes
1
answer
294
views
Micrometer Observation lowCardinalityKeyValue and highCardinalityKeyValue uses/use cases?
I do understand micrometer observation. And i see that it supports adding lowCardinalityKeyValue and highCardinalityKeyValue with something like below -
Observation observation = Observation.start(&...
0
votes
0
answers
280
views
Alternative for lazyTraceExecutor in springBoot 3.x upgrade
I am replacing spring-cloud-sleuth with io.micrometer:micrometer-tracing-bridge-brave for my springboot:3.x upgrade. Can you confirm if below replacement is correct?
public LazyTraceExecutor ...
0
votes
1
answer
283
views
When you create a new span directly in Observability, in what cases do you typically create it?
I'm implementing Observability with Springboot + OpenTelemetry + Micrometer.
I'm still not sure when it's a good idea to create my own spans.
When do you guys usually create your own spans ?
1
vote
1
answer
1k
views
Spring Boot : percentile with micrometer
I need to have a percentile histogram of my metrics (http.server.requests). I have checked the documentation but I cannot make it work.
I'm not using promotheus so the properties here (https://docs....
1
vote
2
answers
1k
views
Spring Boot management.metrics.distribution.percentiles examples
There's a config property for Spring Boot management.metrics.distribution.percentiles
the type of a value of the property is Map<String, double[]>
e.g. it may be set as following:
management....
0
votes
1
answer
349
views
Spring open feign set custom header using baggage (or trace)
I'm developing a spring boot 3 application that must invoke some remote http services.
Inside the application there is a job executing some business logic.
In the business logic there is also the ...
1
vote
0
answers
962
views
Set custom trace ID with Spring Boot 3, Micrometer and OTEL
I have two proprietary microservices (A and B) and a third-party one (C), both consuming and producing Kafka events.
A produces event1, and B consumes it.
B processes event1 and eventually delegates ...
0
votes
1
answer
160
views
Spring integration + Micrometer: Context propagation is not working with DirectChannel
I'm trying to use the micrometer and instrumented the JPA repository and annotated it with @Observed.
I can see the traces & metrics around that but a new trace is generated with every method call ...
1
vote
1
answer
935
views
Spring Boot 3 micrometer http server requests metrics do not include exception and error tags
In Spring Boot 2 my spring default http requests metric would include exception and error tags like this:
http_server_requests_seconds_count{error="NoResourceFoundException",exception="...
0
votes
1
answer
154
views
Micrometer does not work when used at separate services
Currently, I have 2 custom spring artefacts- metrics-util and web-utils. metrics-util contains all the functions related to measuring the metrics such as a web-filter to calculate the metrics of all ...
1
vote
2
answers
733
views
After SpringBoot upgrade v3.2.3 to v3.2.4 app doesn't start - error Failed to register Collector MicrometerCollector: jvm_info is already in use
After upgrading Spring Bootfrom v3.2.3 to v3.2.4 / v3.2.5 the application doesn't start due to error Failed to register Collector of type MicrometerCollector: jvm_info is already in use by another ...
0
votes
0
answers
42
views
Influx micrometer config for spring kafka using xml in non spring boot app
I am using below spring integration kafka. I see lot of JMX metrics using jconsole for producer servers.
kafka-template="kafkaTemplate" id="kafkaOutboundChannelAdapter"
...
0
votes
1
answer
894
views
Tracing context is not propagated when using a CompletableFuture
The following test is not working as it should
@Test
void testContextPropagation() throws ExecutionException, InterruptedException {
// create a new trace using the micrometer tracer coming from ...
1
vote
1
answer
470
views
How to pass the same traceId after consuming from Kafka using micrometer in springboot application
I am using micrometer tracing in my springboot application. My applicationhas an Api that send the data to a kafka topic and later consumes it. I want my application to have the same traceId ...
2
votes
1
answer
132
views
EhCache metrics do not appear in Prometheus if Guava cache is bound to MeterRegistry
Implicitly created EhCache caches
I have a Spring component which declares some caches using a file ehcache.xml with the following kind of configuration:
<?xml version="1.0" encoding=&...
0
votes
1
answer
300
views
How do we use java's micrometer's gauge functionality (with prometheus) for a cron when running through multiple pods?
Context - Currently I have a spring boot application deployed via k8s with the number of pods usually being around 8. I am using a wrapper over Apache Airflow for a cron job that updates the feed in ...
0
votes
1
answer
302
views
Micrometer - Custom Gauge Metric Not Working
I am calculating latency in my application in milliseconds and recording with gauge but value is not updating after first time. (I am aware that Timer metric type can also be used for latency, but I ...
-1
votes
1
answer
1k
views
Correlation ID missing in logs after enabling Log4j2 with Micrometer setup in Spring Boot 3.2.0
I recently implemented Micrometer setup in my Spring Boot 3.2.0 application to enhance tracing and metrics collection, which worked fine. However, after enabling Log4j2 for improved logging, I noticed ...
7
votes
1
answer
1k
views
Difference between opentelemetry-spring-boot-starter and the OpenTelemetry support in micrometer
I am trying to find out the easiest and most reliable way to enable OpenTelemetry observability in SpringBoot. On one hand we have the OpenTelemetry micrometer support for metrics and tracing. Tracing ...
0
votes
4
answers
2k
views
Spring Boot 3 KafkaTemplate tracing (traceId, spanId, baggage) is missing
Prior to Spring Boot 3, tracing, including Kafka tracing, was performed using Sleuth.
It was possible to propagate a tracing context (traceId, spanId, baggage) over Kafka.
Sleuth no longer exists. ...
0
votes
0
answers
586
views
How to send Lombok @Slf4j logs and System.out.println() logs to Open Telemetry through Micrometer
My current setup is: a Spring Boot app (version 3.1.5) with Micrometer, sending traces, metrics and (ideally) all logs to an otel/opentelemetry-collector-contrib Docker container.
Everything seems ...
1
vote
1
answer
323
views
Send metrics to DataDog using micrometer-registry-otlp instead of micrometer-registry-datadog
I am using a SpringBoot 3 with micrometer, actuator, in order to send metrics to Datadog.
My pom contains spring-boot-starter-actuator micrometer-registry-datadog.
I am able to send metrics to datadog ...
1
vote
0
answers
457
views
Manage baggage with Spring Boot 3 and micrometer
I implemented the following simple application in order to understand how to play with baggage.
application.yaml:
management:
tracing:
enabled: true
baggage:
enabled: true
remote-...
0
votes
0
answers
60
views
How to fix uri for `http.server.requests` metric for /token endpoint of spring-authorization-server?
I'm using Spring Authorization Server, and didn't notice that http.server.requests metric contains /oauth2/token uri tag.
But I've noticed during debugging of WebMvcMetricsFilter that the metric is ...
1
vote
1
answer
879
views
Micrometer tracing logs missing with spring boot webclient
I am trying to get the logging working with the micrometer tracing library. I get the logging now almost correct through all my project except for a filter in the spring boot webclient. I use the ...
0
votes
0
answers
439
views
Configure the OTLP address in spring boot 3
I want to congiure my OTLP addresses like described here
I added the following dependencies to export otlp data
implementation 'org.springframework.boot:spring-boot-starter-actuator'
...