Documentation ¶
Index ¶
- func CfnLoadBalancer_CFN_RESOURCE_TYPE_NAME() *string
- func CfnLoadBalancer_IsCfnElement(x interface{}) *bool
- func CfnLoadBalancer_IsCfnResource(construct constructs.IConstruct) *bool
- func CfnLoadBalancer_IsConstruct(x interface{}) *bool
- func LoadBalancer_IsConstruct(x interface{}) *bool
- func LoadBalancer_IsResource(construct constructs.IConstruct) *bool
- func NewCfnLoadBalancer_Override(c CfnLoadBalancer, scope constructs.Construct, id *string, ...)
- func NewListenerPort_Override(l ListenerPort, securityGroup awsec2.ISecurityGroup, defaultPort awsec2.Port)
- func NewLoadBalancer_Override(l LoadBalancer, scope constructs.Construct, id *string, ...)
- type CfnLoadBalancer
- type CfnLoadBalancerProps
- type CfnLoadBalancer_AccessLoggingPolicyProperty
- type CfnLoadBalancer_AppCookieStickinessPolicyProperty
- type CfnLoadBalancer_ConnectionDrainingPolicyProperty
- type CfnLoadBalancer_ConnectionSettingsProperty
- type CfnLoadBalancer_HealthCheckProperty
- type CfnLoadBalancer_LBCookieStickinessPolicyProperty
- type CfnLoadBalancer_ListenersProperty
- type CfnLoadBalancer_PoliciesProperty
- type HealthCheck
- type ILoadBalancerTarget
- type ListenerPort
- type LoadBalancer
- type LoadBalancerListener
- type LoadBalancerProps
- type LoadBalancingProtocol
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CfnLoadBalancer_CFN_RESOURCE_TYPE_NAME ¶
func CfnLoadBalancer_CFN_RESOURCE_TYPE_NAME() *string
func CfnLoadBalancer_IsCfnElement ¶
func CfnLoadBalancer_IsCfnElement(x interface{}) *bool
Returns `true` if a construct is a stack element (i.e. part of the synthesized cloudformation template).
Uses duck-typing instead of `instanceof` to allow stack elements from different versions of this library to be included in the same stack.
Returns: The construct as a stack element or undefined if it is not a stack element. Experimental.
func CfnLoadBalancer_IsCfnResource ¶
func CfnLoadBalancer_IsCfnResource(construct constructs.IConstruct) *bool
Check whether the given construct is a CfnResource. Experimental.
func CfnLoadBalancer_IsConstruct ¶
func CfnLoadBalancer_IsConstruct(x interface{}) *bool
Checks if `x` is a construct.
Returns: true if `x` is an object created from a class which extends `Construct`. Deprecated: use `x instanceof Construct` instead
func LoadBalancer_IsConstruct ¶
func LoadBalancer_IsConstruct(x interface{}) *bool
Checks if `x` is a construct.
Returns: true if `x` is an object created from a class which extends `Construct`. Deprecated: use `x instanceof Construct` instead
func LoadBalancer_IsResource ¶
func LoadBalancer_IsResource(construct constructs.IConstruct) *bool
Check whether the given construct is a Resource. Experimental.
func NewCfnLoadBalancer_Override ¶
func NewCfnLoadBalancer_Override(c CfnLoadBalancer, scope constructs.Construct, id *string, props *CfnLoadBalancerProps)
Create a new `AWS::ElasticLoadBalancing::LoadBalancer`.
func NewListenerPort_Override ¶
func NewListenerPort_Override(l ListenerPort, securityGroup awsec2.ISecurityGroup, defaultPort awsec2.Port)
Experimental.
func NewLoadBalancer_Override ¶
func NewLoadBalancer_Override(l LoadBalancer, scope constructs.Construct, id *string, props *LoadBalancerProps)
Experimental.
Types ¶
type CfnLoadBalancer ¶
type CfnLoadBalancer interface { awscdk.CfnResource awscdk.IInspectable AccessLoggingPolicy() interface{} SetAccessLoggingPolicy(val interface{}) AppCookieStickinessPolicy() interface{} SetAppCookieStickinessPolicy(val interface{}) AttrCanonicalHostedZoneName() *string AttrCanonicalHostedZoneNameId() *string AttrDnsName() *string AttrSourceSecurityGroupGroupName() *string AttrSourceSecurityGroupOwnerAlias() *string AvailabilityZones() *[]*string SetAvailabilityZones(val *[]*string) CfnOptions() awscdk.ICfnResourceOptions CfnProperties() *map[string]interface{} CfnResourceType() *string ConnectionDrainingPolicy() interface{} SetConnectionDrainingPolicy(val interface{}) ConnectionSettings() interface{} SetConnectionSettings(val interface{}) CreationStack() *[]*string CrossZone() interface{} SetCrossZone(val interface{}) HealthCheck() interface{} SetHealthCheck(val interface{}) Instances() *[]*string SetInstances(val *[]*string) LbCookieStickinessPolicy() interface{} SetLbCookieStickinessPolicy(val interface{}) Listeners() interface{} SetListeners(val interface{}) LoadBalancerName() *string SetLoadBalancerName(val *string) LogicalId() *string Node() constructs.Node Policies() interface{} SetPolicies(val interface{}) Ref() *string Scheme() *string SetScheme(val *string) SecurityGroups() *[]*string SetSecurityGroups(val *[]*string) Stack() awscdk.Stack Subnets() *[]*string SetSubnets(val *[]*string) Tags() awscdk.TagManager UpdatedProperites() *map[string]interface{} AddDeletionOverride(path *string) AddDependsOn(target awscdk.CfnResource) AddMetadata(key *string, value interface{}) AddOverride(path *string, value interface{}) AddPropertyDeletionOverride(propertyPath *string) AddPropertyOverride(propertyPath *string, value interface{}) ApplyRemovalPolicy(policy awscdk.RemovalPolicy, options *awscdk.RemovalPolicyOptions) GetAtt(attributeName *string) awscdk.Reference GetMetadata(key *string) interface{} Inspect(inspector awscdk.TreeInspector) OverrideLogicalId(newLogicalId *string) RenderProperties(props *map[string]interface{}) *map[string]interface{} ShouldSynthesize() *bool ToString() *string ValidateProperties(_properties interface{}) }
A CloudFormation `AWS::ElasticLoadBalancing::LoadBalancer`.
func NewCfnLoadBalancer ¶
func NewCfnLoadBalancer(scope constructs.Construct, id *string, props *CfnLoadBalancerProps) CfnLoadBalancer
Create a new `AWS::ElasticLoadBalancing::LoadBalancer`.
type CfnLoadBalancerProps ¶
type CfnLoadBalancerProps struct { // `AWS::ElasticLoadBalancing::LoadBalancer.Listeners`. Listeners interface{} `json:"listeners"` // `AWS::ElasticLoadBalancing::LoadBalancer.AccessLoggingPolicy`. AccessLoggingPolicy interface{} `json:"accessLoggingPolicy"` // `AWS::ElasticLoadBalancing::LoadBalancer.AppCookieStickinessPolicy`. AppCookieStickinessPolicy interface{} `json:"appCookieStickinessPolicy"` // `AWS::ElasticLoadBalancing::LoadBalancer.AvailabilityZones`. AvailabilityZones *[]*string `json:"availabilityZones"` // `AWS::ElasticLoadBalancing::LoadBalancer.ConnectionDrainingPolicy`. ConnectionDrainingPolicy interface{} `json:"connectionDrainingPolicy"` // `AWS::ElasticLoadBalancing::LoadBalancer.ConnectionSettings`. ConnectionSettings interface{} `json:"connectionSettings"` // `AWS::ElasticLoadBalancing::LoadBalancer.CrossZone`. CrossZone interface{} `json:"crossZone"` // `AWS::ElasticLoadBalancing::LoadBalancer.HealthCheck`. HealthCheck interface{} `json:"healthCheck"` // `AWS::ElasticLoadBalancing::LoadBalancer.Instances`. Instances *[]*string `json:"instances"` // `AWS::ElasticLoadBalancing::LoadBalancer.LBCookieStickinessPolicy`. LbCookieStickinessPolicy interface{} `json:"lbCookieStickinessPolicy"` // `AWS::ElasticLoadBalancing::LoadBalancer.LoadBalancerName`. LoadBalancerName *string `json:"loadBalancerName"` // `AWS::ElasticLoadBalancing::LoadBalancer.Policies`. Policies interface{} `json:"policies"` // `AWS::ElasticLoadBalancing::LoadBalancer.Scheme`. Scheme *string `json:"scheme"` // `AWS::ElasticLoadBalancing::LoadBalancer.SecurityGroups`. SecurityGroups *[]*string `json:"securityGroups"` // `AWS::ElasticLoadBalancing::LoadBalancer.Subnets`. Subnets *[]*string `json:"subnets"` // `AWS::ElasticLoadBalancing::LoadBalancer.Tags`. Tags *[]*awscdk.CfnTag `json:"tags"` }
Properties for defining a `AWS::ElasticLoadBalancing::LoadBalancer`.
type CfnLoadBalancer_AccessLoggingPolicyProperty ¶
type CfnLoadBalancer_AccessLoggingPolicyProperty struct { // `CfnLoadBalancer.AccessLoggingPolicyProperty.Enabled`. Enabled interface{} `json:"enabled"` // `CfnLoadBalancer.AccessLoggingPolicyProperty.S3BucketName`. S3BucketName *string `json:"s3BucketName"` // `CfnLoadBalancer.AccessLoggingPolicyProperty.EmitInterval`. EmitInterval *float64 `json:"emitInterval"` // `CfnLoadBalancer.AccessLoggingPolicyProperty.S3BucketPrefix`. S3BucketPrefix *string `json:"s3BucketPrefix"` }
type CfnLoadBalancer_ConnectionDrainingPolicyProperty ¶
type CfnLoadBalancer_ConnectionDrainingPolicyProperty struct { // `CfnLoadBalancer.ConnectionDrainingPolicyProperty.Enabled`. Enabled interface{} `json:"enabled"` // `CfnLoadBalancer.ConnectionDrainingPolicyProperty.Timeout`. Timeout *float64 `json:"timeout"` }
type CfnLoadBalancer_ConnectionSettingsProperty ¶
type CfnLoadBalancer_ConnectionSettingsProperty struct { // `CfnLoadBalancer.ConnectionSettingsProperty.IdleTimeout`. IdleTimeout *float64 `json:"idleTimeout"` }
type CfnLoadBalancer_HealthCheckProperty ¶
type CfnLoadBalancer_HealthCheckProperty struct { // `CfnLoadBalancer.HealthCheckProperty.HealthyThreshold`. HealthyThreshold *string `json:"healthyThreshold"` // `CfnLoadBalancer.HealthCheckProperty.Interval`. Interval *string `json:"interval"` // `CfnLoadBalancer.HealthCheckProperty.Target`. Target *string `json:"target"` // `CfnLoadBalancer.HealthCheckProperty.Timeout`. Timeout *string `json:"timeout"` // `CfnLoadBalancer.HealthCheckProperty.UnhealthyThreshold`. UnhealthyThreshold *string `json:"unhealthyThreshold"` }
type CfnLoadBalancer_LBCookieStickinessPolicyProperty ¶
type CfnLoadBalancer_LBCookieStickinessPolicyProperty struct { // `CfnLoadBalancer.LBCookieStickinessPolicyProperty.CookieExpirationPeriod`. CookieExpirationPeriod *string `json:"cookieExpirationPeriod"` // `CfnLoadBalancer.LBCookieStickinessPolicyProperty.PolicyName`. PolicyName *string `json:"policyName"` }
type CfnLoadBalancer_ListenersProperty ¶
type CfnLoadBalancer_ListenersProperty struct { // `CfnLoadBalancer.ListenersProperty.InstancePort`. InstancePort *string `json:"instancePort"` // `CfnLoadBalancer.ListenersProperty.LoadBalancerPort`. LoadBalancerPort *string `json:"loadBalancerPort"` // `CfnLoadBalancer.ListenersProperty.Protocol`. Protocol *string `json:"protocol"` // `CfnLoadBalancer.ListenersProperty.InstanceProtocol`. InstanceProtocol *string `json:"instanceProtocol"` // `CfnLoadBalancer.ListenersProperty.PolicyNames`. PolicyNames *[]*string `json:"policyNames"` // `CfnLoadBalancer.ListenersProperty.SSLCertificateId`. SslCertificateId *string `json:"sslCertificateId"` }
type CfnLoadBalancer_PoliciesProperty ¶
type CfnLoadBalancer_PoliciesProperty struct { // `CfnLoadBalancer.PoliciesProperty.Attributes`. Attributes interface{} `json:"attributes"` // `CfnLoadBalancer.PoliciesProperty.PolicyName`. PolicyName *string `json:"policyName"` // `CfnLoadBalancer.PoliciesProperty.PolicyType`. PolicyType *string `json:"policyType"` // `CfnLoadBalancer.PoliciesProperty.InstancePorts`. InstancePorts *[]*string `json:"instancePorts"` // `CfnLoadBalancer.PoliciesProperty.LoadBalancerPorts`. LoadBalancerPorts *[]*string `json:"loadBalancerPorts"` }
type HealthCheck ¶
type HealthCheck struct { // What port number to health check on. // Experimental. Port *float64 `json:"port"` // After how many successful checks is an instance considered healthy. // Experimental. HealthyThreshold *float64 `json:"healthyThreshold"` // Number of seconds between health checks. // Experimental. Interval awscdk.Duration `json:"interval"` // What path to use for HTTP or HTTPS health check (must return 200). // // For SSL and TCP health checks, accepting connections is enough to be considered // healthy. // Experimental. Path *string `json:"path"` // What protocol to use for health checking. // // The protocol is automatically determined from the port if it's not supplied. // Experimental. Protocol LoadBalancingProtocol `json:"protocol"` // Health check timeout. // Experimental. Timeout awscdk.Duration `json:"timeout"` // After how many unsuccessful checks is an instance considered unhealthy. // Experimental. UnhealthyThreshold *float64 `json:"unhealthyThreshold"` }
Describe the health check to a load balancer. Experimental.
type ILoadBalancerTarget ¶
type ILoadBalancerTarget interface { awsec2.IConnectable // Attach load-balanced target to a classic ELB. // Experimental. AttachToClassicLB(loadBalancer LoadBalancer) }
Interface that is going to be implemented by constructs that you can load balance to. Experimental.
type ListenerPort ¶
type ListenerPort interface { awsec2.IConnectable Connections() awsec2.Connections }
Reference to a listener's port just created.
This implements IConnectable with a default port (the port that an ELB listener was just created on) for a given security group so that it can be conveniently used just like any Connectable. E.g:
const listener = elb.addListener(...); listener.connections.allowDefaultPortFromAnyIPv4(); // or instance.connections.allowToDefaultPort(listener);
Experimental.
func NewListenerPort ¶
func NewListenerPort(securityGroup awsec2.ISecurityGroup, defaultPort awsec2.Port) ListenerPort
Experimental.
type LoadBalancer ¶
type LoadBalancer interface { awscdk.Resource awsec2.IConnectable Connections() awsec2.Connections Env() *awscdk.ResourceEnvironment ListenerPorts() *[]ListenerPort LoadBalancerCanonicalHostedZoneName() *string LoadBalancerCanonicalHostedZoneNameId() *string LoadBalancerDnsName() *string LoadBalancerName() *string LoadBalancerSourceSecurityGroupGroupName() *string LoadBalancerSourceSecurityGroupOwnerAlias() *string Node() constructs.Node PhysicalName() *string Stack() awscdk.Stack AddListener(listener *LoadBalancerListener) ListenerPort AddTarget(target ILoadBalancerTarget) ApplyRemovalPolicy(policy awscdk.RemovalPolicy) GeneratePhysicalName() *string GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string GetResourceNameAttribute(nameAttr *string) *string ToString() *string }
A load balancer with a single listener.
Routes to a fleet of of instances in a VPC. Experimental.
func NewLoadBalancer ¶
func NewLoadBalancer(scope constructs.Construct, id *string, props *LoadBalancerProps) LoadBalancer
Experimental.
type LoadBalancerListener ¶
type LoadBalancerListener struct { // External listening port. // Experimental. ExternalPort *float64 `json:"externalPort"` // Allow connections to the load balancer from the given set of connection peers. // // By default, connections will be allowed from anywhere. Set this to an empty list // to deny connections, or supply a custom list of peers to allow connections from // (IP ranges or security groups). // Experimental. AllowConnectionsFrom *[]awsec2.IConnectable `json:"allowConnectionsFrom"` // What public protocol to use for load balancing. // // Either 'tcp', 'ssl', 'http' or 'https'. // // May be omitted if the external port is either 80 or 443. // Experimental. ExternalProtocol LoadBalancingProtocol `json:"externalProtocol"` // Instance listening port. // // Same as the externalPort if not specified. // Experimental. InternalPort *float64 `json:"internalPort"` // What public protocol to use for load balancing. // // Either 'tcp', 'ssl', 'http' or 'https'. // // May be omitted if the internal port is either 80 or 443. // // The instance protocol is 'tcp' if the front-end protocol // is 'tcp' or 'ssl', the instance protocol is 'http' if the // front-end protocol is 'https'. // Experimental. InternalProtocol LoadBalancingProtocol `json:"internalProtocol"` // SSL policy names. // Experimental. PolicyNames *[]*string `json:"policyNames"` // the ARN of the SSL certificate. // Experimental. SslCertificateArn *string `json:"sslCertificateArn"` }
Add a backend to the load balancer. Experimental.
type LoadBalancerProps ¶
type LoadBalancerProps struct { // VPC network of the fleet instances. // Experimental. Vpc awsec2.IVpc `json:"vpc"` // Enable Loadbalancer access logs Can be used to avoid manual work as aws console Required S3 bucket name , enabled flag Can add interval for pushing log Can set bucket prefix in order to provide folder name inside bucket. // Experimental. AccessLoggingPolicy *CfnLoadBalancer_AccessLoggingPolicyProperty `json:"accessLoggingPolicy"` // Whether cross zone load balancing is enabled. // // This controls whether the load balancer evenly distributes requests // across each availability zone // Experimental. CrossZone *bool `json:"crossZone"` // Health check settings for the load balancing targets. // // Not required but recommended. // Experimental. HealthCheck *HealthCheck `json:"healthCheck"` // Whether this is an internet-facing Load Balancer. // // This controls whether the LB has a public IP address assigned. It does // not open up the Load Balancer's security groups to public internet access. // Experimental. InternetFacing *bool `json:"internetFacing"` // What listeners to set up for the load balancer. // // Can also be added by .addListener() // Experimental. Listeners *[]*LoadBalancerListener `json:"listeners"` // Which subnets to deploy the load balancer. // // Can be used to define a specific set of subnets to deploy the load balancer to. // Useful multiple public or private subnets are covering the same availability zone. // Experimental. SubnetSelection *awsec2.SubnetSelection `json:"subnetSelection"` // What targets to load balance to. // // Can also be added by .addTarget() // Experimental. Targets *[]ILoadBalancerTarget `json:"targets"` }
Construction properties for a LoadBalancer. Experimental.
type LoadBalancingProtocol ¶
type LoadBalancingProtocol string
Experimental.
const ( LoadBalancingProtocol_TCP LoadBalancingProtocol = "TCP" LoadBalancingProtocol_SSL LoadBalancingProtocol = "SSL" LoadBalancingProtocol_HTTP LoadBalancingProtocol = "HTTP" LoadBalancingProtocol_HTTPS LoadBalancingProtocol = "HTTPS" )