mirror of
https://github.com/weaveworks/scope.git
synced 2026-07-28 17:51:21 +00:00
Add pod delete control
- Push shortcut reports when pods are created/deleted - Buffer upto 2 reports instead of dropping them
This commit is contained in:
@@ -75,7 +75,7 @@ func NewAppClient(pc ProbeConfig, hostname, target string, control xfer.ControlH
|
||||
TLSClientConfig: httpTransport.TLSClientConfig,
|
||||
},
|
||||
conns: map[string]xfer.Websocket{},
|
||||
readers: make(chan io.Reader),
|
||||
readers: make(chan io.Reader, 2),
|
||||
control: control,
|
||||
}, nil
|
||||
}
|
||||
@@ -273,6 +273,7 @@ func (c *appClient) Publish(r io.Reader) error {
|
||||
select {
|
||||
case c.readers <- r:
|
||||
default:
|
||||
log.Errorf("Dropping report to %s", c.target)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user