I know the subject seems little bit clumsy. Let me try to explain it with
the exact usecase. Me and my team members are evaluating elasticsearch for
an eCommerce project. We want our customers to search for products they
want to buy from the search portal. For this we want to show our customer
products in some form of grouping (where each group will represent multiple
similar kind of products e.g. one search result record can be IPhone
representing all IPhone series) in the search result.
We know this cannot be achieved with elasticsearch (
https://github.com/elasticsearch/elasticsearch/issues/256). So we decided
to store the grouped representation of the products in elastic search
instead of actual products with a simple criteria. At time of adding a
product search for the representative product group based on product
attributes and if we find a group then associate the product with the group
otherwise create a new group from this newly added product.
The problem we are facing here is that we cannot search a product (consider
its as a group) which is just added into elasticsearch before adding a new
product resulting in creation of another similar group.
Note: we are aware of elasticsearch realtime get and faceted search
features and both seems irrelevant to our problem space.
My question is that can we achieve realtime indexing without using refresh
API (as it results in complete refresh of index) or is it the only way and
if it is than what will be the performance impact of using refresh API.