Source code for ServiceGateway.exceptions
#!/usr/bin/env python
# coding: utf-8
"""
Various exception classes used by the service gateway and utilities.
"""
[docs]class RubberException(Exception):
"""
Base exception class for elasticity functions.
"""
pass
[docs]class InsufficientResources(RubberException):
"""
Indicates that no more room for other Virtual machine instances in given
cloud
"""
pass
[docs]class NoIdleWorkersError(RubberException):
"""
Indicates that we cannot kill any idle workers, none are idle
"""
pass
[docs]class MinimumWorkersReached(RubberException):
"""
Indicates that we are trying to terminate minimal levels of workers
"""
pass
[docs]class UnknownHostError(RubberException):
"""
Indicates that we cannot reach a given host.
"""
host = None
[docs]class NoTearDownTargets(RubberException):
"""
Indicates that no idle workers could be taken down, perhaps because they
are registered on the queue but not instanciated on the cloud. (?)
"""
pass
[docs]class IncompatibleBackendError(RubberException):
"""
Indicates that the Celery backend uses a broker type which is not
supported by the current class.
"""
pass
[docs]class NoProfilesFoundError(RubberException):
"""
Indicates that rubber could not find any service profiles on which
elasticity might be applied.
"""
pass
[docs]class SGException(Exception):
"""
Base exception class for ServiceGateway
"""
pass
[docs]class MissingParameterError(SGException):
"""
Missing parameter when calling ServiceGateway.
"""
pass