-
Notifications
You must be signed in to change notification settings - Fork 267
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
Add option to follow the component logs when running spin up
#380
Comments
I can take a crack at this, but would like to raise what the UI might look like. A few thoughts (using Option 1
It's terse, but not very selective if you have a lot of components. Option 2
Yes Ivan but what if you really do want to follow all of them what then. Option 3
Plenty of control but phew that's a lotta options to go in the help text. Option 4
Confusing? Even possible in structopt? Option 5
A magic value! Would that be discoverable enough? Could we find one that couldn't clash with a component name and yet would not look weird? Option N Something else that is obvious but I haven't thought of yet! cc @michelleN |
If it was possible (yay for enum shenanigans?), I would very much like option 4. |
I like that too. I will see if I can bend structopt to my will. |
Looks like log handling is wired up at the trigger/executor level at the moment - the I tentatively assume that the desired behaviour after this change is as follows:
But perhaps we should discuss and confirm? We want the behaviour to be useful to users, and perhaps the above is not right for all trigger types? |
clap/structopt has defeated me for option 4. It seems to have firm views that an argument either takes a value or does not, and should jolly well make up its mind. You can handcraft I suspect this is because |
Worth also considering the embedding scenario - if a consumer wants to embed a Spin trigger but wants to customise where the output goes, should we provide for this and if so how? |
Hmm, this brings up an interesting question. Were you thinking that this stop writing the log files and just write to Spin's standard output/error? Right now, the log directory is configured on the execution context, so it can be changed by an embedder. |
No, I will continue writing everything to the log files with an option to also follow via Spin's stdout/stderr. |
When running
spin up
, you see the Spin logs, and the logs of components are saved in the configured logs directory.I would like to propose optionally following the component logs in the standard output / error of the Spin process.
The text was updated successfully, but these errors were encountered: