Commit Graph

259 Commits

Author SHA1 Message Date
Lantao Liu
41e74494b3 Continue watching other directories when there is watch error. 2016-07-18 16:49:47 -07:00
Matt Wringe
6ef612f21e Update collectors to be able to directly access containers by their ip address. 2016-07-14 10:36:53 -04:00
Tim St. Clair
35f7bc5ee7 Move mocks to testing package to remove +build tags
Some go tools (e.g. godef, gorename) don't handle +build tags well, so
I refactored some packages to remove the test tags from cAdvisor.
2016-07-06 14:15:43 -07:00
Ron Lai
29ffb3b6b9 Adding inode info 2016-06-27 11:52:40 -07:00
Tim St. Clair
f02ec8a967 Downgrade failure to rgeister runtime factory to warning
It is not an error to fail to register the Docker factory on a system
running only rkt, and vice-versa, so these failures are downgraded from
an Error to a Warning. The raw handler should always be registered.
2016-06-21 13:21:13 -07:00
Tim St. Clair
81786ec1d2 Fix nil-interface partialFailure bug 2016-05-19 16:16:58 -07:00
Thomas Orozco
2e1f0e2a08 Use a dedicated CpuLoadReader per container
This ensures each goroutine is given its own Netlink connection, and
presumably avoids having a message destined for one goroutine read by
another goroutine.
2016-05-18 09:34:13 +02:00
Vish Kannan
05809d5936 Merge pull request #1286 from timstclair/subcontainers2
Make manager multi-container functions robust to partial failures
2016-05-17 13:22:17 -07:00
Shaya Potter
6fa3687720 Polling rkt implementation of new watcher inteface (#1284)
polling rkt implementation of new watcher inteface
2016-05-17 10:34:56 -07:00
Tim St. Clair
39fe454f32 Make manager multi-container functions robust to partial failures 2016-05-16 13:25:33 -07:00
Shaya Potter
e02632463b Refactor container watching out of raw handler into its own inteface / package 2016-05-11 20:27:10 -07:00
Yu-Ju Hong
f695b7cfc8 Print the event when failed to process it 2016-05-02 17:47:41 -07:00
Tim St. Clair
4d3ef349fb Move utils/machine -> machine 2016-05-02 15:56:49 -07:00
Tim St. Clair
f365c6a115 Move docker types to v1 API 2016-05-02 15:52:29 -07:00
Tim St. Clair
9961e37168 Delete unused ManagerMock 2016-05-02 12:24:33 -07:00
Tim St. Clair
0c89fd1b71 Refactor docker-specific functions from manager to docker 2016-05-02 12:24:31 -07:00
Tim St. Clair
b983d32d96 Refactor manager/machine.go -> utils/machine/info.go 2016-05-02 11:54:10 -07:00
Lantao Liu
ece4c555cc switch to the new engine-api 2016-04-25 19:22:05 -07:00
derekwaynecarr
d01934a3e4 on systemd, we should ignore .mount cgroups 2016-04-20 23:47:19 -04:00
Tim St. Clair
b553e02476 Fix cAdivsor docker validation 2016-04-08 17:05:26 -07:00
Tim St. Clair
d9c864324b Fix usage of the latest go-dockerclient 2016-04-04 18:01:47 -07:00
Shaya Potter
206670a655 first cut of rkt handler 2016-03-21 17:34:42 -07:00
Seth Jennings
8aa6164192 allow ignoreMetrics in new manager 2016-03-14 17:16:56 -05:00
Vish Kannan
06ac85ca29 Merge pull request #1121 from vishh/opt-out-metrics
Support opt out for metrics.
2016-02-25 16:25:02 -08:00
Vishnu kannan
03f19d3576 Add nil pointer checks in disk usage integration test.
Signed-off-by: Vishnu kannan <vishnuk@google.com>
2016-02-25 15:38:15 -08:00
Vishnu kannan
2defa0bddb Adding support for inodes.
Signed-off-by: Vishnu kannan <vishnuk@google.com>
2016-02-25 15:13:58 -08:00
Vishnu kannan
36415f465a Support opt out for metrics.
Signed-off-by: Vishnu kannan <vishnuk@google.com>
2016-02-24 15:57:31 -08:00
Vish Kannan
eab201fdf5 Merge pull request #1109 from enoodle/cloudinfo_add_aws_and_instance_id
cloudinfo: Adding AWS, Azure support and InstanceID
2016-02-24 13:15:28 -08:00
Erez Freiberger
885649a9b6 cloudinfo: Adding AWS support and InstanceID 2016-02-18 15:28:20 +02:00
Vish Kannan
e9739af184 Merge pull request #1110 from timstclair/httptest
Stop leaking testing dependencies (and flags) in non-testing builds
2016-02-12 14:43:45 -08:00
Tim St. Clair
0bc286dc93 Stop leaking testing dependencies (and flags) in non-testing builds 2016-02-11 13:18:02 -08:00
Marcin Wielgus
fb8efe0cf6 Add a flag to control the number of custom metrics scraped by collectors 2016-02-11 01:33:58 +01:00
Vishnu kannan
ae38e6f460 Update docker dependency.
Signed-off-by: Vishnu kannan <vishnuk@google.com>
2016-01-21 14:57:18 -08:00
Vish Kannan
d80cb88dc0 Merge pull request #1057 from timothysc/housekeeping_jitter
Add jitter to housekeeping interval
2016-01-19 11:04:53 -08:00
Timothy St. Clair
3256647668 Add jitter to housekeeping interval 2016-01-16 08:17:46 -06:00
Vishnu Kannan
944201c86b Refactor api conversion methods. 2016-01-15 15:40:15 -08:00
Jimmi Dyson
4e9d29a408 Fix FS usage goroutine leaks 2016-01-14 19:30:48 +00:00
Tim St. Clair
e011781a88 Add V2 ContainerInfo API
- Add V2 ContainerInfo struct
- Move v1/v2 conversion functions to a reusable package
- Add V2 ContainerInfo accessor method to Manager
2016-01-13 11:58:09 -08:00
Pavel Tikhomirov
97257ccf61 v2: Fix cgroupPathRegExp to match path after first colon after devices
If in getCgroupPath in cgroups we have some other hierarchies after
"devices" using ".*" sometimes will cause matching wrong string as
a container path so we need negated character class here: "[^:]*".

e.g.
If cgroups string is
"153:name=systemd:/system.slice/docker-f55e7cad1fcc02f992e0c33c210ecdc6d641858a665f28370523c27c05bdde0e.scope,4:freezer,devices,name=container:/system.slice/docker-f55e7cad1fcc02f992e0c33c210ecdc6d641858a665f28370523c27c05bdde0e.scope,3:cpuacct,cpu,cpuset,name=fairsched:/system.slice/docker-f55e7cad1fcc02f992e0c33c210ecdc6d641858a665f28370523c27c05bdde0e.scope,2:memory:/system.slice/docker-f55e7cad1fcc02f992e0c33c210ecdc6d641858a665f28370523c27c05bdde0e.scope,1:blkio,name=beancounter:/system.slice/docker-f55e7cad1fcc02f992e0c33c210ecdc6d641858a665f28370523c27c05bdde0e.scope"

match[1] will be "blkio" but not:
/system.slice/docker-f55e7cad1fcc02f992e0c33c210ecdc6d641858a665f28370523c27c05bdde0e.scope

These fixes the commit:
4cbd91c761 Make getCgroupPath work in case of named or multi- hierarchies

v2: use negated character class, correct the example, remove .* on
either end as they don't do anything in FindSubmatch.
2015-12-14 10:33:26 +03:00
Vishnu kannan
a6daa760c8 Fix goroutine leak in docker fs handler logic.
Signed-off-by: Vishnu kannan <vishnuk@google.com>
2015-12-04 11:19:49 -08:00
Jimmi Dyson
1d6e0ec9bc Merge pull request #1002 from timstclair/loaddecay
Fix usage of housekeeping_interval flag
2015-12-04 12:55:11 +00:00
Tim St. Clair
33216870d8 Fix usage of housekeeping_interval flag
Defer calculation of `loadDecay`. Flags must be parsed before they can
be read, and therefore cannot be reliably be read at package init time.
2015-12-03 18:39:11 -08:00
Jimmi Dyson
40f908db04 Fix machine ID file path when running in container
Fixes #955
2015-12-02 08:51:48 +00:00
Lei Xue
dbbe38dfed re-order the import package 2015-11-30 16:43:22 +08:00
Jimmi Dyson
1f679cee70 Clean up unused struct fields (via structcheck linter) 2015-11-27 22:06:16 +00:00
Jimmi Dyson
b9ff5c098c Fix up ignored/inefficient assigns (via ineffassign linter) 2015-11-27 22:01:54 +00:00
Jimmi Dyson
f9eb56e800 Merge pull request #966 from afein/godep_update_runc
[Godeps] changed docker/libcontainer dependency to runc/libcontainer
2015-11-26 15:19:28 +00:00
Jimmi Dyson
d1fce20304 Regexp tidy up 2015-11-26 09:14:26 +00:00
Alex Mavrogiannis
4533dd7d18 changed libcontainer dependency to runc 2015-11-21 14:04:01 -08:00
Jimmi Dyson
68db03188f Don't bail out if docker is unreachable - recover when back up 2015-10-23 12:58:44 +01:00