mirror of
https://github.com/weaveworks/scope.git
synced 2026-03-05 11:11:13 +00:00
Merge pull request #67 from weaveworks/remove-topology-type
Topologies no longer have a 'type' (for grouping)
This commit is contained in:
@@ -12,7 +12,6 @@ type APITopologyDesc struct {
|
||||
Name string `json:"name"`
|
||||
URL string `json:"url"`
|
||||
GroupedURL string `json:"grouped_url,omitempty"`
|
||||
Type string `json:"type"`
|
||||
Stats topologyStats `json:"stats"`
|
||||
}
|
||||
|
||||
@@ -43,7 +42,6 @@ func makeTopologyList(rep Reporter) func(w http.ResponseWriter, r *http.Request)
|
||||
Name: def.human,
|
||||
URL: url,
|
||||
GroupedURL: groupedURL,
|
||||
Type: def.typ,
|
||||
Stats: stats(def.topologySelecter(rpt).RenderBy(def.MapFunc, false)),
|
||||
})
|
||||
}
|
||||
|
||||
@@ -21,9 +21,6 @@ func TestAPITopology(t *testing.T) {
|
||||
if topo.GroupedURL != "" {
|
||||
is200(t, ts, topo.GroupedURL)
|
||||
}
|
||||
if have := topo.Type; have == "" {
|
||||
t.Errorf("Type isn't empty: %q", have)
|
||||
}
|
||||
if have := topo.Stats.EdgeCount; have <= 0 {
|
||||
t.Errorf("EdgeCount isn't positive: %d", have)
|
||||
}
|
||||
|
||||
@@ -45,8 +45,7 @@ var topologyRegistry = map[string]struct {
|
||||
topologySelecter
|
||||
report.MapFunc
|
||||
hasGrouped bool
|
||||
typ string
|
||||
}{
|
||||
"applications": {"Applications", selectProcess, report.ProcessPID, true, "Process"},
|
||||
"hosts": {"Hosts", selectNetwork, report.NetworkHostname, false, "Network"},
|
||||
"applications": {"Applications", selectProcess, report.ProcessPID, true},
|
||||
"hosts": {"Hosts", selectNetwork, report.NetworkHostname, false},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user