Skip to content

Commit

Permalink
Add revenue bridge in chain config to configure alerting
Browse files Browse the repository at this point in the history
  • Loading branch information
prevostc committed Oct 26, 2023
1 parent 648a571 commit 44459c6
Showing 1 changed file with 19 additions and 11 deletions.
30 changes: 19 additions & 11 deletions src/lib/db/migrate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -215,18 +215,23 @@ export async function db_migrate() {
(harvest_enabled = 't')::boolean as harvest_enabled,
(harvest_profitability_check_enabled = 't')::boolean as harvest_profitability_check_enabled,
(target_hours_between_harvests || ' hours')::interval as target_time_between_harvests,
harvest_balance_gas_multiplier_threshold::double precision
harvest_balance_gas_multiplier_threshold::double precision,
(revenue_bridge_harvest_enabled = 't')::boolean as revenue_bridge_harvest_enabled,
revenue_bridge_harvest_balance_gas_multiplier_threshold::double precision
FROM (values %L) as c(
chain,
eol,
unwrap_enabled,
unwrap_balance_gas_multiplier_threshold,
unwrap_min_amount_of_wnative_wei,
unwrap_max_amount_of_native_wei,
harvest_enabled,
harvest_profitability_check_enabled,
target_hours_between_harvests,
harvest_balance_gas_multiplier_threshold)
chain,
eol,
unwrap_enabled,
unwrap_balance_gas_multiplier_threshold,
unwrap_min_amount_of_wnative_wei,
unwrap_max_amount_of_native_wei,
harvest_enabled,
harvest_profitability_check_enabled,
target_hours_between_harvests,
harvest_balance_gas_multiplier_threshold,
revenue_bridge_harvest_enabled,
revenue_bridge_harvest_balance_gas_multiplier_threshold
)
);
`,
[
Expand All @@ -241,6 +246,9 @@ export async function db_migrate() {
RPC_CONFIG[c].harvest.profitabilityCheck.enabled,
RPC_CONFIG[c].harvest.targetTimeBetweenHarvestsMs / 1000 / 60 / 60,
RPC_CONFIG[c].harvest.balanceCheck.minGasInWalletThresholdAsMultiplierOfEstimatedTransactionCost,
RPC_CONFIG[c].revenueBridgeHarvest.enabled,
RPC_CONFIG[c].revenueBridgeHarvest.balanceCheck
.minGasInWalletThresholdAsMultiplierOfEstimatedTransactionCost,
]),
]
);
Expand Down

0 comments on commit 44459c6

Please sign in to comment.