heat.engine.clients.os.sahara module

class heat.engine.clients.os.sahara.ClusterConstraint[source]

Bases: SaharaBaseConstraint

resource_name = 'clusters'
class heat.engine.clients.os.sahara.ClusterTemplateConstraint[source]

Bases: SaharaBaseConstraint

resource_name = 'cluster_templates'
class heat.engine.clients.os.sahara.DataSourceConstraint[source]

Bases: SaharaBaseConstraint

resource_name = 'data_sources'
class heat.engine.clients.os.sahara.ImageConstraint[source]

Bases: SaharaBaseConstraint

resource_name = 'images'
class heat.engine.clients.os.sahara.JobBinaryConstraint[source]

Bases: SaharaBaseConstraint

resource_name = 'job_binaries'
class heat.engine.clients.os.sahara.JobTypeConstraint[source]

Bases: BaseCustomConstraint

resource_client_name = 'sahara'
resource_getter_name = 'get_job_type'
class heat.engine.clients.os.sahara.PluginConstraint[source]

Bases: BaseCustomConstraint

resource_client_name = 'sahara'
resource_getter_name = 'get_plugin_id'
class heat.engine.clients.os.sahara.SaharaBaseConstraint[source]

Bases: BaseCustomConstraint

expected_exceptions = (<class 'heat.common.exception.EntityNotFound'>, <class 'heat.common.exception.PhysicalResourceNameAmbiguity'>)
resource_name = None
validate_with_client(client, resource_id)[source]
class heat.engine.clients.os.sahara.SaharaClientPlugin(context)[source]

Bases: ClientPlugin

DATA_PROCESSING = 'data-processing'
exceptions_module = <module 'saharaclient.api.base' from '/home/zuul/src/opendev.org/openstack/heat/.tox/docs/lib/python3.10/site-packages/saharaclient/api/base.py'>
find_resource_by_name(resource_name, value)[source]

Return the ID for the specified entity name.

Raises:
find_resource_by_name_or_id(resource_name, value)[source]

Return the ID for the specified name or identifier.

Parameters:
  • resource_name – API name of entity

  • value – ID or name of entity

Returns:

the id of the requested :value:

Raises:
get_image_id(image_identifier)[source]

Return the ID for the specified image name or identifier.

Parameters:

image_identifier – image name or a UUID-like identifier

Returns:

the id of the requested :image_identifier:

Raises:
get_job_type(job_type)[source]

Find the job type

Parameters:

job_type – the name of sahara job type to find

Returns:

the name of :job_type:

Raises:

exception.EntityNotFound

get_plugin_id(plugin_name)[source]

Get the id for the specified plugin name.

Parameters:

plugin_name – the name of the plugin to find

Returns:

the id of :plugin:

Raises:

exception.EntityNotFound

is_conflict(ex)[source]

Returns True if the exception is a conflict.

is_not_found(ex)[source]

Returns True if the exception is a not-found.

is_not_registered(ex)[source]
is_over_limit(ex)[source]

Returns True if the exception is an over-limit.

service_types = ['data-processing']
validate_hadoop_version(plugin_name, hadoop_version)[source]