-
Type:
Suggestion
-
Resolution: Unresolved
-
Component/s: Forge - App Monitoring, Logging
Issue Summary
This is reproducible on Data Center: (yes) / (no)
Steps to Reproduce
- Create a Forge UIKit app.
- Create a resolver function that calls an external URL in a 100x loop similar to the one below:
resolver.define('fetchJsonplaceholder', async () => { console.log("Executing fetchJsonplaceholder"); var respApi = undefined; for (let i = 0; i <= 100; i++){ try { //console.log("Inside Try block for simple FETCH request"); var response = await fetchWithTimeout('https://jsonplaceholder.typicode.com/posts/1', {}, 5000); //console.log("After simple API execution"); //const responseData = await response.json(); //console.log("Simple API response", responseData); console.log(`i = ${i} - `, response.status); if (i > 95){ console.log(response.headers); //console.log(response); } if (response.status == 429){ console.log(response.headers); console.log(response); } } catch (error) { console.log("Caught error in outer block:", error); } } return "test"; });// code placeholder
- Run the app and observe the output logged by the console.log() statements.
- Observe that the Headers of the responses after the 95th call do not bring anything similar to x-ratelimit-nearlimit to point that the rate limit is close to be hit.
Expected Results
Headers of the responses should bring something similar to x-ratelimit-nearlimit to point that the rate limit is close to be hit.
Actual Results
Headers of the responses do NOT bring anything similar to x-ratelimit-nearlimit to point that the rate limit is close to be hit.
Workaround
Currently there is no known workaround for this behavior. A workaround will be added here when available
- mentioned in
-
Page Loading...