MULESOFT-PLATFORM-ARCHITECT-I practice question 5 of 25
An eCommerce company is adding a new Product Details feature to their website, A customer will launch the product catalog page, a new Product Details…
Full set: 152 questionsDomain Architecting for Reuse
The primary requirements are low response time, fault tolerance, and data consistency for infrequently updated data from a slow database. Using a shared Anypoint Object Store (OSv2) is the optimal solution. The product details can be loaded from the database into the Object Store once. Subsequent API requests can then retrieve this data directly from the high-performance Object Store, bypassing the slow database entirely. In a multi-worker environment like CloudHub, the Object Store is shared across all workers, ensuring data consistency and fault tolerance, as the cache is external to the individual Mule runtimes.
A. Select the product details from a database in a Cache scope and return them within the API response: The default Cache scope uses an in-memory store, which is not shared across workers in a multi-worker deployment. This leads to inconsistent caches and reduced fault tolerance.
B. Select the product details from a database and put them in Anypoint MQ; the Anypoint MQ subscriber will receive the product details and return them within the API response: Anypoint MQ is for asynchronous messaging. Using it for a synchronous request-response pattern like fetching product details would introduce significant latency and architectural complexity, failing the "lowest response time" requirement.
D. Select the product details from a database and return them within the API response: This approach directly queries the database for every request, which is the root cause of the performance problem ("database response time has been very slow") and does not solve the issue.
1. MuleSoft Documentation - Object Store Connector: "You can use Object Store to persist data for later use... A common use case is to use an object store as a cache." This document establishes the Object Store as a primary tool for caching. (MuleSoft Docs, "Object Store Connector", Use Cases section).
2. MuleSoft Documentation - Caching Strategies: "By default, a cache is an in-memory store that is not shared among the nodes in a cluster... To share a cache among the nodes in a cluster, you must configure a global caching strategy that references an Object Store." This highlights the limitation of the default Cache scope (Option A) and points to Object Store (Option C) for distributed, consistent caching. (MuleSoft Docs, "Cache Scope", Caching Strategies section).
3. MuleSoft Documentation - Object Store in CloudHub: "In CloudHub, Object Store v2 is always enabled and shared between all the workers of an application." This confirms that using an Object Store provides the required consistency and fault tolerance across a multi-worker application deployment. (MuleSoft Docs, "Use Object Store v2", CloudHub Applications section).
4. MuleSoft Documentation - Anypoint MQ: "Anypoint MQ is a multi-tenant, cloud messaging service that enables customers to perform advanced asynchronous messaging scenarios..." This defines MQ's purpose as asynchronous, making it unsuitable for the synchronous data retrieval required in the scenario. (MuleSoft Docs, "Anypoint MQ", Overview section).
Keep practicing
Take the free MULESOFT-PLATFORM-ARCHITECT-I practice test
Ten exam-style questions with answers and explanations, plus the exam facts and study guides.
More questions
Other MULESOFT-PLATFORM-ARCHITECT-I practice questions
- Question 1What are 4 important Platform Capabilities offered by Anypoint Platform?
- Question 2What is true about where an API policy is defined in Anypoint Platform and how it is then…
- Question 3Version 3.0.1 of a REST API implementation represents time values in PST time using ISO 8…
- Question 4When must an API implementation be deployed to an Anypoint VPC?
- Question 6An organization requires several APIs to be secured with OAuth 2.0, and PingFederate has …
- Question 7True or False. We should always make sure that the APIs being designed and developed are …
