use of com.sequenceiq.common.api.telemetry.response.WorkloadAnalyticsResponse in project cloudbreak by hortonworks.
the class TelemetryConverter method createWorkloadAnalyticsResponseFromSource.
private WorkloadAnalyticsResponse createWorkloadAnalyticsResponseFromSource(Telemetry telemetry) {
WorkloadAnalyticsResponse waResponse = null;
if (telemetry.getWorkloadAnalytics() != null) {
LOGGER.debug("Setting workload analytics telemetry settings (response).");
WorkloadAnalytics workloadAnalytics = telemetry.getWorkloadAnalytics();
waResponse = new WorkloadAnalyticsResponse();
waResponse.setAttributes(workloadAnalytics.getAttributes());
}
return waResponse;
}
use of com.sequenceiq.common.api.telemetry.response.WorkloadAnalyticsResponse in project cloudbreak by hortonworks.
the class TelemetryConverter method convert.
public TelemetryResponse convert(Telemetry telemetry) {
TelemetryResponse response = null;
if (telemetry != null) {
LoggingResponse loggingResponse = createLoggingResponseFromSource(telemetry);
MonitoringResponse monitoringResponse = createMonitoringResponseFromSource(telemetry);
WorkloadAnalyticsResponse waResponse = createWorkloadAnalyticsResponseFromSource(telemetry);
response = new TelemetryResponse();
response.setLogging(loggingResponse);
response.setMonitoring(monitoringResponse);
response.setWorkloadAnalytics(waResponse);
response.setFluentAttributes(telemetry.getFluentAttributes());
response.setRules(telemetry.getRules());
createFeaturesResponseFromSource(response, telemetry.getFeatures());
}
return response;
}
use of com.sequenceiq.common.api.telemetry.response.WorkloadAnalyticsResponse in project cloudbreak by hortonworks.
the class TelemetryApiConverter method createWorkloadAnalyticsResponseFromSource.
private WorkloadAnalyticsResponse createWorkloadAnalyticsResponseFromSource(EnvironmentWorkloadAnalytics workloadAnalytics) {
WorkloadAnalyticsResponse waResponse = null;
if (workloadAnalytics != null) {
waResponse = new WorkloadAnalyticsResponse();
waResponse.setAttributes(workloadAnalytics.getAttributes());
}
return waResponse;
}
Aggregations