Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sidecar doesn't try again after 'FATAL: the database system is starting up' #7695

Open
paule96 opened this issue Apr 9, 2024 · 1 comment

Comments

@paule96
Copy link

paule96 commented Apr 9, 2024

Ask your question here

I have configured as an actor state store for my dapr environment a Postgres database. My Environment is hosted in aspire.
One of the rules in Aspire is, that everything communicates in a resilient way with each other. That's why there is currently no startup order implemented if you use different services.

This means that my dapr sidecar and my Postgres database start around the same time.
But a Postgres database needs some seconds from the start to be ready. That's when the dapr sidecar will receive the following error message:

time="2024-04-09T14:02:51.3669434+02:00" level=fatal msg="Fatal error from runtime: process component xxx-actorstatestore error: [INIT_COMPONENT_FAILURE]: initialization error occurred for xxx-actorstatestore (state.postgresql/v2): [INIT_COMPONENT_FAILURE]: initialization error occurred for xxx-actorstatestore (state.postgresql/v2): failed to ping the database: failed to connect to `host=localhost user=postgres database=dapractorstatestore`: server error (FATAL: the database system is starting up (SQLSTATE 57P03))" app_id=dmsdocservice instance=PC2024001 scope=dapr.runtime type=log ver=1.13.0

Is there any setting where you can configure the sidecar to try it a defined number of times before it it fails?

@berndverst
Copy link
Member

This question is likely out of scope for Dapr. I will transfer it to the Dapr runtime repo for now however because this question applies to the entire Dapr project all up and isn't really component specific in nature.

Also tagging @philliphoff who has done lots of work with Aspire and might have thoughts.

I do think that question likely is for the Aspire team however.

@berndverst berndverst transferred this issue from dapr/components-contrib Apr 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants