You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The top hits aggregation is quite a powerful feature of Elasticsearch. The aggregation support is a step closer to get this functionality, but it would be awesome to make these top hits reactive and as a built it feature.
varcursor=index.search('test');// get all aggregationsvartypes=cursor.getTophitsTypes();types.forEach(function(type){vartophits=cursor.getTophits(type);console.log(tophits.fetch());})
I'd like some feedback on this 😄
The text was updated successfully, but these errors were encountered:
looks cool for me! would be awesome to have the logic for the tophits implemented in an ElasticsearchCursor so that we don't have to adjust code in the core package unnecessarily.
The top hits aggregation is quite a powerful feature of Elasticsearch. The aggregation support is a step closer to get this functionality, but it would be awesome to make these top hits reactive and as a built it feature.
Example:
This would generate tophits for 5 of the most popular categories. This would result in an ES aggregation that looks like:
The tophits can then be retrieved by:
I'd like some feedback on this 😄
The text was updated successfully, but these errors were encountered: