Pattern Errors When Running Azure Cloud Discovery

Mike I2
Giga Guru

Hi, 

 

I'm seeing multiple errors in some of the Azure patterns, e.g. Azure - Host (LP), Azure Application Gateway HD, Azure Functions, all returning the same or very similar errors. Each pattern returns, in the pattern logs: 

Exception occurred while executing operation Cloud REST - add response to context. Custom operation Failed to run script due to the following error: JAVASCRIPT_CODE_FAILURE: com.snc.sw.exception.CommandFailureException: Cloud request failed. URL: https://management.azure.com/providers/Microsoft.ResourceGraph/resources?api-version=2019-04-01 Status: 429 Response: HttpResponseProxy{HTTP/1.1 429 Too Many Requests [Cache-Control: no-cache, Pragma: no-cache, Content-Length: 421, Content-Type: application/json; charset=utf-8, Expires: -1, Retry-After: 1, Strict-Transport-Security: max-age=31536000; includeSubDomains, x-ms-correlation-request-id: 037aef4d-63e5-44e0-aca6-e02638cd0716, x-ms-user-quota-resets-after: 00:00:04, x-ms-user-quota-remaining: 0, x-ms-ratelimit-remaining-tenant-resource-requests: 0, x-ms-resource-graph-request-duration: 0:00:00:00.0143723,

All with a Check Processing step message of 

Check Processing Success
2022-10-31 09:49:00: Identification Engine: Discovery status is FAILURE, Identification sections in pattern faile
d: section: Azure Host, error: Match step predicate is not matched. Failed Condition(s): [(${resource_response} : value=) IS NOT EMPTY ] .

Has anyone seen the same or similar errors?

Thanks

Mike

1 ACCEPTED SOLUTION

SiD2
ServiceNow Employee
ServiceNow Employee

Hi @Mike I2 

 

This is a known issue and due to the Azure resource throttling constraints and when we have huge hits to azure endpoints, all requests would be throttled and further throws 429 errors.

 

To mitigate this constraint from azure, we have some workarounds implemented in recent releases. Check this feature from our docs.

 

Try and let me know if it works for you.

 

Please mark Helpful / Accept Solution so that it helps others with similar questions.

View solution in original post

6 REPLIES 6

Ofer1
ServiceNow Employee
ServiceNow Employee

@SiD2  can you please be specific on how to setup the Azure portion of the script to minimize 429 errors?

if this is the default:

 

 

how should it be changed?

SiD2
ServiceNow Employee
ServiceNow Employee

Hi @Ofer1 

 

Under "Cloud Request Retry Configuration" from left nav menu, you can open the Azure configuration and play around with the default values if that doesn't solve the throttling.

 

You can increase the retries / additional delay according to your situation and see if the issue is resolved. You can even try changing the strategy too.

 

Please mark Helpful / Accept Solution so that it helps others with similar questions.