Fix critical and major sonar violations
[aai/sparky-be.git] / sparkybe-onap-service / src / main / java / org / onap / aai / sparky / analytics / HistogramSampler.java
index c1fa9f1..1350d28 100644 (file)
@@ -173,7 +173,7 @@ public final class HistogramSampler {
     this.minValue = -1;
     this.maxValue = 0;
     initializeHistogramBins(numBins);
-    this.stepSize = (maxValue / numBins);
+    this.stepSize = ((double) maxValue / (double) numBins);
     clear();
   }