Question about counting performance

We have a document type that has links to other documents of the same
type. We want to store the number of links to each document on the
document itself. We can get those counts out of the source system (MySQL)
but they are slow.

Does anyone have a gut feeling about loading all the documents into
Elasticsearch, forcing a refresh, and then updating all the counts in a
second pass using count queries against Elasticsearch? I think it'd be
faster than waiting on MySQL.

We'd be able to use the count query method on incremental updates without
as well without worrying about a second pass which would be nice. We'd
have to work around refreshes but that shouldn't be too much of a problem.

Nik Everett

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
For more options, visit