Ultimate access to all questions.
Your company is looking to adopt a serverless approach for applications with bursty workloads, heavily relying on Cloud Pub/Sub for decoupling systems. The goal is to minimize costs by scaling down to zero during periods of no traffic, while ensuring seamless integration with Cloud Pub/Sub. Which Google Cloud Platform (GCP) serverless service would you recommend, adhering to Google's best practices?
Explanation:
Among the options provided, Cloud Functions stands out as the most suitable choice. It is Google Cloud’s event-driven serverless compute platform, designed for seamless integration with Cloud Pub/Sub and the ability to scale down to zero, ensuring cost efficiency during inactive periods. Google explicitly recommends Cloud Functions for scenarios involving simple APIs or functions accessed via HTTP or Cloud Pub/Sub. While other services like App Engine Standard and Cloud Run offer scalability and some level of integration with Pub/Sub, they either lack out-of-the-box Pub/Sub integration or are not specifically recommended by Google for Pub/Sub-dependent applications. Cloud Run for Anthos, although capable of scaling pods down to zero, does not allow the number of nodes per cluster to scale to zero, leading to unnecessary costs during idle times.