Skip to content

Commit

Permalink
Add property "sourcetemplate" to eventprovider/service (cloudevents#636)
Browse files Browse the repository at this point in the history
* Add property "sourcetemplate" to entity eventprovider/service

Signed-off-by: Klaus Deissner <[email protected]>

* Added restriction to Level 1 templates
Made sourcetemplate a child of type

Signed-off-by: Klaus Deissner <[email protected]>
  • Loading branch information
deissnerk authored Jun 26, 2020
1 parent 449c8c7 commit 1aae2d4
Showing 1 changed file with 25 additions and 12 deletions.
37 changes: 25 additions & 12 deletions discovery.md
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ entity.
- Examples:
- `http://cloud.example.com/docs/blobstorage`

###### specversions
##### specversions

- Type: Array of `Strings` per [RFC 2046](https://tools.ietf.org/html/rfc2046)
- Description: CloudEvents [`specversions`](https://github.com/cloudevents/spec/blob/master/spec.md#specversion)
Expand All @@ -254,15 +254,15 @@ entity.
- REQUIRED
- MUST be a non-empty array or non-empty strings

###### subscriptionurl
##### subscriptionurl

- Type: `URL`
- Description: An absolute URL indicating where CloudSubscriptions `subscribe`
API calls MUST be sent to.
- Constraints:
- REQUIRED

###### subscriptionconfig
##### subscriptionconfig

- Type: `Map` of `String` to `String`
- Description: A map indicating supported options for the `config` parameter
Expand All @@ -275,7 +275,7 @@ entity.
- Examples:
- ??

###### authscope
##### authscope

- Type: `String`
- Description: Authorization scope needed for creating subscriptions.
Expand All @@ -285,7 +285,7 @@ entity.
- Example:
- `storage.read`

###### protocols
##### protocols

- Type: `List` of `String`
- Description: This field describes the different values that might be passed
Expand Down Expand Up @@ -315,15 +315,15 @@ entity.
- `com.github.pull.create`
- `com.example.object.delete.v2`

##### description (Type)
###### description (type)

- Type: `String`
- Description: Human readable description.
- Constraints:
- OPTIONAL
- If present, MUST be a non-empty string

##### datacontenttype
###### datacontenttype

- Type: `String`
- Description: CloudEvents [`datacontenttype`](https://github.com/cloudevents/spec/blob/master/spec.md#datacontenttype)
Expand All @@ -334,7 +334,7 @@ entity.
- If present, MUST adhere to the format specified in
[RFC 2046](https://tools.ietf.org/html/rfc2046)

##### dataschema
###### dataschema

- Type: `URI`
- Description: CloudEvents [`datacontenttype`](https://github.com/cloudevents/spec/blob/master/spec.md#dataschema)
Expand All @@ -344,7 +344,7 @@ entity.
- OPTIONAL
- If present, MUST be a non-empty URI

##### dataschematype
###### dataschematype

- Type: `String` per [RFC 2046](https://tools.ietf.org/html/rfc2046)
- Description: If using `dataschemacontent` for inline schema storage, the
Expand All @@ -356,7 +356,7 @@ entity.
- Examples:
- `application/json`

##### dataschemacontent
###### dataschemacontent

- Type: `String`
- Description: An inline representation of the schema of the `data` attribute
Expand All @@ -368,6 +368,19 @@ entity.
the `datacontenttype`.
- If `dataschama` is present, this field MUST NOT be present.

###### sourcetemplate

- Type: `URI Template`
- Description: A URI Template according to [RFC
6570](https://tools.ietf.org/html/rfc6570) that defines how the source
attribute will be generated.
- Constraints:
- OPTIONAL
- If present, MUST be a Level 1 template compliant to [RFC
6570](https://tools.ietf.org/html/rfc6570)
- Examples:
- "http://blob.store/{bucket}"

###### extensions

- Type: `Array` of structures
Expand Down Expand Up @@ -402,13 +415,13 @@ entity.
"type": "com.example.storage.object.create",
"specversions": [ "1.x-wip" ],
"datacontenttype": "application/json",
"dataschema": "http://schemas.example.com/download/com.example.storage.object.create.json"
"dataschema": "http://schemas.example.com/download/com.example.storage.object.create.json",
"sourcetemplate": "https://storage.example.com/service/storage/{objectID}"
}
]
}
```


### REST Paths

Each path in the REST API represents either a list (or search) over
Expand Down

0 comments on commit 1aae2d4

Please sign in to comment.