confusion between Index and SearchableTextIndex
Opened this issue · 4 comments
User problem
from https://community.plone.org/t/how-to-using-own-fields-in-live-search/2307/4
its not clear to users the difference between an SearchableText index and other indexes. This is probably caused by a few things
- The word index is used for search engines like google to index a whole document, not an individual field. As in the verb to index, rather than the noun. We should perhaps be using a more specific term. ie, "yes I want to index my new content type, thats obviously how I get it searchable".
- field index is probably an advanced usecase but including all of the fields in the searchabletext is likely a more common usecase. We don't offer a UI for this so users are going to assume Index is the thing they want.
- anyone used to an SQL system would think of accessing items by field values as something to do with a query. indexes are just an optimisation to make that faster so an advanced concept. Plone is abnormal that it requires an index to make that query possible.
Options
Queryable and Searchable
perhaps we could have an UI where you can enable a field to be either:
- query-able
- searchable
- query-able and searchable
Searchable text already includes id + title + summary + text + keywords/tags for native CTs. Also custom CTs get automatically indexed if they use IBasic, IDublinCore or ICategorization behaviors instead of manually defining those fields. I wish that would also happen for IRichText so I don't need to do this but I can understand if it's disabled by default to avoid bloating the catalog.
All in all I agree it'd be a nice to have feature. If we think risks exist we could add it as an addon until the idea matures and they are better measured. Maybe collective.dexteritytextindexer could extend plone.schemaeditor UI?
Later on it'd be probably be nice to also allow setting permissions to individual fields ttw as well. Maybe even custom validators with Restricted Python if that's not too limiting.
@davilima6 were you asking for collective/collective.dexteritytextindexer#11 you can thank @datakurre :-)
I would love to see someone making a PLIP about merging collective.dexterityindexer to the core
It's been awhile I don't use that package and I hadn't noticed the new feature. Excellent! Thanks, @datakurre!
Should I open another issue for allowing to set rw permissions per field? Anything else?