mlabs-haskell / ogmios-datum-cache

6 stars 4 forks source link

User provided block slot after one in DB #91

Open t4ccer opened 2 years ago

t4ccer commented 2 years ago

What should happen when user provided --use-latest and --block-slot XXX but XXX is after slot saved in database? Current behavior will start from block in DB

ryukzak commented 2 years ago

As I see it, the general use case is to run ODC inside docker or as a service. So our users don't want to use a specific command for the first run. So the current behaviour looks correct.

Also, I don't see any reasons to use ODC without --use-latest in production, only for debugging. So I purpose:

And if we speak about CLI, I don't fully understand why we require block-hash as an argument? Maybe I miss something, but a block slot or block number should be enough?

t4ccer commented 2 years ago

I also don't see a reason not to use --use-latest but it's disabled by default to replicate behavior before this flag was implemented. Worth considering using it by default

t4ccer commented 2 years ago

Closing as current behavior is desired

t4ccer commented 2 years ago

I guess it's still relevant wrt. https://github.com/mlabs-haskell/ogmios-datum-cache/pull/111