4
votes

I'm running a sample Google Cloud Function which is triggered by a Pub/Sub subscription. Function is CPU bound (does calculations which take 100-300ms per call).

I've sent 1 million messages to the topic. The function ramps up quickly but plateaued at about 800 calls/sec and never goes above 1000 calls/sec. So, it took about 20 minutes to process all messages.

What is the way to diagnose why this rate limit occurred? Is there a chart or metric which would show which quota I hit?

1
If you comment out the portion of code that is compute intensive, does it process more messages?Oliver

1 Answers

4
votes

Per the GCP function quotas docs, "Max invocation rate for a background function" is 1000/sec.