-
Notifications
You must be signed in to change notification settings - Fork 3
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
Docker compose restart pragma #1442
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I stopped my cluster and restarted by replicating from prod. Spun up like normal 👍🏼
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tested with and without replicating, and my stack came up just like normal. 🚢
@@ -21,6 +20,7 @@ services: | |||
- 'HASURA_GRAPHQL_JWT_SECRET={"type":"RS256","jwk_url": "https://cognito-idp.us-east-1.amazonaws.com/us-east-1_U2dzkxfTv/.well-known/jwks.json","claims_format": "stringified_json"}' | |||
- HASURA_GRAPHQL_ADMIN_SECRET=hasurapassword | |||
- ACTIVITY_LOG_API_SECRET=hasurapassword | |||
- HASURA_GRAPHQL_NO_OF_RETRIES=30 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this was a TIL for me. I was a little confused about the docs saying it was "deprecated" but then I read this blurb.
In v2.0, the values of the following env vars are used to define the connection parameters of the default database while updating an existing instance or while starting a fresh instance.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for finding that Mike, and double thanks for checking so thoroughly into the documentation on the variable. I had not seen the depreciation notice that you pointed out -- I saw the variable name somewhere, thought I'd give it a whirl and it did exactly what I had expected it to do. I don't think they are using the word deprecation here quite right -- they should call it a one-time-use value or something like that. But what I really want to say is - thank you for your detailed review.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tested by spinning up my cluster with and without replicating and both worked smoothly! 🚢
|
Associated issues
This PR is intended to close cityofaustin/atd-data-tech#18960.
Testing
This is the easiest thing to test in the world. Please check out this branch,
cd
into themoped-database
directory, and execute ahasura-cluster start
. Did it work? Did you get a running postgres container and a running graphql-engine container?A note on testing this
The number of retries is chosen out of thin air -- it can be 30, 300, 3000, whatever -- just not 1. It needs to be large enough to keep
graphql-engine
retrying the PG container long enough for the PG container to initialize the fresh DB, which it does on start before it begins accepting connections. I'm asking that everyone who is a regular moped contributor to test this because really, I want to test that this magic number 30 works for all of us. Essentially whoever has the slowest disk or the slowest computer overall will be the person who determines if 30 is suitable.Background
This is copy borrowed from a conversation between @mddilley and myself.
Ship list