-
Notifications
You must be signed in to change notification settings - Fork 618
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 Support for CloudEvents #422
Comments
@jamesward I knew sooner or later we'll reconnect ;) |
@jamesward the lib now has 1.0 support, see: https://github.com/cloudevents/sdk-java/tree/v1.0.0 |
@jamesward @matzew It seems to me that all we need to do on out end is introduce a MessageConverter implementation for CloudEvent (which is effectively marshaller/unmarshaller). |
We have similar idea in Spring Integration: spring-projects/spring-integration#3103 |
That's cool. So i'll go with my plan and then it's really a question where those converters would live (SI or SCSt). |
@olegz have you started this yet? Playing around with functions that accept a |
@trisberg No, I have not started yet, but as I said earlier it appears all that's needed is |
It does look like the latest spec uses some specific Maybe @duglin can help clarify though. |
Hi - yes the CE spec does define a content-type that will help you determine if the incoming message is a CE or not - at least for structured CE mode (meaning the HTTP body is wrapped in a CE structure). However, knowing whether some random message is binary CE or not is harder. To try to address this I just created this: cloudevents/spec#577 |
@jamesward @duglin I am trying, but it appears based on some of the arguments from the gate-keepers of the Cloud Event SDK that we should not even be using CloudEvent type. That it is an anti pattern to have user code to depend on |
Should |
@meltsufin In any event, I do envision simple transformation/conversion of |
I guess this comes down to whether the CloudEvent SDK folks see it as a shareable construct. Should APIs ever build on |
I've asked if we can discuss this on the SDK call tomorrow (right after the normal CE call, which is from 12-1 ET unless it ends early). Anyone is free to join. See: https://docs.google.com/document/d/1OVF68rpuPK5shIHILK9JOqlZBbfe91RNzQ7u_P7YCDE/edit# |
So it looks like maybe some progress on the cloudevents API side of things? |
Indeed @jamesward we now have cleanly defined |
Fantastic! Looks much better. Thanks for working through that! |
Added initial implementation of MessageConverter At the moment there seem that MessageConverter(s) would be the only thing needed to integrate Cloud Events with various elements of Spring
This commit adds initial set of samples and tests demonstrating various ways of how cloud event can be consumed (i.e., structured, bindary, pojo etc)
@jamesward things are finally moving. More to come, keeping it open for now |
Added initial README Polished tests
…ucture-mode CE message Normalizing in this context means converting it to binary-mode so the rest of the processing logic is the same. Added support for canonical attribute names. Now, internally any attribute can be set as 'ce_' regardless where it came from are where it goes to as the frameork will be able to recognize both Removed CloudEventMessageConverter Renamed CloudEventAttributes to CloudEventAttributesHelperas it is better suited to what it actually does
This has been addressed in This README contains initial usage documentation and sample instructions. |
Added initial implementation of MessageConverter At the moment there seem that MessageConverter(s) would be the only thing needed to integrate Cloud Events with various elements of Spring
This commit adds initial set of samples and tests demonstrating various ways of how cloud event can be consumed (i.e., structured, bindary, pojo etc)
…le binary-mode and structured-mode cloud events Moved CloudEvent related artifacts to ‘cloud events’ package with hopes to eventually donating it to CNCF SDK Created CloudEventUtils identifying necessary constants and utility methods
…e mapping Added CloudEventAttributesProvider and default implementation Added CloudEventMessageUtils
Normalizing in this context means converting it to binary-mode so the rest of the processing logic is the same. Added support for canonical attribute names. Now, internally any attribute can be set as 'ce_' regardless where it came from are where it goes to as the frameork will be able to recognize both Removed CloudEventMessageConverter Renamed CloudEventAttributes to CloudEventAttributesHelperas it is better suited to what it actually does
CloudEvents a CNCF standard for event payloads just reached 1.0. It'd be great to have out-of-the-box support with Spring Cloud Functions. So we could do:
There is an existing API for the payload, marshaling, unmarshalling, but it doesn't yet support version 1.0 of the spec
Adding this will make integration with Knative Events easier.
The text was updated successfully, but these errors were encountered: