Google Cloud Professional Cloud Developer — Question 90

You need to redesign the ingestion of audit events from your authentication service to allow it to handle a large increase in traffic. Currently, the audit service and the authentication system run in the same Compute Engine virtual machine. You plan to use the following Google Cloud tools in the new architecture:
✑ Multiple Compute Engine machines, each running an instance of the authentication service
✑ Multiple Compute Engine machines, each running an instance of the audit service
✑ Pub/Sub to send the events from the authentication services.
How should you set up the topics and subscriptions to ensure that the system can handle a large volume of messages and can scale efficiently?

Answer options

Correct answer: A

Explanation

Option A is correct because having one Pub/Sub topic with a single pull subscription allows multiple audit services to share the load efficiently, which is essential for handling a high volume of messages. The other options either complicate the architecture by creating multiple subscriptions or do not effectively utilize shared resources, which could lead to inefficiencies and scaling challenges.