aws logo
AWS Classic v5.33.0, Mar 24 23

aws.rds.getEventCategories

Example Usage

List the event categories of all the RDS resources.

using System.Collections.Generic;
using Pulumi;
using Aws = Pulumi.Aws;

return await Deployment.RunAsync(() => 
{
    var exampleEventCategories = Aws.Rds.GetEventCategories.Invoke();

    return new Dictionary<string, object?>
    {
        ["example"] = exampleEventCategories.Apply(getEventCategoriesResult => getEventCategoriesResult.EventCategories),
    };
});
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/rds"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		exampleEventCategories, err := rds.GetEventCategories(ctx, nil, nil)
		if err != nil {
			return err
		}
		ctx.Export("example", exampleEventCategories.EventCategories)
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.rds.RdsFunctions;
import com.pulumi.aws.rds.inputs.GetEventCategoriesArgs;
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 exampleEventCategories = RdsFunctions.getEventCategories();

        ctx.export("example", exampleEventCategories.applyValue(getEventCategoriesResult -> getEventCategoriesResult.eventCategories()));
    }
}
import pulumi
import pulumi_aws as aws

example_event_categories = aws.rds.get_event_categories()
pulumi.export("example", example_event_categories.event_categories)
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const exampleEventCategories = aws.rds.getEventCategories({});
export const example = exampleEventCategories.then(exampleEventCategories => exampleEventCategories.eventCategories);
variables:
  exampleEventCategories:
    fn::invoke:
      Function: aws:rds:getEventCategories
      Arguments: {}
outputs:
  example: ${exampleEventCategories.eventCategories}

.

using System.Collections.Generic;
using Pulumi;
using Aws = Pulumi.Aws;

return await Deployment.RunAsync(() => 
{
    var exampleEventCategories = Aws.Rds.GetEventCategories.Invoke(new()
    {
        SourceType = "db-snapshot",
    });

    return new Dictionary<string, object?>
    {
        ["example"] = exampleEventCategories.Apply(getEventCategoriesResult => getEventCategoriesResult.EventCategories),
    };
});
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/rds"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		exampleEventCategories, err := rds.GetEventCategories(ctx, &rds.GetEventCategoriesArgs{
			SourceType: pulumi.StringRef("db-snapshot"),
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("example", exampleEventCategories.EventCategories)
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.rds.RdsFunctions;
import com.pulumi.aws.rds.inputs.GetEventCategoriesArgs;
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 exampleEventCategories = RdsFunctions.getEventCategories(GetEventCategoriesArgs.builder()
            .sourceType("db-snapshot")
            .build());

        ctx.export("example", exampleEventCategories.applyValue(getEventCategoriesResult -> getEventCategoriesResult.eventCategories()));
    }
}
import pulumi
import pulumi_aws as aws

example_event_categories = aws.rds.get_event_categories(source_type="db-snapshot")
pulumi.export("example", example_event_categories.event_categories)
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const exampleEventCategories = aws.rds.getEventCategories({
    sourceType: "db-snapshot",
});
export const example = exampleEventCategories.then(exampleEventCategories => exampleEventCategories.eventCategories);
variables:
  exampleEventCategories:
    fn::invoke:
      Function: aws:rds:getEventCategories
      Arguments:
        sourceType: db-snapshot
outputs:
  example: ${exampleEventCategories.eventCategories}

Using getEventCategories

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 getEventCategories(args: GetEventCategoriesArgs, opts?: InvokeOptions): Promise<GetEventCategoriesResult>
function getEventCategoriesOutput(args: GetEventCategoriesOutputArgs, opts?: InvokeOptions): Output<GetEventCategoriesResult>
def get_event_categories(source_type: Optional[str] = None,
                         opts: Optional[InvokeOptions] = None) -> GetEventCategoriesResult
def get_event_categories_output(source_type: Optional[pulumi.Input[str]] = None,
                         opts: Optional[InvokeOptions] = None) -> Output[GetEventCategoriesResult]
func GetEventCategories(ctx *Context, args *GetEventCategoriesArgs, opts ...InvokeOption) (*GetEventCategoriesResult, error)
func GetEventCategoriesOutput(ctx *Context, args *GetEventCategoriesOutputArgs, opts ...InvokeOption) GetEventCategoriesResultOutput

> Note: This function is named GetEventCategories in the Go SDK.

public static class GetEventCategories 
{
    public static Task<GetEventCategoriesResult> InvokeAsync(GetEventCategoriesArgs args, InvokeOptions? opts = null)
    public static Output<GetEventCategoriesResult> Invoke(GetEventCategoriesInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetEventCategoriesResult> getEventCategories(GetEventCategoriesArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
  function: aws:rds/getEventCategories:getEventCategories
  arguments:
    # arguments dictionary

The following arguments are supported:

SourceType string

Type of source that will be generating the events. Valid options are db-instance, db-security-group, db-parameter-group, db-snapshot, db-cluster or db-cluster-snapshot.

SourceType string

Type of source that will be generating the events. Valid options are db-instance, db-security-group, db-parameter-group, db-snapshot, db-cluster or db-cluster-snapshot.

sourceType String

Type of source that will be generating the events. Valid options are db-instance, db-security-group, db-parameter-group, db-snapshot, db-cluster or db-cluster-snapshot.

sourceType string

Type of source that will be generating the events. Valid options are db-instance, db-security-group, db-parameter-group, db-snapshot, db-cluster or db-cluster-snapshot.

source_type str

Type of source that will be generating the events. Valid options are db-instance, db-security-group, db-parameter-group, db-snapshot, db-cluster or db-cluster-snapshot.

sourceType String

Type of source that will be generating the events. Valid options are db-instance, db-security-group, db-parameter-group, db-snapshot, db-cluster or db-cluster-snapshot.

getEventCategories Result

The following output properties are available:

EventCategories List<string>

List of the event categories.

Id string

The provider-assigned unique ID for this managed resource.

SourceType string
EventCategories []string

List of the event categories.

Id string

The provider-assigned unique ID for this managed resource.

SourceType string
eventCategories List<String>

List of the event categories.

id String

The provider-assigned unique ID for this managed resource.

sourceType String
eventCategories string[]

List of the event categories.

id string

The provider-assigned unique ID for this managed resource.

sourceType string
event_categories Sequence[str]

List of the event categories.

id str

The provider-assigned unique ID for this managed resource.

source_type str
eventCategories List<String>

List of the event categories.

id String

The provider-assigned unique ID for this managed resource.

sourceType String

Package Details

Repository
AWS Classic pulumi/pulumi-aws
License
Apache-2.0
Notes

This Pulumi package is based on the aws Terraform Provider.