{"action":"created","issue":{"url":"https://api.github.com/repos/tailhook/rotor/issues/11","repository_url":"https://api.github.com/repos/tailhook/rotor","labels_url":"https://api.github.com/repos/tailhook/rotor/issues/11/labels{/name}","comments_url":"https://api.github.com/repos/tailhook/rotor/issues/11/comments","events_url":"https://api.github.com/repos/tailhook/rotor/issues/11/events","html_url":"https://github.com/tailhook/rotor/issues/11","id":132786801,"number":11,"title":"Default Machine::spawned implementation","user":{"login":"seanmonstar","id":51479,"avatar_url":"https://avatars.githubusercontent.com/u/51479?v=3","gravatar_id":"","url":"https://api.github.com/users/seanmonstar","html_url":"https://github.com/seanmonstar","followers_url":"https://api.github.com/users/seanmonstar/followers","following_url":"https://api.github.com/users/seanmonstar/following{/other_user}","gists_url":"https://api.github.com/users/seanmonstar/gists{/gist_id}","starred_url":"https://api.github.com/users/seanmonstar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seanmonstar/subscriptions","organizations_url":"https://api.github.com/users/seanmonstar/orgs","repos_url":"https://api.github.com/users/seanmonstar/repos","events_url":"https://api.github.com/users/seanmonstar/events{/privacy}","received_events_url":"https://api.github.com/users/seanmonstar/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-02-10T18:53:58Z","updated_at":"2016-02-10T21:48:52Z","closed_at":"2016-02-10T21:48:52Z","body":"Each time I've implemented Machine, I've used the exact same function body for the `spawned` method. Perhaps a default implementation could be provided?\r\n\r\n```rust\r\nfn spawned(self, scope: &mut Scope<Self::Context>) -> Response<Self, Self::Seed> {\r\n    Response::ok(self)\r\n}\r\n```\r\n\r\n----\r\n\r\nSlightly related, but perhaps more controversial: Maybe Machine could provide default stubs for other less important methods also, like `mio::Handler` does. Such as `timeout` and `wakeup` defaulting to just return `ok(self)`."},"comment":{"url":"https://api.github.com/repos/tailhook/rotor/issues/comments/182596235","html_url":"https://github.com/tailhook/rotor/issues/11#issuecomment-182596235","issue_url":"https://api.github.com/repos/tailhook/rotor/issues/11","id":182596235,"user":{"login":"seanmonstar","id":51479,"avatar_url":"https://avatars.githubusercontent.com/u/51479?v=3","gravatar_id":"","url":"https://api.github.com/users/seanmonstar","html_url":"https://github.com/seanmonstar","followers_url":"https://api.github.com/users/seanmonstar/followers","following_url":"https://api.github.com/users/seanmonstar/following{/other_user}","gists_url":"https://api.github.com/users/seanmonstar/gists{/gist_id}","starred_url":"https://api.github.com/users/seanmonstar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seanmonstar/subscriptions","organizations_url":"https://api.github.com/users/seanmonstar/orgs","repos_url":"https://api.github.com/users/seanmonstar/repos","events_url":"https://api.github.com/users/seanmonstar/events{/privacy}","received_events_url":"https://api.github.com/users/seanmonstar/received_events","type":"User","site_admin":false},"created_at":"2016-02-10T21:48:52Z","updated_at":"2016-02-10T21:48:52Z","body":"Yes, that makes sense. I agree, I don't expose `Machine` to a user, but instead a `server::Handler` that is ignorant of the internals."}}