Incorrect Status Code?

228 views
Skip to first unread message

Vlad Kuznetsov

unread,
Mar 1, 2021, 4:50:55 PM3/1/21
to AdWords API and Google Ads API Forum
I am receiving this error:
`{ "StatusCode": 3, "Details": "Request contains an invalid argument.", "RequestId": "uiLQ6D9gihouYpNmE0lsuQ", "Failure": { "errors": [ { "errorCode": { "databaseError": "CONCURRENT_MODIFICATION" }, "message": "Multiple requests were attempting to modify the same resource at once. Please retry the request." } ] } }`

The status code and the details state that the request is flawed. The error and the message state that it's an internal issue and that the request should be retried. 

Is this inconsistency on purpose? Shouldn't the error code be 14 (Unavailable) in this case?

Google Ads API Forum Advisor Prod

unread,
Mar 2, 2021, 2:44:56 PM3/2/21
to adwor...@googlegroups.com

Hi Vlad,

Thank you for reaching out. One possibility is that these two errors might both exist. Please check to make sure the fields are set correctly and also make sure that there is no concurrent modification on the same entity.

Thanks and regards,
Xiaoming, Google Ads API Team
 


Google Logo
Xiaoming
Google Ads API Team
 


ref:_00D1U1174p._5004Q2DKBTj:ref

Vlad Kuznetsov

unread,
Mar 2, 2021, 9:15:48 PM3/2/21
to AdWords API and Google Ads API Forum
Hi, thank you for the reply.

The fields are set correctly, because when I retried the request was executed properly. So it was only one error.

This particular request was to add a number of AdGroupCriterions (batched) to a Listing Tree of a Campaign by calling `MutateAdGroupCriteriaAsync`. I was adding approx ~1500 listing groups to a newly created campaign. No concurrent modifications from my point of view but can't speak for the Google Ads API internals.

I still believe in this specific case the StatusCode was given out incorrectly and I am wondering if this needs to be addressed. The reason I am concerned about this is that Google itself recommends a retry logic on the errors like this, but the StatusCode here doesn't indicate that this is a retriable error. I really don't want to parse the message text and search for words "Please retry the request." and not to rely on the StatusCode.... 

Thank you,
Vlad.

Google Ads API Forum Advisor Prod

unread,
Mar 3, 2021, 3:02:05 PM3/3/21
to adwor...@googlegroups.com

Hi Vlad,

Thank you for reaching out. The Status code might be raised by some other transient issue. The CONCURRENT_MODIFICATION error could be from the API side or both the API and the UI sides. It should be fine if it’s just a transient issue.



Thanks and regards,
Xiaoming, Google Ads API Team
 

Reply all
Reply to author
Forward
0 new messages