Hi, in Daml-On-Sql the postgresql database has a table called Ledger_state, It appears that it is compressed and serialized. Does any one know what that field hold?
1 Like
That table contains the latest known set of active contracts known to the local participant, used as the environment where the local Daml engine looks up contracts referenced in commands as those are evaluated into transactions.
3 Likes
Thanks @stefanobaghino-da. Looks like the table holds the history of the ledger. Any changes on the ledger are recorded there. Just curious, what about Ledger_log table?
2 Likes
That’s the other way around, LEDGER_STATE
tracks the latest ACS for it to be used by the engine, LEDGER_LOG
tracks every event and it’s used to serve transactions, flat transactions and ACS snapshots for the Ledger API.
4 Likes