Commit Graph
5838 Commits
Author SHA1 Message Date
Peter Bourgon c7a06d2a43 Don't flat-embed sampling in the report
In the JSON representation, we want the Sampling data to be distinct.
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 8fdbc44680 Merge pull request #339 from weaveworks/fix-render-map-bug
Fix a subtle bug in render mapping
2015-08-03 10:53:37 +02:00
Peter Bourgon b3868c58d7 Fix a subtle bug in render mapping
During rendering, RenderableNodes are created by Map funcs, which take only
NodeMetadata. Previously, it was simply assumed that the relevant keys for a
given Map func would be present in the metadata. If that implicit invariant
failed, the returned RenderableNode would be invalid, with e.g. an ID of
"hostid::". That, in turn, would trigger undefined behavior later on in the
rendering workflow.

This bug was detected by creating a partial node metadata for a non-local
endpoint node. That node was detected during the first phase of rendering, and
given an invalid renderable node ID of "myhostname::", which prevented it from
attaching to TheInternet pseudonode. It eventually got removed from the  set
of valid nodes, which meant nodes that were adjacent to it suddenly became
orphans, and got filtered out by the FilterUnconnected step of the rendering
pipeline.

With this change, every map func checks for the presence of mandatory fields,
i.e. the fields that compose the resulting renderable node's ID.

Also,

- Add unit tests for LeafMapFuncs
- Topology Validate checks NodeMetadatas must not have nil Metadata
2015-08-03 10:43:07 +02:00
Peter Bourgon ed337dc9aa Merge pull request #335 from weaveworks/fix-new-node-metadata
Fix new node metadata
2015-07-31 14:53:06 +02:00
Paul Bellamy 625a08bd21 forgot to remove reference to gce-parameterize branch of weave 2015-07-31 11:46:50 +01:00
Paul Bellamy e5806f5318 Merge pull request #338 from weaveworks/334-fix-integration-tests
Fixing the build
2015-07-31 10:53:59 +01:00
Paul Bellamy 8aede5aaf9 Fixing the build
* override the weave template and hosts count for gce
* weave gce script wants jq as well now
* build the new weave go test runner
2015-07-31 10:31:07 +01:00
Peter Bourgon 3dd59c8b9b Fixes to NodeMetadata
NewNodeMetadata -> MakeNodeMetadata. It doesn't return a pointer, so
Make is more idiomatic.

Invoke MakeNodeMetadata when necessary. The zero value for a
NodeMetadata is no longer valid.

Split MakeNodeMetadata to two constructors. MakeNodeMetadata when you
don't have anything to prepopulate; MakeNodeMetadataWith when you do.

Also, a fix to the tests in app. We unmarshal a RenderableNode struct,
which has a JSON-ignored NodeMetadata field. The zero value is invalid,
so we need to fix that before performing comparisons.
2015-07-30 17:20:44 +02:00
Peter Bourgon 70ffde9de3 Merge pull request #333 from weaveworks/consistent-variable-naming
Fix some variable names
2015-07-30 17:04:46 +02:00
Peter Bourgon 2a22cc29c2 Merge pull request #332 from weaveworks/dont-panic-on-darwin
Don't panic tests on Darwin.
2015-07-30 16:40:59 +02:00
Peter Bourgon fc308d93b8 Normalize var names; use Addr/Port key constants 2015-07-30 16:36:27 +02:00
Tom Wilkie 85b6d16ee7 Add rebuild-image from scope.git 2015-07-30 14:08:13 +00:00
Tom Wilkie 704f5bd4e4 Automatically run tests with coverage etc on Circle. 2015-07-30 13:21:36 +00:00
Tom Wilkie 76de35ea97 Test script checks for scheduler. 2015-07-30 13:16:49 +00:00
Peter Bourgon 70f8c62415 Don't panic tests on Darwin.
Use the proper DialStub in the container setup.

