Home / Input Output / cardano-db-sync
Jun 28, 9-10 AM (0)
Jun 28, 10-11 AM (0)
Jun 28, 11-12 PM (0)
Jun 28, 12-1 PM (0)
Jun 28, 1-2 PM (0)
Jun 28, 2-3 PM (0)
Jun 28, 3-4 PM (0)
Jun 28, 4-5 PM (0)
Jun 28, 5-6 PM (0)
Jun 28, 6-7 PM (0)
Jun 28, 7-8 PM (0)
Jun 28, 8-9 PM (3)
Jun 28, 9-10 PM (3)
Jun 28, 10-11 PM (0)
Jun 28, 11-12 AM (1)
Jun 29, 12-1 AM (1)
Jun 29, 1-2 AM (0)
Jun 29, 2-3 AM (0)
Jun 29, 3-4 AM (0)
Jun 29, 4-5 AM (0)
Jun 29, 5-6 AM (0)
Jun 29, 6-7 AM (1)
Jun 29, 7-8 AM (0)
Jun 29, 8-9 AM (0)
Jun 29, 9-10 AM (0)
Jun 29, 10-11 AM (0)
Jun 29, 11-12 PM (0)
Jun 29, 12-1 PM (0)
Jun 29, 1-2 PM (0)
Jun 29, 2-3 PM (0)
Jun 29, 3-4 PM (0)
Jun 29, 4-5 PM (0)
Jun 29, 5-6 PM (0)
Jun 29, 6-7 PM (0)
Jun 29, 7-8 PM (0)
Jun 29, 8-9 PM (0)
Jun 29, 9-10 PM (0)
Jun 29, 10-11 PM (0)
Jun 29, 11-12 AM (0)
Jun 30, 12-1 AM (0)
Jun 30, 1-2 AM (0)
Jun 30, 2-3 AM (0)
Jun 30, 3-4 AM (0)
Jun 30, 4-5 AM (0)
Jun 30, 5-6 AM (0)
Jun 30, 6-7 AM (1)
Jun 30, 7-8 AM (8)
Jun 30, 8-9 AM (0)
Jun 30, 9-10 AM (1)
Jun 30, 10-11 AM (0)
Jun 30, 11-12 PM (0)
Jun 30, 12-1 PM (0)
Jun 30, 1-2 PM (1)
Jun 30, 2-3 PM (0)
Jun 30, 3-4 PM (0)
Jun 30, 4-5 PM (0)
Jun 30, 5-6 PM (0)
Jun 30, 6-7 PM (0)
Jun 30, 7-8 PM (0)
Jun 30, 8-9 PM (0)
Jun 30, 9-10 PM (0)
Jun 30, 10-11 PM (0)
Jun 30, 11-12 AM (0)
Jul 01, 12-1 AM (0)
Jul 01, 1-2 AM (0)
Jul 01, 2-3 AM (2)
Jul 01, 3-4 AM (0)
Jul 01, 4-5 AM (0)
Jul 01, 5-6 AM (0)
Jul 01, 6-7 AM (0)
Jul 01, 7-8 AM (0)
Jul 01, 8-9 AM (0)
Jul 01, 9-10 AM (0)
Jul 01, 10-11 AM (0)
Jul 01, 11-12 PM (0)
Jul 01, 12-1 PM (0)
Jul 01, 1-2 PM (0)
Jul 01, 2-3 PM (0)
Jul 01, 3-4 PM (0)
Jul 01, 4-5 PM (0)
Jul 01, 5-6 PM (0)
Jul 01, 6-7 PM (0)
Jul 01, 7-8 PM (0)
Jul 01, 8-9 PM (0)
Jul 01, 9-10 PM (0)
Jul 01, 10-11 PM (0)
Jul 01, 11-12 AM (0)
Jul 02, 12-1 AM (0)
Jul 02, 1-2 AM (0)
Jul 02, 2-3 AM (0)
Jul 02, 3-4 AM (0)
Jul 02, 4-5 AM (0)
Jul 02, 5-6 AM (1)
Jul 02, 6-7 AM (0)
Jul 02, 7-8 AM (0)
Jul 02, 8-9 AM (1)
Jul 02, 9-10 AM (0)
Jul 02, 10-11 AM (0)
Jul 02, 11-12 PM (0)
Jul 02, 12-1 PM (0)
Jul 02, 1-2 PM (0)
Jul 02, 2-3 PM (3)
Jul 02, 3-4 PM (1)
Jul 02, 4-5 PM (0)
Jul 02, 5-6 PM (0)
Jul 02, 6-7 PM (0)
Jul 02, 7-8 PM (0)
Jul 02, 8-9 PM (1)
Jul 02, 9-10 PM (0)
Jul 02, 10-11 PM (2)
Jul 02, 11-12 AM (0)
Jul 03, 12-1 AM (0)
Jul 03, 1-2 AM (0)
Jul 03, 2-3 AM (2)
Jul 03, 3-4 AM (2)
Jul 03, 4-5 AM (0)
Jul 03, 5-6 AM (0)
Jul 03, 6-7 AM (0)
Jul 03, 7-8 AM (0)
Jul 03, 8-9 AM (0)
Jul 03, 9-10 AM (0)
Jul 03, 10-11 AM (0)
Jul 03, 11-12 PM (0)
Jul 03, 12-1 PM (1)
Jul 03, 1-2 PM (0)
Jul 03, 2-3 PM (0)
Jul 03, 3-4 PM (0)
Jul 03, 4-5 PM (0)
Jul 03, 5-6 PM (0)
Jul 03, 6-7 PM (0)
Jul 03, 7-8 PM (0)
Jul 03, 8-9 PM (0)
Jul 03, 9-10 PM (0)
Jul 03, 10-11 PM (0)
Jul 03, 11-12 AM (0)
Jul 04, 12-1 AM (0)
Jul 04, 1-2 AM (2)
Jul 04, 2-3 AM (0)
Jul 04, 3-4 AM (0)
Jul 04, 4-5 AM (0)
Jul 04, 5-6 AM (0)
Jul 04, 6-7 AM (0)
Jul 04, 7-8 AM (1)
Jul 04, 8-9 AM (0)
Jul 04, 9-10 AM (0)
Jul 04, 10-11 AM (0)
Jul 04, 11-12 PM (0)
Jul 04, 12-1 PM (0)
Jul 04, 1-2 PM (0)
Jul 04, 2-3 PM (0)
Jul 04, 3-4 PM (0)
Jul 04, 4-5 PM (0)
Jul 04, 5-6 PM (0)
Jul 04, 6-7 PM (0)
Jul 04, 7-8 PM (0)
Jul 04, 8-9 PM (0)
Jul 04, 9-10 PM (0)
Jul 04, 10-11 PM (0)
Jul 04, 11-12 AM (2)
Jul 05, 12-1 AM (0)
Jul 05, 1-2 AM (0)
Jul 05, 2-3 AM (2)
Jul 05, 3-4 AM (0)
Jul 05, 4-5 AM (0)
Jul 05, 5-6 AM (4)
Jul 05, 6-7 AM (0)
Jul 05, 7-8 AM (0)
Jul 05, 8-9 AM (0)
Jul 05, 9-10 AM (0)
47 commits this week Jun 28, 2020 - Jul 05, 2020
db: Use proper Word64 support
This commit uses a version of persistent that has been modified to add
proper Word64 support.

