-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Restrict queried fields to those that are indexed #7
Comments
…at are indexed.
I've included a fix for this in #9. |
Also, it would be possible to retrieve all indexed fields and actually make those available in the view, too. (At least I'm pretty sure it should be possible.) So maybe we could make that configurable? |
I'd considered doing that when I started thinking about this issue. I thought maybe it might be beneficial to have a checkbox setting that would enable all fields to be available. I would want it to be clear what the potential performance impacts are, possibly even labeling the setting as "Development mode" or something similar. That's mostly because my recommendation would be that it only be enabled on a dev server while setting up views. Admins would need to know that if they have it enabled on production then it could cause major bandwidth issues. |
This is a performance enhancement. The list of fields that is returned by a Solr query needs to be restricted to those that have been added to the index. Because of the way that SearchApiSolrBackend::extractResults() is written, only those fields are available for display. Any other fields in the Solr output are wasted overhead, which could be highly detrimental to some sites depending on the data they have stored in the index. It could also be really bad for sites that have their index hosted by a third party. That unneeded data would do nothing but eat up their bandwidth.
The text was updated successfully, but these errors were encountered: