-
Notifications
You must be signed in to change notification settings - Fork 584
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
JSON format implicit datacontenttype is asymmetrical #880
Comments
(I may well have just missed it, of course...) cc @dazuma |
(Just in case I forget - Clemens pointed out that the core spec does say that an event using JSON format can be implicitly application/json. So I'll just make that absolutely concrete in 3.1.1) |
(I've used SHOULD rather than MUST to be consistent with deserialization. If we were starting from scratch, I'd suggest that MUST would be more appropriate, but it's probably too late to do that.) Fixes cloudevents#880
(I've used SHOULD rather than MUST to be consistent with deserialization. If we were starting from scratch, I'd suggest that MUST would be more appropriate, but it's probably too late to do that.) Fixes cloudevents#880 Signed-off-by: Jon Skeet <jonskeet@google.com>
regarding that the addition refers to the user-provided datacontenttype plainly as "the |
@jskeet can we close this now? |
Yup! |
Just trying to write tests for the clarifications in #861, and I think there's an asymmetry:
datacontenttype
isn't specified it defaults toapplication/json
I suspect that we should say that if
datacontenttype
is missing when serializing - and ifdata
is present - it should default toapplication/json
, so the payload should be serialized as JSON.I'll proceed along those lines, and we can discuss whether that was actually the intention - and I can put together a PR to clarify the spec if so.
The text was updated successfully, but these errors were encountered: