-
- Downloads
Fix calculating rshares
In previous commit vote notifications were changed to be inserted after processing each block. But in massive sync rshares for posts were calculated only at the end of massive sync. This resulted in vote notifications to not be inserted, because score were always calculated as 0. To fix this, calculate rshares for modified posts after processing each block. `hive_posts` are now modified in posts and votes indexer. An advisory lock was added to synchronise, because deadlock was detected by postgres failing transactions.
parent
e1acb85c
No related branches found
No related tags found
This commit is part of merge request !863. Comments created here will be created in the context of that merge request.
Showing
- hive/db/adapter.py 4 additions, 0 deletionshive/db/adapter.py
- hive/db/db_state.py 0 additions, 6 deletionshive/db/db_state.py
- hive/db/sql_scripts/update_posts_rshares.sql 3 additions, 37 deletionshive/db/sql_scripts/update_posts_rshares.sql
- hive/indexer/blocks.py 0 additions, 1 deletionhive/indexer/blocks.py
- hive/indexer/posts.py 1 addition, 0 deletionshive/indexer/posts.py
- hive/indexer/votes.py 14 additions, 23 deletionshive/indexer/votes.py
- tests/api_tests/hivemind/tavern/bridge_api_patterns/unread_notifications/abit.pat.json 1 addition, 1 deletion...rn/bridge_api_patterns/unread_notifications/abit.pat.json
- tests/api_tests/hivemind/tavern/bridge_api_patterns/unread_notifications/anton333.pat.json 1 addition, 1 deletion...ridge_api_patterns/unread_notifications/anton333.pat.json
- tests/api_tests/hivemind/tavern/bridge_api_patterns/unread_notifications/elyaque.pat.json 1 addition, 1 deletion...bridge_api_patterns/unread_notifications/elyaque.pat.json
- tests/api_tests/hivemind/tavern/bridge_api_patterns/unread_notifications/larrytom.pat.json 1 addition, 1 deletion...ridge_api_patterns/unread_notifications/larrytom.pat.json
- tests/api_tests/hivemind/tavern/bridge_api_patterns/unread_notifications/max_score.pat.json 1 addition, 1 deletion...idge_api_patterns/unread_notifications/max_score.pat.json
- tests/api_tests/hivemind/tavern/bridge_api_patterns/unread_notifications/min_score.pat.json 1 addition, 1 deletion...idge_api_patterns/unread_notifications/min_score.pat.json
Loading
Please register or sign in to comment