{"action":"created","comment":{"url":"https://api.github.com/repos/cakephp/cakephp/pulls/comments/41084964","id":41084964,"diff_hunk":"@@ -48,6 +48,24 @@ public function drop(ConnectionInterface $db);\n     public function insert(ConnectionInterface $db);\n \n     /**\n+     * Build and execute SQL queries necessary to create the constraints for the\n+     * fixture\n+     *\n+     * @param \\Cake\\Datasource\\ConnectionInterface $db An instance of the database into which the constraints will be created\n+     * @return bool on success or if there are no constraints to create, or false on failure\n+     */\n+    public function createConstraints(ConnectionInterface $db);\n+\n+    /**\n+     * Build and execute SQL queries necessary to drop the constraints for the\n+     * fixture\n+     *\n+     * @param \\Cake\\Datasource\\ConnectionInterface $db An instance of the database into which the constraints will be dropped\n+     * @return bool on success or if there are no constraints to drop, or false on failure\n+     */\n+    public function dropConstraints(ConnectionInterface $db);","path":"src/Datasource/FixtureInterface.php","position":19,"original_position":19,"commit_id":"6cf0a16a01ccce436dd5038b1b3c28d6269ccf6c","original_commit_id":"6cf0a16a01ccce436dd5038b1b3c28d6269ccf6c","user":{"login":"HavokInspiration","id":5243386,"avatar_url":"https://avatars.githubusercontent.com/u/5243386?v=3","gravatar_id":"","url":"https://api.github.com/users/HavokInspiration","html_url":"https://github.com/HavokInspiration","followers_url":"https://api.github.com/users/HavokInspiration/followers","following_url":"https://api.github.com/users/HavokInspiration/following{/other_user}","gists_url":"https://api.github.com/users/HavokInspiration/gists{/gist_id}","starred_url":"https://api.github.com/users/HavokInspiration/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/HavokInspiration/subscriptions","organizations_url":"https://api.github.com/users/HavokInspiration/orgs","repos_url":"https://api.github.com/users/HavokInspiration/repos","events_url":"https://api.github.com/users/HavokInspiration/events{/privacy}","received_events_url":"https://api.github.com/users/HavokInspiration/received_events","type":"User","site_admin":false},"body":"I can see what I can do about that. I might need some guidance though, I don't really know elasticsearch.","created_at":"2015-10-03T08:01:04Z","updated_at":"2015-10-03T08:01:04Z","html_url":"https://github.com/cakephp/cakephp/pull/7503#discussion_r41084964","pull_request_url":"https://api.github.com/repos/cakephp/cakephp/pulls/7503","_links":{"self":{"href":"https://api.github.com/repos/cakephp/cakephp/pulls/comments/41084964"},"html":{"href":"https://github.com/cakephp/cakephp/pull/7503#discussion_r41084964"},"pull_request":{"href":"https://api.github.com/repos/cakephp/cakephp/pulls/7503"}}},"pull_request":{"url":"https://api.github.com/repos/cakephp/cakephp/pulls/7503","id":46690158,"html_url":"https://github.com/cakephp/cakephp/pull/7503","diff_url":"https://github.com/cakephp/cakephp/pull/7503.diff","patch_url":"https://github.com/cakephp/cakephp/pull/7503.patch","issue_url":"https://api.github.com/repos/cakephp/cakephp/issues/7503","number":7503,"state":"open","locked":false,"title":"Fix constraints in fixtures","user":{"login":"HavokInspiration","id":5243386,"avatar_url":"https://avatars.githubusercontent.com/u/5243386?v=3","gravatar_id":"","url":"https://api.github.com/users/HavokInspiration","html_url":"https://github.com/HavokInspiration","followers_url":"https://api.github.com/users/HavokInspiration/followers","following_url":"https://api.github.com/users/HavokInspiration/following{/other_user}","gists_url":"https://api.github.com/users/HavokInspiration/gists{/gist_id}","starred_url":"https://api.github.com/users/HavokInspiration/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/HavokInspiration/subscriptions","organizations_url":"https://api.github.com/users/HavokInspiration/orgs","repos_url":"https://api.github.com/users/HavokInspiration/repos","events_url":"https://api.github.com/users/HavokInspiration/events{/privacy}","received_events_url":"https://api.github.com/users/HavokInspiration/received_events","type":"User","site_admin":false},"body":"Currently, when you load your fixtures, you have to carefully order them so constraints are dealt with correctly to avoid some db drivers complaining about constraint integrity violation.\r\nThis PR aims to correct that by allowing you to put your fixtures and whatever order.\r\n\r\nThe same idea than with the migration plugin was applied : first, all tables are created and only after that are constraints added. Same thing goes for a truncate or a drop : first constraints are dropped and then the truncate or drop is done.\r\n\r\nRefs #6323 ","created_at":"2015-10-02T22:44:14Z","updated_at":"2015-10-03T08:01:04Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b83eea335c949790f2edaae1ac3d8875dd3e85a0","assignee":null,"milestone":{"url":"https://api.github.com/repos/cakephp/cakephp/milestones/60","html_url":"https://github.com/cakephp/cakephp/milestones/3.1.1","labels_url":"https://api.github.com/repos/cakephp/cakephp/milestones/60/labels","id":1314897,"number":60,"title":"3.1.1","description":"Bugfixes and minor enhancements for 3.1.x","creator":{"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},"open_issues":36,"closed_issues":52,"state":"open","created_at":"2015-09-20T02:24:50Z","updated_at":"2015-10-03T05:32:06Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/cakephp/cakephp/pulls/7503/commits","review_comments_url":"https://api.github.com/repos/cakephp/cakephp/pulls/7503/comments","review_comment_url":"https://api.github.com/repos/cakephp/cakephp/pulls/comments{/number}","comments_url":"https://api.github.com/repos/cakephp/cakephp/issues/7503/comments","statuses_url":"https://api.github.com/repos/cakephp/cakephp/statuses/6cf0a16a01ccce436dd5038b1b3c28d6269ccf6c","head":{"label":"HavokInspiration:fixtures-order","ref":"fixtures-order","sha":"6cf0a16a01ccce436dd5038b1b3c28d6269ccf6c","user":{"login":"HavokInspiration","id":5243386,"avatar_url":"https://avatars.githubusercontent.com/u/5243386?v=3","gravatar_id":"","url":"https://api.github.com/users/HavokInspiration","html_url":"https://github.com/HavokInspiration","followers_url":"https://api.github.com/users/HavokInspiration/followers","following_url":"https://api.github.com/users/HavokInspiration/following{/other_user}","gists_url":"https://api.github.com/users/HavokInspiration/gists{/gist_id}","starred_url":"https://api.github.com/users/HavokInspiration/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/HavokInspiration/subscriptions","organizations_url":"https://api.github.com/users/HavokInspiration/orgs","repos_url":"https://api.github.com/users/HavokInspiration/repos","events_url":"https://api.github.com/users/HavokInspiration/events{/privacy}","received_events_url":"https://api.github.com/users/HavokInspiration/received_events","type":"User","site_admin":false},"repo":{"id":23718050,"name":"cakephp","full_name":"HavokInspiration/cakephp","owner":{"login":"HavokInspiration","id":5243386,"avatar_url":"https://avatars.githubusercontent.com/u/5243386?v=3","gravatar_id":"","url":"https://api.github.com/users/HavokInspiration","html_url":"https://github.com/HavokInspiration","followers_url":"https://api.github.com/users/HavokInspiration/followers","following_url":"https://api.github.com/users/HavokInspiration/following{/other_user}","gists_url":"https://api.github.com/users/HavokInspiration/gists{/gist_id}","starred_url":"https://api.github.com/users/HavokInspiration/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/HavokInspiration/subscriptions","organizations_url":"https://api.github.com/users/HavokInspiration/orgs","repos_url":"https://api.github.com/users/HavokInspiration/repos","events_url":"https://api.github.com/users/HavokInspiration/events{/privacy}","received_events_url":"https://api.github.com/users/HavokInspiration/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/HavokInspiration/cakephp","description":"CakePHP: The Rapid Development Framework for PHP - Official Repository","fork":true,"url":"https://api.github.com/repos/HavokInspiration/cakephp","forks_url":"https://api.github.com/repos/HavokInspiration/cakephp/forks","keys_url":"https://api.github.com/repos/HavokInspiration/cakephp/keys{/key_id}","collaborators_url":"https://api.github.com/repos/HavokInspiration/cakephp/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/HavokInspiration/cakephp/teams","hooks_url":"https://api.github.com/repos/HavokInspiration/cakephp/hooks","issue_events_url":"https://api.github.com/repos/HavokInspiration/cakephp/issues/events{/number}","events_url":"https://api.github.com/repos/HavokInspiration/cakephp/events","assignees_url":"https://api.github.com/repos/HavokInspiration/cakephp/assignees{/user}","branches_url":"https://api.github.com/repos/HavokInspiration/cakephp/branches{/branch}","tags_url":"https://api.github.com/repos/HavokInspiration/cakephp/tags","blobs_url":"https://api.github.com/repos/HavokInspiration/cakephp/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/HavokInspiration/cakephp/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/HavokInspiration/cakephp/git/refs{/sha}","trees_url":"https://api.github.com/repos/HavokInspiration/cakephp/git/trees{/sha}","statuses_url":"https://api.github.com/repos/HavokInspiration/cakephp/statuses/{sha}","languages_url":"https://api.github.com/repos/HavokInspiration/cakephp/languages","stargazers_url":"https://api.github.com/repos/HavokInspiration/cakephp/stargazers","contributors_url":"https://api.github.com/repos/HavokInspiration/cakephp/contributors","subscribers_url":"https://api.github.com/repos/HavokInspiration/cakephp/subscribers","subscription_url":"https://api.github.com/repos/HavokInspiration/cakephp/subscription","commits_url":"https://api.github.com/repos/HavokInspiration/cakephp/commits{/sha}","git_commits_url":"https://api.github.com/repos/HavokInspiration/cakephp/git/commits{/sha}","comments_url":"https://api.github.com/repos/HavokInspiration/cakephp/comments{/number}","issue_comment_url":"https://api.github.com/repos/HavokInspiration/cakephp/issues/comments{/number}","contents_url":"https://api.github.com/repos/HavokInspiration/cakephp/contents/{+path}","compare_url":"https://api.github.com/repos/HavokInspiration/cakephp/compare/{base}...{head}","merges_url":"https://api.github.com/repos/HavokInspiration/cakephp/merges","archive_url":"https://api.github.com/repos/HavokInspiration/cakephp/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/HavokInspiration/cakephp/downloads","issues_url":"https://api.github.com/repos/HavokInspiration/cakephp/issues{/number}","pulls_url":"https://api.github.com/repos/HavokInspiration/cakephp/pulls{/number}","milestones_url":"https://api.github.com/repos/HavokInspiration/cakephp/milestones{/number}","notifications_url":"https://api.github.com/repos/HavokInspiration/cakephp/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/HavokInspiration/cakephp/labels{/name}","releases_url":"https://api.github.com/repos/HavokInspiration/cakephp/releases{/id}","created_at":"2014-09-05T20:55:13Z","updated_at":"2015-04-28T17:13:46Z","pushed_at":"2015-10-02T23:52:41Z","git_url":"git://github.com/HavokInspiration/cakephp.git","ssh_url":"git@github.com:HavokInspiration/cakephp.git","clone_url":"https://github.com/HavokInspiration/cakephp.git","svn_url":"https://github.com/HavokInspiration/cakephp","homepage":"http://cakephp.org","size":87290,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"cakephp:master","ref":"master","sha":"e38b6268f3f717c41c565ff1c189754f2eddbb78","user":{"login":"cakephp","id":23666,"avatar_url":"https://avatars.githubusercontent.com/u/23666?v=3","gravatar_id":"","url":"https://api.github.com/users/cakephp","html_url":"https://github.com/cakephp","followers_url":"https://api.github.com/users/cakephp/followers","following_url":"https://api.github.com/users/cakephp/following{/other_user}","gists_url":"https://api.github.com/users/cakephp/gists{/gist_id}","starred_url":"https://api.github.com/users/cakephp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cakephp/subscriptions","organizations_url":"https://api.github.com/users/cakephp/orgs","repos_url":"https://api.github.com/users/cakephp/repos","events_url":"https://api.github.com/users/cakephp/events{/privacy}","received_events_url":"https://api.github.com/users/cakephp/received_events","type":"Organization","site_admin":false},"repo":{"id":656494,"name":"cakephp","full_name":"cakephp/cakephp","owner":{"login":"cakephp","id":23666,"avatar_url":"https://avatars.githubusercontent.com/u/23666?v=3","gravatar_id":"","url":"https://api.github.com/users/cakephp","html_url":"https://github.com/cakephp","followers_url":"https://api.github.com/users/cakephp/followers","following_url":"https://api.github.com/users/cakephp/following{/other_user}","gists_url":"https://api.github.com/users/cakephp/gists{/gist_id}","starred_url":"https://api.github.com/users/cakephp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cakephp/subscriptions","organizations_url":"https://api.github.com/users/cakephp/orgs","repos_url":"https://api.github.com/users/cakephp/repos","events_url":"https://api.github.com/users/cakephp/events{/privacy}","received_events_url":"https://api.github.com/users/cakephp/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/cakephp/cakephp","description":"CakePHP: The Rapid Development Framework for PHP - Official Repository","fork":false,"url":"https://api.github.com/repos/cakephp/cakephp","forks_url":"https://api.github.com/repos/cakephp/cakephp/forks","keys_url":"https://api.github.com/repos/cakephp/cakephp/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cakephp/cakephp/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cakephp/cakephp/teams","hooks_url":"https://api.github.com/repos/cakephp/cakephp/hooks","issue_events_url":"https://api.github.com/repos/cakephp/cakephp/issues/events{/number}","events_url":"https://api.github.com/repos/cakephp/cakephp/events","assignees_url":"https://api.github.com/repos/cakephp/cakephp/assignees{/user}","branches_url":"https://api.github.com/repos/cakephp/cakephp/branches{/branch}","tags_url":"https://api.github.com/repos/cakephp/cakephp/tags","blobs_url":"https://api.github.com/repos/cakephp/cakephp/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cakephp/cakephp/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cakephp/cakephp/git/refs{/sha}","trees_url":"https://api.github.com/repos/cakephp/cakephp/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cakephp/cakephp/statuses/{sha}","languages_url":"https://api.github.com/repos/cakephp/cakephp/languages","stargazers_url":"https://api.github.com/repos/cakephp/cakephp/stargazers","contributors_url":"https://api.github.com/repos/cakephp/cakephp/contributors","subscribers_url":"https://api.github.com/repos/cakephp/cakephp/subscribers","subscription_url":"https://api.github.com/repos/cakephp/cakephp/subscription","commits_url":"https://api.github.com/repos/cakephp/cakephp/commits{/sha}","git_commits_url":"https://api.github.com/repos/cakephp/cakephp/git/commits{/sha}","comments_url":"https://api.github.com/repos/cakephp/cakephp/comments{/number}","issue_comment_url":"https://api.github.com/repos/cakephp/cakephp/issues/comments{/number}","contents_url":"https://api.github.com/repos/cakephp/cakephp/contents/{+path}","compare_url":"https://api.github.com/repos/cakephp/cakephp/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cakephp/cakephp/merges","archive_url":"https://api.github.com/repos/cakephp/cakephp/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cakephp/cakephp/downloads","issues_url":"https://api.github.com/repos/cakephp/cakephp/issues{/number}","pulls_url":"https://api.github.com/repos/cakephp/cakephp/pulls{/number}","milestones_url":"https://api.github.com/repos/cakephp/cakephp/milestones{/number}","notifications_url":"https://api.github.com/repos/cakephp/cakephp/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cakephp/cakephp/labels{/name}","releases_url":"https://api.github.com/repos/cakephp/cakephp/releases{/id}","created_at":"2010-05-08T14:38:22Z","updated_at":"2015-10-02T23:51:37Z","pushed_at":"2015-10-03T05:32:06Z","git_url":"git://github.com/cakephp/cakephp.git","ssh_url":"git@github.com:cakephp/cakephp.git","clone_url":"https://github.com/cakephp/cakephp.git","svn_url":"https://github.com/cakephp/cakephp","homepage":"http://cakephp.org","size":185682,"stargazers_count":6082,"watchers_count":6082,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":2760,"mirror_url":null,"open_issues_count":146,"forks":2760,"open_issues":146,"watchers":6082,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/cakephp/cakephp/pulls/7503"},"html":{"href":"https://github.com/cakephp/cakephp/pull/7503"},"issue":{"href":"https://api.github.com/repos/cakephp/cakephp/issues/7503"},"comments":{"href":"https://api.github.com/repos/cakephp/cakephp/issues/7503/comments"},"review_comments":{"href":"https://api.github.com/repos/cakephp/cakephp/pulls/7503/comments"},"review_comment":{"href":"https://api.github.com/repos/cakephp/cakephp/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/cakephp/cakephp/pulls/7503/commits"},"statuses":{"href":"https://api.github.com/repos/cakephp/cakephp/statuses/6cf0a16a01ccce436dd5038b1b3c28d6269ccf6c"}}}}