Browse Source

Add a property to enable/disable metrics module (#8484)

3.0.0/version-upgrade
kezhenxu94 3 years ago committed by GitHub
parent
commit
fa19006a18
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      dolphinscheduler-alert/dolphinscheduler-alert-server/src/main/resources/application.yaml
  2. 3
      dolphinscheduler-api/src/main/resources/application.yaml
  3. 3
      dolphinscheduler-master/src/main/resources/application.yaml
  4. 3
      dolphinscheduler-meter/src/main/java/org/apache/dolphinscheduler/meter/MeterConfiguration.java
  5. 3
      dolphinscheduler-python/src/main/resources/application.yaml
  6. 3
      dolphinscheduler-standalone-server/src/main/resources/application.yaml
  7. 3
      dolphinscheduler-worker/src/main/resources/application.yaml

3
dolphinscheduler-alert/dolphinscheduler-alert-server/src/main/resources/application.yaml

@ -52,6 +52,9 @@ management:
alert:
port: 50052
metrics:
enabled: true
# Override by profile
---

3
dolphinscheduler-api/src/main/resources/application.yaml

@ -104,6 +104,9 @@ registry:
audit:
enabled: false
metrics:
enabled: true
# Override by profile
---

3
dolphinscheduler-master/src/main/resources/application.yaml

@ -121,6 +121,9 @@ management:
tags:
application: ${spring.application.name}
metrics:
enabled: true
# Override by profile
---

3
dolphinscheduler-meter/src/main/java/org/apache/dolphinscheduler/meter/MeterConfiguration.java

@ -21,10 +21,10 @@
package org.apache.dolphinscheduler.meter;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.EnableAspectJAutoProxy;
import org.springframework.context.annotation.Profile;
import io.micrometer.core.aop.CountedAspect;
import io.micrometer.core.aop.TimedAspect;
@ -33,6 +33,7 @@ import io.micrometer.core.instrument.MeterRegistry;
@Configuration
@EnableAspectJAutoProxy
@EnableAutoConfiguration
@ConditionalOnProperty(prefix = "metrics", name = "enabled", havingValue = "true")
public class MeterConfiguration {
@Bean
public TimedAspect timedAspect(MeterRegistry registry) {

3
dolphinscheduler-python/src/main/resources/application.yaml

@ -67,6 +67,9 @@ management:
tags:
application: ${spring.application.name}
metrics:
enabled: true
# Override by profile
---
spring:

3
dolphinscheduler-standalone-server/src/main/resources/application.yaml

@ -180,6 +180,9 @@ management:
audit:
enabled: true
metrics:
enabled: true
# Override by profile
---
spring:

3
dolphinscheduler-worker/src/main/resources/application.yaml

@ -83,3 +83,6 @@ management:
metrics:
tags:
application: ${spring.application.name}
metrics:
enabled: true

Loading…
Cancel
Save