We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 1683669 + 1f4d746 commit 958ff1dCopy full SHA for 958ff1d
src/main/kotlin/com/cosmotech/api/metrics/MonitorServiceAspect.kt
@@ -17,12 +17,17 @@ import org.aspectj.lang.annotation.Pointcut
17
import org.aspectj.lang.reflect.CodeSignature
18
import org.slf4j.Logger
19
import org.slf4j.LoggerFactory
20
+import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty
21
import org.springframework.stereotype.Component
22
23
private const val SERVICE_NAME = "API"
24
25
@Aspect
26
@Component
27
+@ConditionalOnProperty(
28
+ name = ["csm.platform.metrics.enabled"],
29
+ havingValue = "true",
30
+ matchIfMissing = false)
31
class MonitorServiceAspect(
32
private var meterRegistry: MeterRegistry,
33
private val eventPublisher: CsmEventPublisher,
0 commit comments