Achilleas Tzenetopoulos 5 rokov pred
rodič
commit
c58c94f163

+ 13 - 12
kubernetes-v1.15.4/pkg/scheduler/algorithm/priorities/custom_resource_allocation.go

@@ -105,18 +105,19 @@ func customScoreInfluxDB(metrics []string, uuid string, socket,
 	// Calculate the average for the metrics provided
 	return calculateWeightedAverage(response, numberOfRows, len(metrics))
 }
-func InvalidateCache() {
-	// Check if the cache needs update
-	select {
-	// clean the cache if 10 seconds are passed
-	case <-customcache.LabCache.Timeout.C:
-		klog.Infof("Time to erase")
-		//customcache.LabCache.Timeout.Stop()
-		customcache.LabCache.CleanCache()
-
-	default:
-	}
-}
+
+// func InvalidateCache() {
+// 	// Check if the cache needs update
+// 	select {
+// 	// clean the cache if 10 seconds are passed
+// 	case <-customcache.LabCache.Timeout.C:
+// 		klog.Infof("Time to erase")
+// 		//customcache.LabCache.Timeout.Stop()
+// 		customcache.LabCache.CleanCache()
+
+// 	default:
+// 	}
+// }
 
 func customResourceScorer(nodeName string) (float64, error) {