Hi, i wrote an async automation that grant permissions to specific DB groups according to folders paths for an existing folders structure.
This structure gets built using a different automation but both are individual from each other.
on my logic i'm using multiple DB functions (by order: filesGetMetadata -> sharingShareFolder -> sharingUpdateFolderPolicy -> sharingSetAccessInheritance -> sharingUpdateFolderPolicy (owner) -> sharingAddFolderMember).
On 75% of times it's running - i'm getting an error of 'too_many_write_operations' as error in return to 'sharingAddFolderMember'.
I'm creating a list of 3-5 groups for each folder, some of the folders are exists in different paths under same mother folder. (on the other 25% it works like charm).
The whole logic is async, awaiting for each method to finish before starting the next.
Any Idea what can cause this issue? and what should be my way of thinking when designing the solution?
Thanks!!