{"action":"created","issue":{"url":"https://api.github.com/repos/nodejs/node-addon-api/issues/252","repository_url":"https://api.github.com/repos/nodejs/node-addon-api","labels_url":"https://api.github.com/repos/nodejs/node-addon-api/issues/252/labels{/name}","comments_url":"https://api.github.com/repos/nodejs/node-addon-api/issues/252/comments","events_url":"https://api.github.com/repos/nodejs/node-addon-api/issues/252/events","html_url":"https://github.com/nodejs/node-addon-api/pull/252","id":318913912,"node_id":"MDExOlB1bGxSZXF1ZXN0MTg0OTczODYy","number":252,"title":"Implement AsyncContext class","user":{"login":"romandev","id":1106770,"node_id":"MDQ6VXNlcjExMDY3NzA=","avatar_url":"https://avatars0.githubusercontent.com/u/1106770?v=4","gravatar_id":"","url":"https://api.github.com/users/romandev","html_url":"https://github.com/romandev","followers_url":"https://api.github.com/users/romandev/followers","following_url":"https://api.github.com/users/romandev/following{/other_user}","gists_url":"https://api.github.com/users/romandev/gists{/gist_id}","starred_url":"https://api.github.com/users/romandev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/romandev/subscriptions","organizations_url":"https://api.github.com/users/romandev/orgs","repos_url":"https://api.github.com/users/romandev/repos","events_url":"https://api.github.com/users/romandev/events{/privacy}","received_events_url":"https://api.github.com/users/romandev/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2018-04-30T14:38:19Z","updated_at":"2018-09-18T17:51:50Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/nodejs/node-addon-api/pulls/252","html_url":"https://github.com/nodejs/node-addon-api/pull/252","diff_url":"https://github.com/nodejs/node-addon-api/pull/252.diff","patch_url":"https://github.com/nodejs/node-addon-api/pull/252.patch"},"body":"This class provides a wrapper for the following custom asynchronous\r\noperation APIs.\r\n  - napi_async_init()\r\n  - napi_async_destroy()\r\n  - napi_make_callback()\r\n\r\nThis PR is initiated from https://github.com/nodejs/node-addon-api/pull/140#issuecomment-330685533."},"comment":{"url":"https://api.github.com/repos/nodejs/node-addon-api/issues/comments/422487350","html_url":"https://github.com/nodejs/node-addon-api/pull/252#issuecomment-422487350","issue_url":"https://api.github.com/repos/nodejs/node-addon-api/issues/252","id":422487350,"node_id":"MDEyOklzc3VlQ29tbWVudDQyMjQ4NzM1MA==","user":{"login":"mhdawson","id":9373002,"node_id":"MDQ6VXNlcjkzNzMwMDI=","avatar_url":"https://avatars3.githubusercontent.com/u/9373002?v=4","gravatar_id":"","url":"https://api.github.com/users/mhdawson","html_url":"https://github.com/mhdawson","followers_url":"https://api.github.com/users/mhdawson/followers","following_url":"https://api.github.com/users/mhdawson/following{/other_user}","gists_url":"https://api.github.com/users/mhdawson/gists{/gist_id}","starred_url":"https://api.github.com/users/mhdawson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mhdawson/subscriptions","organizations_url":"https://api.github.com/users/mhdawson/orgs","repos_url":"https://api.github.com/users/mhdawson/repos","events_url":"https://api.github.com/users/mhdawson/events{/privacy}","received_events_url":"https://api.github.com/users/mhdawson/received_events","type":"User","site_admin":false},"created_at":"2018-09-18T17:51:50Z","updated_at":"2018-09-18T17:51:50Z","author_association":"MEMBER","body":"@romandev sorry its taken so long to comment.\r\n\r\nA couple of high level comments/questions\r\n\r\n1) It might be better if the class was not used with new/delete, but instead stack allocated and then automatically was cleaned up when existing a {} scope.  I think that is the way that HandleScope works.\r\n\r\n2) I'm not sure including passing a callback and including the MakeCallback methods makes sense.  I think it would be possible to make 2 callbacks within a since AsyncContext, and if you already have a FunctionReference its just as easy to call MakeCallback on that?"}}
{"actor":{"display_login":"mhdawson"}}