eventsourcing/es4j

Problem: querying for aggregates is expensive

Open

#177 创建于 2016年11月6日

在 GitHub 查看
 (1 评论) (0 反应) (0 负责人)Java (27 fork)batch import
enhancementhelp wantedoptimization

仓库指标

Star
 (406 star)
PR 合并指标
 (30 天内没有已合并 PR)

描述

Querying for things like:

  • latest (as in, biggest TIMESTAMP) event for a certain scope (say, reference=R1)
  • sum/avg/max/min for a certain scope (say, reference=R1)

is quite expensive as it involved a lot of scanning (as can be seen in https://github.com/eventsourcing/es4j/blob/master/eventsourcing-queries/src/main/java/com/eventsourcing/queries/IsLatestEntity.java and https://github.com/eventsourcing/es4j/blob/master/eventsourcing-queries/src/main/java/com/eventsourcing/queries/LatestAssociatedEntryQuery.java)

Proposed solution: designate and formalize an aggregate indexing system.

贡献者指南