Allow overriding the number of attempts in TzKt.Api
Closed this issue · 2 comments
In Tzkt.Api/Program.cs
We have a hardcoded attempt = 30;
.
In Taqueria, we start a Flextesa Sandbox, then a TzKt.Sync, postgres, and finally a TzKt.Api. Some times, the hardcoded 30 attempts is not enough and Api exits before Sync can update the database.
Can we Allow overriding this value from config or environment variables?
Thank you for the PR!
Yes, increasing max attempts would work, but if it's just a matter of running one container after another container, why not to use more appropriate mechanisms, like depends_on
+healthcheck
?
@Groxan Thanks for your reply. This is certainly fine in real server deployments, as all infrastructures have a mechanism for that. But for a simpler deployment someone might do on their desktop to check out something, it can be useful if we do not bother them with process/container orchestration complexities?