例如 我有一个叫人名的字段,当用户键入内容时,我们将显示与用户输入内容匹配的所有选项。
我的第一个问题:
which one should maintain trie tree, frontend, backend or both?
第二个问题:
No matter front end or back end, when will trie tree be loaded?
If trie loaded on start, million of entities loaded take a lot time, and huge data in memory.
If trie loaded once user searched, each time user typed is a DB call and a Rest call, which also consumme a lot resources. And at first search, user will see no options till he did once, which is bad user experience.
如果您有想法,请期待!