@pulumi/databricks
Version:
A Pulumi package for creating and managing databricks cloud resources.
144 lines • 6.79 kB
JavaScript
// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.getSqlWarehouseOutput = exports.getSqlWarehouse = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("./utilities");
/**
* > **Note** If you have a fully automated setup with workspaces created by databricks.MwsWorkspaces or azurerm_databricks_workspace, please make sure to add dependsOn attribute in order to prevent _default auth: cannot configure default credentials_ errors.
*
* Retrieves information about a databricks.getSqlWarehouse using its id. This could be retrieved programmatically using databricks.getSqlWarehouses data source.
*
* ## Example Usage
*
* * Retrieve attributes of each SQL warehouses in a workspace:
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as databricks from "@pulumi/databricks";
*
* const all = databricks.getSqlWarehouses({});
* const _this = all.then(all => .reduce((__obj, [__key, __value]) => ({ ...__obj, [__key]: databricks.getSqlWarehouse({
* id: __value,
* }) })));
* ```
*
* * Search for a specific SQL Warehouse by name:
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as databricks from "@pulumi/databricks";
*
* const all = databricks.getSqlWarehouse({
* name: "Starter Warehouse",
* });
* ```
*
* ## Related resources
*
* The following resources are often used in the same context:
*
* * End to end workspace management guide.
* * databricks.InstanceProfile to manage AWS EC2 instance profiles that users can launch databricks.Cluster and access data, like databricks_mount.
* * databricks.SqlDashboard to manage Databricks SQL [Dashboards](https://docs.databricks.com/sql/user/dashboards/index.html).
* * databricks.SqlGlobalConfig to configure the security policy, databricks_instance_profile, and [data access properties](https://docs.databricks.com/sql/admin/data-access-configuration.html) for all databricks.getSqlWarehouse of workspace.
* * databricks.SqlPermissions to manage data object access control lists in Databricks workspaces for things like tables, views, databases, and [more](https://docs.databricks.com/security/access-control/table-acls/object-privileges.html).
*/
function getSqlWarehouse(args, opts) {
args = args || {};
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
return pulumi.runtime.invoke("databricks:index/getSqlWarehouse:getSqlWarehouse", {
"autoStopMins": args.autoStopMins,
"channel": args.channel,
"clusterSize": args.clusterSize,
"creatorName": args.creatorName,
"dataSourceId": args.dataSourceId,
"enablePhoton": args.enablePhoton,
"enableServerlessCompute": args.enableServerlessCompute,
"health": args.health,
"id": args.id,
"instanceProfileArn": args.instanceProfileArn,
"jdbcUrl": args.jdbcUrl,
"maxNumClusters": args.maxNumClusters,
"minNumClusters": args.minNumClusters,
"name": args.name,
"numActiveSessions": args.numActiveSessions,
"numClusters": args.numClusters,
"odbcParams": args.odbcParams,
"spotInstancePolicy": args.spotInstancePolicy,
"state": args.state,
"tags": args.tags,
"warehouseType": args.warehouseType,
}, opts);
}
exports.getSqlWarehouse = getSqlWarehouse;
/**
* > **Note** If you have a fully automated setup with workspaces created by databricks.MwsWorkspaces or azurerm_databricks_workspace, please make sure to add dependsOn attribute in order to prevent _default auth: cannot configure default credentials_ errors.
*
* Retrieves information about a databricks.getSqlWarehouse using its id. This could be retrieved programmatically using databricks.getSqlWarehouses data source.
*
* ## Example Usage
*
* * Retrieve attributes of each SQL warehouses in a workspace:
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as databricks from "@pulumi/databricks";
*
* const all = databricks.getSqlWarehouses({});
* const _this = all.then(all => .reduce((__obj, [__key, __value]) => ({ ...__obj, [__key]: databricks.getSqlWarehouse({
* id: __value,
* }) })));
* ```
*
* * Search for a specific SQL Warehouse by name:
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as databricks from "@pulumi/databricks";
*
* const all = databricks.getSqlWarehouse({
* name: "Starter Warehouse",
* });
* ```
*
* ## Related resources
*
* The following resources are often used in the same context:
*
* * End to end workspace management guide.
* * databricks.InstanceProfile to manage AWS EC2 instance profiles that users can launch databricks.Cluster and access data, like databricks_mount.
* * databricks.SqlDashboard to manage Databricks SQL [Dashboards](https://docs.databricks.com/sql/user/dashboards/index.html).
* * databricks.SqlGlobalConfig to configure the security policy, databricks_instance_profile, and [data access properties](https://docs.databricks.com/sql/admin/data-access-configuration.html) for all databricks.getSqlWarehouse of workspace.
* * databricks.SqlPermissions to manage data object access control lists in Databricks workspaces for things like tables, views, databases, and [more](https://docs.databricks.com/security/access-control/table-acls/object-privileges.html).
*/
function getSqlWarehouseOutput(args, opts) {
args = args || {};
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
return pulumi.runtime.invokeOutput("databricks:index/getSqlWarehouse:getSqlWarehouse", {
"autoStopMins": args.autoStopMins,
"channel": args.channel,
"clusterSize": args.clusterSize,
"creatorName": args.creatorName,
"dataSourceId": args.dataSourceId,
"enablePhoton": args.enablePhoton,
"enableServerlessCompute": args.enableServerlessCompute,
"health": args.health,
"id": args.id,
"instanceProfileArn": args.instanceProfileArn,
"jdbcUrl": args.jdbcUrl,
"maxNumClusters": args.maxNumClusters,
"minNumClusters": args.minNumClusters,
"name": args.name,
"numActiveSessions": args.numActiveSessions,
"numClusters": args.numClusters,
"odbcParams": args.odbcParams,
"spotInstancePolicy": args.spotInstancePolicy,
"state": args.state,
"tags": args.tags,
"warehouseType": args.warehouseType,
}, opts);
}
exports.getSqlWarehouseOutput = getSqlWarehouseOutput;
//# sourceMappingURL=getSqlWarehouse.js.map
;