Skip to content

Commit

Permalink
chore: update to [email protected] and [email protected]
Browse files Browse the repository at this point in the history
  • Loading branch information
rhyslbw committed Jun 15, 2021
1 parent 4127abd commit 8b3b718
Show file tree
Hide file tree
Showing 7 changed files with 34 additions and 33 deletions.
4 changes: 2 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ services:
max-size: "200k"
max-file: "10"
cardano-node:
image: inputoutput/cardano-node:${CARDANO_NODE_VERSION:-1.25.1}
image: inputoutput/cardano-node:${CARDANO_NODE_VERSION:-1.27.0}
command: [
"run",
"--config", "/config/config.json",
Expand All @@ -44,7 +44,7 @@ services:
max-size: "400k"
max-file: "20"
cardano-db-sync-extended:
image: inputoutput/cardano-db-sync:${CARDANO_DB_SYNC_VERSION:-9.0.0}
image: inputoutput/cardano-db-sync:${CARDANO_DB_SYNC_VERSION:-10.0.0}
command: [
"--config", "/config/cardano-db-sync/config.json",
"--socket-path", "/node-ipc/node.socket",
Expand Down
43 changes: 21 additions & 22 deletions packages/api-cardano-db-hasura/hasura/project/metadata/tables.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,6 @@
- fees
- forgedAt
- hash
- merkleRoot
- nextBlockHash
- number
- opCert
Expand Down Expand Up @@ -470,7 +469,7 @@
manual_configuration:
remote_table:
schema: public
name: pool_owner
name: StakePoolOwner
column_mapping:
hash_id: pool_hash_id
- name: relays
Expand Down Expand Up @@ -512,6 +511,26 @@
filter: {}
limit: 2500
allow_aggregations: true
- table:
schema: public
name: StakePoolOwner
object_relationships:
- name: stakePool
using:
manual_configuration:
remote_table:
schema: public
name: StakePool
column_mapping:
hash: hash
select_permissions:
- role: cardano-graphql
permission:
columns:
- hash
filter: {}
limit: 2500
allow_aggregations: true
- table:
schema: public
name: StakePoolRetirement
Expand Down Expand Up @@ -851,26 +870,6 @@
filter: {}
limit: 2500
allow_aggregations: true
- table:
schema: public
name: pool_owner
object_relationships:
- name: stakePool
using:
manual_configuration:
remote_table:
schema: public
name: StakePool
column_mapping:
pool_hash_id: hash_id
select_permissions:
- role: cardano-graphql
permission:
columns:
- hash
filter: {}
limit: 2500
allow_aggregations: true
- table:
schema: public
name: pool_relay
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ DROP VIEW IF EXISTS
"SlotLeader",
"StakeDeregistration",
"StakePool",
"StakePoolOwner",
"StakeRegistration",
"StakePoolRetirement",
"TokenMint",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ CREATE VIEW "Block" AS
FROM tx
WHERE (tx.block_id = block.id)), (0)::NUMERIC))::bigint AS fees,
block.hash,
block.merkle_root AS "merkleRoot",
block.block_no AS "number",
block.op_cert AS "opCert",
previous_block.hash AS "previousBlockHash",
Expand Down Expand Up @@ -147,20 +146,27 @@ SELECT
pool.hash_id AS "hash_id",
pool.id AS "update_id",
pool.margin AS "margin",
pool_meta_data.hash AS "metadataHash",
pool_metadata_ref.hash AS "metadataHash",
block.block_no AS "blockNo",
pool.registered_tx_id AS "updated_in_tx_id",
pool.pledge AS "pledge",
stake_address.view AS "rewardAddress",
pool_meta_data.url AS "url"
pool_metadata_ref.url AS "url"
FROM pool_update AS pool
LEFT JOIN pool_meta_data ON pool.meta_id = pool_meta_data.id
LEFT JOIN pool_metadata_ref ON pool.meta_id = pool_metadata_ref.id
INNER JOIN tx ON pool.registered_tx_id = tx.id
INNER JOIN latest_block_times ON latest_block_times.hash_id = pool.hash_id
INNER JOIN block ON tx.block_id = block.id AND latest_block_times.blockTime = block.time
JOIN stake_address on pool.reward_addr = stake_address.hash_raw
JOIN pool_hash on pool_hash.id = pool.hash_id;

CREATE VIEW "StakePoolOwner" AS
SELECT
stake_address.hash_raw as "hash",
pool_owner.pool_hash_id as "pool_hash_id"
FROM pool_owner
LEFT JOIN stake_address ON pool_owner.addr_id = stake_address.id;

CREATE VIEW "StakePoolRetirement" AS
SELECT
retiring_epoch as "inEffectFrom",
Expand Down
2 changes: 0 additions & 2 deletions packages/api-cardano-db-hasura/schema.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -1190,8 +1190,6 @@ type Block {
forgedAt: DateTime!
slotLeader: SlotLeader!
hash: Hash32Hex!
# Ouroboros Classic Epoch Boundary blocks (EBB) do not have a block number
merkleRoot: Hash32Hex
number: Int
opCert: Hash32Hex
slotInEpoch: Int
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ query blocksByHashes(
epochNo
fees
hash
merkleRoot
number
forgedAt
slotLeader {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ export const block29021 = {
epochNo: 1,
fees: 342316,
hash: '00aea2405f7cf4eb1d9e6694770ea25eeb113b857e377d22641aa1099742615d',
merkleRoot: '1acc618aebd703ab201ef790a379a0bd8748ac7a4ed4bf425e0b12f8b7afd812',
forgedAt: '2017-09-30T15:03:11Z',
createdBy: 'SlotLeader-8e8a7b0f4a23f07a',
number: 29021,
Expand Down Expand Up @@ -72,7 +71,6 @@ export const block29022 = {
epochNo: 1,
fees: 0,
hash: 'bf13d9a80ad99a4f34edb8a3262dd8120e29bbe182732cd3b00bf3d1bb7c2380',
merkleRoot: '0e5751c026e543b2e8ab2eb06099daa1d1e5df47778f7787faab45cdf12fe3a8',
number: 29022,
forgedAt: '2017-09-30T15:03:31Z',
createdBy: 'SlotLeader-7b00350597671036',
Expand Down

0 comments on commit 8b3b718

Please sign in to comment.