@Endpoint()
def get_cluster_fsid(self):
return mgr.get('config')['fsid']
+
+ @Endpoint()
+ def get_telemetry_status(self):
+ return mgr.get_module_option_ex('telemetry', 'enabled', False)
import { PrometheusListHelper } from '~/app/shared/helpers/prometheus-list-helper';
import { PrometheusAlertService } from '~/app/shared/services/prometheus-alert.service';
import { OrchestratorService } from '~/app/shared/api/orchestrator.service';
-import { MgrModuleService } from '~/app/shared/api/mgr-module.service';
import { AlertClass } from '~/app/shared/enum/health-icon.enum';
@Component({
private featureToggles: FeatureTogglesService,
private healthService: HealthService,
public prometheusService: PrometheusService,
- private mgrModuleService: MgrModuleService,
private refreshIntervalService: RefreshIntervalService,
public prometheusAlertService: PrometheusAlertService
) {
}
private getTelemetryReport() {
- this.mgrModuleService.getConfig('telemetry').subscribe((resp: any) => {
- this.telemetryEnabled = resp?.enabled;
+ this.healthService.getTelemetryStatus().subscribe((enabled: boolean) => {
+ this.telemetryEnabled = enabled;
});
}
- jwt: []
tags:
- Health
+ /api/health/get_telemetry_status:
+ get:
+ parameters: []
+ responses:
+ '200':
+ content:
+ application/vnd.ceph.api.v1.0+json:
+ type: object
+ description: OK
+ '400':
+ description: Operation exception. Please check the response body for details.
+ '401':
+ description: Unauthenticated access. Please login first.
+ '403':
+ description: Unauthorized access. Please check your permissions.
+ '500':
+ description: Unexpected error. Please check the response body for the stack
+ trace.
+ security:
+ - jwt: []
+ tags:
+ - Health
/api/health/minimal:
get:
parameters: []