Class FlowLog

java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.Resource
software.amazon.awscdk.services.ec2.FlowLog
All Implemented Interfaces:
IResource, IFlowLog, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.104.0 (build e79254c)", date="2024-11-27T16:50:56.568Z") @Stability(Stable) public class FlowLog extends Resource implements IFlowLog
A VPC flow log.

Example:

 CfnTransitGateway tgw;
 FlowLog.Builder.create(this, "TransitGatewayFlowLog")
         .resourceType(FlowLogResourceType.fromTransitGatewayId(tgw.getRef()))
         .build();
 
  • Constructor Details

    • FlowLog

      protected FlowLog(software.amazon.jsii.JsiiObjectRef objRef)
    • FlowLog

      protected FlowLog(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • FlowLog

      @Stability(Stable) public FlowLog(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull FlowLogProps props)
      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      props - This parameter is required.
  • Method Details

    • fromFlowLogId

      @Stability(Stable) @NotNull public static IFlowLog fromFlowLogId(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String flowLogId)
      Import a Flow Log by it's Id.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      flowLogId - This parameter is required.
    • getFlowLogId

      @Stability(Stable) @NotNull public String getFlowLogId()
      The Id of the VPC Flow Log.
      Specified by:
      getFlowLogId in interface IFlowLog
    • getBucket

      @Stability(Stable) @Nullable public IBucket getBucket()
      The S3 bucket to publish flow logs to.
    • getDeliveryStreamArn

      @Stability(Stable) @Nullable public String getDeliveryStreamArn()
      The ARN of the Kinesis Data Firehose delivery stream to publish flow logs to.
    • getIamRole

      @Stability(Stable) @Nullable public IRole getIamRole()
      The iam role used to publish logs to CloudWatch.
    • getKeyPrefix

      @Stability(Stable) @Nullable public String getKeyPrefix()
      S3 bucket key prefix to publish the flow logs under.
    • getLogGroup

      @Stability(Stable) @Nullable public ILogGroup getLogGroup()
      The CloudWatch Logs LogGroup to publish flow logs to.