A developer is inspecting the weekly service status report for a critical internally-hosted web service and notices there are too many instances of unavailability.
Which solution can reduce service unavailability?
A.
Increase the web service time out.
B.
Change the code that sets the throwOnError attribute of the service to be true.
C.
Modify the code that makes the request to the external service to be wrapped in a try/catch block.
If a service is being classified as unavailable because legitimate responses are taking longer than the configured timeout, increasing the service timeout can reduce timeout-generated failures. B2C Commerce service profiles define the number of milliseconds the platform waits for a service response before treating the operation as an error.
Salesforce ' s Service Framework documentation states that the configured timeout is used for connection and socket operations. If no response arrives within the configured interval, the service operation fails. Thedw.svc.ResultAPI further identifiesTIMEOUTas an explicit reason forSERVICE_UNAVAILABLE.
Option B changes error-propagation behavior;throwOnErrordetermines how a failed result is surfaced to application code, but it does not make the external service more available. Option C can improve exception handling and prevent uncaught application failures, but wrapping the call intry/catchdoes not alter Service Framework availability metrics or prevent timeouts.
The timeout should still be increased cautiously. Excessive timeouts can worsen shopper-facing latency and interact poorly with circuit-breaker behavior.
Study Guide reference:Application Development — Service Framework, service profiles, connection/socket timeouts, Service Status monitoring, and service availability.
===============
Contribute your Thoughts:
Chosen Answer:
This is a voting comment (?). You can switch to a simple comment. It is better to Upvote an existing comment if you don't have anything to add.
Submit