All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
- Data migration on updating relayer:
$ ./util/update/update.sh
This replaces all previous update steps!
- Run
node lib/data_migrations/2021-12-14-empty-blocks.js
to reindex all historical empty blocks.
$ cd migrations
$ goose postgres "user=<USERNAME> password=<PASSWORD> dbname=aurora sslmode=disable" up
A new column from
was added into the event
table. Check out this PR #120 for more info.
To update the event
table, execute:
- Create
from
column:
$ cd migrations
$ goose postgres "user=<USERNAME> password=<PASSWORD> dbname=aurora sslmode=disable" up-to 20211208103001
- Run
node lib/data_migrations/2021-12-02-event.js
to reindex all historical events. - Set
from
column toNOT NULL
:
$ cd migrations
$ goose postgres "user=<USERNAME> password=<PASSWORD> dbname=aurora sslmode=disable" up-to 20211208110338
- Finally check the status of the migration:
goose postgres "user=<USERNAME> password=<PASSWORD> dbname=aurora sslmode=disable" status
New table to handle subscriptions. To update your existing schema, execute:
CREATE TABLE subscription (
sec_websocket_key varchar COLLATE "default",
id varchar COLLATE "default",
type varchar COLLATE "default",
ip varchar COLLATE "default",
filter jsonb NULL
);
CREATE UNIQUE INDEX subscription_sec_websocket_key_type_filter_index_idx ON subscription (sec_websocket_key, type, filter);
Stored procedure needs to be reloaded Issue #133
etc/schema/functions/eth_getTransactionReceipt.sql
Some schema changes were necessary in order to be able to index prehistory. To update your existing schema, execute:
ALTER TABLE block ALTER COLUMN near_hash DROP NOT NULL;
ALTER TABLE block ALTER COLUMN timestamp DROP NOT NULL;
ALTER DOMAIN instant DROP CONSTRAINT instant_check;
ALTER DOMAIN instant ADD CONSTRAINT instant_check CHECK (value = timestamptz '1970-01-01T00:00:00Z' OR value > timestamptz '2015-07-30T00:00:00Z');
In addition, reload the following stored procedures:
etc/schema/functions/eth_getBlockByNumber.sql