RayB
RayB

Reputation: 2336

Does gcloud app versions delete remove instances immediately?

When I run gcloud app versions delete (docs) it often takes a while (2-5 minutes) to delete a version.

When that command is finished do that mean the version is totally deleted?

Upvotes: 0

Views: 149

Answers (1)

RayB
RayB

Reputation: 2336

Answering my own question here because the inconsistent behavior took a while to debug.

When you delete a Google App Engine Standard instance using the CLI it seems to be deleted pretty much immediately. If you check operations by running gcloud app operations list it won't be in the pending state for more than a second or two.

However, when you delete a Google App Engine Flexible instance using the CLI it is still in a pending state for 5-10 minutes after the the CLI command seems to have been finished.

I reached out to GCP support about this and they said:

It is normal that the version may still be completing some steps in the background shortly after the delete command is complete and remain in PENDING state for a short time.

Edit: I have since wrote a script to wait for GAE operations to finish before moving on. It's available here: https://gist.github.com/RayBB/0b442641ad740701ef5c96f5f9ef9dd9

Upvotes: 1

Related Questions