You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficcontrol.apache.org by ne...@apache.org on 2016/10/28 20:15:51 UTC

[13/30] incubator-trafficcontrol git commit: Remove TM2 unused symbols

Remove TM2 unused symbols


Project: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/commit/7e1fefd4
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/tree/7e1fefd4
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/diff/7e1fefd4

Branch: refs/heads/master
Commit: 7e1fefd41b54881a58ecbf75ce2d27a9f28d1ea6
Parents: 89249d5
Author: Robert Butts <ro...@gmail.com>
Authored: Thu Oct 20 14:33:24 2016 -0600
Committer: Dave Neuman <ne...@apache.org>
Committed: Fri Oct 28 14:00:36 2016 -0600

----------------------------------------------------------------------
 .../traffic_monitor/health/cache_health.go      | 22 --------------------
 .../traffic_monitor/manager/healthresult.go     |  3 ---
 2 files changed, 25 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/blob/7e1fefd4/traffic_monitor/experimental/traffic_monitor/health/cache_health.go
----------------------------------------------------------------------
diff --git a/traffic_monitor/experimental/traffic_monitor/health/cache_health.go b/traffic_monitor/experimental/traffic_monitor/health/cache_health.go
index eba1d30..cf1acff 100644
--- a/traffic_monitor/experimental/traffic_monitor/health/cache_health.go
+++ b/traffic_monitor/experimental/traffic_monitor/health/cache_health.go
@@ -10,28 +10,6 @@ import (
 	"strings"
 )
 
-// Get the String value of one of those pesky map[string]interface{} things that seem so easy
-func getString(key string, intface map[string]interface{}) (string, error) {
-	str, ok := intface[key].(string)
-
-	if ok {
-		return str, nil
-	} else {
-		return "", fmt.Errorf("Error in getString: No string found for key %s", key)
-	}
-}
-
-// Get the float64 value of one of those pesky map[string]interface{} things that seem so easy
-func getNumber(key string, intface map[string]interface{}) (float64, error) {
-	val, ok := intface[key].(float64)
-
-	if ok {
-		return val, nil
-	} else {
-		return -1, fmt.Errorf("Error in getNumber: No number found for %s", key)
-	}
-}
-
 func setError(newResult *cache.Result, err error) {
 	newResult.Error = err
 	newResult.Available = false

http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/blob/7e1fefd4/traffic_monitor/experimental/traffic_monitor/manager/healthresult.go
----------------------------------------------------------------------
diff --git a/traffic_monitor/experimental/traffic_monitor/manager/healthresult.go b/traffic_monitor/experimental/traffic_monitor/manager/healthresult.go
index b4ad2bb..dda4d27 100644
--- a/traffic_monitor/experimental/traffic_monitor/manager/healthresult.go
+++ b/traffic_monitor/experimental/traffic_monitor/manager/healthresult.go
@@ -84,9 +84,6 @@ func StartHealthResultManager(
 	return lastHealthDurations, events, localCacheStatus
 }
 
-// cacheAggregateSeconds is how often to aggregate stats, if the health chan is never empty. (Otherwise, we read from the chan until it's empty, then aggregate, continuously)
-const cacheAggregateSeconds = 1
-
 func healthResultManagerListen(
 	cacheHealthChan <-chan cache.Result,
 	toData todata.TODataThreadsafe,