I have a simple MongoDB website where dedicated search engine (like elasticsearch) will be an overkill and will add support complexity, so I want to stick with MongoDB 2.6 full text search. As i can see, MongoDB llimits text search index to only one
field per collection. If I have a Users
collection with and want to enable full text search for both user name and user description, what is a correct collection structure for this? I can suggest to create a separate Text
collection where I will keep all text information for my website and use it for search. For example, user will be inserted like this:
users.insert({
name_ref: texts.insert({text: "John Doe", type: USER_NAME}),
description_ref: texts.insert({text: "This is a test user", type: USER_DESCR}),
});
Is it a good solution, or so many inter-collection dependencies will kill MongoDB, and I need to use some other appproach?