weaveworks / scope

Monitoring, visualisation & management for Docker & Kubernetes
https://www.weave.works/oss/scope/
Apache License 2.0
5.87k stars 714 forks source link

perf(probe): add 'omitempty' tag to Topology.Nodes #3678

Closed bboreham closed 5 years ago

bboreham commented 5 years ago

So we save space writing out empty topologies, which we see more often after #3677. Very small impact overall.

Need to fix up app_client_internal_test.go to use Scope's test/reflect package that understands empty==nil, so now it doesn't need a previous workaround.

Remove a similar workaround in probe_internal_test.go that isn't necessary since it's already using that package.