{"action":"created","issue":{"url":"https://api.github.com/repos/juju/juju/issues/7418","repository_url":"https://api.github.com/repos/juju/juju","labels_url":"https://api.github.com/repos/juju/juju/issues/7418/labels{/name}","comments_url":"https://api.github.com/repos/juju/juju/issues/7418/comments","events_url":"https://api.github.com/repos/juju/juju/issues/7418/events","html_url":"https://github.com/juju/juju/pull/7418","id":232430701,"number":7418,"title":"log forwarding: Workers now run per-model","user":{"login":"babbageclunk","id":563399,"avatar_url":"https://avatars1.githubusercontent.com/u/563399?v=3","gravatar_id":"","url":"https://api.github.com/users/babbageclunk","html_url":"https://github.com/babbageclunk","followers_url":"https://api.github.com/users/babbageclunk/followers","following_url":"https://api.github.com/users/babbageclunk/following{/other_user}","gists_url":"https://api.github.com/users/babbageclunk/gists{/gist_id}","starred_url":"https://api.github.com/users/babbageclunk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/babbageclunk/subscriptions","organizations_url":"https://api.github.com/users/babbageclunk/orgs","repos_url":"https://api.github.com/users/babbageclunk/repos","events_url":"https://api.github.com/users/babbageclunk/events{/privacy}","received_events_url":"https://api.github.com/users/babbageclunk/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2017-05-31T01:50:02Z","updated_at":"2017-06-01T03:34:07Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/juju/juju/pulls/7418","html_url":"https://github.com/juju/juju/pull/7418","diff_url":"https://github.com/juju/juju/pull/7418.diff","patch_url":"https://github.com/juju/juju/pull/7418.patch"},"body":"## Description of change\r\n\r\nAt the moment, the most expensive step in destroying a model is clearing out its logs. We want to make this cheaper by having a log collection for each model. But in order to do this we have to make log forwarding happen per-model rather than running for all models at once.\r\n\r\nMove the log forwarder worker creation into the model manifolds, and allow the log streaming endpoint to be called for non-controller models. Remove the all-model capability of the log tailer, and always include the model UUID in the log messages it generates.\r\n\r\n## QA steps\r\n\r\n* Generate a CA cert + key and certs and keys for a server and client. \r\n* Set up an rsyslog server to receive forwarded messages with the server certificate. \r\n  * Refer to [this tutorial](http://www.rsyslog.com/doc/v8-stable/tutorials/tls_cert_summary.html) for information on this. \r\n  * Be sure to match the common names in the certificates to the names you put into the rsyslog config.\r\n  * If you're specifying the IP address of the server, ensure the server certificate has the right IP address as a SubjectAltName - Go TLS support enforces this although OpenSSL doesn't by default.\r\n* Bootstrap a controller and deploy some applications and relations to the default model.\r\n* Configure log forwarding by specifying the following model-config for both controller and default model:\r\n  * `syslog-host`: the IP and port of the rsyslog receiver (10514 if you follow the instructions above).\r\n  * `syslog-ca-cert`\r\n  * `syslog-client-cert`\r\n  * `syslog-client-key`\r\n* Turn forwarding on for only the controller by setting `logforward-enable` to true.\r\n* Check that log messages from the controller appear in the receiver's logs, and that messages from the default model don't.\r\n* Turn off logging for the controller model and enable it for the default model - records from the default model should start coming in and the controller ones should stop.\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/juju/juju/issues/comments/305379974","html_url":"https://github.com/juju/juju/pull/7418#issuecomment-305379974","issue_url":"https://api.github.com/repos/juju/juju/issues/7418","id":305379974,"user":{"login":"jujubot","id":7779494,"avatar_url":"https://avatars3.githubusercontent.com/u/7779494?v=3","gravatar_id":"","url":"https://api.github.com/users/jujubot","html_url":"https://github.com/jujubot","followers_url":"https://api.github.com/users/jujubot/followers","following_url":"https://api.github.com/users/jujubot/following{/other_user}","gists_url":"https://api.github.com/users/jujubot/gists{/gist_id}","starred_url":"https://api.github.com/users/jujubot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jujubot/subscriptions","organizations_url":"https://api.github.com/users/jujubot/orgs","repos_url":"https://api.github.com/users/jujubot/repos","events_url":"https://api.github.com/users/jujubot/events{/privacy}","received_events_url":"https://api.github.com/users/jujubot/received_events","type":"User","site_admin":false},"created_at":"2017-06-01T03:34:07Z","updated_at":"2017-06-01T03:34:07Z","body":"Status: merge request accepted. Url: http://juju-ci.vapour.ws:8080/job/github-merge-juju"}}
{"actor":{"display_login":"jujubot"}}