CardanoSolutions / ogmios

❇️ A WebSocket JSON/RPC bridge for Cardano
https://ogmios.dev
Mozilla Public License 2.0
304 stars 90 forks source link

Make state-queries era-agnostic #8

Closed KtorZ closed 3 years ago

KtorZ commented 3 years ago

So far, the JSON parsers for queries are era-dependent, and calibrated to work only on the next era. This has two downsides (the latter being however much more problematic than the former):

  1. It will cause the server to return an "EraMismatch" error to clients should they make a query while in the wrong era (i.e. when syncing).

  2. It means that the server will stop responding to queries on hard-forks without a new release.

Ideally, ogmios should support the current and next era; if possible all eras when it makes sense.

KtorZ commented 3 years ago

Done in: https://github.com/KtorZ/cardano-ogmios/commit/a8ca047380122e1d64e24d83e8a73de755ed4c83