Northern Trail Outfitters needs a synchronous callout from Salesforce to an Order Management System (OMS) when an opportunity is "Closed/Won" with products attached. What should an integration architect do to satisfy these requirements?
Correct Answer: A
To satisfy a requirement for a synchronous callout triggered by a user action, the architect should use a UI- driven approach, such as a Lightning component and a button. In Salesforce, triggers (Option B) are primarily used for asynchronous logic in integration contexts. Because a trigger executes as part of the database save operation, making a synchronous callout directly from a trigger is prohibited as it would block the database transaction until the external system responds, leading to performance degradation and "uncommitted work pending" errors. If a trigger must initiate an integration, it must do so asynchronously (using @future or Queueable Apex), which violates the requirement for a synchronous call. By using a Lightning component, the architect can initiate a synchronous Request-and-Reply pattern. When the sales rep clicks the "7Submit to OMS" button, the componen8t invokes an Apex method that makes the REST callout to the OMS in real-time. The user remains on the page while the system waits for the OMS to respond, allowing for immediate feedback-such as an order confirmation number or an error message-to be displayed in the UI. A Batch Apex job (Option C) is inherently asynchronous and delayed, making it unsuitable for a synchronous, real-time fulfillment requirement.
Integration-Architect Exam Question 17
An integration architect has designed a mobile application for Salesforce users to get data while on the road using a custom user interface (UI). The application is secured with OAuth and is currently functioning well. There is a new requirement where the mobile application needs to obtain the GPS coordinates and store them on a custom geolocation field. The geolocation field is secured with field-level security, so users can view the value without changing it. What should be don4e to meet the requirement?
Correct Answer: B
When a custom mobile application already secured with OAuth needs to update a record in Salesforce, the standard architectural recommendation is to use the REST API. The REST API is optimized for mobile environments because it uses lightweight JSON payloads and follows standard HTTP methods (such as PATCH for updates), which are highly compatible with mobile development frameworks. In this specific scenario, the architect must address the Field-Level Security (FLS) constraint. Because the geolocation field is set to read-only for users, a standard UI-based update would typically fail. However, when using an inbound REST API call with a properly authorized integration user or via a "System Mode" context (if utilizing a custom Apex REST resource), the system can be configured to bypass UI-level restrictions while maintaining data integrity. The mobile device captures the coordinates via the device's native GPS capabilities and initiates an inbound call to the Salesforce REST endpoint. Option A (Apex inbound call) is a subset of REST functionality but is only necessary if complex server-side logic is required that the standard REST API cannot handle. Option C is technically incorrect as mobile devices do not typically "receive" callouts from Salesforce in this pattern; they initiate the requests. By leveraging the standard REST API, the architect ensures a scalable, secure, and standardized integration that adheres to Salesforce's mobile-first integration principles.
Integration-Architect Exam Question 18
Northern Trail Outfitters (NTO) wants to improve the quality of callouts from Salesforce to its REST APIs. For this purpose, NTO will require all API Clients/consumers to adhere to REST API Markup Language (RAML) specifications that include the field-level definition of every API request and response Payload. The RAML specs serve as interface contracts that Apex REST API Clients can rely on. Which design specification should the integration architect include in the integration architecture to ensure that Apex REST API Clients' unit tests confirm Adherence to the RAML specs?
Correct Answer: C
In a contract-first integration strategy using RAML (RESTful API Modeling Language), the specification defines the exact structure of requests and responses. Because Salesforce unit tests cannot perform actual network callouts, the platform requires d1evelopers to use the HttpCalloutMock interface to simulate responses. To ensure that the integration code strictly adheres to the established RAML contract, the integration architect must mandate that the HttpCalloutMock implementation returns responses that mirror the RAML specification. This means the mock must include all required fields, correct data types, and the expected HTTP status codes (e.g., 200 OK, 201 Created) as defined in the contract. By doing this, the unit tests verify that the Apex client code can successfully parse and process the specific JSON or XML payloads defined in the RAML spec. Option A and B are technically imprecise. The Apex client does not "implement" the mock; rather, the test class provides a separate mock implementation to the runtime via Test.setMock(). The value of the integration architecture lies in the content of that mock. If the mock is designed to return contract-compliant data, then any change to the RAML that breaks the Apex code's ability to process it will be caught immediately during the testing phase. This "Mock-as-a-Contract" approach provides a safety net, ensuring that Salesforce remains compatible with external services even as those services evolve, provided the RAML is kept up to date.
Integration-Architect Exam Question 19
Universal Containers (UC) support agents would like to open bank accounts on the spot. During the process, agents execute credit checks through external agencies. At any given time, up to 30 concurrent reps will be using the service. Which error handling mechanisms should be built to display an error to the agent when the credit verification process has failed?
Correct Answer: A
In a synchronous Request-Reply scenario where a bank agent is waiting "on the spot" for a credit check, the error-handling strategy must balance immediate feedback with system resilience. Option A is the recommended architectural approach for enterprise resiliency. By placing a Middleware layer (like MuleSoft) between Salesforce and the credit agencies, the architect can implement sophisticated error- handling patterns that are invisible to the user but critical for success. If a credit agency's API is momentarily unreachable, the middleware can perform automated retries (e.g., three attempts with 500ms intervals). If the retries still fail, the middleware sends a clean, structured error response back to Salesforce. Option B (Fire and Forget) is fundamentally unsuitable for this use case because the agent needs the result immediately to open the account; they cannot wait for a callback that might arrive hours later. Option C (Mock service) is only a testing tool and provides no value in a production environment where real financial data is required. By delegating the retry logic to the middleware, the architect protects Salesforce's concurrent request limits (since the agent only occupies a thread for the duration of the final response) and ensures that transient network issues do not result in a "failed" bank account application for the customer.
Integration-Architect Exam Question 20
A customer's enterprise architect has identified requirements around caching, queuing, error handling, alerts, retries, event handling, etc. Which recommendation should the integration architect make?
Correct Answer: B
When an enterprise architect identifies complex infrastructure needs such as caching, queuing, and sophisticated event routing, it signals that a point-to-point integration architecture is insufficient. In such cases, the Integration Architect should recommend a Middleware-mediated architecture. Middleware tools, such as an Enterprise Service Bus (ESB) or an iPaaS (Integration Platform as a Service), are specifically designed to fulfill these complex "Quality of Service" (QoS) requirements. In a publish/subscribe scenario, the middleware acts as the central orchestrator. It can receive a single "Fire and Forget" event from a publisher (like Salesforce) and then manage the technical complexities of routing that message to multiple active subscribers. Middleware handles infrastructure-level tasks such as message queuing for offline systems, automatic retries with exponential backoff, and error handling with alerts-capabilities that are either unavailable or difficult to scale within Salesforce natively. Performing message transformation and protocol translation (e.g., SOAP to REST) within the middleware layer also protects Salesforce's Apex CPU limits. By leveraging middleware for these concerns, the architect ensures that Salesforce remains a performant engagement layer while the middleware provides the robust technical backbone for a resilient enterprise landscape.