createSubscription("topic-name", ...).topic is undefined
See original GitHub issueHowever createSubscription("topic-name", ...).metadata.topic
contains the topic name
Environment details
Seen in the firebase emulator thing.
- OS: Mac
- Node.js version: v12.15.0
- npm version: 6.13.4
@google-cloud/pubsub
version: 2.1.0
Steps to reproduce
const sub = createSubscription("topicname", "subscriptionName", {
pushEndpoint: `subscriber.com/api/mushroomFacts`,
})
sub.topic //undefined
sub.metadata.topic // projects/local-emulator/topics/topicname
Issue Analytics
- State:
- Created 3 years ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
[service-bus] topic subscription receives messages even with ...
While creating a subscription on a Topic Service Bus with many incoming messages ... createSubscription(topicName, subscriptionName,{status: ...
Read more >Create and use subscriptions | Cloud Pub/Sub Documentation
Click Create subscription. For the Subscription ID field, enter a name. For information on how to name a subscription, see Guidelines to name...
Read more >Pulling messages from Google PubSub not working
I haven't found a way to do this though and every example online does it the same way. TopicName topic = TopicName.create("cloud-project", "sn- ......
Read more >pubsub - Go Packages
CreateSubscription creates a new subscription on a topic. id is the name of the subscription to create. It must start with a letter,...
Read more >Check for Missing SNS Topic within Trail Configuration
Ensure that your CloudTrail trails are using active Amazon SNS topics. ... 5, select the Subscriptions tab, and choose Create subscription.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@psilospore Thanks, good to hear. I’ll close for now and let @feywind determine if there’s a bug we need to address.
Sorry for getting back late. I did find another workaround to get the topic name when I reported this but thought it was a bug that might be worth reporting. Based on the previous comments it seems that it is a bug, but feel free to close this if you would like.
Thanks for the responses!