Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Log and status history pruner workers react to pruning config changes #7251
Conversation
| + maxLogAge = newMaxAge | ||
| + maxCollectionMB = newMaxCollectionMB | ||
| + } | ||
| + continue |
babbageclunk
Apr 19, 2017
Member
This seems a bit redundant, although I guess it does guard against someone adding code after the select.
wallyworld
Apr 19, 2017
Owner
it also forces the check for a new update prior to doing the pruning in case one comes in at the same time
| @@ -54,8 +87,8 @@ func (s *suite) StartWorker(c *gc.C, maxLogAge time.Duration, maxCollectionMB in | ||
| func (s *suite) TestPrunesOldLogs(c *gc.C) { | ||
| maxLogAge := 24 * time.Hour | ||
| - noPruneMB := int(1e9) | ||
| - s.StartWorker(c, maxLogAge, noPruneMB) | ||
| + s.setupState(c, "24h", "1000P") |
axw
Apr 19, 2017
Member
It actually goes up to yottabytes. You never know how much status history you'll need ;)
|
$$merge$$ |
|
Status: merge request accepted. Url: http://juju-ci.vapour.ws:8080/job/github-merge-juju |
|
Build failed: Tests failed |
|
$$merge$$ |
|
Status: merge request accepted. Url: http://juju-ci.vapour.ws:8080/job/github-merge-juju |
jujubot
merged commit 3b1eb58
into
juju:develop
Apr 19, 2017
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
wallyworld commentedApr 19, 2017
Description of change
This PR follows up on the work to allow the log pruner and status history pruner workers to be configured with respect to max record age and size of history collections. It adds the ability for the pruning parameters to be changed and the workers pick up the new parameters.
The log pruning parameters are controller settings and currently we don't support changing those. However, a watcher is added for when such changes are possible.
For the status history pruning parameters, these are changed via the juju model-config CLI.
QA steps
configure small values for log pruning in clouds.yaml
bootstrap, check debug-log to see that expected pruning values are picked up
deploy a unit
run juju model-config to set small values for status history pruning
check that history pruning occurs via juju show-status-log
check that log pruning occurs using juju debug-log
Bug reference
http://pad.lv/1681352