cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

Creating Collections within retry blocks

jason1
Deputy Chef I
Deputy Chef I

We have error handling retry logic that re-runs our recipe up to some max_attempts whenever we hit API rate limits. Since our recipe creates a Collection as part of its logic, we started seeing failures due to "table name already exists" -- which I suspect is because you can only create a single Collection for a list once in a given recipe.


Are there any good workarounds for this?

9 REPLIES 9

gordon-hu
Deputy Chef I
Deputy Chef I

Hi I have the same issue. It seems that during the retry, Workato was not smart enough to โ€œclearโ€ the Collection. In the end, we just decided not to retry โ€ฆ.

 

Is it a bug? Feature request? ๐Ÿ˜Š

 

Gordon

 

ajorde
Deputy Chef II
Deputy Chef II

A couple options I've done on this - name your collection with the name you want, but append the retry count to the name. It looks silly but it still runs correctly. Option 2 - create your collection outside the error monitor and right after the monitor starts, delete the records from the collection so that you know you're starting fresh with an empty collection.

jason1
Deputy Chef I
Deputy Chef I

Amazing. Amy Jorde and Simon Zelazo using the attempt number variable seemed to do the trick. Thank you!

ajorde
Deputy Chef II
Deputy Chef II

Small caveat - just make sure when you're querying results back that you're querying the right version of the collection with the retry count name.