Also, one change to increase test coverage.
2015-07-30 15:16:26 +02:00
Tom Wilkie 4f611e832c Add test script from weave 2015-07-30 13:12:48 +00:00
Tom Wilkie 696d3fae4b Add coverage merge tool from weave.git 2015-07-30 13:10:48 +00:00
Tom Wilkie fb308bdee3 Add lint script from scope.yml 2015-07-30 13:00:33 +00:00
Peter Bourgon a565acc871 Unbreak the build 2015-07-22 14:26:09 +01:00
Tom Wilkie 05c3b87aba Build scope and weave master for demos. 2015-07-22 12:20:25 +00:00
Peter Bourgon 6f414ac89c Process rank by comm (app name) 2015-07-22 10:51:58 +01:00
Peter Bourgon fb7eed103e Merge pull request #320 from weaveworks/process-names-on-darwin
Naïve process walker for Darwin
2015-07-20 16:37:25 +01:00
Tom Wilkie 69265d2801 Merge pull request #327 from weaveworks/319-integration-test-sans-weave
add integration test for launching scope without weave installed
2015-07-20 16:02:25 +01:00
Paul Bellamy 799e5b2ace add integration test for launching scope without weave installed 2015-07-20 15:53:08 +01:00
Tom Wilkie 275aec4a95 Merge pull request #325 from weaveworks/321-dns-detection
Detect WeaveDNS by an open port 53 on the docker bridge && the presence of the weave script.
2015-07-20 15:04:49 +01:00
Tom Wilkie 843ac4e8ee Detech WeaveDNS by an open port 53 on the docker bridge && the presence of the weave script. 2015-07-20 13:56:23 +00:00
Tom Wilkie ad1ffa87d3 Update circle.yml for changes in weave.git 2015-07-20 13:50:52 +00:00
Tom Wilkie 4305b917a7 Script to spin up a demo scope cluster. 2015-07-20 13:38:47 +00:00
David 7b1b8731f1 Merge pull request #316 from weaveworks/297-close-details
Close details when changing topologies
2015-07-20 11:10:28 +01:00
Tom Wilkie 9a314b1e3f Merge pull request #318 from weaveworks/315-nodemetadata-struct
Make NodeMetadata a struct, move existing map[string]string to NodeMetadata.Metadata
2015-07-17 17:25:24 +01:00
David Kaltschmidt 988e2e05d7 Renamed app to scope-app in release script 2015-07-16 16:38:43 +02:00
David Kaltschmidt c695c79045 Changelog for 0.5.0 v0.5.0 2015-07-16 15:54:49 +02:00
Tom Wilkie f85195308c report.Metadata -> map[string]string 2015-07-16 12:06:05 +00:00
Peter Bourgon b585a362ac Naïve process walker for Darwin
This fixes the regression where process names weren't appearing for
Darwin probes. Makes testing easier.

Also, changes the process walker to operate on value types. There's no
performance advantage to using reference types for something of this
size, and there appeared to be a data race in the Darwin port that
caused nodes to gain and lose process names over time.

Also, restructures how to enable docker scraping. Default false when run
manually, and enabled via --probe.docker true in the scope script.
2015-07-16 12:33:59 +02:00
Peter Bourgon c8079daf26 Improve scope script <--> weave interaction
- Use command_exists function from weave script
- Collapse boolean checks for DNS registration
2015-07-15 12:10:50 +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
Peter Bourgon 53e70b02f4 Don't fast-fail if weave isn't present 2015-07-15 11:57:48 +02:00
David Kaltschmidt dfd158cceb close details when changing topologies
fixes #297
2015-07-14 16:16:09 +02:00
Peter Bourgon c9e74f754d Merge pull request #314 from weaveworks/fix-circle-without-cache
Don't fail if CACHE_DIR has a missing component
2015-07-13 16:39:50 +02:00
Peter Bourgon ac29fba7bc Don't fail if CACHE_DIR has a missing component
Also, don't invoke weave if it's not running.
2015-07-13 16:03:19 +02:00
Peter Bourgon dd59810196 Merge pull request #302 from weaveworks/scope-on-weave
weave expose prior to scope launch
2015-07-13 13:23:12 +02:00
Peter Bourgon c57a04e1dd Use weave add-dns instead of HTTP calls to DNS container 2015-07-13 12:47:21 +02:00
Tom Wilkie ddb29626f2 Merge pull request #310 from weaveworks/259-rebuild-ui-image
Detect when to rebuild cached build image.
2015-07-08 16:52:57 +01:00
Tom Wilkie cf261282e2 Detect when to rebuild cached build image. 2015-07-08 15:43:48 +00:00
Tom Wilkie c35269e01c Merge pull request #312 from weaveworks/311-flaky
Use poll in TestRegistryEvents.
2015-07-08 16:41:59 +01:00
Tom Wilkie 9fc02d941e Fix flaky tests
- Make poll take interfaces, do diff on error
- Use poll in TestRegistryEvents
- Improve the locking to prevent deadlocks and data races in registry_test.go
2015-07-08 13:54:09 +00:00
Tom Wilkie bed9c9325b Merge pull request #313 from weaveworks/266-smarter-merge-take2
Neater implementation of de-duplication in MakeIDList()
2015-07-08 13:50:13 +01:00
Bryan Boreham 1fa853befe Neater implementation of de-duplication in MakeIDList() 2015-07-08 13:38:39 +01:00
Tom Wilkie 0f76661bf6 Merge pull request #309 from weaveworks/266-smarter-merge
Reduce garbage generation with smarter IDList merge
2015-07-08 13:07:12 +01:00