A custom API call to a web service is used inside of a high volume iteration. The module that calls the web service sometimes returns an error - 429: Too many requests.
Which two actions may be used to address this error? (Choose two.)
A.
Add a sleep module just prior to the module generating the error
B.
Use an ignore directive on the module generating the error
C.
Add a module to test the service for errors
D.
Use a break directive on the module generating the error
When encountering the error429: Too many requests, which indicates the web service is being overwhelmed by requests, the following actions can help:
A. Add a Sleep Module:
Adding aSleepmodule introduces a delay between iterations, reducing the frequency of API calls.
By slowing down the rate of requests, you avoid hitting the rate limits of the web service, thus reducing the chances of receiving a 429 error.
This approach is useful for managing high-volume iterations without overloading the external service.
C. Add a Module to Test the Service for Errors:
Adding a module to test the service's response before making a call can help prevent the 429 error by checking if the service is ready to handle requests.
This preemptive check allows the scenario to conditionally execute, ensuring that it doesn't overwhelm the service and respects the API rate limits.
Why Not Other Options?
B. Use an Ignore Directive: Ignoring errors can be risky because it would cause the scenario to ignore 429 errors, possibly leading to failed API calls that are not addressed. Ignoring an error doesn’t solve the issue of too many requests being sent to the service.
D. Use a Break Directive: TheBreakdirective would stop the execution, which is counterproductive when trying to resolve the issue by reducing the rate of requests. It would not address the root cause of too many requests.
References:
Adobe Workfront Fusion Documentation: Handling API Rate Limiting with Sleep and Error Handling
Experience League Community: Managing Web Service Errors in High-Volume Iterations
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