MozillaSecurity / laniakea

Laniakea is a utility for managing instances at various cloud providers and aids in setting up a fuzzing cluster.
Mozilla Public License 2.0
27 stars 12 forks source link

[GCE] API should be usable asynchronously #41

Open jschwartzentruber opened 5 years ago

jschwartzentruber commented 5 years ago

Operations like create() and terminate() block execution until completed. There should be a way of polling for state changes as we do with EC2. Not sure if there is a precedent for this in libcloud or if we would have to abandon libcloud.

posidron commented 5 years ago

https://libcloud.apache.org/blog/2017/04/09/async-rfc.html

jschwartzentruber commented 5 years ago

Yeah, that's in the API documentation too, but that's for using py3 asyncio or gevent, etc. What

I'm talking about is being able to hook provider polling so we can poll from another process using tokens or similar (eg. EC2 request ID). It looks like libcloud's async support works this way internally, but it isn't exposed directly.

I worked around this for termination in #42, and creation is fast in GCE, so it's less of an issue.