awslogsdestinations

package
v1.155.0-devpreview Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 4, 2022 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewKinesisDestination_Override

func NewKinesisDestination_Override(k KinesisDestination, stream awskinesis.IStream, props *KinesisDestinationProps)

Experimental.

func NewLambdaDestination_Override

func NewLambdaDestination_Override(l LambdaDestination, fn awslambda.IFunction, options *LambdaDestinationOptions)

LambdaDestinationOptions. Experimental.

Types

type KinesisDestination

type KinesisDestination interface {
	awslogs.ILogSubscriptionDestination
	// Return the properties required to send subscription events to this destination.
	//
	// If necessary, the destination can use the properties of the SubscriptionFilter
	// object itself to configure its permissions to allow the subscription to write
	// to it.
	//
	// The destination may reconfigure its own permissions in response to this
	// function call.
	// Experimental.
	Bind(scope awscdk.Construct, _sourceLogGroup awslogs.ILogGroup) *awslogs.LogSubscriptionDestinationConfig
}

Use a Kinesis stream as the destination for a log subscription.

Example:

import awscdk "github.com/aws/aws-cdk-go/awscdk"import iam "github.com/aws/aws-cdk-go/awscdk/aws_iam"import awscdk "github.com/aws/aws-cdk-go/awscdk"import kinesis "github.com/aws/aws-cdk-go/awscdk/aws_kinesis"import awscdk "github.com/aws/aws-cdk-go/awscdk"import logs_destinations "github.com/aws/aws-cdk-go/awscdk/aws_logs_destinations"

var role role
var stream stream
kinesisDestination := logs_destinations.NewKinesisDestination(stream, &kinesisDestinationProps{
	role: role,
})

Experimental.

func NewKinesisDestination

func NewKinesisDestination(stream awskinesis.IStream, props *KinesisDestinationProps) KinesisDestination

Experimental.

type KinesisDestinationProps

type KinesisDestinationProps struct {
	// The role to assume to write log events to the destination.
	// Experimental.
	Role awsiam.IRole `json:"role" yaml:"role"`
}

Customize the Kinesis Logs Destination.

Example:

import awscdk "github.com/aws/aws-cdk-go/awscdk"import iam "github.com/aws/aws-cdk-go/awscdk/aws_iam"import awscdk "github.com/aws/aws-cdk-go/awscdk"import logs_destinations "github.com/aws/aws-cdk-go/awscdk/aws_logs_destinations"

var role role
kinesisDestinationProps := &kinesisDestinationProps{
	role: role,
}

Experimental.

type LambdaDestination

type LambdaDestination interface {
	awslogs.ILogSubscriptionDestination
	// Return the properties required to send subscription events to this destination.
	//
	// If necessary, the destination can use the properties of the SubscriptionFilter
	// object itself to configure its permissions to allow the subscription to write
	// to it.
	//
	// The destination may reconfigure its own permissions in response to this
	// function call.
	// Experimental.
	Bind(scope awscdk.Construct, logGroup awslogs.ILogGroup) *awslogs.LogSubscriptionDestinationConfig
}

Use a Lambda Function as the destination for a log subscription.

Example:

import destinations "github.com/aws/aws-cdk-go/awscdk"
var fn function
var logGroup logGroup

logs.NewSubscriptionFilter(this, jsii.String("Subscription"), &subscriptionFilterProps{
	logGroup: logGroup,
	destination: destinations.NewLambdaDestination(fn),
	filterPattern: logs.filterPattern.allTerms(jsii.String("ERROR"), jsii.String("MainThread")),
})

Experimental.

func NewLambdaDestination

func NewLambdaDestination(fn awslambda.IFunction, options *LambdaDestinationOptions) LambdaDestination

LambdaDestinationOptions. Experimental.

type LambdaDestinationOptions

type LambdaDestinationOptions struct {
	// Whether or not to add Lambda Permissions.
	// Experimental.
	AddPermissions *bool `json:"addPermissions" yaml:"addPermissions"`
}

Options that may be provided to LambdaDestination.

Example:

import awscdk "github.com/aws/aws-cdk-go/awscdk"import logs_destinations "github.com/aws/aws-cdk-go/awscdk/aws_logs_destinations"
lambdaDestinationOptions := &lambdaDestinationOptions{
	addPermissions: jsii.Boolean(false),
}

Experimental.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL