GoogleCloudPlatform / GoogleCloudPlatform/functions-framework-dart

Parsing pub sub messages

Open
#239 24 comments 0 reactions 0 assignees View on GitHub
kind/enhancement
Dominant language
Dart
Stars
548
Forks
49
Avg merge
53m
Merged PRs (30d)
1

Description

Hi,
I'm moving over some of my Pub Sub endpoints to `functions_framework` (from `firebase_functions_interop`), I've just started with the package so still finding my way around. I've seen support for `CloudEvent` (which are new to me) and I'm wondering if I can use those to parse pub sub messages ?

I see a mention of parsing the pub sub message data structure as a CloudEvent here:
https://github.com/GoogleCloudPlatform/functions-framework-dart/issues/1#issuecomment-740127873

There is a `CloudEvent` class included in this package, do I need to make a new similar class for `PubSubMessage`? I think doing that I might be complicating the situation as I might be able to use the existing CloudEvent class (perhaps with like [the schema for pub sub messages](https://github.com/googleapis/google-cloudevents))

If this is feasible, this might be a really cool thing to include an example for?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.