mirror of
https://github.com/weaveworks/scope.git
synced 2026-03-03 02:00:43 +00:00
fix bug: handle short-lived ebpf-tracked connections again
This got broken in #2559. The problem here is similar to #2551.
This commit is contained in:
@@ -44,10 +44,10 @@ var ContainerRenderer = MakeFilter(
|
||||
|
||||
var mapEndpoint2IP = MakeMap(
|
||||
endpoint2IP,
|
||||
// We drop endpoint nodes which were procspied or eBBF-tracked, as
|
||||
// they will be joined to containers through the process topology,
|
||||
// and we don't want to double count edges.
|
||||
MakeFilter(Complement(procspiedOrEBPF), SelectEndpoint),
|
||||
// We drop endpoint nodes which were procspied, as they will be
|
||||
// joined to containers through the process topology, and we don't
|
||||
// want to double count edges.
|
||||
MakeFilter(Complement(procspied), SelectEndpoint),
|
||||
)
|
||||
|
||||
const originalNodeID = "original_node_id"
|
||||
|
||||
@@ -237,8 +237,13 @@ func IsRunning(n report.Node) bool {
|
||||
// IsStopped checks if the node is *not* a running docker container
|
||||
var IsStopped = Complement(IsRunning)
|
||||
|
||||
func procspied(node report.Node) bool {
|
||||
_, ok := node.Latest.Lookup(endpoint.Procspied)
|
||||
return ok
|
||||
}
|
||||
|
||||
func procspiedOrEBPF(node report.Node) bool {
|
||||
if _, ok := node.Latest.Lookup(endpoint.Procspied); ok {
|
||||
if procspied(node) {
|
||||
return true
|
||||
}
|
||||
_, ok := node.Latest.Lookup(endpoint.EBPF)
|
||||
|
||||
Reference in New Issue
Block a user