X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/2f83fcd45b4b23db2bb5bb4afbe1e863ebd77ec6..2c0bf8219eb3ff5f978d147bff7ae6c6a73e8188:/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