{"action":"created","issue":{"url":"https://api.github.com/repos/h3poteto/fascia/issues/90","repository_url":"https://api.github.com/repos/h3poteto/fascia","labels_url":"https://api.github.com/repos/h3poteto/fascia/issues/90/labels{/name}","comments_url":"https://api.github.com/repos/h3poteto/fascia/issues/90/comments","events_url":"https://api.github.com/repos/h3poteto/fascia/issues/90/events","html_url":"https://github.com/h3poteto/fascia/issues/90","id":142986335,"number":90,"title":"webhookが同時に飛んできた時にエラーを起こさないようにする","user":{"login":"h3poteto","id":4631959,"avatar_url":"https://avatars.githubusercontent.com/u/4631959?v=3","gravatar_id":"","url":"https://api.github.com/users/h3poteto","html_url":"https://github.com/h3poteto","followers_url":"https://api.github.com/users/h3poteto/followers","following_url":"https://api.github.com/users/h3poteto/following{/other_user}","gists_url":"https://api.github.com/users/h3poteto/gists{/gist_id}","starred_url":"https://api.github.com/users/h3poteto/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/h3poteto/subscriptions","organizations_url":"https://api.github.com/users/h3poteto/orgs","repos_url":"https://api.github.com/users/h3poteto/repos","events_url":"https://api.github.com/users/h3poteto/events{/privacy}","received_events_url":"https://api.github.com/users/h3poteto/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/h3poteto/fascia/labels/ToDo","name":"ToDo","color":"f37b1d"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-03-23T15:07:32Z","updated_at":"2016-03-23T15:53:02Z","closed_at":null,"body":"よくよく考えると，エラーになっているということは片方のイベントが実行されていない．\r\nopened -> labeled で，labeledが失敗したら，正しく反映されないので，そもそもエラーになってはいけない．\r\n\r\nシングルスレッド実行にするとか，テーブルロック取るとか，何かしらの対策が必要である．"},"comment":{"url":"https://api.github.com/repos/h3poteto/fascia/issues/comments/200407000","html_url":"https://github.com/h3poteto/fascia/issues/90#issuecomment-200407000","issue_url":"https://api.github.com/repos/h3poteto/fascia/issues/90","id":200407000,"user":{"login":"h3poteto","id":4631959,"avatar_url":"https://avatars.githubusercontent.com/u/4631959?v=3","gravatar_id":"","url":"https://api.github.com/users/h3poteto","html_url":"https://github.com/h3poteto","followers_url":"https://api.github.com/users/h3poteto/followers","following_url":"https://api.github.com/users/h3poteto/following{/other_user}","gists_url":"https://api.github.com/users/h3poteto/gists{/gist_id}","starred_url":"https://api.github.com/users/h3poteto/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/h3poteto/subscriptions","organizations_url":"https://api.github.com/users/h3poteto/orgs","repos_url":"https://api.github.com/users/h3poteto/repos","events_url":"https://api.github.com/users/h3poteto/events{/privacy}","received_events_url":"https://api.github.com/users/h3poteto/received_events","type":"User","site_admin":false},"created_at":"2016-03-23T15:53:02Z","updated_at":"2016-03-23T15:53:02Z","body":"- openのときに存在していたら更新\r\n- labeledのときに存在していたら作成\r\n\r\nというこの2つをやめて，エラーにすればいいのではないか？\r\n正常な順序でリクエストが飛んだ場合には，エラーにならないと思うんだが．\r\nもちろんイベントは正しく反映されないが，それはそれでリトライの機構を考えればいいだけの話．\r\n"}}