Skip to content
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

Delivery Format: support specifying the event format #8057

Open
Cali0707 opened this issue Jun 28, 2024 · 8 comments
Open

Delivery Format: support specifying the event format #8057

Cali0707 opened this issue Jun 28, 2024 · 8 comments
Assignees
Labels
area/delivery Epic Epics to group issues kind/feature-request triage/accepted Issues which should be fixed (post-triage)

Comments

@Cali0707
Copy link
Member

Cali0707 commented Jun 28, 2024

Problem
Currently, when dispatching an event, we generally send it in the binary event format. However, to integrate with some systems (such as AWS EventBridge) we will need to be able to support sending events in structured format.

To support this, we are going to add a new field to the Delivery spec of resources, which will look like:

spec:
  delivery:
    format: ingress|structured|binary|null

If set to binary, then the component would deliver the event in binary format. If set to structured, then the component would deliver the event in structured format. If set to ingress, then the component would send the event in the format that the broker received it.

Persona:
Which persona is this feature for?
System integrators

Exit Criteria
An e2e test for each resource that supports the delivery spec that verifies that the event was received in structured format.

Time Estimate (optional):
How many developer-days do you think this may take to resolve?
10 days

Additional context (optional)

@Cali0707
Copy link
Member Author

Cali0707 commented Jun 28, 2024

cc @pierDipi @matzew @creydr any thoughts about this?

If this design makes sense, I'll open an equivalent issue for subscriptions

@pierDipi
Copy link
Member

pierDipi commented Jul 4, 2024

Maybe even a delivery spec field

spec:
  delivery:
    format: input|structured|binary|null

@pierDipi pierDipi added the triage/accepted Issues which should be fixed (post-triage) label Jul 4, 2024
@Cali0707 Cali0707 changed the title Support sending structured events from Triggers Support sending structured events Jul 4, 2024
@Cali0707
Copy link
Member Author

Cali0707 commented Jul 4, 2024

@pierDipi I've updated this issue to be more generic (just sending structured events from the delivery spec), and I'll open individual sub issues to add support for this

@Cali0707
Copy link
Member Author

Cali0707 commented Jul 4, 2024

@pierDipi should we have a feature flag for this?

@matzew
Copy link
Member

matzew commented Jul 8, 2024

Would we than start to track what we actually received? currently we accept binary/structure, but dispatch via binary due to reasons.

For ingress would we need extra logic to remember what came in? Not sure

@Cali0707
Copy link
Member Author

Cali0707 commented Jul 8, 2024

Would we than start to track what we actually received? currently we accept binary/structure, but dispatch via binary due to reasons.

For ingress would we need extra logic to remember what came in? Not sure

@matzew the current idea is to add a new CE extensions to the events at ingress which indicated the format we received them in

See for example #8076

@matzew
Copy link
Member

matzew commented Jul 9, 2024

should we have a feature flag for this?

I think if we keep the current behavior (e.g. we emit as binary), nothing changes. so the new field seems to have no impact...

But, perhaps that can lead to side effects? 🤔

@matzew
Copy link
Member

matzew commented Jul 9, 2024

So, I'd go just structured or binary (default) for the egress to other systems. If we really want something like ingress, we can always add that as a future option.

But I guess just structured or binary, as default - and also not bother on the feature flag for this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/delivery Epic Epics to group issues kind/feature-request triage/accepted Issues which should be fixed (post-triage)
Projects
Development

No branches or pull requests

3 participants