Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The monitor agent consumes the eventsmap to multicast its events, as well as other agent events, to subscribers. Pull it's initialization logic into a cell, to reduce the amount of logic needed in the daemon startup sequence. If there's no eventsmap in the hive graph, the agent functions solely for passing along agent events. Dropping RunMonitor flag: Except for testing, there isn't really a use case for not attaching to the eventsmap (The attachment alone doesn't cause performance overhead yet, only once there is a consumer/listener we start reading.) Putting RunMonitor into AgentConfig would mean exposing it as a flag, which is not desirable. Instead, make the eventsmap dependency optional so that non-privileged tests/benchmarks can still use the monitor agent for its userspace capabilities. Proxy Logger changes: To improve on the isolation of components, make NewAgent private. The only consumer other than the cell is the proxy logger benchmark, which can create a hive instead. Unfortunately, this makes the benchmarks require privileges. Dropping Context() from the API: There isn't a good reason to export the context, and it doesn't belong in the monitor's public API. Rework the coordination between the monitor API server and the agent slightly to make the Context() method unnecessary. Signed-off-by: David Bimmler <david.bimmler@isovalent.com>
- Loading branch information
1 parent
80d30af
commit d496777
Showing
12 changed files
with
223 additions
and
101 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.