{"action":"created","issue":{"url":"https://api.github.com/repos/cakephp/cakephp/issues/5972","labels_url":"https://api.github.com/repos/cakephp/cakephp/issues/5972/labels{/name}","comments_url":"https://api.github.com/repos/cakephp/cakephp/issues/5972/comments","events_url":"https://api.github.com/repos/cakephp/cakephp/issues/5972/events","html_url":"https://github.com/cakephp/cakephp/pull/5972","id":59081973,"number":5972,"title":"3.0 afterSaveCommit","user":{"login":"ADmad","id":142658,"avatar_url":"https://avatars.githubusercontent.com/u/142658?v=3","gravatar_id":"","url":"https://api.github.com/users/ADmad","html_url":"https://github.com/ADmad","followers_url":"https://api.github.com/users/ADmad/followers","following_url":"https://api.github.com/users/ADmad/following{/other_user}","gists_url":"https://api.github.com/users/ADmad/gists{/gist_id}","starred_url":"https://api.github.com/users/ADmad/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ADmad/subscriptions","organizations_url":"https://api.github.com/users/ADmad/orgs","repos_url":"https://api.github.com/users/ADmad/repos","events_url":"https://api.github.com/users/ADmad/events{/privacy}","received_events_url":"https://api.github.com/users/ADmad/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/cakephp/cakephp/labels/ORM","name":"ORM","color":"ffffff"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/cakephp/cakephp/milestones/7","html_url":"https://github.com/cakephp/cakephp/milestones/3.0.0","labels_url":"https://api.github.com/repos/cakephp/cakephp/milestones/7/labels","id":453043,"number":7,"title":"3.0.0","description":"New major release that breaks compatibility with 2.x\r\n\r\n- PHP5.4.19+\r\n- New ORM & behaviors.\r\n- Improved Routing\r\n- PSR-0 and composer support.\r\n- Simpler configuration and bootstrapping.\r\n- Improved configuration handling.\r\n- Improved bake.\r\n\r\nSee [the roadmap](http://github.com/cakephp/cakephp/wiki/3.0-roadmap) for more details.","creator":{"login":"lh-import","id":5175817,"avatar_url":"https://avatars.githubusercontent.com/u/5175817?v=3","gravatar_id":"","url":"https://api.github.com/users/lh-import","html_url":"https://github.com/lh-import","followers_url":"https://api.github.com/users/lh-import/followers","following_url":"https://api.github.com/users/lh-import/following{/other_user}","gists_url":"https://api.github.com/users/lh-import/gists{/gist_id}","starred_url":"https://api.github.com/users/lh-import/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lh-import/subscriptions","organizations_url":"https://api.github.com/users/lh-import/orgs","repos_url":"https://api.github.com/users/lh-import/repos","events_url":"https://api.github.com/users/lh-import/events{/privacy}","received_events_url":"https://api.github.com/users/lh-import/received_events","type":"User","site_admin":false},"open_issues":18,"closed_issues":2360,"state":"open","created_at":"2013-10-11T20:56:23Z","updated_at":"2015-02-27T22:42:24Z","due_on":"2015-03-22T04:00:00Z","closed_at":null},"comments":7,"created_at":"2015-02-26T14:43:07Z","updated_at":"2015-02-28T02:02:44Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/cakephp/cakephp/pulls/5972","html_url":"https://github.com/cakephp/cakephp/pull/5972","diff_url":"https://github.com/cakephp/cakephp/pull/5972.diff","patch_url":"https://github.com/cakephp/cakephp/pull/5972.patch"},"body":"Added a new `Model.afterSaveCommit` event. As per its name it's triggered after a save has been committed.\r\n\r\nThe reason for this that `Model.afterSave` is triggered before operations are commited and not useful if you wanted to perform some task only after it's guaranteed that the changes have been persisted to db."},"comment":{"url":"https://api.github.com/repos/cakephp/cakephp/issues/comments/76504208","html_url":"https://github.com/cakephp/cakephp/pull/5972#issuecomment-76504208","issue_url":"https://api.github.com/repos/cakephp/cakephp/issues/5972","id":76504208,"user":{"login":"markstory","id":24086,"avatar_url":"https://avatars.githubusercontent.com/u/24086?v=3","gravatar_id":"","url":"https://api.github.com/users/markstory","html_url":"https://github.com/markstory","followers_url":"https://api.github.com/users/markstory/followers","following_url":"https://api.github.com/users/markstory/following{/other_user}","gists_url":"https://api.github.com/users/markstory/gists{/gist_id}","starred_url":"https://api.github.com/users/markstory/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/markstory/subscriptions","organizations_url":"https://api.github.com/users/markstory/orgs","repos_url":"https://api.github.com/users/markstory/repos","events_url":"https://api.github.com/users/markstory/events{/privacy}","received_events_url":"https://api.github.com/users/markstory/received_events","type":"User","site_admin":false},"created_at":"2015-02-28T02:02:44Z","updated_at":"2015-02-28T02:02:44Z","body":"afterAtomicSave is a bit clearer, as it could only be fired after atomic saves. Right now afterSaveCommited doesn't entirely fit as without atomic saves, each query is 'committed' when executed."}}