-
-
Notifications
You must be signed in to change notification settings - Fork 561
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
feat(rust): support node create
first argument as inline configuration
#8582
feat(rust): support node create
first argument as inline configuration
#8582
Conversation
d91208c
to
88c7a4c
Compare
88c7a4c
to
b27d3ff
Compare
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.
Approved but I am not a big fan of this because this prevents us from giving precise error messages. For example an incorrect input could be a malformed path but also a configuration file having inlet:
instead of tcp-inlet
and we can't tell the difference in terms of error.
I would be more comfortable if we could:
- Determine for sure what was the intent of the user.
- Display an appropriate message saying: "incorrect name" or "incorrect URL", or ... And giving as info we can on why it's incorrect and how to fix it.
Overall I think it is better to reduce the ambiguity in the user intent for command line arguments, at the expense of verbosity. For example what happens if I enter a file name for a local file test-config
that does not exist because I made a typo in my file name? Are we going to determine that this is not a file name, thus it must be a node name, and going to silently create a node with that name?
I don't like it either, but we have to be consistent for now. If the user can run The |
b27d3ff
to
25db6c3
Compare
Now we can use the
node create
positional argument to pass an inline configuration. So, the following are equivalents: