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

Running ddshow automatically. #8

Open
ryzhyk opened this issue Jun 21, 2021 · 2 comments
Open

Running ddshow automatically. #8

ryzhyk opened this issue Jun 21, 2021 · 2 comments

Comments

@ryzhyk
Copy link

ryzhyk commented Jun 21, 2021

I am adding an option to ddlog CLI to start ddshow before initializing the dataflow graph. This should greatly simplify the profiling workflow as the user only needs to type one command and doesn't need to worry about providing matching arguments (socket address, number of workers). Problem is, there is no easy way to know that ddshow is listening. Starting the graph before ddshow has called bind() returns an error. I noticed that ddshow prints a message to stdout on startup ("Waiting for 2 Timely connections on 127.0.0.1:51317..."), so I thought of to capturing its stdout and waiting for the message; however I checked the source and it does this before actually calling bind. Also, this seems like an ugly hack...

It's be great to have a more reliable startup protocol (any ideas?) or at least reorder things to print the message once ddshow is actually listening...

@Kixiron
Copy link
Owner

Kixiron commented Jun 21, 2021

Hum, that sounds like it'd be a good cli switch, I'm not entirely sure what would actually be done though

@ryzhyk
Copy link
Author

ryzhyk commented Jun 22, 2021

PS. The new version of ddshow no longer prints anything on stdout, so I gave up on trying to implement a reliable status check and just wait for few hundred milliseconds in the hope that ddshow will be ready by then.

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