-
Notifications
You must be signed in to change notification settings - Fork 107
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
Improve accuracy of application start up time in docker #559
Comments
When I was measuring startup times, I used For a Go app using |
I believe the main issue is that gin doesn't output anything and we can only know when it has started by polling the http endpoint. Assuming docker is out of the picture, how would we measure the startup time of "this" app? On a side note I agree with the suggestion of using the .State.StartedAt property, but it might be easier to keep what the current code is doing and split |
Yeah, :(. What I did is updated gin to print out a message right before it starts listening. |
That sounds like a good solution. It can be automatically applied to docker startup measurement in crank. |
I'd rather update the TE benchmark to output the message when the application is ready. Will submit a PR. |
Today it's impossible to compare application start-up time between docker and non-docker hosted apps. The docker-hosted startup time includes the time to start the container.
For example, comparing a .NET app to a go app in docker:
I'm pretty sure the go app should start faster than the .NET app, but the current numbers indicate the reverse.
Is there a way to make these app types more comparable?
One idea: write to the console as we do with ready-state text. The docker container could use CMD + bash to write to the console to indicate that the docker container has finished starting, then launch the docker-hosted app. Crank uses that console write to remove the docker container start time from the app startup time.
The text was updated successfully, but these errors were encountered: