From 1482a88a9b8f7f3a24b55588ebbcde091c87333b Mon Sep 17 00:00:00 2001 From: dydxwill <119354122+dydxwill@users.noreply.github.com> Date: Mon, 18 Mar 2024 13:35:07 -0400 Subject: [PATCH] use read replica rather than main instance (#1190) --- .../services/roundtable/src/tasks/aggregate-trading-rewards.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/indexer/services/roundtable/src/tasks/aggregate-trading-rewards.ts b/indexer/services/roundtable/src/tasks/aggregate-trading-rewards.ts index f0beb0a83c..7bad1e8c1a 100644 --- a/indexer/services/roundtable/src/tasks/aggregate-trading-rewards.ts +++ b/indexer/services/roundtable/src/tasks/aggregate-trading-rewards.ts @@ -384,7 +384,7 @@ export class AggregateTradingReward { const blocks: BlockFromDatabase[] = await BlockTable.findAll({ createdOnOrAfter: time, limit: 1, - }, []); + }, [], { readReplica: true }); if (blocks.length === 0) { logger.error({