Skip to content
Snippets Groups Projects
Commit cda0831d authored by Dariusz Kędzierski's avatar Dariusz Kędzierski
Browse files

More fixes

parent 44e0b332
No related branches found
No related tags found
5 merge requests!456Release candidate v1 24,!230Setup monitoring with pghero,!135Enable postgres monitoring on CI server,!16Dk issue 3 concurrent block query rebase,!15Dk issue 3 concurrent block query
......@@ -86,7 +86,7 @@ class Sync:
# take care of payout backlog
CachedPost.dirty_paidouts(Blocks.head_date())
CachedPost.flush(self._steem, trx=True)
#CachedPost.flush(self._steem, trx=True)
try:
# listen for new blocks
......@@ -174,7 +174,7 @@ class Sync:
# edits and pre-payout votes. If the post has not been paid out yet,
# then the worst case is it will be synced upon payout. If the post
# is already paid out, worst case is to lose an edit.
CachedPost.flush(steemd, trx=True)
#CachedPost.flush(steemd, trx=True)
def listen(self):
"""Live (block following) mode."""
......@@ -196,15 +196,13 @@ class Sync:
follows = Follow.flush(trx=False)
accts = Accounts.flush(steemd, trx=False, spread=8)
CachedPost.dirty_paidouts(block['timestamp'])
cnt = CachedPost.flush(steemd, trx=False)
#cnt = CachedPost.flush(steemd, trx=False)
self._db.query("COMMIT")
ms = (perf() - start_time) * 1000
log.info("[LIVE] Got block %d at %s --% 4d txs,% 3d posts,% 3d edits,"
"% 3d payouts,% 3d votes,% 3d counts,% 3d accts,% 3d follows"
log.info("[LIVE] Got block %d at %s --% 4d txs,% 3d accts,% 3d follows"
" --% 5dms%s", num, block['timestamp'], len(block['transactions']),
cnt['insert'], cnt['update'], cnt['payout'], cnt['upvote'],
cnt['recount'], accts, follows, ms, ' SLOW' if ms > 1000 else '')
accts, follows, ms, ' SLOW' if ms > 1000 else '')
if num % 1200 == 0: #1hr
log.warning("head block %d @ %s", num, block['timestamp'])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment