|
|
@ -31,7 +31,7 @@ public class PrometheusMonitorCondition implements Condition {
|
|
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
@Override
|
|
|
|
public boolean matches(ConditionContext context, AnnotatedTypeMetadata metadata) {
|
|
|
|
public boolean matches(ConditionContext context, AnnotatedTypeMetadata metadata) {
|
|
|
|
String collectType = context.getEnvironment().getProperty(BootstrapCoreProperties.PREFIX + "collect-type", "");
|
|
|
|
String collectType = context.getEnvironment().getProperty(BootstrapCoreProperties.PREFIX + ".collect-type", "");
|
|
|
|
return StringUtil.isNotEmpty(collectType) && collectType.contains(MonitorTypeEnum.PROMETHEUS.name().toLowerCase()) ? true : false;
|
|
|
|
return StringUtil.isNotEmpty(collectType) && collectType.contains(MonitorTypeEnum.PROMETHEUS.name().toLowerCase()) ? true : false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|