I have following requirements,
For every project that I index has 2 values
- Id: Each project has a unique ID
- Name: Name of the project. But Name of the project can change.
For every project, we index a document with different attributes. Say each
document in index will have an Attribute A1 with different values. Each
attribute has an Id and Name. Name again can change.
Oveall index would look like
ProjectName ProjectGUID A1Name A1Id File
P1 P1ID T1 T1-ID f11
P1 P1ID T1 T1-ID f12
P1 P1ID T1 T1-ID f13
P1 P1ID T2 T2-ID f21
post rename of T2 to T3 index will look like,
P1 P1ID T3 T2-ID f21
So Name has changed but not Id.
During query I aggregate on different attributes.
- User always queries with Project name.
- During displaying results I want to display results based upon different
attributes. Say for attribute A1 with name T1 3 documents exist. For T2 5
If I index document with name query is very simple. But as we support
renames, any rename means indexing whole project.
So another option is to store ids in documents and store id to name map
separately. For project rename we can use Alias with id as filter. For
aggregations, one of the options I could see is term lookup filters. But I
- read about aggregating on term lookup rather than term itself
- cost associated with term lookup.
Are any other alternatives available with elasticsearch? I believe this
should be a common problem. Any suggestions,
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to email@example.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/460062d0-2e72-48f6-a4e7-08fc65e8c8e6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.