@Test public void testConvertToRequestWithEmptyTelemetry() { Telemetry telemetry = new Telemetry(); TelemetryRequest result = underTest.convertToRequest(telemetry); assertNotNull(result); assertNull(result.getLogging()); assertNull(result.getWorkloadAnalytics()); assertNull(result.getFeatures()); }
public TelemetryRequest convertToRequest(Telemetry telemetry) { TelemetryRequest telemetryRequest = new TelemetryRequest(); if (telemetry != null) { LoggingRequest loggingRequest = createLoggingRequestFromSource(telemetry); WorkloadAnalyticsRequest waRequest = createWorkloadAnalyticsRequestFromSource(telemetry); FeaturesRequest featuresRequest = createFeaturesRequestFromSource(telemetry); telemetryRequest.setWorkloadAnalytics(waRequest); telemetryRequest.setLogging(loggingRequest); telemetryRequest.setFluentAttributes(telemetry.getFluentAttributes()); telemetryRequest.setFeatures(featuresRequest); } return telemetryRequest; }
TelemetryConverter { public TelemetryRequest convertToRequest(Telemetry telemetry) { TelemetryRequest telemetryRequest = new TelemetryRequest(); if (telemetry != null) { LoggingRequest loggingRequest = createLoggingRequestFromSource(telemetry); WorkloadAnalyticsRequest waRequest = createWorkloadAnalyticsRequestFromSource(telemetry); FeaturesRequest featuresRequest = createFeaturesRequestFromSource(telemetry); telemetryRequest.setWorkloadAnalytics(waRequest); telemetryRequest.setLogging(loggingRequest); telemetryRequest.setFluentAttributes(telemetry.getFluentAttributes()); telemetryRequest.setFeatures(featuresRequest); } return telemetryRequest; } }
TelemetryConverter { public TelemetryRequest convertToRequest(Telemetry telemetry) { TelemetryRequest telemetryRequest = new TelemetryRequest(); if (telemetry != null) { LoggingRequest loggingRequest = createLoggingRequestFromSource(telemetry); WorkloadAnalyticsRequest waRequest = createWorkloadAnalyticsRequestFromSource(telemetry); FeaturesRequest featuresRequest = createFeaturesRequestFromSource(telemetry); telemetryRequest.setWorkloadAnalytics(waRequest); telemetryRequest.setLogging(loggingRequest); telemetryRequest.setFluentAttributes(telemetry.getFluentAttributes()); telemetryRequest.setFeatures(featuresRequest); } return telemetryRequest; } TelemetryConverter(TelemetryConfiguration configuration,
            @Value("${cb.cm.telemetrypublisher.enabled:false}") boolean telemetryPublisherEnabled,
            @Value("${cb.cm.telemetrypublisher.default:true}") boolean telemetryPublisherDefaultValue); }
TelemetryConverter { public TelemetryRequest convertToRequest(Telemetry telemetry) { TelemetryRequest telemetryRequest = new TelemetryRequest(); if (telemetry != null) { LoggingRequest loggingRequest = createLoggingRequestFromSource(telemetry); WorkloadAnalyticsRequest waRequest = createWorkloadAnalyticsRequestFromSource(telemetry); FeaturesRequest featuresRequest = createFeaturesRequestFromSource(telemetry); telemetryRequest.setWorkloadAnalytics(waRequest); telemetryRequest.setLogging(loggingRequest); telemetryRequest.setFluentAttributes(telemetry.getFluentAttributes()); telemetryRequest.setFeatures(featuresRequest); } return telemetryRequest; } TelemetryConverter(TelemetryConfiguration configuration,
            @Value("${cb.cm.telemetrypublisher.enabled:false}") boolean telemetryPublisherEnabled,
            @Value("${cb.cm.telemetrypublisher.default:true}") boolean telemetryPublisherDefaultValue); TelemetryResponse convert(Telemetry telemetry); Telemetry convert(TelemetryRequest request, StackType type); TelemetryRequest convert(TelemetryResponse response,
            SdxClusterResponse sdxClusterResponse); TelemetryRequest convertToRequest(Telemetry telemetry); Optional<FeatureSetting> createWorkloadAnalyticsFeature(WorkloadAnalyticsRequest waRequest); WorkloadAnalyticsRequest createWorkloadAnalyticsRequest(TelemetryResponse response,
            SdxClusterResponse sdxClusterResponse); }
TelemetryConverter { public TelemetryRequest convertToRequest(Telemetry telemetry) { TelemetryRequest telemetryRequest = new TelemetryRequest(); if (telemetry != null) { LoggingRequest loggingRequest = createLoggingRequestFromSource(telemetry); WorkloadAnalyticsRequest waRequest = createWorkloadAnalyticsRequestFromSource(telemetry); FeaturesRequest featuresRequest = createFeaturesRequestFromSource(telemetry); telemetryRequest.setWorkloadAnalytics(waRequest); telemetryRequest.setLogging(loggingRequest); telemetryRequest.setFluentAttributes(telemetry.getFluentAttributes()); telemetryRequest.setFeatures(featuresRequest); } return telemetryRequest; } TelemetryConverter(TelemetryConfiguration configuration,
            @Value("${cb.cm.telemetrypublisher.enabled:false}") boolean telemetryPublisherEnabled,
            @Value("${cb.cm.telemetrypublisher.default:true}") boolean telemetryPublisherDefaultValue); TelemetryResponse convert(Telemetry telemetry); Telemetry convert(TelemetryRequest request, StackType type); TelemetryRequest convert(TelemetryResponse response,
            SdxClusterResponse sdxClusterResponse); TelemetryRequest convertToRequest(Telemetry telemetry); Optional<FeatureSetting> createWorkloadAnalyticsFeature(WorkloadAnalyticsRequest waRequest); WorkloadAnalyticsRequest createWorkloadAnalyticsRequest(TelemetryResponse response,
            SdxClusterResponse sdxClusterResponse);  }