cloudfoundry/stratos

View on GitHub
src/frontend/packages/cf-autoscaler/src/core/autoscaler-helpers/autoscaler-transform-metric.ts

Summary

Maintainability
B
4 hrs
Test Coverage

File autoscaler-transform-metric.ts has 258 lines of code (exceeds 250 allowed). Consider refactoring.
Open

import moment from 'moment-timezone';

import { PaginationResponse } from '../../../../cloud-foundry/src/store/types/cf-api.types';
import {
  AppAutoscalerMetricBasicInfo,

    Function buildMetricData has 7 arguments (exceeds 4 allowed). Consider refactoring.
    Open

      metricName: string,
      data: PaginationResponse<AppAutoscalerMetricData>,
      startTime: number,
      endTime: number,
      skipFormat: boolean,

      Function transformMetricData has 5 arguments (exceeds 4 allowed). Consider refactoring.
      Open

        source: AppAutoscalerMetricData[],
        interval: number,
        startTime: number,
        endTime: number,
        timezone: string): AppAutoscalerMetricDataPoint[] {

        Function insertEmptyMetrics has 5 arguments (exceeds 4 allowed). Consider refactoring.
        Open

          data: AppAutoscalerMetricDataPoint[],
          startTime: number,
          endTime: number,
          interval: number,
          timezone?: string

          There are no issues that match your filters.

          Category
          Status