Skip to main content

environment_operations

Creates, updates, deletes, gets or lists an environment_operations resource.

Overview​

Nameenvironment_operations
TypeResource
Iddatabricks_workspace.environments.environment_operations

Fields​

The following fields are returned by SELECT queries:

NameDatatypeDescription
namestringThe server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the ``name`` should be a resource name ending with ``operations/{unique_id}``.
donebooleanIf the value is ``false``, it means the operation is still in progress. If ``true``, the operation is completed, and either ``error`` or ``response`` is available.
â–¶errorobjectThe error result of the operation in case of failure or cancellation.
metadataobjectService-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata.
responseobjectThe normal, successful response of the operation.

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectname, deployment_name, workspace_domainGets the status of a long-running operation. Clients can use this method to poll the operation result.

Parameters​

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
deployment_namestringThe Databricks workspace deployment name: the host prefix of the workspace URL (dbc-abcd0123-a1bc on AWS, adb-1234567890123456.7 on Azure, 1234567890123456.7 on GCP). Set DATABRICKS_DEPLOYMENT_NAME to default it for the session. (default: dbc-abcd0123-a1bc, x-stackQL-envVar: DATABRICKS_DEPLOYMENT_NAME)
namestringThe name of the operation resource.
workspace_domainstringThe Databricks workspace domain suffix for the cloud. Selected by DATABRICKS_CLOUD (aws, azure or gcp; default aws). (default: cloud.databricks.com, x-stackQL-envVarSelector: {"envVar":"DATABRICKS_CLOUD","default":"aws","values":{"aws":"cloud.databricks.com","azure":"azuredatabricks.net","gcp":"gcp.databricks.com"}})

SELECT examples​

Gets the status of a long-running operation. Clients can use this method to poll the operation result.

SELECT
name,
done,
error,
metadata,
response
FROM databricks_workspace.environments.environment_operations
WHERE name = '{{ name }}' -- required
AND deployment_name = '{{ deployment_name }}' -- required
AND workspace_domain = '{{ workspace_domain }}' -- required
;