{"action":"created","issue":{"url":"https://api.github.com/repos/apple/swift-nio/issues/515","repository_url":"https://api.github.com/repos/apple/swift-nio","labels_url":"https://api.github.com/repos/apple/swift-nio/issues/515/labels{/name}","comments_url":"https://api.github.com/repos/apple/swift-nio/issues/515/comments","events_url":"https://api.github.com/repos/apple/swift-nio/issues/515/events","html_url":"https://github.com/apple/swift-nio/pull/515","id":341220319,"node_id":"MDExOlB1bGxSZXF1ZXN0MjAxNDQyNDQ2","number":515,"title":"Pass RepeatedTask to its closure #514","user":{"login":"FranzBusch","id":3491887,"node_id":"MDQ6VXNlcjM0OTE4ODc=","avatar_url":"https://avatars3.githubusercontent.com/u/3491887?v=4","gravatar_id":"","url":"https://api.github.com/users/FranzBusch","html_url":"https://github.com/FranzBusch","followers_url":"https://api.github.com/users/FranzBusch/followers","following_url":"https://api.github.com/users/FranzBusch/following{/other_user}","gists_url":"https://api.github.com/users/FranzBusch/gists{/gist_id}","starred_url":"https://api.github.com/users/FranzBusch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FranzBusch/subscriptions","organizations_url":"https://api.github.com/users/FranzBusch/orgs","repos_url":"https://api.github.com/users/FranzBusch/repos","events_url":"https://api.github.com/users/FranzBusch/events{/privacy}","received_events_url":"https://api.github.com/users/FranzBusch/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-07-14T08:31:42Z","updated_at":"2018-07-14T08:31:43Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/apple/swift-nio/pulls/515","html_url":"https://github.com/apple/swift-nio/pull/515","diff_url":"https://github.com/apple/swift-nio/pull/515.diff","patch_url":"https://github.com/apple/swift-nio/pull/515.patch"},"body":"Pass the reference to `RepeatedTask` to its closure to allow a thread-safe cancelling.\r\n\r\n### Motivation:\r\n\r\nWith the current implementation, one has to create a reference and use a lock to thread-safely cancel the `RepeatedTask`. This makes the use more difficult and not so straight-forward.\r\n\r\n### Modifications:\r\n\r\nAdded a weak `RepeatedTask?` parameter to the `scheduleRepeatedTask` closure.\r\n\r\n### Result:\r\n\r\nIt is now possible to cancel the `RepeatedTask` from within the task closure.\r\n"},"comment":{"url":"https://api.github.com/repos/apple/swift-nio/issues/comments/405008720","html_url":"https://github.com/apple/swift-nio/pull/515#issuecomment-405008720","issue_url":"https://api.github.com/repos/apple/swift-nio/issues/515","id":405008720,"node_id":"MDEyOklzc3VlQ29tbWVudDQwNTAwODcyMA==","user":{"login":"swift-nio-bot","id":36821322,"node_id":"MDQ6VXNlcjM2ODIxMzIy","avatar_url":"https://avatars1.githubusercontent.com/u/36821322?v=4","gravatar_id":"","url":"https://api.github.com/users/swift-nio-bot","html_url":"https://github.com/swift-nio-bot","followers_url":"https://api.github.com/users/swift-nio-bot/followers","following_url":"https://api.github.com/users/swift-nio-bot/following{/other_user}","gists_url":"https://api.github.com/users/swift-nio-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/swift-nio-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/swift-nio-bot/subscriptions","organizations_url":"https://api.github.com/users/swift-nio-bot/orgs","repos_url":"https://api.github.com/users/swift-nio-bot/repos","events_url":"https://api.github.com/users/swift-nio-bot/events{/privacy}","received_events_url":"https://api.github.com/users/swift-nio-bot/received_events","type":"User","site_admin":false},"created_at":"2018-07-14T08:31:43Z","updated_at":"2018-07-14T08:31:43Z","author_association":"NONE","body":"Can one of the admins verify this patch?"}}
{"actor":{"display_login":"swift-nio-bot"}}