databricks.getCatalogs
Retrieves a list of databricks.Catalog ids, that were created by Pulumi or manually, so that special handling could be applied.
This data source can only be used with a workspace-level provider!
Example Usage
Listing all catalogs:
import * as pulumi from "@pulumi/pulumi";
import * as databricks from "@pulumi/databricks";
const all = databricks.getCatalogs({});
export const allCatalogs = all;
import pulumi
import pulumi_databricks as databricks
all = databricks.get_catalogs()
pulumi.export("allCatalogs", all)
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 {
all, err := databricks.GetCatalogs(ctx, &databricks.GetCatalogsArgs{}, nil)
if err != nil {
return err
}
ctx.Export("allCatalogs", all)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Databricks = Pulumi.Databricks;
return await Deployment.RunAsync(() =>
{
var all = Databricks.GetCatalogs.Invoke();
return new Dictionary<string, object?>
{
["allCatalogs"] = all,
};
});
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.GetCatalogsArgs;
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 all = DatabricksFunctions.getCatalogs(GetCatalogsArgs.builder()
.build());
ctx.export("allCatalogs", all);
}
}
variables:
all:
fn::invoke:
function: databricks:getCatalogs
arguments: {}
outputs:
allCatalogs: ${all}
Related Resources
The following resources are used in the same context:
* databricks.Schema to manage schemas within Unity Catalog. * databricks.Catalog to manage catalogs within Unity Catalog.
Using getCatalogs
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 getCatalogs(args: GetCatalogsArgs, opts?: InvokeOptions): Promise<GetCatalogsResult>
function getCatalogsOutput(args: GetCatalogsOutputArgs, opts?: InvokeOptions): Output<GetCatalogsResult>def get_catalogs(ids: Optional[Sequence[str]] = None,
provider_config: Optional[GetCatalogsProviderConfig] = None,
opts: Optional[InvokeOptions] = None) -> GetCatalogsResult
def get_catalogs_output(ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
provider_config: Optional[pulumi.Input[GetCatalogsProviderConfigArgs]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetCatalogsResult]func GetCatalogs(ctx *Context, args *GetCatalogsArgs, opts ...InvokeOption) (*GetCatalogsResult, error)
func GetCatalogsOutput(ctx *Context, args *GetCatalogsOutputArgs, opts ...InvokeOption) GetCatalogsResultOutput> Note: This function is named GetCatalogs in the Go SDK.
public static class GetCatalogs
{
public static Task<GetCatalogsResult> InvokeAsync(GetCatalogsArgs args, InvokeOptions? opts = null)
public static Output<GetCatalogsResult> Invoke(GetCatalogsInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetCatalogsResult> getCatalogs(GetCatalogsArgs args, InvokeOptions options)
public static Output<GetCatalogsResult> getCatalogs(GetCatalogsArgs args, InvokeOptions options)
fn::invoke:
function: databricks:index/getCatalogs:getCatalogs
arguments:
# arguments dictionaryThe following arguments are supported:
- Ids List<string>
- set of databricks.Catalog names
- Provider
Config GetCatalogs Provider Config - Configure the provider for management through account provider. This block consists of the following fields:
- Ids []string
- set of databricks.Catalog names
- Provider
Config GetCatalogs Provider Config - Configure the provider for management through account provider. This block consists of the following fields:
- ids List<String>
- set of databricks.Catalog names
- provider
Config GetCatalogs Provider Config - Configure the provider for management through account provider. This block consists of the following fields:
- ids string[]
- set of databricks.Catalog names
- provider
Config GetCatalogs Provider Config - Configure the provider for management through account provider. This block consists of the following fields:
- ids Sequence[str]
- set of databricks.Catalog names
- provider_
config GetCatalogs Provider Config - Configure the provider for management through account provider. This block consists of the following fields:
- ids List<String>
- set of databricks.Catalog names
- provider
Config Property Map - Configure the provider for management through account provider. This block consists of the following fields:
getCatalogs Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids List<string>
- set of databricks.Catalog names
- Provider
Config GetCatalogs Provider Config
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids []string
- set of databricks.Catalog names
- Provider
Config GetCatalogs Provider Config
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- set of databricks.Catalog names
- provider
Config GetCatalogs Provider Config
- id string
- The provider-assigned unique ID for this managed resource.
- ids string[]
- set of databricks.Catalog names
- provider
Config GetCatalogs Provider Config
- id str
- The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- set of databricks.Catalog names
- provider_
config GetCatalogs Provider Config
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- set of databricks.Catalog names
- provider
Config Property Map
Supporting Types
GetCatalogsProviderConfig
- 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.
