subcategory |
---|
Unity Catalog |
-> This resource can only be used with a workspace-level provider!
This resource allows you to create Models in Unity Catalog in Databricks.
resource "databricks_registered_model" "this" {
name = "my_model"
catalog_name = "main"
schema_name = "default"
}
The following arguments are supported:
name
- (Required) The name of the registered model. Change of this parameter forces recreation of the resource.catalog_name
- (Required) The name of the catalog where the schema and the registered model reside. Change of this parameter forces recreation of the resource.schema_name
- (Required) The name of the schema where the registered model resides. Change of this parameter forces recreation of the resource.owner
- (Optional) Name of the registered model owner.comment
- (Optional) The comment attached to the registered model.storage_location
- (Optional) The storage location under which model version data files are stored. Change of this parameter forces recreation of the resource.
In addition to all arguments above, the following attributes are exported:
id
- Equal to the full name of the model (catalog_name.schema_name.name
) and used to identify the model uniquely across the metastore.
- databricks_grants can be used to grant principals
ALL_PRIVILEGES
,APPLY_TAG
, andEXECUTE
privileges.
The registered model resource can be imported using the full (3-level) name of the model.
terraform import databricks_registered_model.this <catalog_name.schema_name.model_name>
The following resources are often used in the same context:
- databricks_model_serving to serve this model on a Databricks serving endpoint.
- databricks_mlflow_experiment to manage MLflow experiments in Databricks.
- databricks_schema to manage schemas within Unity Catalog.
- databricks_catalog to manage catalogs within Unity Catalog.