Add support for Pub/Sub #154
Labels
api: eventarc
Issues related to the googleapis/google-cloudevents-go API.
priority: p3
Desirable enhancement or fix. May not be included in next release.
type: feature request
‘Nice-to-have’ improvement, new feature or different behavior or design.
Current Behavior
Pub/Sub is suppressed from the code generation process in generate-code.sh because Pub/Sub messages are incompatible with protojson parsing. This is because Pub/Sub messages include duplicate fields
message_id
/messageId
, andpublish_time
/publishTime
, which the protobuf spec indicates is invalid.Expected Behavior
All Event Sources have type libraries.
Approach
Add a custom function that can be used to pre-process Pub/Sub payloads before unmarshalling.
We already have a function in the repository that can facilitate this that was put in place to enable testing:
google-cloudevents-go/internal/testhelper/prepare.go
Lines 11 to 27 in 322c786
pubsubdata
package. This will require a copying/templating process.google-cloudevents-go/generators/protoc-gen-go-googlecetypes/generator.go
Lines 146 to 147 in 322c786
The text was updated successfully, but these errors were encountered: