-
Notifications
You must be signed in to change notification settings - Fork 22
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 specify Subject
#32
Comments
Makes sense, although Subject is considered optional. I'm thinking that maybe a general way of setting optional Cloud Event fields be better?!? Something similar to kn event build \
--ce-field subject=Acme \
--field email=a@b.c WDYT? |
I think that makes a nice API and could later be combined with a So do you think of migrating the existing CE metadata fields as well, i.e. not only optional fields in |
I feel like the non-optional fields should stay as they are, as they are often used. Exposing them would be easier to use and easier for newcomers to get familiar with CE basics - they can just invoke |
I understand your rational but that would ultimately lead to an inconsistent API, especially for newcomers I think. So I'm in favor of harmonizing them with consistent prefixes, provide defaults (e.g. for required fields), descriptions and examples in the help section. E.g. one might want to add additional context attributes later, which could be passed with |
All those required fields have some defaults already. Calling:
So, the type, source, id and time are all set, by default. |
Yes, I know they exist :) But consider the changes for optional envelop fields, we would end up with different fields for:
So my thought was keeping
|
Closing this as there is no consensus. |
I think it's worth having this ticket open for a while longer, as this is a real issue. We just need to settle on an API, and I think we could get to it shortly. /cc @rhuss |
tbh, for known fields i'm woudl support typed fields over key=value options for these reasons:
However, I probably would even omit the |
I have the same opinion as @rhuss on this, now. I think we should just add I didn't added it initially because I just missed it, tbh. For me, type and source are well enough. But, subject is part of CE spec so it should be supported here as well. |
This issue is stale because it has been open for 90 days with no |
/remove-lifecycle stale |
This issue is stale because it has been open for 90 days with no |
/remove-lifecycle stale |
This issue is stale because it has been open for 90 days with no |
/reopen |
@cardil: Reopened this issue. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Could not find any related issue/discussion. It would be nice to set a
ce-subject
in build/send commands. If you think that's useful I can create a PR.The text was updated successfully, but these errors were encountered: