staking_reward_transfer is distributed in V2 on account_id so it's performant to query certain account(s) staking reward transfers. However, given a set of consensus timestamps, querying the staking reward transfers become all-shard slow query.
The table is very small, and partitioned monthly. The max number of rows so far in a partition is around 730k. It should be undistributed for better performance
Solution
Undistribute the table
Adjust index, drop the primary key, and add an index on consensus_timestamp
Problem
staking_reward_transfer
is distributed in V2 onaccount_id
so it's performant to query certain account(s) staking reward transfers. However, given a set of consensus timestamps, querying the staking reward transfers become all-shard slow query.The table is very small, and partitioned monthly. The max number of rows so far in a partition is around 730k. It should be undistributed for better performance
Solution
consensus_timestamp
payer_account_id
Alternatives
No response