54 Commits

Author SHA1 Message Date
Paul Bellamy
8f63d7be7f Metrics plumbing for reports.
- base load graph x-axis on data, not a hardcoded window
- format memory dynamically to scale
- add some tests for the immutability of metrics
- use ps.List for Sample storage, so it is immutable. Have to implement custom marshalling
- adding tests for report.Metrics
- check the ordering of the json samples
- Make the nil value for Metrics valid.
- Sort samples from oldest to newest on the wire.
2015-11-11 17:16:13 +00:00
Tom Wilkie
8dbc586866 Merge pull request #628 from weaveworks/latest-map
Add 'latest' CRDT, make UI update quicker.
2015-11-09 16:10:28 +00:00
Alvaro
4f21919858 Merge pull request #639 from weaveworks/scope-504-2
Resolve to a group of names
2015-11-09 15:29:28 +01:00
Alvaro Saurin
82d9e35da6 Use the "name" set for the connection details 2015-11-09 13:45:02 +01:00
Tom Wilkie
43d0ce986f Add 'latest' CRDT; use it to store container state.
Also use same technique to merge the controls, returning the latest
set of controls instead of the union.
2015-11-06 18:26:38 +00:00
Tom Wilkie
8f957c4f13 Add docker lifecycle controls, containers in states other that running, and a filter for those containers.
Also add integration test for container controls.
2015-11-06 17:39:54 +00:00
Tom Wilkie
76d34330a9 Add Control plumbing. 2015-11-06 17:39:48 +00:00
Alfonso Acosta
ebefa5e8f0 Use label "com.amazonaws.ecs.container-name" to render container names 2015-09-07 20:52:13 +00:00
Tom Wilkie
303e11be6a Don't send numeric=true for connections table. 2015-09-07 13:06:13 +00:00
Alvaro Saurin
15e25edc40 New asynchronous, caching DNS resolver for reverse resolutions
Add nodes for the remote side of connections iff we have a DNS reverse resolution for the IP.
Unit test for the resolver
2015-09-04 17:21:45 +02:00
Tom Wilkie
57f7b4f2e6 Rename NodeMetadata -> Node 2015-09-03 16:18:54 +00:00
Tom Wilkie
1f6b3d4a45 Move Adjacency info inside the NodeMetadata struct; move pseudo node generation to the probes. 2015-08-28 15:20:27 +00:00
Peter Bourgon
44e6fd2adb Merge pull request #399 from weaveworks/topology-copy
Moar functional: Topology Merge methods don't mutate the receiver
2015-08-27 17:05:12 +02:00
Alfonso Acosta
9ba37402cf Report/render both image and container labels
Daemon labels will have to wait since the go client (Docker API v1.14) doesn't support
them yet (daemon labels were exposed in Docker API v1.16)

See https://godoc.org/github.com/fsouza/go-dockerclient#Client.Info for details.
2015-08-27 09:45:30 +00:00
Alfonso Acosta
529aa3d84f Use a metadata key per docker label 2015-08-26 15:49:13 +00:00
Alfonso Acosta
e1c05012ca Report docker container labels and render them in the details pane 2015-08-26 13:38:53 +00:00
Tom Wilkie
1ad1197051 Review feedback 2015-08-26 13:00:33 +00:00
Peter Bourgon
775f0ede90 render: fixes for new merge semantics 2015-08-26 12:02:11 +01:00
Tom Wilkie
d8ac16d3f3 Gather container IP addresses from Docker and Weave, and apply them to nodes in the container topology. 2015-08-26 10:19:08 +00:00
Tom Wilkie
e9fad6136f Tag containers with WeaveDNS hostnames. 2015-08-25 16:41:56 +00:00
Alfonso Acosta
11e5135d19 Address PR comment 2015-08-25 10:31:13 +00:00
Alfonso Acosta
d1126f911b Desambiguate Container associated to processes in details pane 2015-08-24 21:13:27 +00:00
Alfonso Acosta
117b0e190b Address PR comment 2015-08-24 18:51:12 +00:00
Alfonso Acosta
807b30bfe3 Figure out whether to show host tags in details pane from context 2015-08-24 18:40:24 +00:00
Alfonso Acosta
75595a5519 Add useful information to table titles in details pane
Title modifications:
* "Origin Process" -> "Process \"name\" (pid)"
* "Origin Container" -> "Container \"name\" (pid)"
* "Origin Host" -> "Host \"name\""
* "Origin Container Image" -> "Container Image \"name\""
2015-08-21 16:37:12 +00:00
Alfonso Acosta
a01a7069b6 Make tables and addContainerTable consistent with the rest of the code 2015-08-21 15:30:56 +00:00
Alfonso Acosta
10199737e4 Add host context in the details pane
In situations when the details can refer to entities from multiple hosts
(e.g. container image) make explicit to what host we are referring to.
2015-08-21 15:19:30 +00:00
Alfonso Acosta
37307c26b9 Merge 'Connections' and 'Connection Details' in node details pane
* Now the Connections table appears at the end of the pane

