new natural primary key scheme

This commit is contained in:
i-norden 2021-11-14 18:06:02 -06:00
parent 075a790dfc
commit 7cc9201a94
20 changed files with 432 additions and 730 deletions

View File

@ -0,0 +1,91 @@
-- +goose Up
-- log indexes
DROP INDEX eth.log_topic3_index;
DROP INDEX eth.log_topic2_index;
DROP INDEX eth.log_topic1_index;
DROP INDEX eth.log_topic0_index;
DROP INDEX eth.log_address_index;
DROP INDEX eth.log_cid_index;
-- access list indexes
DROP INDEX eth.access_list_storage_keys_index;
DROP INDEX eth.access_list_element_address_index;
-- state account indexes
DROP INDEX eth.storage_root_index;
DROP index eth.account_state_path_index;
-- storage node indexes
DROP INDEX eth.storage_node_type_index;
DROP INDEX eth.storage_path_index;
DROP INDEX eth.storage_cid_index;
DROP INDEX eth.storage_leaf_key_index;
DROP INDEX eth.storage_state_path_index;
-- state node indexes
DROP INDEX eth.state_node_type_index;
DROP INDEX eth.state_path_index;
DROP INDEX eth.state_cid_index;
DROP INDEX eth.state_leaf_key_index;
-- receipt indexes
DROP INDEX eth.rct_contract_hash_index;
DROP INDEX eth.rct_contract_index;
DROP INDEX eth.rct_leaf_cid_index;
-- transaction indexes
DROP INDEX eth.tx_src_index;
DROP INDEX eth.tx_dst_index;
DROP INDEX eth.tx_cid_index;
-- header indexes
DROP INDEX eth.timestamp_index;
DROP INDEX eth.state_root_index;
DROP INDEX eth.header_cid_index;
DROP INDEX eth.block_number_index;
-- +goose Down
-- header indexes
CREATE INDEX block_number_index ON eth.header_cids USING brin (block_number);
CREATE INDEX header_cid_index ON eth.header_cids USING btree (cid);
CREATE INDEX state_root_index ON eth.header_cids USING btree (state_root);
CREATE INDEX timestamp_index ON eth.header_cids USING brin (timestamp);
-- transaction indexes
CREATE INDEX tx_cid_index ON eth.transaction_cids USING btree (cid);
CREATE INDEX tx_dst_index ON eth.transaction_cids USING btree (dst);
CREATE INDEX tx_src_index ON eth.transaction_cids USING btree (src);
-- receipt indexes
CREATE INDEX rct_leaf_cid_index ON eth.receipt_cids USING btree (leaf_cid);
CREATE INDEX rct_contract_index ON eth.receipt_cids USING btree (contract);
CREATE INDEX rct_contract_hash_index ON eth.receipt_cids USING btree (contract_hash);
-- state node indexes
CREATE INDEX state_leaf_key_index ON eth.state_cids USING btree (state_leaf_key);
CREATE INDEX state_cid_index ON eth.state_cids USING btree (cid);
CREATE INDEX state_path_index ON eth.state_cids USING btree (state_path);
CREATE INDEX state_node_type_index ON eth.state_cids USING btree (node_type);
-- storage node indexes
CREATE INDEX storage_state_path_index ON eth.storage_cids USING btree (state_path);
CREATE INDEX storage_leaf_key_index ON eth.storage_cids USING btree (storage_leaf_key);
CREATE INDEX storage_cid_index ON eth.storage_cids USING btree (cid);
CREATE INDEX storage_path_index ON eth.storage_cids USING btree (storage_path);
CREATE INDEX storage_node_type_index ON eth.storage_cids USING btree (node_type);
-- state accounts indexes
CREATE INDEX account_state_path_index ON eth.state_accounts USING btree (state_path);
CREATE INDEX storage_root_index ON eth.state_accounts USING btree (storage_root);
-- access list indexes
CREATE INDEX access_list_element_address_index ON eth.access_list_element USING btree (address);
CREATE INDEX access_list_storage_keys_index ON eth.access_list_element USING gin (storage_keys);
-- log indexes
CREATE INDEX log_cid_index ON eth.log_cids USING btree (leaf_cid);
CREATE INDEX log_address_index ON eth.log_cids USING btree (address);
CREATE INDEX log_topic0_index ON eth.log_cids USING btree (topic0);
CREATE INDEX log_topic1_index ON eth.log_cids USING btree (topic1);
CREATE INDEX log_topic2_index ON eth.log_cids USING btree (topic2);
CREATE INDEX log_topic3_index ON eth.log_cids USING btree (topic3);

View File

@ -1,6 +1,6 @@
-- +goose Up
CREATE TABLE IF NOT EXISTS public.blocks (
key TEXT UNIQUE NOT NULL,
key TEXT PRIMARY KEY,
data BYTEA NOT NULL
);

View File

@ -1,24 +1,22 @@
-- +goose Up
CREATE TABLE eth.header_cids (
id SERIAL PRIMARY KEY,
block_number BIGINT NOT NULL,
block_hash VARCHAR(66) NOT NULL,
parent_hash VARCHAR(66) NOT NULL,
cid TEXT NOT NULL,
mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
td NUMERIC NOT NULL,
node_id INTEGER NOT NULL REFERENCES nodes (id) ON DELETE CASCADE,
reward NUMERIC NOT NULL,
state_root VARCHAR(66) NOT NULL,
tx_root VARCHAR(66) NOT NULL,
receipt_root VARCHAR(66) NOT NULL,
uncle_root VARCHAR(66) NOT NULL,
bloom BYTEA NOT NULL,
timestamp NUMERIC NOT NULL,
times_validated INTEGER NOT NULL DEFAULT 1,
base_fee BIGINT,
UNIQUE (block_number, block_hash)
block_hash VARCHAR(66) PRIMARY KEY,
block_number BIGINT NOT NULL,
parent_hash VARCHAR(66) NOT NULL,
cid TEXT NOT NULL,
mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
td NUMERIC NOT NULL,
node_id INTEGER NOT NULL REFERENCES nodes (id) ON DELETE CASCADE,
reward NUMERIC NOT NULL,
state_root VARCHAR(66) NOT NULL,
tx_root VARCHAR(66) NOT NULL,
receipt_root VARCHAR(66) NOT NULL,
uncle_root VARCHAR(66) NOT NULL,
bloom BYTEA NOT NULL,
timestamp NUMERIC NOT NULL,
times_validated INTEGER NOT NULL DEFAULT 1,
base_fee BIGINT
);
-- +goose Down
DROP TABLE eth.header_cids;
DROP TABLE eth.header_cids;

View File

