-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: migrate SpokePoolIndexer to new Indexer (#64)
Co-authored-by: Alexandru Matei <[email protected]>
- Loading branch information
1 parent
92c966b
commit 048b8b6
Showing
18 changed files
with
486 additions
and
381 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
packages/indexer-database/src/migrations/1728296909794-SpokePoolFinalised.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
import { MigrationInterface, QueryRunner } from "typeorm"; | ||
|
||
export class SpokePoolFinalised1728296909794 implements MigrationInterface { | ||
name = "SpokePoolFinalised1728296909794"; | ||
|
||
public async up(queryRunner: QueryRunner): Promise<void> { | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."v3_funds_deposited" ADD "finalised" boolean NOT NULL`, | ||
); | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."filled_v3_relay" ADD "finalised" boolean NOT NULL`, | ||
); | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."requested_v3_slow_fill" ADD "finalised" boolean NOT NULL`, | ||
); | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."requested_speed_up_v3_deposit" ADD "finalised" boolean NOT NULL`, | ||
); | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."relayed_root_bundle" ADD "finalised" boolean NOT NULL`, | ||
); | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."executed_relayer_refund_root" ADD "finalised" boolean NOT NULL`, | ||
); | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."tokens_bridged" ADD "finalised" boolean NOT NULL`, | ||
); | ||
} | ||
|
||
public async down(queryRunner: QueryRunner): Promise<void> { | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."tokens_bridged" DROP COLUMN "finalised"`, | ||
); | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."executed_relayer_refund_root" DROP COLUMN "finalised"`, | ||
); | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."relayed_root_bundle" DROP COLUMN "finalised"`, | ||
); | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."requested_speed_up_v3_deposit" DROP COLUMN "finalised"`, | ||
); | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."requested_v3_slow_fill" DROP COLUMN "finalised"`, | ||
); | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."filled_v3_relay" DROP COLUMN "finalised"`, | ||
); | ||
await queryRunner.query( | ||
`ALTER TABLE "evm"."v3_funds_deposited" DROP COLUMN "finalised"`, | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.