GCP - Cloud Pub/SubA developer tries to pull messages but receives none, even though messages were published. What could be the problem?AThe topic has no messages published.BThe subscriber is using the wrong project ID.CThe subscription is a push subscription, so pull won't work.DThe messages were acknowledged automatically.Check Answer
Step-by-Step SolutionSolution:Step 1: Understand subscription types and message retrievalPulling messages only works with pull subscriptions; push subscriptions deliver automatically.Step 2: Check other optionsMessages were published; wrong project ID would cause errors; messages are not auto-acknowledged.Final Answer:The subscription is a push subscription, so pull won't work. -> Option CQuick Check:Pull only works with pull subscriptions [OK]Quick Trick: Pull won't work on push subscriptions [OK]Common Mistakes:Assuming pull works on push subscriptionsIgnoring project ID mismatchThinking messages auto-acknowledge
Master "Cloud Pub/Sub" in GCP9 interactive learning modes - each teaches the same concept differentlyLearnWhyDeepVisualTryChallengeProjectRecallTime
More GCP Quizzes Cloud Firestore and Bigtable - Bigtable schema design - Quiz 3easy Cloud Functions - Cold start behavior - Quiz 13medium Cloud Functions - Environment variables and secrets - Quiz 12easy Cloud IAM Advanced - Why advanced IAM matters - Quiz 15hard Cloud IAM Advanced - VPC Service Controls - Quiz 5medium Cloud Load Balancing - Why load balancing matters - Quiz 6medium Cloud Run - Cloud Run service concept - Quiz 6medium Cloud Run - Deploying container images - Quiz 1easy Cloud SQL and Databases - Cloud Spanner for global distribution - Quiz 1easy Cloud SQL and Databases - Backup and restore - Quiz 7medium