class LogGroupGrants
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.Logs.LogGroupGrants |
Go | github.com/aws/aws-cdk-go/awscdk/v2/awslogs#LogGroupGrants |
Java | software.amazon.awscdk.services.logs.LogGroupGrants |
Python | aws_cdk.aws_logs.LogGroupGrants |
TypeScript | aws-cdk-lib » aws_logs » LogGroupGrants |
Collection of grant methods for a ILogGroupRef.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_logs as logs } from 'aws-cdk-lib';
import { aws_logs as interfaces_aws_logs } from 'aws-cdk-lib/interfaces';
declare const logGroupRef: interfaces_aws_logs.ILogGroupRef;
const logGroupGrants = logs.LogGroupGrants.fromLogGroup(logGroupRef);
Properties
| Name | Type | Description |
|---|---|---|
| resource | ILog | |
| policy | IResource |
resource
Type:
ILog
policyResource?
Type:
IResource
(optional)
Methods
| Name | Description |
|---|---|
| read(grantee) | Give permissions to read and filter events from this log group. |
| write(grantee) | Give permissions to create and write to streams in this log group. |
| static from | Creates grants for LogGroupGrants. |
read(grantee)
public read(grantee: IGrantable): Grant
Parameters
- grantee
IGrantable
Returns
Give permissions to read and filter events from this log group.
write(grantee)
public write(grantee: IGrantable): Grant
Parameters
- grantee
IGrantable
Returns
Give permissions to create and write to streams in this log group.
static fromLogGroup(resource)
public static fromLogGroup(resource: ILogGroupRef): LogGroupGrants
Parameters
- resource
ILogGroup Ref
Returns
Creates grants for LogGroupGrants.

.NET
Go
Java
Python
TypeScript