{"action":"created","issue":{"url":"https://api.github.com/repos/babenkoivan/scout-elasticsearch-driver/issues/161","repository_url":"https://api.github.com/repos/babenkoivan/scout-elasticsearch-driver","labels_url":"https://api.github.com/repos/babenkoivan/scout-elasticsearch-driver/issues/161/labels{/name}","comments_url":"https://api.github.com/repos/babenkoivan/scout-elasticsearch-driver/issues/161/comments","events_url":"https://api.github.com/repos/babenkoivan/scout-elasticsearch-driver/issues/161/events","html_url":"https://github.com/babenkoivan/scout-elasticsearch-driver/issues/161","id":387149246,"node_id":"MDU6SXNzdWUzODcxNDkyNDY=","number":161,"title":"Why is database being queried for search?","user":{"login":"TheBigK","id":9932882,"node_id":"MDQ6VXNlcjk5MzI4ODI=","avatar_url":"https://avatars2.githubusercontent.com/u/9932882?v=4","gravatar_id":"","url":"https://api.github.com/users/TheBigK","html_url":"https://github.com/TheBigK","followers_url":"https://api.github.com/users/TheBigK/followers","following_url":"https://api.github.com/users/TheBigK/following{/other_user}","gists_url":"https://api.github.com/users/TheBigK/gists{/gist_id}","starred_url":"https://api.github.com/users/TheBigK/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TheBigK/subscriptions","organizations_url":"https://api.github.com/users/TheBigK/orgs","repos_url":"https://api.github.com/users/TheBigK/repos","events_url":"https://api.github.com/users/TheBigK/events{/privacy}","received_events_url":"https://api.github.com/users/TheBigK/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-12-04T07:10:49Z","updated_at":"2018-12-06T17:18:13Z","closed_at":null,"author_association":"NONE","body":"I see that whenever I perform search, the database is still getting queried. For example, I have this -\r\n\r\n`User::search($keywords)->take(5)->get();`\r\n\r\nI see that when the search is performed, following query is executed \r\n\r\n`select * from `users` where `id` in ('1', '2', '3', '4', '5);`\r\n\r\nIs there any way to avoid querying database? Or this behavior is expected? "},"comment":{"url":"https://api.github.com/repos/babenkoivan/scout-elasticsearch-driver/issues/comments/444953695","html_url":"https://github.com/babenkoivan/scout-elasticsearch-driver/issues/161#issuecomment-444953695","issue_url":"https://api.github.com/repos/babenkoivan/scout-elasticsearch-driver/issues/161","id":444953695,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0NDk1MzY5NQ==","user":{"login":"michaelnguyen547","id":436950,"node_id":"MDQ6VXNlcjQzNjk1MA==","avatar_url":"https://avatars3.githubusercontent.com/u/436950?v=4","gravatar_id":"","url":"https://api.github.com/users/michaelnguyen547","html_url":"https://github.com/michaelnguyen547","followers_url":"https://api.github.com/users/michaelnguyen547/followers","following_url":"https://api.github.com/users/michaelnguyen547/following{/other_user}","gists_url":"https://api.github.com/users/michaelnguyen547/gists{/gist_id}","starred_url":"https://api.github.com/users/michaelnguyen547/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/michaelnguyen547/subscriptions","organizations_url":"https://api.github.com/users/michaelnguyen547/orgs","repos_url":"https://api.github.com/users/michaelnguyen547/repos","events_url":"https://api.github.com/users/michaelnguyen547/events{/privacy}","received_events_url":"https://api.github.com/users/michaelnguyen547/received_events","type":"User","site_admin":false},"created_at":"2018-12-06T17:18:13Z","updated_at":"2018-12-06T17:18:13Z","author_association":"NONE","body":"it is intended by default. Check out #116 for more info"}}
{"actor":{"display_login":"michaelnguyen547"}}