databricks.getVolumes
Retrieves a list of databricks.Volume ids (full names), that were created by Pulumi or manually.
This data source can only be used with a workspace-level provider!
Plugin Framework Migration
The volumes data source has been migrated from sdkv2 to plugin framework in version 1.57。 If you encounter any problem with this data source and suspect it is due to the migration, you can fallback to sdkv2 by setting the environment variable in the following way export USE_SDK_V2_DATA_SOURCES=<span pulumi-lang-nodejs=""databricks.getVolumes"" pulumi-lang-dotnet=""databricks.getVolumes"" pulumi-lang-go=""getVolumes"" pulumi-lang-python=""get_volumes"" pulumi-lang-yaml=""databricks.getVolumes"" pulumi-lang-java=""databricks.getVolumes"">"databricks.getVolumes"</span>.
Example Usage
Listing all volumes in a things databricks.Schema of a sandbox databricks_catalog:
import * as pulumi from "@pulumi/pulumi";
import * as databricks from "@pulumi/databricks";
const _this = databricks.getVolumes({
catalogName: "sandbox",
schemaName: "things",
});
export const allVolumes = _this;
import pulumi
import pulumi_databricks as databricks
this = databricks.get_volumes(catalog_name="sandbox",
schema_name="things")
pulumi.export("allVolumes", this)
package main
import (
"github.com/pulumi/pulumi-databricks/sdk/go/databricks"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
this, err := databricks.GetVolumes(ctx, &databricks.GetVolumesArgs{
CatalogName: "sandbox",
SchemaName: "things",
}, nil)
if err != nil {
return err
}
ctx.Export("allVolumes", this)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Databricks = Pulumi.Databricks;
return await Deployment.RunAsync(() =>
{
var @this = Databricks.GetVolumes.Invoke(new()
{
CatalogName = "sandbox",
SchemaName = "things",
});
return new Dictionary<string, object?>
{
["allVolumes"] = @this,
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.databricks.DatabricksFunctions;
import com.pulumi.databricks.inputs.GetVolumesArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var this = DatabricksFunctions.getVolumes(GetVolumesArgs.builder()
.catalogName("sandbox")
.schemaName("things")
.build());
ctx.export("allVolumes", this_);
}
}
variables:
this:
fn::invoke:
function: databricks:getVolumes
arguments:
catalogName: sandbox
schemaName: things
outputs:
allVolumes: ${this}
Related Resources
The following resources are used in the same context:
* databricks.Volume to manage volumes within Unity Catalog. * databricks.Schema to manage schemas within Unity Catalog. * databricks.Catalog to manage catalogs within Unity Catalog.
Using getVolumes
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getVolumes(args: GetVolumesArgs, opts?: InvokeOptions): Promise<GetVolumesResult>
function getVolumesOutput(args: GetVolumesOutputArgs, opts?: InvokeOptions): Output<GetVolumesResult>def get_volumes(catalog_name: Optional[str] = None,
ids: Optional[Sequence[str]] = None,
provider_config: Optional[GetVolumesProviderConfig] = None,
schema_name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetVolumesResult
def get_volumes_output(catalog_name: Optional[pulumi.Input[str]] = None,
ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
provider_config: Optional[pulumi.Input[GetVolumesProviderConfigArgs]] = None,
schema_name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetVolumesResult]func GetVolumes(ctx *Context, args *GetVolumesArgs, opts ...InvokeOption) (*GetVolumesResult, error)
func GetVolumesOutput(ctx *Context, args *GetVolumesOutputArgs, opts ...InvokeOption) GetVolumesResultOutput> Note: This function is named GetVolumes in the Go SDK.
public static class GetVolumes
{
public static Task<GetVolumesResult> InvokeAsync(GetVolumesArgs args, InvokeOptions? opts = null)
public static Output<GetVolumesResult> Invoke(GetVolumesInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetVolumesResult> getVolumes(GetVolumesArgs args, InvokeOptions options)
public static Output<GetVolumesResult> getVolumes(GetVolumesArgs args, InvokeOptions options)
fn::invoke:
function: databricks:index/getVolumes:getVolumes
arguments:
# arguments dictionaryThe following arguments are supported:
- Catalog
Name string - Name of databricks_catalog
- Schema
Name string - Name of databricks_schema
- Ids List<string>
- a list of databricks.Volume full names:
catalog.schema.volume - Provider
Config GetVolumes Provider Config - Configure the provider for management through account provider. This block consists of the following fields:
- Catalog
Name string - Name of databricks_catalog
- Schema
Name string - Name of databricks_schema
- Ids []string
- a list of databricks.Volume full names:
catalog.schema.volume - Provider
Config GetVolumes Provider Config - Configure the provider for management through account provider. This block consists of the following fields:
- catalog
Name String - Name of databricks_catalog
- schema
Name String - Name of databricks_schema
- ids List<String>
- a list of databricks.Volume full names:
catalog.schema.volume - provider
Config GetVolumes Provider Config - Configure the provider for management through account provider. This block consists of the following fields:
- catalog
Name string - Name of databricks_catalog
- schema
Name string - Name of databricks_schema
- ids string[]
- a list of databricks.Volume full names:
catalog.schema.volume - provider
Config GetVolumes Provider Config - Configure the provider for management through account provider. This block consists of the following fields:
- catalog_
name str - Name of databricks_catalog
- schema_
name str - Name of databricks_schema
- ids Sequence[str]
- a list of databricks.Volume full names:
catalog.schema.volume - provider_
config GetVolumes Provider Config - Configure the provider for management through account provider. This block consists of the following fields:
- catalog
Name String - Name of databricks_catalog
- schema
Name String - Name of databricks_schema
- ids List<String>
- a list of databricks.Volume full names:
catalog.schema.volume - provider
Config Property Map - Configure the provider for management through account provider. This block consists of the following fields:
getVolumes Result
The following output properties are available:
- Catalog
Name string - Id string
- The provider-assigned unique ID for this managed resource.
- Ids List<string>
- a list of databricks.Volume full names:
catalog.schema.volume - Schema
Name string - Provider
Config GetVolumes Provider Config
- Catalog
Name string - Id string
- The provider-assigned unique ID for this managed resource.
- Ids []string
- a list of databricks.Volume full names:
catalog.schema.volume - Schema
Name string - Provider
Config GetVolumes Provider Config
- catalog
Name String - id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- a list of databricks.Volume full names:
catalog.schema.volume - schema
Name String - provider
Config GetVolumes Provider Config
- catalog
Name string - id string
- The provider-assigned unique ID for this managed resource.
- ids string[]
- a list of databricks.Volume full names:
catalog.schema.volume - schema
Name string - provider
Config GetVolumes Provider Config
- catalog_
name str - id str
- The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- a list of databricks.Volume full names:
catalog.schema.volume - schema_
name str - provider_
config GetVolumes Provider Config
- catalog
Name String - id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- a list of databricks.Volume full names:
catalog.schema.volume - schema
Name String - provider
Config Property Map
Supporting Types
GetVolumesProviderConfig
- Workspace
Id string - Workspace ID which the resource belongs to. This workspace must be part of the account which the provider is configured with.
- Workspace
Id string - Workspace ID which the resource belongs to. This workspace must be part of the account which the provider is configured with.
- workspace
Id String - Workspace ID which the resource belongs to. This workspace must be part of the account which the provider is configured with.
- workspace
Id string - Workspace ID which the resource belongs to. This workspace must be part of the account which the provider is configured with.
- workspace_
id str - Workspace ID which the resource belongs to. This workspace must be part of the account which the provider is configured with.
- workspace
Id String - Workspace ID which the resource belongs to. This workspace must be part of the account which the provider is configured with.
Package Details
- Repository
- databricks pulumi/pulumi-databricks
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
databricksTerraform Provider.
