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

network-container-start: await healthy network by default #1701

Open
chadoh opened this issue Nov 5, 2024 · 0 comments
Open

network-container-start: await healthy network by default #1701

chadoh opened this issue Nov 5, 2024 · 0 comments

Comments

@chadoh
Copy link
Contributor

chadoh commented Nov 5, 2024

What problem does your feature solve?

When I run

stellar network container start local

I always, every single time I personally do this, don't want the network to be considered "started" until it's actually healthy.

Right now, I need to manually check if it's healthy, with an ugly curl command like

curl -s -X POST "http://localhost:8000/rpc" \
  -H "Content-Type: application/json" \
  -d '{ "jsonrpc": "2.0", "id": 8675309, "method": "getHealth" }' \
  | sed 's/.*"status":"\([^"]*\)".*/\1/'

Right after stellar network container start returns me to my prompt, this command will tell me "502: Bad Gateway". Then it will tell me "data stores not yet initialized" for a minute or so. Then, finally, it just says "healthy".

What would you like to see?

I don't want to be returned to my prompt until the network is healthy.

It would be nice to have some sort of loader, and maybe a status message. "Starting http...", "Initializing data stores...".

What alternatives are there?

If there's some edge case I'm unaware of in which it would be useful for people to have a partially-started local network, then we could also provide a --no-wait flag.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Backlog (Not Ready)
Development

No branches or pull requests

1 participant