@ -1,14 +1,12 @@
-- +goose Up
CREATE TABLE eth.uncle_cids (
id SERIAL PRIMARY KEY,
header_id INTEGER NOT NULL REFERENCES eth.header_cids (id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
block_hash VARCHAR(66) NOT NULL,
parent_hash VARCHAR(66) NOT NULL,
cid TEXT NOT NULL,
mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
reward NUMERIC NOT NULL,
UNIQUE (header_id, block_hash)
block_hash VARCHAR(66) PRIMARY KEY,
header_id VARCHAR(66) NOT NULL REFERENCES eth.header_cids (block_hash) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
parent_hash VARCHAR(66) NOT NULL,
cid TEXT NOT NULL,
mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
reward NUMERIC NOT NULL
);
-- +goose Down
DROP TABLE eth.uncle_cids;
DROP TABLE eth.uncle_cids;

View File

@ -1,16 +1,14 @@
-- +goose Up
CREATE TABLE eth.transaction_cids (
id SERIAL PRIMARY KEY,
header_id INTEGER NOT NULL REFERENCES eth.header_cids (id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
tx_hash VARCHAR(66) NOT NULL,
index INTEGER NOT NULL,
cid TEXT NOT NULL,
mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
dst VARCHAR(66) NOT NULL,
src VARCHAR(66) NOT NULL,
tx_data BYTEA,
tx_type BYTEA,
UNIQUE (header_id, tx_hash)
tx_hash VARCHAR(66) PRIMARY KEY,
header_id VARCHAR(66) NOT NULL REFERENCES eth.header_cids (block_hash) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
index INTEGER NOT NULL,
cid TEXT NOT NULL,
mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
dst VARCHAR(66) NOT NULL,
src VARCHAR(66) NOT NULL,
tx_data BYTEA,
tx_type INTEGER
);
-- +goose Down

View File

@ -1,16 +1,14 @@
-- +goose Up
CREATE TABLE eth.receipt_cids (
id SERIAL PRIMARY KEY,
tx_id INTEGER NOT NULL REFERENCES eth.transaction_cids (id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
leaf_cid TEXT NOT NULL,
leaf_mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
contract VARCHAR(66),
contract_hash VARCHAR(66),
post_state VARCHAR(66),
post_status INTEGER,
log_root VARCHAR(66),
UNIQUE (tx_id)
tx_id VARCHAR(66) PRIMARY KEY REFERENCES eth.transaction_cids (tx_hash) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
leaf_cid TEXT NOT NULL,
leaf_mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
contract VARCHAR(66),
contract_hash VARCHAR(66),
post_state VARCHAR(66),
post_status INTEGER,
log_root VARCHAR(66)
);
-- +goose Down
DROP TABLE eth.receipt_cids;
DROP TABLE eth.receipt_cids;

View File

@ -1,15 +1,14 @@
-- +goose Up
CREATE TABLE eth.state_cids (
id BIGSERIAL PRIMARY KEY,
header_id INTEGER NOT NULL REFERENCES eth.header_cids (id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
state_leaf_key VARCHAR(66),
cid TEXT NOT NULL,
mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
state_path BYTEA,
node_type INTEGER NOT NULL,
diff BOOLEAN NOT NULL DEFAULT FALSE,
UNIQUE (header_id, state_path)
header_id VARCHAR(66) NOT NULL REFERENCES eth.header_cids (block_hash) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
state_leaf_key VARCHAR(66),
cid TEXT NOT NULL,
mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
state_path BYTEA NOT NULL,
node_type INTEGER NOT NULL,
diff BOOLEAN NOT NULL DEFAULT FALSE,
PRIMARY KEY (header_id, state_path)
);
-- +goose Down
DROP TABLE eth.state_cids;
DROP TABLE eth.state_cids;

View File

@ -1,15 +1,16 @@
-- +goose Up
CREATE TABLE eth.storage_cids (
id BIGSERIAL PRIMARY KEY,
state_id BIGINT NOT NULL REFERENCES eth.state_cids (id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
storage_leaf_key VARCHAR(66),
cid TEXT NOT NULL,
mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
storage_path BYTEA,
node_type INTEGER NOT NULL,
diff BOOLEAN NOT NULL DEFAULT FALSE,
UNIQUE (state_id, storage_path)
header_id VARCHAR(66) NOT NULL,
state_path BYTEA NOT NULL,
storage_leaf_key VARCHAR(66),
cid TEXT NOT NULL,
mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
storage_path BYTEA NOT NULL,
node_type INTEGER NOT NULL,
diff BOOLEAN NOT NULL DEFAULT FALSE,
FOREIGN KEY (header_id, state_path) REFERENCES eth.state_cids (header_id, state_path) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
PRIMARY KEY (header_id, state_path, storage_path)
);
-- +goose Down
DROP TABLE eth.storage_cids;
DROP TABLE eth.storage_cids;

View File

@ -1,13 +1,14 @@
-- +goose Up
CREATE TABLE eth.state_accounts (
id SERIAL PRIMARY KEY,
state_id BIGINT NOT NULL REFERENCES eth.state_cids (id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
balance NUMERIC NOT NULL,
nonce INTEGER NOT NULL,
code_hash BYTEA NOT NULL,
storage_root VARCHAR(66) NOT NULL,
UNIQUE (state_id)
header_id VARCHAR(66) NOT NULL,
state_path BYTEA NOT NULL,
balance NUMERIC NOT NULL,
nonce INTEGER NOT NULL,
code_hash BYTEA NOT NULL,
storage_root VARCHAR(66) NOT NULL,
FOREIGN KEY (header_id, state_path) REFERENCES eth.state_cids (header_id, state_path) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
PRIMARY KEY (header_id, state_path)
);
-- +goose Down
DROP TABLE eth.state_accounts;
DROP TABLE eth.state_accounts;

View File

@ -0,0 +1,11 @@
-- +goose Up
CREATE TABLE eth.access_list_element (
tx_id VARCHAR(66) NOT NULL REFERENCES eth.transaction_cids (tx_hash) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
index INTEGER NOT NULL,
address VARCHAR(66),
storage_keys VARCHAR(66)[],
PRIMARY KEY (tx_id, index)
);
-- +goose Down
DROP TABLE eth.access_list_element;

View File

@ -0,0 +1,18 @@
-- +goose Up
CREATE TABLE eth.log_cids (
rct_id VARCHAR(66) NOT NULL REFERENCES eth.receipt_cids (tx_id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
leaf_cid TEXT NOT NULL,
leaf_mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
address VARCHAR(66) NOT NULL,
log_data BYTEA,
index INTEGER NOT NULL,
topic0 VARCHAR(66),
topic1 VARCHAR(66),
topic2 VARCHAR(66),
topic3 VARCHAR(66),
PRIMARY KEY (rct_id, index)
);
-- +goose Down
-- log indexes
DROP TABLE eth.log_cids;

View File

@ -1,76 +1,76 @@
-- +goose Up
-- header indexes
CREATE INDEX block_number_index ON eth.header_cids USING brin (block_number);
CREATE INDEX block_hash_index ON eth.header_cids USING btree (block_hash);
CREATE INDEX header_cid_index ON eth.header_cids USING btree (cid);
CREATE INDEX header_mh_index ON eth.header_cids USING btree (mh_key);
CREATE INDEX state_root_index ON eth.header_cids USING btree (state_root);
CREATE INDEX timestamp_index ON eth.header_cids USING brin (timestamp);
-- uncle indexes
CREATE INDEX uncle_header_id_index ON eth.uncle_cids USING btree (header_id);
-- transaction indexes
CREATE INDEX tx_header_id_index ON eth.transaction_cids USING btree (header_id);
CREATE INDEX tx_hash_index ON eth.transaction_cids USING btree (tx_hash);
CREATE INDEX tx_cid_index ON eth.transaction_cids USING btree (cid);
CREATE INDEX tx_mh_index ON eth.transaction_cids USING btree (mh_key);
CREATE INDEX tx_dst_index ON eth.transaction_cids USING btree (dst);
CREATE INDEX tx_src_index ON eth.transaction_cids USING btree (src);
-- receipt indexes
CREATE INDEX rct_tx_id_index ON eth.receipt_cids USING btree (tx_id);
CREATE INDEX rct_leaf_cid_index ON eth.receipt_cids USING btree (leaf_cid);
CREATE INDEX rct_leaf_mh_index ON eth.receipt_cids USING btree (leaf_mh_key);
CREATE INDEX rct_contract_index ON eth.receipt_cids USING btree (contract);
CREATE INDEX rct_contract_hash_index ON eth.receipt_cids USING btree (contract_hash);
-- state node indexes
CREATE INDEX state_header_id_index ON eth.state_cids USING btree (header_id);
CREATE INDEX state_leaf_key_index ON eth.state_cids USING btree (state_leaf_key);
CREATE INDEX state_cid_index ON eth.state_cids USING btree (cid);
CREATE INDEX state_mh_index ON eth.state_cids USING btree (mh_key);
CREATE INDEX state_path_index ON eth.state_cids USING btree (state_path);
CREATE INDEX state_node_type_index ON eth.state_cids USING btree (node_type);
-- storage node indexes
CREATE INDEX storage_state_id_index ON eth.storage_cids USING btree (state_id);
CREATE INDEX storage_state_path_index ON eth.storage_cids USING btree (state_path);
CREATE INDEX storage_leaf_key_index ON eth.storage_cids USING btree (storage_leaf_key);
CREATE INDEX storage_cid_index ON eth.storage_cids USING btree (cid);
CREATE INDEX storage_mh_index ON eth.storage_cids USING btree (mh_key);
CREATE INDEX storage_path_index ON eth.storage_cids USING btree (storage_path);
CREATE INDEX storage_node_type_index ON eth.storage_cids USING btree (node_type);
-- state accounts indexes
CREATE INDEX account_state_id_index ON eth.state_accounts USING btree (state_id);
CREATE INDEX account_state_path_index ON eth.state_accounts USING btree (state_path);
CREATE INDEX storage_root_index ON eth.state_accounts USING btree (storage_root);
-- access list indexes
CREATE INDEX access_list_element_address_index ON eth.access_list_element USING btree (address);
CREATE INDEX access_list_storage_keys_index ON eth.access_list_element USING gin (storage_keys);
-- log indexes
CREATE INDEX log_mh_index ON eth.log_cids USING btree (leaf_mh_key);
CREATE INDEX log_cid_index ON eth.log_cids USING btree (leaf_cid);
CREATE INDEX log_address_index ON eth.log_cids USING btree (address);
CREATE INDEX log_topic0_index ON eth.log_cids USING btree (topic0);
CREATE INDEX log_topic1_index ON eth.log_cids USING btree (topic1);
CREATE INDEX log_topic2_index ON eth.log_cids USING btree (topic2);
CREATE INDEX log_topic3_index ON eth.log_cids USING btree (topic3);
-- +goose Down
-- log indexes
DROP INDEX eth.log_topic3_index;
DROP INDEX eth.log_topic2_index;
DROP INDEX eth.log_topic1_index;
DROP INDEX eth.log_topic0_index;
DROP INDEX eth.log_address_index;
DROP INDEX eth.log_cid_index;
DROP INDEX eth.log_mh_index;
-- access list indexes
DROP INDEX eth.access_list_storage_keys_index;
DROP INDEX eth.access_list_element_address_index;
-- state account indexes
DROP INDEX eth.storage_root_index;
DROP INDEX eth.account_state_id_index;
DROP index eth.account_state_path_index;
-- storage node indexes
DROP INDEX eth.storage_node_type_index;
@ -78,7 +78,7 @@ DROP INDEX eth.storage_path_index;
DROP INDEX eth.storage_mh_index;
DROP INDEX eth.storage_cid_index;
DROP INDEX eth.storage_leaf_key_index;
DROP INDEX eth.storage_state_id_index;
DROP INDEX eth.storage_state_path_index;
-- state node indexes
DROP INDEX eth.state_node_type_index;
@ -86,27 +86,26 @@ DROP INDEX eth.state_path_index;
DROP INDEX eth.state_mh_index;
DROP INDEX eth.state_cid_index;
DROP INDEX eth.state_leaf_key_index;
DROP INDEX eth.state_header_id_index;
-- receipt indexes
DROP INDEX eth.rct_contract_hash_index;
DROP INDEX eth.rct_contract_index;
DROP INDEX eth.rct_leaf_mh_index;
DROP INDEX eth.rct_leaf_cid_index;
DROP INDEX eth.rct_tx_id_index;
-- transaction indexes
DROP INDEX eth.tx_src_index;
DROP INDEX eth.tx_dst_index;
DROP INDEX eth.tx_mh_index;
DROP INDEX eth.tx_cid_index;
DROP INDEX eth.tx_hash_index;
DROP INDEX eth.tx_header_id_index;
-- uncle indexes
DROP INDEX eth.uncle_header_id_index;
-- header indexes
DROP INDEX eth.timestamp_index;
DROP INDEX eth.state_root_index;
DROP INDEX eth.header_mh_index;
DROP INDEX eth.header_cid_index;
DROP INDEX eth.block_hash_index;
DROP INDEX eth.block_number_index;
DROP INDEX eth.block_number_index;

View File

@ -1,15 +0,0 @@
-- +goose Up
CREATE TABLE eth.access_list_element (
id SERIAL PRIMARY KEY,
tx_id INTEGER NOT NULL REFERENCES eth.transaction_cids (id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
index INTEGER NOT NULL,
address VARCHAR(66),
storage_keys VARCHAR(66)[],
UNIQUE (tx_id, index)
);
CREATE INDEX accesss_list_element_address_index ON eth.access_list_element USING btree (address);
-- +goose Down
DROP INDEX eth.accesss_list_element_address_index;
DROP TABLE eth.access_list_element;

View File

@ -1,61 +0,0 @@
-- +goose Up
CREATE TABLE eth.log_cids (
id SERIAL PRIMARY KEY,
leaf_cid TEXT NOT NULL,
leaf_mh_key TEXT NOT NULL REFERENCES public.blocks (key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
receipt_id INTEGER NOT NULL REFERENCES eth.receipt_cids (id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
address VARCHAR(66) NOT NULL,
log_data BYTEA,
index INTEGER NOT NULL,
topic0 VARCHAR(66),
topic1 VARCHAR(66),
topic2 VARCHAR(66),
topic3 VARCHAR(66),
UNIQUE (receipt_id, index)
);
CREATE INDEX log_mh_index ON eth.log_cids USING btree (leaf_mh_key);
CREATE INDEX log_cid_index ON eth.log_cids USING btree (leaf_cid);
CREATE INDEX log_rct_id_index ON eth.log_cids USING btree (receipt_id);
--
-- Name: log_topic0_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX log_topic0_index ON eth.log_cids USING btree (topic0);
--
-- Name: log_topic1_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX log_topic1_index ON eth.log_cids USING btree (topic1);
--
-- Name: log_topic2_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX log_topic2_index ON eth.log_cids USING btree (topic2);
--
-- Name: log_topic3_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX log_topic3_index ON eth.log_cids USING btree (topic3);
-- +goose Down
-- log indexes
DROP INDEX eth.log_mh_index;
DROP INDEX eth.log_cid_index;
DROP INDEX eth.log_rct_id_index;
DROP INDEX eth.log_topic0_index;
DROP INDEX eth.log_topic1_index;
DROP INDEX eth.log_topic2_index;
DROP INDEX eth.log_topic3_index;
DROP TABLE eth.log_cids;

View File

@ -5,7 +5,7 @@ CREATE OR REPLACE FUNCTION was_state_leaf_removed(key character varying, hash ch
RETURNS boolean AS $$
SELECT state_cids.node_type = 3
FROM eth.state_cids
INNER JOIN eth.header_cids ON (state_cids.header_id = header_cids.id)
INNER JOIN eth.header_cids ON (state_cids.header_id = header_cids.block_hash)
WHERE state_leaf_key = key
AND block_number <= (SELECT block_number
FROM eth.header_cids
@ -135,4 +135,4 @@ DROP FUNCTION was_state_leaf_removed;
DROP FUNCTION canonical_header_id;
DROP FUNCTION canonical_header_from_array;
DROP FUNCTION has_child;
DROP TYPE child_result;
DROP TYPE child_result;

View File

@ -2,8 +2,8 @@
-- PostgreSQL database dump
--
-- Dumped from database version 10.12
-- Dumped by pg_dump version 14.0 (Ubuntu 14.0-1.pgdg20.04+1)
-- Dumped from database version 14beta3
-- Dumped by pg_dump version 14beta3
SET statement_timeout = 0;
SET lock_timeout = 0;
@ -25,14 +25,15 @@ CREATE SCHEMA eth;
SET default_tablespace = '';
SET default_table_access_method = heap;
--
-- Name: header_cids; Type: TABLE; Schema: eth; Owner: -
--
CREATE TABLE eth.header_cids (
id integer NOT NULL,
block_number bigint NOT NULL,
block_hash character varying(66) NOT NULL,
block_number bigint NOT NULL,
parent_hash character varying(66) NOT NULL,
cid text NOT NULL,
mh_key text NOT NULL,
@ -230,7 +231,7 @@ CREATE FUNCTION public.was_state_leaf_removed(key character varying, hash charac
AS $$
SELECT state_cids.node_type = 3
FROM eth.state_cids
INNER JOIN eth.header_cids ON (state_cids.header_id = header_cids.id)
INNER JOIN eth.header_cids ON (state_cids.header_id = header_cids.block_hash)
WHERE state_leaf_key = key
AND block_number <= (SELECT block_number
FROM eth.header_cids
@ -244,63 +245,21 @@ $$;
--
CREATE TABLE eth.access_list_element (
id integer NOT NULL,
tx_id integer NOT NULL,
tx_id character varying(66) NOT NULL,
index integer NOT NULL,
address character varying(66),
storage_keys character varying(66)[]
);
--
-- Name: access_list_element_id_seq; Type: SEQUENCE; Schema: eth; Owner: -
--
CREATE SEQUENCE eth.access_list_element_id_seq
AS integer
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
--
-- Name: access_list_element_id_seq; Type: SEQUENCE OWNED BY; Schema: eth; Owner: -
--
ALTER SEQUENCE eth.access_list_element_id_seq OWNED BY eth.access_list_element.id;
--
-- Name: header_cids_id_seq; Type: SEQUENCE; Schema: eth; Owner: -
--
CREATE SEQUENCE eth.header_cids_id_seq
AS integer
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
--
-- Name: header_cids_id_seq; Type: SEQUENCE OWNED BY; Schema: eth; Owner: -
--
ALTER SEQUENCE eth.header_cids_id_seq OWNED BY eth.header_cids.id;
--
-- Name: log_cids; Type: TABLE; Schema: eth; Owner: -
--
CREATE TABLE eth.log_cids (
id integer NOT NULL,
rct_id character varying(66) NOT NULL,
leaf_cid text NOT NULL,
leaf_mh_key text NOT NULL,
receipt_id integer NOT NULL,
address character varying(66) NOT NULL,
log_data bytea,
index integer NOT NULL,
@ -311,33 +270,12 @@ CREATE TABLE eth.log_cids (
);
--
-- Name: log_cids_id_seq; Type: SEQUENCE; Schema: eth; Owner: -
--
CREATE SEQUENCE eth.log_cids_id_seq
AS integer
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
--
-- Name: log_cids_id_seq; Type: SEQUENCE OWNED BY; Schema: eth; Owner: -
--
ALTER SEQUENCE eth.log_cids_id_seq OWNED BY eth.log_cids.id;
--
-- Name: receipt_cids; Type: TABLE; Schema: eth; Owner: -
--
CREATE TABLE eth.receipt_cids (
id integer NOT NULL,
tx_id integer NOT NULL,
tx_id character varying(66) NOT NULL,
leaf_cid text NOT NULL,
leaf_mh_key text NOT NULL,
contract character varying(66),
@ -348,33 +286,13 @@ CREATE TABLE eth.receipt_cids (
);
--
-- Name: receipt_cids_id_seq; Type: SEQUENCE; Schema: eth; Owner: -
--
CREATE SEQUENCE eth.receipt_cids_id_seq
AS integer
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
--
-- Name: receipt_cids_id_seq; Type: SEQUENCE OWNED BY; Schema: eth; Owner: -
--
ALTER SEQUENCE eth.receipt_cids_id_seq OWNED BY eth.receipt_cids.id;
--
-- Name: state_accounts; Type: TABLE; Schema: eth; Owner: -
--
CREATE TABLE eth.state_accounts (
id integer NOT NULL,
state_id bigint NOT NULL,
header_id character varying(66) NOT NULL,
state_path bytea NOT NULL,
balance numeric NOT NULL,
nonce integer NOT NULL,
code_hash bytea NOT NULL,
@ -382,111 +300,51 @@ CREATE TABLE eth.state_accounts (
);
--
-- Name: state_accounts_id_seq; Type: SEQUENCE; Schema: eth; Owner: -
--
CREATE SEQUENCE eth.state_accounts_id_seq
AS integer
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
--
-- Name: state_accounts_id_seq; Type: SEQUENCE OWNED BY; Schema: eth; Owner: -
--
ALTER SEQUENCE eth.state_accounts_id_seq OWNED BY eth.state_accounts.id;
--
-- Name: state_cids; Type: TABLE; Schema: eth; Owner: -
--
CREATE TABLE eth.state_cids (
id bigint NOT NULL,
header_id integer NOT NULL,
header_id character varying(66) NOT NULL,
state_leaf_key character varying(66),
cid text NOT NULL,
mh_key text NOT NULL,
state_path bytea,
state_path bytea NOT NULL,
node_type integer NOT NULL,
diff boolean DEFAULT false NOT NULL
);
--
-- Name: state_cids_id_seq; Type: SEQUENCE; Schema: eth; Owner: -
--
CREATE SEQUENCE eth.state_cids_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
--
-- Name: state_cids_id_seq; Type: SEQUENCE OWNED BY; Schema: eth; Owner: -
--
ALTER SEQUENCE eth.state_cids_id_seq OWNED BY eth.state_cids.id;
--
-- Name: storage_cids; Type: TABLE; Schema: eth; Owner: -
--
CREATE TABLE eth.storage_cids (
id bigint NOT NULL,
state_id bigint NOT NULL,
header_id character varying(66) NOT NULL,
state_path bytea NOT NULL,
storage_leaf_key character varying(66),
cid text NOT NULL,
mh_key text NOT NULL,
storage_path bytea,
storage_path bytea NOT NULL,
node_type integer NOT NULL,
diff boolean DEFAULT false NOT NULL
);
--
-- Name: storage_cids_id_seq; Type: SEQUENCE; Schema: eth; Owner: -
--
CREATE SEQUENCE eth.storage_cids_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
--
-- Name: storage_cids_id_seq; Type: SEQUENCE OWNED BY; Schema: eth; Owner: -
--
ALTER SEQUENCE eth.storage_cids_id_seq OWNED BY eth.storage_cids.id;
--
-- Name: transaction_cids; Type: TABLE; Schema: eth; Owner: -
--
CREATE TABLE eth.transaction_cids (
id integer NOT NULL,
header_id integer NOT NULL,
tx_hash character varying(66) NOT NULL,
header_id character varying(66) NOT NULL,
index integer NOT NULL,
cid text NOT NULL,
mh_key text NOT NULL,
dst character varying(66) NOT NULL,
src character varying(66) NOT NULL,
tx_data bytea,
tx_type bytea
tx_type integer
);
@ -497,34 +355,13 @@ CREATE TABLE eth.transaction_cids (
COMMENT ON TABLE eth.transaction_cids IS '@name EthTransactionCids';
--
-- Name: transaction_cids_id_seq; Type: SEQUENCE; Schema: eth; Owner: -
--
CREATE SEQUENCE eth.transaction_cids_id_seq
AS integer
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
--
-- Name: transaction_cids_id_seq; Type: SEQUENCE OWNED BY; Schema: eth; Owner: -
--
ALTER SEQUENCE eth.transaction_cids_id_seq OWNED BY eth.transaction_cids.id;
--
-- Name: uncle_cids; Type: TABLE; Schema: eth; Owner: -
--
CREATE TABLE eth.uncle_cids (
id integer NOT NULL,
header_id integer NOT NULL,
block_hash character varying(66) NOT NULL,
header_id character varying(66) NOT NULL,
parent_hash character varying(66) NOT NULL,
cid text NOT NULL,
mh_key text NOT NULL,
@ -532,26 +369,6 @@ CREATE TABLE eth.uncle_cids (
);
--
-- Name: uncle_cids_id_seq; Type: SEQUENCE; Schema: eth; Owner: -
--
CREATE SEQUENCE eth.uncle_cids_id_seq
AS integer
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
--
-- Name: uncle_cids_id_seq; Type: SEQUENCE OWNED BY; Schema: eth; Owner: -
--
ALTER SEQUENCE eth.uncle_cids_id_seq OWNED BY eth.uncle_cids.id;
--
-- Name: blocks; Type: TABLE; Schema: public; Owner: -
--
@ -642,69 +459,6 @@ CREATE SEQUENCE public.nodes_id_seq
ALTER SEQUENCE public.nodes_id_seq OWNED BY public.nodes.id;
--
-- Name: access_list_element id; Type: DEFAULT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.access_list_element ALTER COLUMN id SET DEFAULT nextval('eth.access_list_element_id_seq'::regclass);
--
-- Name: header_cids id; Type: DEFAULT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.header_cids ALTER COLUMN id SET DEFAULT nextval('eth.header_cids_id_seq'::regclass);
--
-- Name: log_cids id; Type: DEFAULT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.log_cids ALTER COLUMN id SET DEFAULT nextval('eth.log_cids_id_seq'::regclass);
--
-- Name: receipt_cids id; Type: DEFAULT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.receipt_cids ALTER COLUMN id SET DEFAULT nextval('eth.receipt_cids_id_seq'::regclass);
--
-- Name: state_accounts id; Type: DEFAULT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.state_accounts ALTER COLUMN id SET DEFAULT nextval('eth.state_accounts_id_seq'::regclass);
--
-- Name: state_cids id; Type: DEFAULT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.state_cids ALTER COLUMN id SET DEFAULT nextval('eth.state_cids_id_seq'::regclass);
--
-- Name: storage_cids id; Type: DEFAULT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.storage_cids ALTER COLUMN id SET DEFAULT nextval('eth.storage_cids_id_seq'::regclass);
--
-- Name: transaction_cids id; Type: DEFAULT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.transaction_cids ALTER COLUMN id SET DEFAULT nextval('eth.transaction_cids_id_seq'::regclass);
--
-- Name: uncle_cids id; Type: DEFAULT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.uncle_cids ALTER COLUMN id SET DEFAULT nextval('eth.uncle_cids_id_seq'::regclass);
--
-- Name: goose_db_version id; Type: DEFAULT; Schema: public; Owner: -
--
@ -724,23 +478,7 @@ ALTER TABLE ONLY public.nodes ALTER COLUMN id SET DEFAULT nextval('public.nodes_
--
ALTER TABLE ONLY eth.access_list_element
ADD CONSTRAINT access_list_element_pkey PRIMARY KEY (id);
--
-- Name: access_list_element access_list_element_tx_id_index_key; Type: CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.access_list_element
ADD CONSTRAINT access_list_element_tx_id_index_key UNIQUE (tx_id, index);
--
-- Name: header_cids header_cids_block_number_block_hash_key; Type: CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.header_cids
ADD CONSTRAINT header_cids_block_number_block_hash_key UNIQUE (block_number, block_hash);
ADD CONSTRAINT access_list_element_pkey PRIMARY KEY (tx_id, index);
--
@ -748,7 +486,7 @@ ALTER TABLE ONLY eth.header_cids
--
ALTER TABLE ONLY eth.header_cids
ADD CONSTRAINT header_cids_pkey PRIMARY KEY (id);
ADD CONSTRAINT header_cids_pkey PRIMARY KEY (block_hash);
--
@ -756,15 +494,7 @@ ALTER TABLE ONLY eth.header_cids
--
ALTER TABLE ONLY eth.log_cids
ADD CONSTRAINT log_cids_pkey PRIMARY KEY (id);
--
-- Name: log_cids log_cids_receipt_id_index_key; Type: CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.log_cids
ADD CONSTRAINT log_cids_receipt_id_index_key UNIQUE (receipt_id, index);
ADD CONSTRAINT log_cids_pkey PRIMARY KEY (rct_id, index);
--
@ -772,15 +502,7 @@ ALTER TABLE ONLY eth.log_cids
--
ALTER TABLE ONLY eth.receipt_cids
ADD CONSTRAINT receipt_cids_pkey PRIMARY KEY (id);
--
-- Name: receipt_cids receipt_cids_tx_id_key; Type: CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.receipt_cids
ADD CONSTRAINT receipt_cids_tx_id_key UNIQUE (tx_id);
ADD CONSTRAINT receipt_cids_pkey PRIMARY KEY (tx_id);
--
@ -788,23 +510,7 @@ ALTER TABLE ONLY eth.receipt_cids
--
ALTER TABLE ONLY eth.state_accounts
ADD CONSTRAINT state_accounts_pkey PRIMARY KEY (id);
--
-- Name: state_accounts state_accounts_state_id_key; Type: CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.state_accounts
ADD CONSTRAINT state_accounts_state_id_key UNIQUE (state_id);
--
-- Name: state_cids state_cids_header_id_state_path_key; Type: CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.state_cids
ADD CONSTRAINT state_cids_header_id_state_path_key UNIQUE (header_id, state_path);
ADD CONSTRAINT state_accounts_pkey PRIMARY KEY (header_id, state_path);
--
@ -812,7 +518,7 @@ ALTER TABLE ONLY eth.state_cids
--
ALTER TABLE ONLY eth.state_cids
ADD CONSTRAINT state_cids_pkey PRIMARY KEY (id);
ADD CONSTRAINT state_cids_pkey PRIMARY KEY (header_id, state_path);
--
@ -820,23 +526,7 @@ ALTER TABLE ONLY eth.state_cids
--
ALTER TABLE ONLY eth.storage_cids
ADD CONSTRAINT storage_cids_pkey PRIMARY KEY (id);
--
-- Name: storage_cids storage_cids_state_id_storage_path_key; Type: CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.storage_cids
ADD CONSTRAINT storage_cids_state_id_storage_path_key UNIQUE (state_id, storage_path);
--
-- Name: transaction_cids transaction_cids_header_id_tx_hash_key; Type: CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.transaction_cids
ADD CONSTRAINT transaction_cids_header_id_tx_hash_key UNIQUE (header_id, tx_hash);
ADD CONSTRAINT storage_cids_pkey PRIMARY KEY (header_id, state_path, storage_path);
--
@ -844,15 +534,7 @@ ALTER TABLE ONLY eth.transaction_cids
--
ALTER TABLE ONLY eth.transaction_cids
ADD CONSTRAINT transaction_cids_pkey PRIMARY KEY (id);
--
-- Name: uncle_cids uncle_cids_header_id_block_hash_key; Type: CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.uncle_cids
ADD CONSTRAINT uncle_cids_header_id_block_hash_key UNIQUE (header_id, block_hash);
ADD CONSTRAINT transaction_cids_pkey PRIMARY KEY (tx_hash);
--
@ -860,15 +542,15 @@ ALTER TABLE ONLY eth.uncle_cids
--
ALTER TABLE ONLY eth.uncle_cids
ADD CONSTRAINT uncle_cids_pkey PRIMARY KEY (id);
ADD CONSTRAINT uncle_cids_pkey PRIMARY KEY (block_hash);
--
-- Name: blocks blocks_key_key; Type: CONSTRAINT; Schema: public; Owner: -
-- Name: blocks blocks_pkey; Type: CONSTRAINT; Schema: public; Owner: -
--
ALTER TABLE ONLY public.blocks
ADD CONSTRAINT blocks_key_key UNIQUE (key);
ADD CONSTRAINT blocks_pkey PRIMARY KEY (key);
--
@ -896,24 +578,24 @@ ALTER TABLE ONLY public.nodes
--
-- Name: accesss_list_element_address_index; Type: INDEX; Schema: eth; Owner: -
-- Name: access_list_element_address_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX accesss_list_element_address_index ON eth.access_list_element USING btree (address);
CREATE INDEX access_list_element_address_index ON eth.access_list_element USING btree (address);
--
-- Name: account_state_id_index; Type: INDEX; Schema: eth; Owner: -
-- Name: access_list_storage_keys_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX account_state_id_index ON eth.state_accounts USING btree (state_id);
CREATE INDEX access_list_storage_keys_index ON eth.access_list_element USING gin (storage_keys);
--
-- Name: block_hash_index; Type: INDEX; Schema: eth; Owner: -
-- Name: account_state_path_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX block_hash_index ON eth.header_cids USING btree (block_hash);
CREATE INDEX account_state_path_index ON eth.state_accounts USING btree (state_path);
--
@ -937,6 +619,13 @@ CREATE INDEX header_cid_index ON eth.header_cids USING btree (cid);
CREATE INDEX header_mh_index ON eth.header_cids USING btree (mh_key);
--
-- Name: log_address_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX log_address_index ON eth.log_cids USING btree (address);
--
-- Name: log_cid_index; Type: INDEX; Schema: eth; Owner: -
--
@ -951,13 +640,6 @@ CREATE INDEX log_cid_index ON eth.log_cids USING btree (leaf_cid);
CREATE INDEX log_mh_index ON eth.log_cids USING btree (leaf_mh_key);
--
-- Name: log_rct_id_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX log_rct_id_index ON eth.log_cids USING btree (receipt_id);
--
-- Name: log_topic0_index; Type: INDEX; Schema: eth; Owner: -
--
@ -1014,13 +696,6 @@ CREATE INDEX rct_leaf_cid_index ON eth.receipt_cids USING btree (leaf_cid);
CREATE INDEX rct_leaf_mh_index ON eth.receipt_cids USING btree (leaf_mh_key);
--
-- Name: rct_tx_id_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX rct_tx_id_index ON eth.receipt_cids USING btree (tx_id);
--
-- Name: state_cid_index; Type: INDEX; Schema: eth; Owner: -
--
@ -1028,13 +703,6 @@ CREATE INDEX rct_tx_id_index ON eth.receipt_cids USING btree (tx_id);
CREATE INDEX state_cid_index ON eth.state_cids USING btree (cid);
--
-- Name: state_header_id_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX state_header_id_index ON eth.state_cids USING btree (header_id);
--
-- Name: state_leaf_key_index; Type: INDEX; Schema: eth; Owner: -
--
@ -1113,10 +781,10 @@ CREATE INDEX storage_root_index ON eth.state_accounts USING btree (storage_root)
--
-- Name: storage_state_id_index; Type: INDEX; Schema: eth; Owner: -
-- Name: storage_state_path_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX storage_state_id_index ON eth.storage_cids USING btree (state_id);
CREATE INDEX storage_state_path_index ON eth.storage_cids USING btree (state_path);
--
@ -1140,13 +808,6 @@ CREATE INDEX tx_cid_index ON eth.transaction_cids USING btree (cid);
CREATE INDEX tx_dst_index ON eth.transaction_cids USING btree (dst);
--
-- Name: tx_hash_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX tx_hash_index ON eth.transaction_cids USING btree (tx_hash);
--
-- Name: tx_header_id_index; Type: INDEX; Schema: eth; Owner: -
--
@ -1168,53 +829,60 @@ CREATE INDEX tx_mh_index ON eth.transaction_cids USING btree (mh_key);
CREATE INDEX tx_src_index ON eth.transaction_cids USING btree (src);
--
-- Name: uncle_header_id_index; Type: INDEX; Schema: eth; Owner: -
--
CREATE INDEX uncle_header_id_index ON eth.uncle_cids USING btree (header_id);
--
-- Name: header_cids header_cids_ai; Type: TRIGGER; Schema: eth; Owner: -
--
CREATE TRIGGER header_cids_ai AFTER INSERT ON eth.header_cids FOR EACH ROW EXECUTE PROCEDURE eth.graphql_subscription('header_cids', 'id');
CREATE TRIGGER header_cids_ai AFTER INSERT ON eth.header_cids FOR EACH ROW EXECUTE FUNCTION eth.graphql_subscription('header_cids', 'id');
--
-- Name: receipt_cids receipt_cids_ai; Type: TRIGGER; Schema: eth; Owner: -
--
CREATE TRIGGER receipt_cids_ai AFTER INSERT ON eth.receipt_cids FOR EACH ROW EXECUTE PROCEDURE eth.graphql_subscription('receipt_cids', 'id');
CREATE TRIGGER receipt_cids_ai AFTER INSERT ON eth.receipt_cids FOR EACH ROW EXECUTE FUNCTION eth.graphql_subscription('receipt_cids', 'id');
--
-- Name: state_accounts state_accounts_ai; Type: TRIGGER; Schema: eth; Owner: -
--
CREATE TRIGGER state_accounts_ai AFTER INSERT ON eth.state_accounts FOR EACH ROW EXECUTE PROCEDURE eth.graphql_subscription('state_accounts', 'id');
CREATE TRIGGER state_accounts_ai AFTER INSERT ON eth.state_accounts FOR EACH ROW EXECUTE FUNCTION eth.graphql_subscription('state_accounts', 'id');
--
-- Name: state_cids state_cids_ai; Type: TRIGGER; Schema: eth; Owner: -
--
CREATE TRIGGER state_cids_ai AFTER INSERT ON eth.state_cids FOR EACH ROW EXECUTE PROCEDURE eth.graphql_subscription('state_cids', 'id');
CREATE TRIGGER state_cids_ai AFTER INSERT ON eth.state_cids FOR EACH ROW EXECUTE FUNCTION eth.graphql_subscription('state_cids', 'id');
--
-- Name: storage_cids storage_cids_ai; Type: TRIGGER; Schema: eth; Owner: -
--
CREATE TRIGGER storage_cids_ai AFTER INSERT ON eth.storage_cids FOR EACH ROW EXECUTE PROCEDURE eth.graphql_subscription('storage_cids', 'id');
CREATE TRIGGER storage_cids_ai AFTER INSERT ON eth.storage_cids FOR EACH ROW EXECUTE FUNCTION eth.graphql_subscription('storage_cids', 'id');
--
-- Name: transaction_cids transaction_cids_ai; Type: TRIGGER; Schema: eth; Owner: -
--
CREATE TRIGGER transaction_cids_ai AFTER INSERT ON eth.transaction_cids FOR EACH ROW EXECUTE PROCEDURE eth.graphql_subscription('transaction_cids', 'id');
CREATE TRIGGER transaction_cids_ai AFTER INSERT ON eth.transaction_cids FOR EACH ROW EXECUTE FUNCTION eth.graphql_subscription('transaction_cids', 'id');
--
-- Name: uncle_cids uncle_cids_ai; Type: TRIGGER; Schema: eth; Owner: -
--
CREATE TRIGGER uncle_cids_ai AFTER INSERT ON eth.uncle_cids FOR EACH ROW EXECUTE PROCEDURE eth.graphql_subscription('uncle_cids', 'id');
CREATE TRIGGER uncle_cids_ai AFTER INSERT ON eth.uncle_cids FOR EACH ROW EXECUTE FUNCTION eth.graphql_subscription('uncle_cids', 'id');
--
@ -1222,7 +890,7 @@ CREATE TRIGGER uncle_cids_ai AFTER INSERT ON eth.uncle_cids FOR EACH ROW EXECUTE
--
ALTER TABLE ONLY eth.access_list_element
ADD CONSTRAINT access_list_element_tx_id_fkey FOREIGN KEY (tx_id) REFERENCES eth.transaction_cids(id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
ADD CONSTRAINT access_list_element_tx_id_fkey FOREIGN KEY (tx_id) REFERENCES eth.transaction_cids(tx_hash) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
--
@ -1250,11 +918,11 @@ ALTER TABLE ONLY eth.log_cids
--
-- Name: log_cids log_cids_receipt_id_fkey; Type: FK CONSTRAINT; Schema: eth; Owner: -
-- Name: log_cids log_cids_rct_id_fkey; Type: FK CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.log_cids
ADD CONSTRAINT log_cids_receipt_id_fkey FOREIGN KEY (receipt_id) REFERENCES eth.receipt_cids(id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
ADD CONSTRAINT log_cids_rct_id_fkey FOREIGN KEY (rct_id) REFERENCES eth.receipt_cids(tx_id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
--
@ -1270,15 +938,15 @@ ALTER TABLE ONLY eth.receipt_cids
--
ALTER TABLE ONLY eth.receipt_cids
ADD CONSTRAINT receipt_cids_tx_id_fkey FOREIGN KEY (tx_id) REFERENCES eth.transaction_cids(id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
ADD CONSTRAINT receipt_cids_tx_id_fkey FOREIGN KEY (tx_id) REFERENCES eth.transaction_cids(tx_hash) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
--
-- Name: state_accounts state_accounts_state_id_fkey; Type: FK CONSTRAINT; Schema: eth; Owner: -
-- Name: state_accounts state_accounts_header_id_state_path_fkey; Type: FK CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.state_accounts
ADD CONSTRAINT state_accounts_state_id_fkey FOREIGN KEY (state_id) REFERENCES eth.state_cids(id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
ADD CONSTRAINT state_accounts_header_id_state_path_fkey FOREIGN KEY (header_id, state_path) REFERENCES eth.state_cids(header_id, state_path) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
--
@ -1286,7 +954,7 @@ ALTER TABLE ONLY eth.state_accounts
--
ALTER TABLE ONLY eth.state_cids
ADD CONSTRAINT state_cids_header_id_fkey FOREIGN KEY (header_id) REFERENCES eth.header_cids(id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
ADD CONSTRAINT state_cids_header_id_fkey FOREIGN KEY (header_id) REFERENCES eth.header_cids(block_hash) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
--
@ -1297,6 +965,14 @@ ALTER TABLE ONLY eth.state_cids
ADD CONSTRAINT state_cids_mh_key_fkey FOREIGN KEY (mh_key) REFERENCES public.blocks(key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
--
-- Name: storage_cids storage_cids_header_id_state_path_fkey; Type: FK CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.storage_cids
ADD CONSTRAINT storage_cids_header_id_state_path_fkey FOREIGN KEY (header_id, state_path) REFERENCES eth.state_cids(header_id, state_path) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
--
-- Name: storage_cids storage_cids_mh_key_fkey; Type: FK CONSTRAINT; Schema: eth; Owner: -
--
@ -1305,20 +981,12 @@ ALTER TABLE ONLY eth.storage_cids
ADD CONSTRAINT storage_cids_mh_key_fkey FOREIGN KEY (mh_key) REFERENCES public.blocks(key) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
--
-- Name: storage_cids storage_cids_state_id_fkey; Type: FK CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.storage_cids
ADD CONSTRAINT storage_cids_state_id_fkey FOREIGN KEY (state_id) REFERENCES eth.state_cids(id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
--
-- Name: transaction_cids transaction_cids_header_id_fkey; Type: FK CONSTRAINT; Schema: eth; Owner: -
--
ALTER TABLE ONLY eth.transaction_cids
ADD CONSTRAINT transaction_cids_header_id_fkey FOREIGN KEY (header_id) REFERENCES eth.header_cids(id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
ADD CONSTRAINT transaction_cids_header_id_fkey FOREIGN KEY (header_id) REFERENCES eth.header_cids(block_hash) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
--
@ -1334,7 +1002,7 @@ ALTER TABLE ONLY eth.transaction_cids
--
ALTER TABLE ONLY eth.uncle_cids
ADD CONSTRAINT uncle_cids_header_id_fkey FOREIGN KEY (header_id) REFERENCES eth.header_cids(id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
ADD CONSTRAINT uncle_cids_header_id_fkey FOREIGN KEY (header_id) REFERENCES eth.header_cids(block_hash) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED;
--

Binary file not shown.

Before

Width:  |  Height:  |  Size: 493 KiB

After

Width:  |  Height:  |  Size: 494 KiB

View File

@ -1,150 +1,148 @@
<?xml version="1.0" encoding="UTF-8"?>
<Diagram>
<ID>DATABASE</ID>
<OriginalElement>763cb2dc-728a-4fbd-a163-94dd564429aa</OriginalElement>
<OriginalElement>7d32edb9-2bc3-46e6-9f18-0d9158833b0d</OriginalElement>
<nodes>
<node x="508.5625" y="998.0">763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.receipt_cids</node>
<node x="227.705078125" y="1282.0">763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.log_cids</node>
<node x="256.5" y="1031.0">763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.state_accounts</node>
<node x="156.705078125" y="712.0">763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.state_cids</node>
<node x="193.330078125" y="44.5">763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.public.blocks</node>
<node x="10.5" y="1009.0">763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.storage_cids</node>
<node x="547.375" y="723.0">763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.uncle_cids</node>
<node x="1146.375" y="0.0">763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.public.goose_db_version</node>
<node x="499.455078125" y="0.0">763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.public.nodes</node>
<node x="824.375" y="1042.0">763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.access_list_element</node>
<node x="614.5" y="228.0">763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.header_cids</node>
<node x="761.375" y="690.0">763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.transaction_cids</node>
<node x="294.34375" y="44.0">7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.public.blocks</node>
<node x="58.0" y="1216.0">7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.log_cids</node>
<node x="109.5" y="954.0">7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.receipt_cids</node>
<node x="835.84375" y="228.0">7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.header_cids</node>
<node x="336.5" y="954.0">7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.storage_cids</node>
<node x="776.81640625" y="690.0">7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.state_cids</node>
<node x="582.5" y="998.0">7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.access_list_element</node>
<node x="816.5" y="976.0">7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.state_accounts</node>
<node x="403.5" y="668.0">7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.transaction_cids</node>
<node x="1005.81640625" y="701.0">7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.uncle_cids</node>
<node x="1294.21875" y="0.0">7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.public.goose_db_version</node>
<node x="943.21875" y="0.0">7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.public.nodes</node>
</nodes>
<notes />
<edges>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.public.nodes" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.public.nodes" relationship="REFERENCES">
<point x="-76.5" y="83.0" />
<point x="575.955078125" y="151.63819095477388" />
<point x="532.3193997330402" y="151.63819095477388" />
<point x="532.3193997330402" y="83.0" />
<point x="-153.0" y="0.0" />
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.transaction_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.public.blocks" relationship="REFERENCES">
<point x="-85.0" y="-116.0" />
<point x="488.5" y="646.0" />
<point x="534.59375" y="646.0" />
<point x="534.59375" y="207.0" />
<point x="701.025390625" y="207.0" />
<point x="701.025390625" y="197.0" />
<point x="370.09375" y="197.0" />
<point x="25.25" y="39.0" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.uncle_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.header_cids" relationship="REFERENCES">
<point x="48.5" y="-94.0" />
<point x="692.875" y="668.0" />
<point x="756.0" y="668.0" />
<point x="0.0" y="204.0" />
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.state_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.header_cids" relationship="REFERENCES">
<point x="52.25" y="-94.0" />
<point x="933.56640625" y="646.0" />
<point x="977.34375" y="646.0" />
<point x="0.0" y="193.0" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.storage_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.public.blocks" relationship="REFERENCES">
<point x="-56.5" y="-105.0" />
<point x="67.0" y="971.0" />
<point x="111.205078125" y="971.0" />
<point x="111.205078125" y="207.0" />
<point x="502.875" y="207.0" />
<point x="502.875" y="197.0" />
<point x="269.080078125" y="197.0" />
<point x="25.25" y="38.5" />
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.uncle_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.public.blocks" relationship="REFERENCES">
<point x="48.5" y="-83.0" />
<point x="1151.31640625" y="646.0" />
<point x="1142.19140625" y="646.0" />
<point x="1142.19140625" y="207.0" />
<point x="701.025390625" y="207.0" />
<point x="701.025390625" y="197.0" />
<point x="370.09375" y="197.0" />
<point x="25.25" y="39.0" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.state_accounts" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.state_cids" relationship="REFERENCES">
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.state_accounts" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.state_cids" relationship="REFERENCES">
<point x="0.0" y="-83.0" />
<point x="355.0" y="971.0" />
<point x="261.205078125" y="971.0" />
<point x="0.0" y="105.0" />
<point x="915.0" y="922.0" />
<point x="881.31640625" y="922.0" />
<point x="0.0" y="94.0" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.uncle_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.public.blocks" relationship="REFERENCES">
<point x="-48.5" y="-94.0" />
<point x="595.875" y="658.0" />
<point x="589.25" y="658.0" />
<point x="589.25" y="207.0" />
<point x="502.875" y="207.0" />
<point x="502.875" y="197.0" />
<point x="269.080078125" y="197.0" />
<point x="25.25" y="38.5" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.storage_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.state_cids" relationship="REFERENCES">
<point x="56.5" y="-105.0" />
<point x="180.0" y="971.0" />
<point x="261.205078125" y="971.0" />
<point x="0.0" y="105.0" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.log_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.receipt_cids" relationship="REFERENCES">
<point x="41.0" y="-138.0" />
<point x="350.705078125" y="1256.0" />
<point x="612.0625" y="1256.0" />
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.receipt_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.transaction_cids" relationship="REFERENCES">
<point x="51.75" y="-105.0" />
<point x="264.75" y="932.0" />
<point x="573.5" y="932.0" />
<point x="0.0" y="116.0" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.header_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.public.blocks" relationship="REFERENCES">
<point x="-70.75" y="-204.0" />
<point x="685.25" y="207.0" />
<point x="502.875" y="207.0" />
<point x="502.875" y="197.0" />
<point x="269.080078125" y="197.0" />
<point x="25.25" y="38.5" />
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.log_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.public.blocks" relationship="REFERENCES">
<point x="-41.0" y="-127.0" />
<point x="99.0" y="197.0" />
<point x="319.59375" y="197.0" />
<point x="-25.25" y="39.0" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.state_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.header_cids" relationship="REFERENCES">
<point x="52.25" y="-105.0" />
<point x="313.455078125" y="668.0" />
<point x="756.0" y="668.0" />
<point x="0.0" y="204.0" />
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.storage_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.state_cids" relationship="REFERENCES">
<point x="56.5" y="-105.0" />
<point x="506.0" y="922.0" />
<point x="881.31640625" y="922.0" />
<point x="0.0" y="94.0" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.receipt_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.transaction_cids" relationship="REFERENCES">
<point x="51.75" y="-116.0" />
<point x="663.8125" y="971.0" />
<point x="931.375" y="971.0" />
<point x="0.0" y="127.0" />
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.receipt_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.public.blocks" relationship="REFERENCES">
<point x="-51.75" y="-105.0" />
<point x="161.25" y="207.0" />
<point x="99.0" y="207.0" />
<point x="99.0" y="197.0" />
<point x="319.59375" y="197.0" />
<point x="-25.25" y="39.0" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.transaction_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.public.blocks" relationship="REFERENCES">
<point x="85.0" y="-127.0" />
<point x="1016.375" y="668.0" />
<point x="923.3125" y="668.0" />
<point x="923.3125" y="207.0" />
<point x="502.875" y="207.0" />
<point x="502.875" y="197.0" />
<point x="269.080078125" y="197.0" />
<point x="25.25" y="38.5" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.receipt_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.public.blocks" relationship="REFERENCES">
<point x="-51.75" y="-116.0" />
<point x="560.3125" y="971.0" />
<point x="497.625" y="971.0" />
<point x="497.625" y="207.0" />
<point x="502.875" y="207.0" />
<point x="502.875" y="197.0" />
<point x="269.080078125" y="197.0" />
<point x="25.25" y="38.5" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.log_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.public.blocks" relationship="REFERENCES">
<point x="-41.0" y="-138.0" />
<point x="268.705078125" y="1256.0" />
<point x="0.0" y="1256.0" />
<point x="0.0" y="197.0" />
<point x="218.580078125" y="197.0" />
<point x="-25.25" y="38.5" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.transaction_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.header_cids" relationship="REFERENCES">
<point x="-85.0" y="-127.0" />
<point x="846.375" y="668.0" />
<point x="756.0" y="668.0" />
<point x="0.0" y="204.0" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.state_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.public.blocks" relationship="REFERENCES">
<point x="-52.25" y="-105.0" />
<point x="208.955078125" y="668.0" />
<point x="256.205078125" y="668.0" />
<point x="256.205078125" y="207.0" />
<point x="502.875" y="207.0" />
<point x="502.875" y="197.0" />
<point x="269.080078125" y="197.0" />
<point x="25.25" y="38.5" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.access_list_element" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.transaction_cids" relationship="REFERENCES">
<point x="0.0" y="-72.0" />
<point x="0.0" y="127.0" />
</edge>
<edge source="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.eth.header_cids" target="763cb2dc-728a-4fbd-a163-94dd564429aa.TABLE:vulcanize_testing.public.nodes" relationship="REFERENCES">
<point x="70.75" y="-204.0" />
<point x="826.75" y="197.0" />
<point x="728.955078125" y="197.0" />
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.header_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.public.nodes" relationship="REFERENCES">
<point x="70.75" y="-193.0" />
<point x="1048.09375" y="197.0" />
<point x="1172.71875" y="197.0" />
<point x="76.5" y="83.0" />
</edge>
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.access_list_element" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.transaction_cids" relationship="REFERENCES">
<point x="0.0" y="-61.0" />
<point x="689.5" y="932.0" />
<point x="573.5" y="932.0" />
<point x="0.0" y="116.0" />
</edge>
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.log_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.receipt_cids" relationship="REFERENCES">
<point x="41.0" y="-127.0" />
<point x="181.0" y="1190.0" />
<point x="213.0" y="1190.0" />
<point x="0.0" y="105.0" />
</edge>
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.header_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.public.blocks" relationship="REFERENCES">
<point x="-70.75" y="-193.0" />
<point x="906.59375" y="207.0" />
<point x="701.025390625" y="207.0" />
<point x="701.025390625" y="197.0" />
<point x="370.09375" y="197.0" />
<point x="25.25" y="39.0" />
</edge>
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.storage_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.public.blocks" relationship="REFERENCES">
<point x="-56.5" y="-105.0" />
<point x="393.0" y="922.0" />
<point x="346.123046875" y="922.0" />
<point x="346.123046875" y="207.0" />
<point x="701.025390625" y="207.0" />
<point x="701.025390625" y="197.0" />
<point x="370.09375" y="197.0" />
<point x="25.25" y="39.0" />
</edge>
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.transaction_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.header_cids" relationship="REFERENCES">
<point x="85.0" y="-116.0" />
<point x="658.5" y="646.0" />
<point x="977.34375" y="646.0" />
<point x="0.0" y="193.0" />
</edge>
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.public.nodes" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.public.nodes" relationship="REFERENCES">
<point x="-76.5" y="83.0" />
<point x="1019.71875" y="118.61306532663318" />
<point x="960.6559359296482" y="118.61306532663318" />
<point x="960.6559359296482" y="83.0" />
<point x="-153.0" y="-0.0" />
</edge>
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.uncle_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.header_cids" relationship="REFERENCES">
<point x="-48.5" y="-83.0" />
<point x="1054.31640625" y="646.0" />
<point x="977.34375" y="646.0" />
<point x="0.0" y="193.0" />
</edge>
<edge source="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.eth.state_cids" target="7d32edb9-2bc3-46e6-9f18-0d9158833b0d.TABLE:new_vulcanize_test.public.blocks" relationship="REFERENCES">
<point x="-52.25" y="-94.0" />
<point x="829.06640625" y="636.0" />
<point x="743.248046875" y="636.0" />
<point x="743.248046875" y="207.0" />
<point x="701.025390625" y="207.0" />
<point x="701.025390625" y="197.0" />
<point x="370.09375" y="197.0" />
<point x="25.25" y="39.0" />
</edge>
</edges>
<settings layout="Hierarchic" zoom="0.37832699619771865" showDependencies="false" x="667.5" y="779.0" />
<settings layout="Hierarchic" zoom="0.4006711409395973" showDependencies="false" x="741.5" y="735.0" />
<SelectedNodes />
<Categories>
<Category>Columns</Category>