Class LoadBalancerV2Origin

java.lang.Object
software.amazon.jsii.JsiiObject
All Implemented Interfaces:
IOrigin, software.amazon.jsii.JsiiSerializable

@Generated(value="jsii-pacmak/1.103.1 (build bef2dea)", date="2024-10-25T14:21:11.683Z") @Stability(Stable) public class LoadBalancerV2Origin extends HttpOrigin
An Origin for a v2 load balancer.

Example:

 import software.amazon.awscdk.services.ec2.*;
 import software.amazon.awscdk.services.elasticloadbalancingv2.*;
 Vpc vpc;
 // Create an application load balancer in a VPC. 'internetFacing' must be 'true'
 // for CloudFront to access the load balancer and use it as an origin.
 ApplicationLoadBalancer lb = ApplicationLoadBalancer.Builder.create(this, "LB")
         .vpc(vpc)
         .internetFacing(true)
         .build();
 Distribution.Builder.create(this, "myDist")
         .defaultBehavior(BehaviorOptions.builder().origin(new LoadBalancerV2Origin(lb)).build())
         .build();
 
  • Constructor Details

    • LoadBalancerV2Origin

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

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

      @Stability(Stable) public LoadBalancerV2Origin(@NotNull ILoadBalancerV2 loadBalancer, @Nullable LoadBalancerV2OriginProps props)
      Parameters:
      loadBalancer - This parameter is required.
      props -
    • LoadBalancerV2Origin

      @Stability(Stable) public LoadBalancerV2Origin(@NotNull ILoadBalancerV2 loadBalancer)
      Parameters:
      loadBalancer - This parameter is required.