This repository was archived by the owner on Sep 13, 2022. It is now read-only.

Description
The appengine sharded counter documentation
describes the implementation example as seen in: Sharded Counters Java Implementation
Whereas the implementation uses an unindexed property for the count.
I believe this causes a read-operation for each count entity, whereas
if I would make it indexed, and use a project query as;
final Query query = new Query(getKind())
.addProjection(new PropertyProjection(CounterShard.COUNT, Long.class));
It would (according to the current quota/pricing page create a projection query
Projection queries that do not use the distinct on clause.
This type of query is counted as a single entity read for the query itself.
The individual results are counted as small operations.
So that would be a single entity read for the entire query, instead of readops being equal to the number of shards?
Is this correct or am I missing something?
See also: Quotas, App Engine Issue