X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/7af506a0e9712ca22096ebd56df8867a427dae96..8090581c645f62fec8337b3a2b9f72448fc24431:/lib/cloud/interfaces.go diff --git a/lib/cloud/interfaces.go b/lib/cloud/interfaces.go index 7c532fda4a..a2aa9e1432 100644 --- a/lib/cloud/interfaces.go +++ b/lib/cloud/interfaces.go @@ -37,6 +37,20 @@ type QuotaError interface { error } +// A CapacityError should be returned by an InstanceSet's Create +// method when the cloud service indicates it has insufficient +// capacity to create new instances -- i.e., we shouldn't retry right +// away. +type CapacityError interface { + // If true, wait before trying to create more instances. + IsCapacityError() bool + // If true, the condition is specific to the requested + // instance types. Wait before trying to create more + // instances of that same type. + IsInstanceTypeSpecific() bool + error +} + type SharedResourceTags map[string]string type InstanceSetID string type InstanceTags map[string]string