go-ego / riot

Go Open Source, Distributed, Simple and efficient Search Engine; Warning: This is V1 and beta version, because of big memory consume, and the V2 will be rewrite all code.
Apache License 2.0
6.11k stars 473 forks source link

Q: handling unpredictable schema #30

Closed ghost closed 6 years ago

ghost commented 6 years ago

Hi, I have a use case where each object can and will have completely different fields(and data types). So I cannot create schema that the search server can use to index this data in advance.

With elasticsearch I would have to create basically new index for every object which would be a nightmare, or translate each field into flat key/value structure and have a global index of these without a lot of features that would be otherwise available(facets, range search..).

Can riot handle such use case?

vcaesar commented 6 years ago

Riot currently indexes based on the Content, the Tokens, and the score fields, types.DocIndexData{Content: "test, in the way", Tokens: tokenDatas, Fields: "way"}.