X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/f34a8d68bdd096cf1b019a9806bd1e6eba028d77..24f2f4c4f0c25cbdafb974354d7aff117854923f:/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