gce_au_worker: Add a loop counter to avoid instance name collision
Instances are named with the timestamp (second precision) when they are created.
If multiple instances are created in the same second, name collisions happen.
While this may sound rare, due to the fact that instance names are bound in a
non-blocking forloop, this does happen, actually frequently. So we are adding a
forloop counter as a suffix to avoid collisions.
TEST=unit test and trybot run against lakitu-pre-cq, with a custom
gce_tests.json that has multiple test entries.
Commit-Ready: Daniel Wang <firstname.lastname@example.org>
Tested-by: Daniel Wang <email@example.com>
Reviewed-by: Amey Deshpande <firstname.lastname@example.org>
1 file changed