Problem
Now the Trigger filtering abilities are poor, because they require direct match on specific CloudEvent attributes.
Persona:
User
Exit Criteria
Trigger APIs should have a more powerful filtering abilities
Time Estimate (optional):
2
Additional context (optional)
Json Schema pro:
- widely used
- widely known, no need to teach people about it
- there is a validator for each language out there
- declarative, no issues about security, halting problem, turing completeness etc
- very expressive
Json Schema cons:
What has to be discussed is: which json schema version we want to support? I guess we should support the last one draft2019-09
An example trigger could be:
apiVersion: eventing.knative.dev/v1beta1
kind: Trigger
metadata:
name: my-service-trigger
spec:
broker: default
filter:
schema:
required: ["subject"]
properties:
id:
pattern: "[a-z]*"
subscriber:
ref:
apiVersion: serving.knative.dev/v1
kind: Service
name: my-service
I'm gonna add this (with all the details) to the expression language document i made for JS: https://docs.google.com/document/d/1Pz2vaLWKUrMQDLNyDW7ksjgLG4GAxBY546dT7_jF5Rk/edit#
Problem
Now the
Triggerfiltering abilities are poor, because they require direct match on specificCloudEventattributes.Persona:
User
Exit Criteria
TriggerAPIs should have a more powerful filtering abilitiesTime Estimate (optional):
2
Additional context (optional)
Json Schema pro:
Json Schema cons:
What has to be discussed is: which json schema version we want to support? I guess we should support the last one draft2019-09
An example trigger could be:
I'm gonna add this (with all the details) to the expression language document i made for JS: https://docs.google.com/document/d/1Pz2vaLWKUrMQDLNyDW7ksjgLG4GAxBY546dT7_jF5Rk/edit#