I was hoping to call the Pub / Sub function (using the .pubsub / onPublish functions) whenever a new Pub / Sub message is sent to a topic / subscription in a third-party project, i.e. in cross-projects.
After some research and experimentation, I found that TopicBuilder gives an error message if the topic name contains /, and the default is "projects /" + process.env.GCLOUD_PROJECT + "/ themes /" + topic ( https: // github.com/firebase/firebase-functions/blob/master/src/providers/pubsub.ts ).
I also found a post on Stack Overflow that says "Firebase provides a (relatively thin) wrapper around Google cloud functions" ( What is the difference between cloud functions and Firebase functions? )
It made me peek into Google’s cloud features. Although I managed to create a subscription in the project that I have in the subject in a third-party project - after changing permissions in IAM - I could not find a way to associate the function with the theme. Also, I was not able to associate the function with the theme and subscription in a third-party project. In the console, I only see topics in my project, and I was not successful with gcloud.
Has anyone been successful in using the function through projects, and if so, how did you achieve it and is there a documentation URL that you could provide? If the function cannot be called by posting to a topic and subscribing in a third-party project, can you think about how I can swallow third-party Pub / Sub data?
As a Pub / Sub payment for a project that contains a subscription, I would prefer that the subscription be contained in a third-party project with a theme.
thank
source
share