Below is an example of a Google Cloud Storage event for the Google Cloud Storage source. It includes lots of CloudEvents extensions which may not be desirable for certain users, and they contain duplicate information that is already available elsewhere. Also, we don't do this consistently, e.g. S3 source does not produce these extensions.
☁️ cloudevents.Event
Context Attributes,
specversion: 1.0
type: com.google.cloud.storage.notification
source: gs://...
id: 7283369936877024
time: 2023-04-04T08:36:13.699Z
datacontenttype: application/json
Extensions,
pubsubmsgbucketid: jmcx-test
pubsubmsgeventtime: 2023-04-04T08:36:13.658837Z
pubsubmsgeventtype: OBJECT_FINALIZE
pubsubmsgnotificationconfig: projects/_/buckets/jmcx-test/notificationConfigs/1
pubsubmsgobjectgeneration: 1680597373646330
pubsubmsgobjectid: MonaLisa.jpeg
pubsubmsgoverwrotegeneration: 1680597265096910
pubsubmsgpayloadformat: JSON_API_V1
Data,
{
"Data": {
"kind": "storage#object",
"id": "jmcx-test/MonaLisa.jpeg/1680597373646330",
"selfLink": "https://www.googleapis.com/storage/v1/b/jmcx-test/o/MonaLisa.jpeg",
"name": "MonaLisa.jpeg",
"bucket": "jmcx-test",
"generation": "1680597373646330",
"metageneration": "1",
"contentType": "image/jpeg",
"timeCreated": "2023-04-04T08:36:13.658Z",
"updated": "2023-04-04T08:36:13.658Z",
"storageClass": "STANDARD",
"timeStorageClassUpdated": "2023-04-04T08:36:13.658Z",
"size": "853892",
"md5Hash": "++/0oLKpdfakuNh6C6+d/g==",
"mediaLink": "https://storage.googleapis.com/download/storage/v1/b/jmcx-test/o/MonaLisa.jpeg?generation=1680597373646330\u0026alt=media",
"crc32c": "0kDLnA==",
"etag": "CPrr3Yvpj/4CEAE="
},
"ID": "7283369936877024",
"Attributes": {
"bucketId": "jmcx-test",
"eventTime": "2023-04-04T08:36:13.658837Z",
"eventType": "OBJECT_FINALIZE",
"notificationConfig": "projects/_/buckets/jmcx-test/notificationConfigs/1",
"objectGeneration": "1680597373646330",
"objectId": "MonaLisa.jpeg",
"overwroteGeneration": "1680597265096910",
"payloadFormat": "JSON_API_V1"
},
"PublishTime": "2023-04-04T08:36:13.699Z",
"DeliveryAttempt": null,
"OrderingKey": ""
}
Below is an example of a Google Cloud Storage event for the Google Cloud Storage source. It includes lots of CloudEvents extensions which may not be desirable for certain users, and they contain duplicate information that is already available elsewhere. Also, we don't do this consistently, e.g. S3 source does not produce these extensions.
Can we stop creating these extensions?