Module 2: Best Practices for Cloud Application Development

Looking for โ€˜Developing Applications with Google Cloud: Foundations Module 2 Answersโ€™?

In this post, I provide complete, accurate, and detailed explanations for the answers to Module 2: Best Practices for Cloud Application Development of Course 3: Developing Applications with Google Cloud: Foundations โ€“ Preparing for Google Cloud Certification: Cloud Developer Professional Certificate

Whether youโ€™re preparing for quizzes or brushing up on your knowledge, these insights will help you master the concepts effectively. Letโ€™s dive into the correct answers and detailed explanations for each question!

Best Practices for Cloud Application Development

Graded Assignment

1. Which of the following is an anti-pattern when designing a cloud application?

  • Perform asynchronous operations
  • Embed configuration settings in your source code โœ…
  • Cache application data and frontend content
  • Use APIs and API gateways to connect to legacy systems in applications

Explanation:

  • An anti-pattern is a poor practice that leads to inefficiency or problems in cloud application design.
  • Embedding configuration settings in source code is bad because:
    • It makes applications less flexible and harder to update.
    • It exposes sensitive information (e.g., API keys, credentials).
    • It prevents environment-specific configurations (e.g., dev, test, prod).
  • Instead, use environment variables or configuration files stored securely.

2. For transient network issues, what error-handling approach should you implement?

  • Implement a circuit breaker
  • Display the error to the user
  • Retry with exponential backoff โœ…
  • Retry constantly until the call succeeds

Explanation:

  • Transient network issues are temporary failures that usually resolve themselves (e.g., timeouts, packet loss).
  • The best approach is retrying with exponential backoff, meaning:
  • Wait a short time before retrying.
    • Gradually increase the wait time if failures continue.
    • This prevents overloading the system with constant retries.

Leave a Reply