Previously when the schema used `Word64` as the column type, Persistent
would use `SqlInt64` as the SQL representation which means that `Word64`
values above `maxBound :: Int64` would be stored as negative values in
the database. That is fine for a database only accessed from Haskell but
is a pain in the neck when the database is used as an interop layer for
other languages.
db: Use proper Word64 support
This commit uses a version of persistent that has been modified to add
proper Word64 support.

Previously when the schema used `Word64` as the column type, Persistent
would use `SqlInt64` as the SQL representation which means that `Word64`
values above `maxBound :: Int64` would be stored as negative values in
the database. That is fine for a database only accessed from Haskell but
is a pain in the neck when the database is used as an interop layer for
other languages.
db: Use proper Word64 support
This commit uses a version of persistent that has been modified to add
proper Word64 support.

Previously when the schema used `Word64` as the column type, Persistent
would use `SqlInt64` as the SQL representation which means that `Word64`
values above `maxBound :: Int64` would be stored as negative values in
the database. That is fine for a database only accessed from Haskell but
is a pain in the neck when the database is used as an interop layer for
other languages.
Shelley: Add a deposit column to tx table
The type of this column is `Int64` allowing for positive values to
represent a deposit when a pool is registered and a negative value
to represent a refund when the pool is de-registered.

An attempt was made to add Shelley era accounting validation but that
still fails because db-sync needs more information from the ledger that
is not available on the chain.
Epoch: Fix the epoch update logic
This meets the requirements of:
* When syncing, the rows for old epochs are only updated once after the
  whole epoch has been retrieved.
* The point above is true even when the node is syncing (as opposed to
  following). Specifically, the TipBlock value provided by the node over
  the chain sync protocol is useless because it reports node tip, not
  network wide chain tip).
* Only updates the current epoch when we are close to the actual chain
  tip.

Closes: https://github.com/input-output-hk/cardano-db-sync/issues/111
Closes: https://github.com/input-output-hk/cardano-db-sync/issues/139