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
Detailed Description
The single account rest request /api/v1/accounts/0.0.1129 is very slow in perfnet. Analysis shows the account balance and token balances db query of the rest request takes seconds to finish:
pg explain analyze:
Hash Full Join (cost=64608.65..413475.09 rows=2 width=106) (actual time=3683.482..3924.771 rows=1 loops=1)
Hash Cond: ((ab.account_id)::bigint = entity.id)
Filter: (((ab.account_id)::bigint = 1129) OR (entity.id = 1129))
Rows Removed by Filter: 742763
-> Nested Loop (cost=1.20..319480.36 rows=772116 width=24) (actual time=0.074..348.685 rows=742762 loops=1)
-> Result (cost=0.63..0.64 rows=1 width=8) (actual time=0.051..0.051 rows=1 loops=1)
InitPlan 2 (returns $2)
-> Limit (cost=0.57..0.63 rows=1 width=8) (actual time=0.047..0.047 rows=1 loops=1)
-> Index Only Scan Backward using account_balance__pk on account_balance (cost=0.57..12781658.29 rows=223141583 width=8) (actual time=0.046..0.046 rows=1 loops=1)
Index Cond: (consensus_timestamp IS NOT NULL)
Heap Fetches: 1
-> Index Scan using account_balance__pk on account_balance ab (cost=0.57..311758.56 rows=772116 width=24) (actual time=0.017..240.906 rows=742762 loops=1)
Index Cond: ((consensus_timestamp)::bigint = ($2))
-> Hash (cost=47568.95..47568.95 rows=733080 width=58) (actual time=2848.622..2848.622 rows=742589 loops=1)
Buckets: 524288 Batches: 2 Memory Usage: 34531kB
-> Seq Scan on entity (cost=0.00..47568.95 rows=733080 width=58) (actual time=0.027..1641.357 rows=742589 loops=1)
Filter: (type < 3)
Rows Removed by Filter: 309208
SubPlan 1
-> Aggregate (cost=747.76..747.77 rows=1 width=32) (actual time=0.094..0.094 rows=1 loops=1)
-> Index Scan using token_balance__pk on token_balance tb (cost=0.57..733.43 rows=1433 width=16) (actual time=0.038..0.039 rows=1 loops=1)
Index Cond: (((ab.consensus_timestamp)::bigint = consensus_timestamp) AND ((ab.account_id)::bigint = (account_id)::bigint))
Planning time: 0.822 ms
Execution time: 3926.015 ms
Actual Behavior
Steps to reproduce the behavior:
Go to '...'
Click on '....'
Scroll down to '....'
Expected Behavior
Environment:
Additional Context
The text was updated successfully, but these errors were encountered:
Detailed Description
The single account rest request
/api/v1/accounts/0.0.1129
is very slow in perfnet. Analysis shows the account balance and token balances db query of the rest request takes seconds to finish:pg explain analyze:
Actual Behavior
Steps to reproduce the behavior:
Expected Behavior
Environment:
Additional Context
The text was updated successfully, but these errors were encountered: