{"action":"created","comment":{"url":"https://api.github.com/repos/api-platform/docs/pulls/comments/77773155","id":77773155,"diff_hunk":"@@ -16,5 +16,152 @@ you want to use it on your project, follow the documentation dedicated to Symfon\n \n Keep in mind that PPM is still in an early stage of development and can cause issues in production.\n \n+## Doctrine Queries and Indexes\n+\n+### Search Filter\n+\n+When using the `SearchFilter` and case insensivity, Doctrine will be using the `LOWER` sql function. Depending on your driver, you may want to carefully index it by using a [*function-based index*](http://use-the-index-luke.com/sql/where-clause/functions/case-insensitive-search) or it will impact performances with a huge collection.\n+\n+### Lazy Joins\n+\n+Doctrine will do lazy joins. It's recommended to take a look at the Symfony profiler and check what SQL queries Doctrine is really doing in background. Note that `OneToOne` relations will be lazy loaded by default. To disable those in Api Platform you'd have to build a [`QueryResultExtension`](https://github.com/api-platform/core/blob/master/src/Bridge/Doctrine/Orm/Extension/QueryResultExtensionInterface.php).","path":"core/performance.md","position":12,"original_position":12,"commit_id":"f63831d2e00237fdc2055c43e6034536ceb8951c","original_commit_id":"f63831d2e00237fdc2055c43e6034536ceb8951c","user":{"login":"teohhanhui","id":548843,"avatar_url":"https://avatars.githubusercontent.com/u/548843?v=3","gravatar_id":"","url":"https://api.github.com/users/teohhanhui","html_url":"https://github.com/teohhanhui","followers_url":"https://api.github.com/users/teohhanhui/followers","following_url":"https://api.github.com/users/teohhanhui/following{/other_user}","gists_url":"https://api.github.com/users/teohhanhui/gists{/gist_id}","starred_url":"https://api.github.com/users/teohhanhui/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/teohhanhui/subscriptions","organizations_url":"https://api.github.com/users/teohhanhui/orgs","repos_url":"https://api.github.com/users/teohhanhui/repos","events_url":"https://api.github.com/users/teohhanhui/events{/privacy}","received_events_url":"https://api.github.com/users/teohhanhui/received_events","type":"User","site_admin":false},"body":"And it's also confusing to me that this paragraph starts out by talking about lazy joins in general, but then proceeds to narrow down to `OneToOne`. It's also misleading because `Query::HINT_FORCE_PARTIAL_LOAD` may affect more than `OneToOne` associations.","created_at":"2016-09-07T07:40:12Z","updated_at":"2016-09-07T07:40:12Z","html_url":"https://github.com/api-platform/docs/pull/106#discussion_r77773155","pull_request_url":"https://api.github.com/repos/api-platform/docs/pulls/106","_links":{"self":{"href":"https://api.github.com/repos/api-platform/docs/pulls/comments/77773155"},"html":{"href":"https://github.com/api-platform/docs/pull/106#discussion_r77773155"},"pull_request":{"href":"https://api.github.com/repos/api-platform/docs/pulls/106"}}},"pull_request":{"url":"https://api.github.com/repos/api-platform/docs/pulls/106","id":84081291,"html_url":"https://github.com/api-platform/docs/pull/106","diff_url":"https://github.com/api-platform/docs/pull/106.diff","patch_url":"https://github.com/api-platform/docs/pull/106.patch","issue_url":"https://api.github.com/repos/api-platform/docs/issues/106","number":106,"state":"open","locked":false,"title":"Add notes about Doctrine performances","user":{"login":"soyuka","id":1321971,"avatar_url":"https://avatars.githubusercontent.com/u/1321971?v=3","gravatar_id":"","url":"https://api.github.com/users/soyuka","html_url":"https://github.com/soyuka","followers_url":"https://api.github.com/users/soyuka/followers","following_url":"https://api.github.com/users/soyuka/following{/other_user}","gists_url":"https://api.github.com/users/soyuka/gists{/gist_id}","starred_url":"https://api.github.com/users/soyuka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/soyuka/subscriptions","organizations_url":"https://api.github.com/users/soyuka/orgs","repos_url":"https://api.github.com/users/soyuka/repos","events_url":"https://api.github.com/users/soyuka/events{/privacy}","received_events_url":"https://api.github.com/users/soyuka/received_events","type":"User","site_admin":false},"body":"https://github.com/api-platform/core/pull/717 related","created_at":"2016-09-06T08:36:47Z","updated_at":"2016-09-07T07:40:12Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d2bfed16ddfe0487f84b3b5b7e61eb13f2746503","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/api-platform/docs/pulls/106/commits","review_comments_url":"https://api.github.com/repos/api-platform/docs/pulls/106/comments","review_comment_url":"https://api.github.com/repos/api-platform/docs/pulls/comments{/number}","comments_url":"https://api.github.com/repos/api-platform/docs/issues/106/comments","statuses_url":"https://api.github.com/repos/api-platform/docs/statuses/f63831d2e00237fdc2055c43e6034536ceb8951c","head":{"label":"api-platform:soyuka-patch-1","ref":"soyuka-patch-1","sha":"f63831d2e00237fdc2055c43e6034536ceb8951c","user":{"login":"api-platform","id":13420081,"avatar_url":"https://avatars.githubusercontent.com/u/13420081?v=3","gravatar_id":"","url":"https://api.github.com/users/api-platform","html_url":"https://github.com/api-platform","followers_url":"https://api.github.com/users/api-platform/followers","following_url":"https://api.github.com/users/api-platform/following{/other_user}","gists_url":"https://api.github.com/users/api-platform/gists{/gist_id}","starred_url":"https://api.github.com/users/api-platform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/api-platform/subscriptions","organizations_url":"https://api.github.com/users/api-platform/orgs","repos_url":"https://api.github.com/users/api-platform/repos","events_url":"https://api.github.com/users/api-platform/events{/privacy}","received_events_url":"https://api.github.com/users/api-platform/received_events","type":"Organization","site_admin":false},"repo":{"id":38251565,"name":"docs","full_name":"api-platform/docs","owner":{"login":"api-platform","id":13420081,"avatar_url":"https://avatars.githubusercontent.com/u/13420081?v=3","gravatar_id":"","url":"https://api.github.com/users/api-platform","html_url":"https://github.com/api-platform","followers_url":"https://api.github.com/users/api-platform/followers","following_url":"https://api.github.com/users/api-platform/following{/other_user}","gists_url":"https://api.github.com/users/api-platform/gists{/gist_id}","starred_url":"https://api.github.com/users/api-platform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/api-platform/subscriptions","organizations_url":"https://api.github.com/users/api-platform/orgs","repos_url":"https://api.github.com/users/api-platform/repos","events_url":"https://api.github.com/users/api-platform/events{/privacy}","received_events_url":"https://api.github.com/users/api-platform/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/api-platform/docs","description":"API Platform documentation","fork":false,"url":"https://api.github.com/repos/api-platform/docs","forks_url":"https://api.github.com/repos/api-platform/docs/forks","keys_url":"https://api.github.com/repos/api-platform/docs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/api-platform/docs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/api-platform/docs/teams","hooks_url":"https://api.github.com/repos/api-platform/docs/hooks","issue_events_url":"https://api.github.com/repos/api-platform/docs/issues/events{/number}","events_url":"https://api.github.com/repos/api-platform/docs/events","assignees_url":"https://api.github.com/repos/api-platform/docs/assignees{/user}","branches_url":"https://api.github.com/repos/api-platform/docs/branches{/branch}","tags_url":"https://api.github.com/repos/api-platform/docs/tags","blobs_url":"https://api.github.com/repos/api-platform/docs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/api-platform/docs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/api-platform/docs/git/refs{/sha}","trees_url":"https://api.github.com/repos/api-platform/docs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/api-platform/docs/statuses/{sha}","languages_url":"https://api.github.com/repos/api-platform/docs/languages","stargazers_url":"https://api.github.com/repos/api-platform/docs/stargazers","contributors_url":"https://api.github.com/repos/api-platform/docs/contributors","subscribers_url":"https://api.github.com/repos/api-platform/docs/subscribers","subscription_url":"https://api.github.com/repos/api-platform/docs/subscription","commits_url":"https://api.github.com/repos/api-platform/docs/commits{/sha}","git_commits_url":"https://api.github.com/repos/api-platform/docs/git/commits{/sha}","comments_url":"https://api.github.com/repos/api-platform/docs/comments{/number}","issue_comment_url":"https://api.github.com/repos/api-platform/docs/issues/comments{/number}","contents_url":"https://api.github.com/repos/api-platform/docs/contents/{+path}","compare_url":"https://api.github.com/repos/api-platform/docs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/api-platform/docs/merges","archive_url":"https://api.github.com/repos/api-platform/docs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/api-platform/docs/downloads","issues_url":"https://api.github.com/repos/api-platform/docs/issues{/number}","pulls_url":"https://api.github.com/repos/api-platform/docs/pulls{/number}","milestones_url":"https://api.github.com/repos/api-platform/docs/milestones{/number}","notifications_url":"https://api.github.com/repos/api-platform/docs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/api-platform/docs/labels{/name}","releases_url":"https://api.github.com/repos/api-platform/docs/releases{/id}","deployments_url":"https://api.github.com/repos/api-platform/docs/deployments","created_at":"2015-06-29T14:19:34Z","updated_at":"2016-09-05T15:27:37Z","pushed_at":"2016-09-06T13:40:17Z","git_url":"git://github.com/api-platform/docs.git","ssh_url":"git@github.com:api-platform/docs.git","clone_url":"https://github.com/api-platform/docs.git","svn_url":"https://github.com/api-platform/docs","homepage":"https://api-platform.com/doc/","size":778,"stargazers_count":21,"watchers_count":21,"language":null,"has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":33,"mirror_url":null,"open_issues_count":8,"forks":33,"open_issues":8,"watchers":21,"default_branch":"master"}},"base":{"label":"api-platform:master","ref":"master","sha":"20b576b60d23fc13734f4b7d4fa04b1fc607e474","user":{"login":"api-platform","id":13420081,"avatar_url":"https://avatars.githubusercontent.com/u/13420081?v=3","gravatar_id":"","url":"https://api.github.com/users/api-platform","html_url":"https://github.com/api-platform","followers_url":"https://api.github.com/users/api-platform/followers","following_url":"https://api.github.com/users/api-platform/following{/other_user}","gists_url":"https://api.github.com/users/api-platform/gists{/gist_id}","starred_url":"https://api.github.com/users/api-platform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/api-platform/subscriptions","organizations_url":"https://api.github.com/users/api-platform/orgs","repos_url":"https://api.github.com/users/api-platform/repos","events_url":"https://api.github.com/users/api-platform/events{/privacy}","received_events_url":"https://api.github.com/users/api-platform/received_events","type":"Organization","site_admin":false},"repo":{"id":38251565,"name":"docs","full_name":"api-platform/docs","owner":{"login":"api-platform","id":13420081,"avatar_url":"https://avatars.githubusercontent.com/u/13420081?v=3","gravatar_id":"","url":"https://api.github.com/users/api-platform","html_url":"https://github.com/api-platform","followers_url":"https://api.github.com/users/api-platform/followers","following_url":"https://api.github.com/users/api-platform/following{/other_user}","gists_url":"https://api.github.com/users/api-platform/gists{/gist_id}","starred_url":"https://api.github.com/users/api-platform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/api-platform/subscriptions","organizations_url":"https://api.github.com/users/api-platform/orgs","repos_url":"https://api.github.com/users/api-platform/repos","events_url":"https://api.github.com/users/api-platform/events{/privacy}","received_events_url":"https://api.github.com/users/api-platform/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/api-platform/docs","description":"API Platform documentation","fork":false,"url":"https://api.github.com/repos/api-platform/docs","forks_url":"https://api.github.com/repos/api-platform/docs/forks","keys_url":"https://api.github.com/repos/api-platform/docs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/api-platform/docs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/api-platform/docs/teams","hooks_url":"https://api.github.com/repos/api-platform/docs/hooks","issue_events_url":"https://api.github.com/repos/api-platform/docs/issues/events{/number}","events_url":"https://api.github.com/repos/api-platform/docs/events","assignees_url":"https://api.github.com/repos/api-platform/docs/assignees{/user}","branches_url":"https://api.github.com/repos/api-platform/docs/branches{/branch}","tags_url":"https://api.github.com/repos/api-platform/docs/tags","blobs_url":"https://api.github.com/repos/api-platform/docs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/api-platform/docs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/api-platform/docs/git/refs{/sha}","trees_url":"https://api.github.com/repos/api-platform/docs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/api-platform/docs/statuses/{sha}","languages_url":"https://api.github.com/repos/api-platform/docs/languages","stargazers_url":"https://api.github.com/repos/api-platform/docs/stargazers","contributors_url":"https://api.github.com/repos/api-platform/docs/contributors","subscribers_url":"https://api.github.com/repos/api-platform/docs/subscribers","subscription_url":"https://api.github.com/repos/api-platform/docs/subscription","commits_url":"https://api.github.com/repos/api-platform/docs/commits{/sha}","git_commits_url":"https://api.github.com/repos/api-platform/docs/git/commits{/sha}","comments_url":"https://api.github.com/repos/api-platform/docs/comments{/number}","issue_comment_url":"https://api.github.com/repos/api-platform/docs/issues/comments{/number}","contents_url":"https://api.github.com/repos/api-platform/docs/contents/{+path}","compare_url":"https://api.github.com/repos/api-platform/docs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/api-platform/docs/merges","archive_url":"https://api.github.com/repos/api-platform/docs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/api-platform/docs/downloads","issues_url":"https://api.github.com/repos/api-platform/docs/issues{/number}","pulls_url":"https://api.github.com/repos/api-platform/docs/pulls{/number}","milestones_url":"https://api.github.com/repos/api-platform/docs/milestones{/number}","notifications_url":"https://api.github.com/repos/api-platform/docs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/api-platform/docs/labels{/name}","releases_url":"https://api.github.com/repos/api-platform/docs/releases{/id}","deployments_url":"https://api.github.com/repos/api-platform/docs/deployments","created_at":"2015-06-29T14:19:34Z","updated_at":"2016-09-05T15:27:37Z","pushed_at":"2016-09-06T13:40:17Z","git_url":"git://github.com/api-platform/docs.git","ssh_url":"git@github.com:api-platform/docs.git","clone_url":"https://github.com/api-platform/docs.git","svn_url":"https://github.com/api-platform/docs","homepage":"https://api-platform.com/doc/","size":778,"stargazers_count":21,"watchers_count":21,"language":null,"has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":33,"mirror_url":null,"open_issues_count":8,"forks":33,"open_issues":8,"watchers":21,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/api-platform/docs/pulls/106"},"html":{"href":"https://github.com/api-platform/docs/pull/106"},"issue":{"href":"https://api.github.com/repos/api-platform/docs/issues/106"},"comments":{"href":"https://api.github.com/repos/api-platform/docs/issues/106/comments"},"review_comments":{"href":"https://api.github.com/repos/api-platform/docs/pulls/106/comments"},"review_comment":{"href":"https://api.github.com/repos/api-platform/docs/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/api-platform/docs/pulls/106/commits"},"statuses":{"href":"https://api.github.com/repos/api-platform/docs/statuses/f63831d2e00237fdc2055c43e6034536ceb8951c"}}}}
{"actor":{"display_login":"teohhanhui"}}