mirror of
https://github.com/valitydev/disputes-api.git
synced 2024-11-06 00:55:23 +00:00
add otel.enabled
This commit is contained in:
parent
9345e2efd5
commit
b3200e2914
@ -16,6 +16,7 @@ import io.opentelemetry.semconv.resource.attributes.ResourceAttributes;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
|
||||
@ -23,6 +24,7 @@ import java.time.Duration;
|
||||
|
||||
@Slf4j
|
||||
@Configuration
|
||||
@ConditionalOnProperty(value = "otel.enabled", havingValue = "true", matchIfMissing = true)
|
||||
@RequiredArgsConstructor
|
||||
public class OtelConfig {
|
||||
|
||||
|
@ -137,3 +137,4 @@ http-client:
|
||||
otel:
|
||||
resource: http://localhost:4318/v1/traces
|
||||
timeout: 60000
|
||||
enabled: false
|
||||
|
Loading…
Reference in New Issue
Block a user