* Connection details are expandable (still not implemented in the UI but backwards
compatible).
2015-08-21 10:11:39 +00:00
Alfonso Acosta
c78f9d812c Add Expandable attribute to detailed-pane rows 2015-08-20 15:26:23 +00:00
Tom Wilkie
6f1f453098 Review feedback 2015-08-19 12:22:28 +00:00
Tom Wilkie
7fb1a98eca Update detail node logic to deal with connection directionality; also correctly merge edge metadata for pseudo nodes. 2015-08-19 10:21:01 +00:00
Tom Wilkie
0cc3dd0eea Merge pull request #367 from weaveworks/323-origin-address
Condense origin address entries into a single table.
2015-08-19 11:16:00 +01:00
Tom Wilkie
75369acb42 Review feedback 2015-08-19 10:06:57 +00:00
Peter Bourgon
a1b0088bf3 Remove (comm) from Name field in detail pane 2015-08-19 11:07:31 +02:00
Tom Wilkie
89831bfdd2 Condense origin address entries into a single table. 2015-08-18 11:23:45 +00:00
Peter Bourgon
0dafad763f Calculate rates in detailed nodes 2015-08-03 16:04:06 +02:00
Peter Bourgon
e1f7752a34 Split PacketCount to Egress and Ingress
Also, 1 packet may be counted in N topologies, so you can't rely on the
sum of all packet counts across topologies having any relation to the
sampling data.
2015-08-03 14:58:41 +02:00
Peter Bourgon
0aadf6447b Revert to correct edge construction
Another implicit invariant in the data model is that edges are always of the
form (local -> remote). That is, the source of an edge must always be a node
that originates from within Scope's domain of visibility. This was evident by
the presence of ingress and egress fields in edge/aggregate metadata.

When building the sniffer, I accidentally and incorrectly violated this
invariant, by constructing distinct edges for (local -> remote) and (remote ->
local), and collapsing ingress and egress byte counts to a single scalar. I
experienced a variety of subtle undefined behavior as a result. See #339.

This change reverts to the old, correct methodology. Consequently the sniffer
needs to be able to find out which side of the sniffed packet is local v.
remote, and to do that it needs access to local networks. I moved the
discovery from the probe/host package into probe/main.go.

As part of that work I discovered that package report also maintains its own,
independent "cache" of local networks. Except it contains only the (optional)
Docker bridge network, if it's been populated by the probe, and it's only used
by the report.Make{Endpoint,Address}NodeID constructors to scope local
addresses. Normally, scoping happens during rendering, and only for pseudo
nodes -- see current LeafMap Render localNetworks. This is pretty convoluted
and should be either be made consistent or heavily commented.
2015-08-03 10:55:59 +02:00
Peter Bourgon
b9afa67ad6 gopacket-based traffic sniffing 2015-08-03 10:55:59 +02:00
Peter Bourgon
fc308d93b8 Normalize var names; use Addr/Port key constants 2015-07-30 16:36:27 +02:00
Tom Wilkie
c2065836e2 Make NodeMetadata a struct, move existing map[string]string to NodeMetadata.Metadata 2015-07-15 10:06:36 +00:00
Paul Bellamy
95f941ff2d const-izing NodeMetadata fields 2015-07-02 14:51:12 +01:00
Paul Bellamy
129e529a0e removing duplication checking, which is no longer needed due to connection aggregation 2015-07-02 14:21:16 +01:00
Paul Bellamy
cd71f82d4d aggregate connection details table
List Local and Remote endpoints for each TCP connection on the node.
2015-07-02 14:21:16 +01:00
Tom Wilkie
93cf639418 Fix order of tables in details panel to go from most to least granular. 2015-06-23 15:09:20 +00:00
Tom Wilkie
626320d7f4 Move probe host topology code into its own module
- add tests
- use constants for NodeMetadata keys
- add host uptime and kernel version
2015-06-23 13:31:22 +00:00
Tom Wilkie
560cf66454 Refactor PIDTree
- Move pidtree to its own module and disaggregate it into tree, walker and reporter.
- Extend testing for probe/process
- Extend process metadata; add command line & # threads.
2015-06-23 09:40:35 +00:00
Tom Wilkie
c793e86d5b Expose some more information on containers. 2015-06-19 13:02:07 +00:00
Tom Wilkie
49dae07cca Make render module produce The Internet pseudo node. 2015-06-19 11:09:52 +00:00
Tom Wilkie
25ca0c0eb7 Add ContainerImage topology and use it to build the Container By Image graph.
This makes container image details show the containers (and processes) correctly.

Also:
- introduces a 'test' package, moved Diff function there.
- adds some tests for this new rendered view.
2015-06-18 09:16:20 +00:00