1// Code generated by smithy-go-codegen DO NOT EDIT.
2
3package types
4
5import (
6	"time"
7)
8
9// An accelerator is a complex type that includes one or more listeners that
10// process inbound connections and then direct traffic to one or more endpoint
11// groups, each of which includes endpoints, such as load balancers.
12type Accelerator struct {
13
14	// The Amazon Resource Name (ARN) of the accelerator.
15	AcceleratorArn *string
16
17	// The date and time that the accelerator was created.
18	CreatedTime *time.Time
19
20	// The Domain Name System (DNS) name that Global Accelerator creates that points to
21	// your accelerator's static IP addresses. The naming convention for the DNS name
22	// is the following: A lowercase letter a, followed by a 16-bit random hex string,
23	// followed by .awsglobalaccelerator.com. For example:
24	// a1234567890abcdef.awsglobalaccelerator.com. For more information about the
25	// default DNS name, see  Support for DNS Addressing in Global Accelerator
26	// (https://docs.aws.amazon.com/global-accelerator/latest/dg/about-accelerators.html#about-accelerators.dns-addressing)
27	// in the AWS Global Accelerator Developer Guide.
28	DnsName *string
29
30	// Indicates whether the accelerator is enabled. The value is true or false. The
31	// default value is true. If the value is set to true, the accelerator cannot be
32	// deleted. If set to false, accelerator can be deleted.
33	Enabled *bool
34
35	// The value for the address type must be IPv4.
36	IpAddressType IpAddressType
37
38	// The static IP addresses that Global Accelerator associates with the accelerator.
39	IpSets []IpSet
40
41	// The date and time that the accelerator was last modified.
42	LastModifiedTime *time.Time
43
44	// The name of the accelerator. The name must contain only alphanumeric characters
45	// or hyphens (-), and must not begin or end with a hyphen.
46	Name *string
47
48	// Describes the deployment status of the accelerator.
49	Status AcceleratorStatus
50}
51
52// Attributes of an accelerator.
53type AcceleratorAttributes struct {
54
55	// Indicates whether flow logs are enabled. The default value is false. If the
56	// value is true, FlowLogsS3Bucket and FlowLogsS3Prefix must be specified. For more
57	// information, see Flow Logs
58	// (https://docs.aws.amazon.com/global-accelerator/latest/dg/monitoring-global-accelerator.flow-logs.html)
59	// in the AWS Global Accelerator Developer Guide.
60	FlowLogsEnabled *bool
61
62	// The name of the Amazon S3 bucket for the flow logs. Attribute is required if
63	// FlowLogsEnabled is true. The bucket must exist and have a bucket policy that
64	// grants AWS Global Accelerator permission to write to the bucket.
65	FlowLogsS3Bucket *string
66
67	// The prefix for the location in the Amazon S3 bucket for the flow logs. Attribute
68	// is required if FlowLogsEnabled is true. If you don’t specify a prefix, the flow
69	// logs are stored in the root of the bucket. If you specify slash (/) for the S3
70	// bucket prefix, the log file bucket folder structure will include a double slash
71	// (//), like the following: s3-bucket_name//AWSLogs/aws_account_id
72	FlowLogsS3Prefix *string
73}
74
75// Information about an IP address range that is provisioned for use with your AWS
76// resources through bring your own IP address (BYOIP). The following describes
77// each BYOIP State that your IP address range can be in.
78//
79// * PENDING_PROVISIONING —
80// You’ve submitted a request to provision an IP address range but it is not yet
81// provisioned with AWS Global Accelerator.
82//
83// * READY — The address range is
84// provisioned with AWS Global Accelerator and can be advertised.
85//
86// *
87// PENDING_ADVERTISING — You’ve submitted a request for AWS Global Accelerator to
88// advertise an address range but it is not yet being advertised.
89//
90// * ADVERTISING —
91// The address range is being advertised by AWS Global Accelerator.
92//
93// *
94// PENDING_WITHDRAWING — You’ve submitted a request to withdraw an address range
95// from being advertised but it is still being advertised by AWS Global
96// Accelerator.
97//
98// * PENDING_DEPROVISIONING — You’ve submitted a request to
99// deprovision an address range from AWS Global Accelerator but it is still
100// provisioned.
101//
102// * DEPROVISIONED — The address range is deprovisioned from AWS
103// Global Accelerator.
104//
105// * FAILED_PROVISION — The request to provision the address
106// range from AWS Global Accelerator was not successful. Please make sure that you
107// provide all of the correct information, and try again. If the request fails a
108// second time, contact AWS support.
109//
110// * FAILED_ADVERTISING — The request for AWS
111// Global Accelerator to advertise the address range was not successful. Please
112// make sure that you provide all of the correct information, and try again. If the
113// request fails a second time, contact AWS support.
114//
115// * FAILED_WITHDRAW — The
116// request to withdraw the address range from advertising by AWS Global Accelerator
117// was not successful. Please make sure that you provide all of the correct
118// information, and try again. If the request fails a second time, contact AWS
119// support.
120//
121// * FAILED_DEPROVISION — The request to deprovision the address range
122// from AWS Global Accelerator was not successful. Please make sure that you
123// provide all of the correct information, and try again. If the request fails a
124// second time, contact AWS support.
125type ByoipCidr struct {
126
127	// The address range, in CIDR notation.
128	Cidr *string
129
130	// A history of status changes for an IP address range that you bring to AWS Global
131	// Accelerator through bring your own IP address (BYOIP).
132	Events []ByoipCidrEvent
133
134	// The state of the address pool.
135	State ByoipCidrState
136}
137
138// A complex type that contains a Message and a Timestamp value for changes that
139// you make in the status an IP address range that you bring to AWS Global
140// Accelerator through bring your own IP address (BYOIP).
141type ByoipCidrEvent struct {
142
143	// A string that contains an Event message describing changes that you make in the
144	// status of an IP address range that you bring to AWS Global Accelerator through
145	// bring your own IP address (BYOIP).
146	Message *string
147
148	// A timestamp when you make a status change for an IP address range that you bring
149	// to AWS Global Accelerator through bring your own IP address (BYOIP).
150	Timestamp *time.Time
151}
152
153// Provides authorization for Amazon to bring a specific IP address range to a
154// specific AWS account using bring your own IP addresses (BYOIP). For more
155// information, see Bring Your Own IP Addresses (BYOIP)
156// (https://docs.aws.amazon.com/global-accelerator/latest/dg/using-byoip.html) in
157// the AWS Global Accelerator Developer Guide.
158type CidrAuthorizationContext struct {
159
160	// The plain-text authorization message for the prefix and account.
161	//
162	// This member is required.
163	Message *string
164
165	// The signed authorization message for the prefix and account.
166	//
167	// This member is required.
168	Signature *string
169}
170
171// Attributes of a custom routing accelerator.
172type CustomRoutingAccelerator struct {
173
174	// The Amazon Resource Name (ARN) of the custom routing accelerator.
175	AcceleratorArn *string
176
177	// The date and time that the accelerator was created.
178	CreatedTime *time.Time
179
180	// The Domain Name System (DNS) name that Global Accelerator creates that points to
181	// your accelerator's static IP addresses. The naming convention for the DNS name
182	// is the following: A lowercase letter a, followed by a 16-bit random hex string,
183	// followed by .awsglobalaccelerator.com. For example:
184	// a1234567890abcdef.awsglobalaccelerator.com. For more information about the
185	// default DNS name, see  Support for DNS Addressing in Global Accelerator
186	// (https://docs.aws.amazon.com/global-accelerator/latest/dg/about-accelerators.html#about-accelerators.dns-addressing)
187	// in the AWS Global Accelerator Developer Guide.
188	DnsName *string
189
190	// Indicates whether the accelerator is enabled. The value is true or false. The
191	// default value is true. If the value is set to true, the accelerator cannot be
192	// deleted. If set to false, accelerator can be deleted.
193	Enabled *bool
194
195	// The value for the address type must be IPv4.
196	IpAddressType IpAddressType
197
198	// The static IP addresses that Global Accelerator associates with the accelerator.
199	IpSets []IpSet
200
201	// The date and time that the accelerator was last modified.
202	LastModifiedTime *time.Time
203
204	// The name of the accelerator. The name must contain only alphanumeric characters
205	// or hyphens (-), and must not begin or end with a hyphen.
206	Name *string
207
208	// Describes the deployment status of the accelerator.
209	Status CustomRoutingAcceleratorStatus
210}
211
212// Attributes of a custom routing accelerator.
213type CustomRoutingAcceleratorAttributes struct {
214
215	// Indicates whether flow logs are enabled. The default value is false. If the
216	// value is true, FlowLogsS3Bucket and FlowLogsS3Prefix must be specified. For more
217	// information, see Flow Logs
218	// (https://docs.aws.amazon.com/global-accelerator/latest/dg/monitoring-global-accelerator.flow-logs.html)
219	// in the AWS Global Accelerator Developer Guide.
220	FlowLogsEnabled *bool
221
222	// The name of the Amazon S3 bucket for the flow logs. Attribute is required if
223	// FlowLogsEnabled is true. The bucket must exist and have a bucket policy that
224	// grants AWS Global Accelerator permission to write to the bucket.
225	FlowLogsS3Bucket *string
226
227	// The prefix for the location in the Amazon S3 bucket for the flow logs. Attribute
228	// is required if FlowLogsEnabled is true. If you don’t specify a prefix, the flow
229	// logs are stored in the root of the bucket. If you specify slash (/) for the S3
230	// bucket prefix, the log file bucket folder structure will include a double slash
231	// (//), like the following: DOC-EXAMPLE-BUCKET//AWSLogs/aws_account_id
232	FlowLogsS3Prefix *string
233}
234
235// For a custom routing accelerator, sets the port range and protocol for all
236// endpoints (virtual private cloud subnets) in an endpoint group to accept client
237// traffic on.
238type CustomRoutingDestinationConfiguration struct {
239
240	// The first port, inclusive, in the range of ports for the endpoint group that is
241	// associated with a custom routing accelerator.
242	//
243	// This member is required.
244	FromPort *int32
245
246	// The protocol for the endpoint group that is associated with a custom routing
247	// accelerator. The protocol can be either TCP or UDP.
248	//
249	// This member is required.
250	Protocols []CustomRoutingProtocol
251
252	// The last port, inclusive, in the range of ports for the endpoint group that is
253	// associated with a custom routing accelerator.
254	//
255	// This member is required.
256	ToPort *int32
257}
258
259// For a custom routing accelerator, describes the port range and protocol for all
260// endpoints (virtual private cloud subnets) in an endpoint group to accept client
261// traffic on.
262type CustomRoutingDestinationDescription struct {
263
264	// The first port, inclusive, in the range of ports for the endpoint group that is
265	// associated with a custom routing accelerator.
266	FromPort *int32
267
268	// The protocol for the endpoint group that is associated with a custom routing
269	// accelerator. The protocol can be either TCP or UDP.
270	Protocols []Protocol
271
272	// The last port, inclusive, in the range of ports for the endpoint group that is
273	// associated with a custom routing accelerator.
274	ToPort *int32
275}
276
277// The list of endpoint objects. For custom routing, this is a list of virtual
278// private cloud (VPC) subnet IDs.
279type CustomRoutingEndpointConfiguration struct {
280
281	// An ID for the endpoint. For custom routing accelerators, this is the virtual
282	// private cloud (VPC) subnet ID.
283	EndpointId *string
284}
285
286// A complex type for an endpoint for a custom routing accelerator. Each endpoint
287// group can include one or more endpoints, which are virtual private cloud (VPC)
288// subnets.
289type CustomRoutingEndpointDescription struct {
290
291	// An ID for the endpoint. For custom routing accelerators, this is the virtual
292	// private cloud (VPC) subnet ID.
293	EndpointId *string
294}
295
296// A complex type for the endpoint group for a custom routing accelerator. An AWS
297// Region can have only one endpoint group for a specific listener.
298type CustomRoutingEndpointGroup struct {
299
300	// For a custom routing accelerator, describes the port range and protocol for all
301	// endpoints (virtual private cloud subnets) in an endpoint group to accept client
302	// traffic on.
303	DestinationDescriptions []CustomRoutingDestinationDescription
304
305	// For a custom routing accelerator, describes the endpoints (virtual private cloud
306	// subnets) in an endpoint group to accept client traffic on.
307	EndpointDescriptions []CustomRoutingEndpointDescription
308
309	// The Amazon Resource Name (ARN) of the endpoint group.
310	EndpointGroupArn *string
311
312	// The AWS Region where the endpoint group is located.
313	EndpointGroupRegion *string
314}
315
316// A complex type for a listener for a custom routing accelerator.
317type CustomRoutingListener struct {
318
319	// The Amazon Resource Name (ARN) of the listener.
320	ListenerArn *string
321
322	// The port range to support for connections from clients to your accelerator.
323	// Separately, you set port ranges for endpoints. For more information, see About
324	// endpoints for custom routing accelerators
325	// (https://docs.aws.amazon.com/global-accelerator/latest/dg/about-custom-routing-endpoints.html).
326	PortRanges []PortRange
327}
328
329// The port mappings for a specified endpoint IP address (destination).
330type DestinationPortMapping struct {
331
332	// The Amazon Resource Name (ARN) of the custom routing accelerator that you have
333	// port mappings for.
334	AcceleratorArn *string
335
336	// The IP address/port combinations (sockets) that map to a given destination
337	// socket address.
338	AcceleratorSocketAddresses []SocketAddress
339
340	// The endpoint IP address/port combination for traffic received on the accelerator
341	// socket address.
342	DestinationSocketAddress *SocketAddress
343
344	// Indicates whether or not a port mapping destination can receive traffic. The
345	// value is either ALLOW, if traffic is allowed to the destination, or DENY, if
346	// traffic is not allowed to the destination.
347	DestinationTrafficState CustomRoutingDestinationTrafficState
348
349	// The Amazon Resource Name (ARN) of the endpoint group.
350	EndpointGroupArn *string
351
352	// The AWS Region for the endpoint group.
353	EndpointGroupRegion *string
354
355	// The ID for the virtual private cloud (VPC) subnet.
356	EndpointId *string
357
358	// The IP address type, which must be IPv4.
359	IpAddressType IpAddressType
360}
361
362// A complex type for endpoints. A resource must be valid and active when you add
363// it as an endpoint.
364type EndpointConfiguration struct {
365
366	// Indicates whether client IP address preservation is enabled for an Application
367	// Load Balancer endpoint. The value is true or false. The default value is true
368	// for new accelerators. If the value is set to true, the client's IP address is
369	// preserved in the X-Forwarded-For request header as traffic travels to
370	// applications on the Application Load Balancer endpoint fronted by the
371	// accelerator. For more information, see  Preserve Client IP Addresses in AWS
372	// Global Accelerator
373	// (https://docs.aws.amazon.com/global-accelerator/latest/dg/preserve-client-ip-address.html)
374	// in the AWS Global Accelerator Developer Guide.
375	ClientIPPreservationEnabled *bool
376
377	// An ID for the endpoint. If the endpoint is a Network Load Balancer or
378	// Application Load Balancer, this is the Amazon Resource Name (ARN) of the
379	// resource. If the endpoint is an Elastic IP address, this is the Elastic IP
380	// address allocation ID. For Amazon EC2 instances, this is the EC2 instance ID. A
381	// resource must be valid and active when you add it as an endpoint. An Application
382	// Load Balancer can be either internal or internet-facing.
383	EndpointId *string
384
385	// The weight associated with the endpoint. When you add weights to endpoints, you
386	// configure AWS Global Accelerator to route traffic based on proportions that you
387	// specify. For example, you might specify endpoint weights of 4, 5, 5, and 6
388	// (sum=20). The result is that 4/20 of your traffic, on average, is routed to the
389	// first endpoint, 5/20 is routed both to the second and third endpoints, and 6/20
390	// is routed to the last endpoint. For more information, see Endpoint Weights
391	// (https://docs.aws.amazon.com/global-accelerator/latest/dg/about-endpoints-endpoint-weights.html)
392	// in the AWS Global Accelerator Developer Guide.
393	Weight *int32
394}
395
396// A complex type for an endpoint. Each endpoint group can include one or more
397// endpoints, such as load balancers.
398type EndpointDescription struct {
399
400	// Indicates whether client IP address preservation is enabled for an Application
401	// Load Balancer endpoint. The value is true or false. The default value is true
402	// for new accelerators. If the value is set to true, the client's IP address is
403	// preserved in the X-Forwarded-For request header as traffic travels to
404	// applications on the Application Load Balancer endpoint fronted by the
405	// accelerator. For more information, see  Viewing Client IP Addresses in AWS
406	// Global Accelerator
407	// (https://docs.aws.amazon.com/global-accelerator/latest/dg/introduction-how-it-works-client-ip.html)
408	// in the AWS Global Accelerator Developer Guide.
409	ClientIPPreservationEnabled *bool
410
411	// An ID for the endpoint. If the endpoint is a Network Load Balancer or
412	// Application Load Balancer, this is the Amazon Resource Name (ARN) of the
413	// resource. If the endpoint is an Elastic IP address, this is the Elastic IP
414	// address allocation ID. For Amazon EC2 instances, this is the EC2 instance ID. An
415	// Application Load Balancer can be either internal or internet-facing.
416	EndpointId *string
417
418	// Returns a null result.
419	HealthReason *string
420
421	// The health status of the endpoint.
422	HealthState HealthState
423
424	// The weight associated with the endpoint. When you add weights to endpoints, you
425	// configure AWS Global Accelerator to route traffic based on proportions that you
426	// specify. For example, you might specify endpoint weights of 4, 5, 5, and 6
427	// (sum=20). The result is that 4/20 of your traffic, on average, is routed to the
428	// first endpoint, 5/20 is routed both to the second and third endpoints, and 6/20
429	// is routed to the last endpoint. For more information, see Endpoint Weights
430	// (https://docs.aws.amazon.com/global-accelerator/latest/dg/about-endpoints-endpoint-weights.html)
431	// in the AWS Global Accelerator Developer Guide.
432	Weight *int32
433}
434
435// A complex type for the endpoint group. An AWS Region can have only one endpoint
436// group for a specific listener.
437type EndpointGroup struct {
438
439	// The list of endpoint objects.
440	EndpointDescriptions []EndpointDescription
441
442	// The Amazon Resource Name (ARN) of the endpoint group.
443	EndpointGroupArn *string
444
445	// The AWS Region where the endpoint group is located.
446	EndpointGroupRegion *string
447
448	// The time—10 seconds or 30 seconds—between health checks for each endpoint. The
449	// default value is 30.
450	HealthCheckIntervalSeconds *int32
451
452	// If the protocol is HTTP/S, then this value provides the ping path that Global
453	// Accelerator uses for the destination on the endpoints for health checks. The
454	// default is slash (/).
455	HealthCheckPath *string
456
457	// The port that Global Accelerator uses to perform health checks on endpoints that
458	// are part of this endpoint group. The default port is the port for the listener
459	// that this endpoint group is associated with. If the listener port is a list,
460	// Global Accelerator uses the first specified port in the list of ports.
461	HealthCheckPort *int32
462
463	// The protocol that Global Accelerator uses to perform health checks on endpoints
464	// that are part of this endpoint group. The default value is TCP.
465	HealthCheckProtocol HealthCheckProtocol
466
467	// Allows you to override the destination ports used to route traffic to an
468	// endpoint. Using a port override lets you to map a list of external destination
469	// ports (that your users send traffic to) to a list of internal destination ports
470	// that you want an application endpoint to receive traffic on.
471	PortOverrides []PortOverride
472
473	// The number of consecutive health checks required to set the state of a healthy
474	// endpoint to unhealthy, or to set an unhealthy endpoint to healthy. The default
475	// value is 3.
476	ThresholdCount *int32
477
478	// The percentage of traffic to send to an AWS Region. Additional traffic is
479	// distributed to other endpoint groups for this listener. Use this action to
480	// increase (dial up) or decrease (dial down) traffic to a specific Region. The
481	// percentage is applied to the traffic that would otherwise have been routed to
482	// the Region based on optimal routing. The default value is 100.
483	TrafficDialPercentage *float32
484}
485
486// A complex type for the set of IP addresses for an accelerator.
487type IpSet struct {
488
489	// The array of IP addresses in the IP address set. An IP address set can have a
490	// maximum of two IP addresses.
491	IpAddresses []string
492
493	// The types of IP addresses included in this IP set.
494	IpFamily *string
495}
496
497// A complex type for a listener.
498type Listener struct {
499
500	// Client affinity lets you direct all requests from a user to the same endpoint,
501	// if you have stateful applications, regardless of the port and protocol of the
502	// client request. Client affinity gives you control over whether to always route
503	// each client to the same specific endpoint. AWS Global Accelerator uses a
504	// consistent-flow hashing algorithm to choose the optimal endpoint for a
505	// connection. If client affinity is NONE, Global Accelerator uses the "five-tuple"
506	// (5-tuple) properties—source IP address, source port, destination IP address,
507	// destination port, and protocol—to select the hash value, and then chooses the
508	// best endpoint. However, with this setting, if someone uses different ports to
509	// connect to Global Accelerator, their connections might not be always routed to
510	// the same endpoint because the hash value changes. If you want a given client to
511	// always be routed to the same endpoint, set client affinity to SOURCE_IP instead.
512	// When you use the SOURCE_IP setting, Global Accelerator uses the "two-tuple"
513	// (2-tuple) properties— source (client) IP address and destination IP address—to
514	// select the hash value. The default value is NONE.
515	ClientAffinity ClientAffinity
516
517	// The Amazon Resource Name (ARN) of the listener.
518	ListenerArn *string
519
520	// The list of port ranges for the connections from clients to the accelerator.
521	PortRanges []PortRange
522
523	// The protocol for the connections from clients to the accelerator.
524	Protocol Protocol
525}
526
527// Returns the ports and associated IP addresses and ports of Amazon EC2 instances
528// in your virtual private cloud (VPC) subnets. Custom routing is a port mapping
529// protocol in AWS Global Accelerator that statically associates port ranges with
530// VPC subnets, which allows Global Accelerator to route to specific instances and
531// ports within one or more subnets.
532type PortMapping struct {
533
534	// The accelerator port.
535	AcceleratorPort *int32
536
537	// The EC2 instance IP address and port number in the virtual private cloud (VPC)
538	// subnet.
539	DestinationSocketAddress *SocketAddress
540
541	// Indicates whether or not a port mapping destination can receive traffic. The
542	// value is either ALLOW, if traffic is allowed to the destination, or DENY, if
543	// traffic is not allowed to the destination.
544	DestinationTrafficState CustomRoutingDestinationTrafficState
545
546	// The Amazon Resource Name (ARN) of the endpoint group.
547	EndpointGroupArn *string
548
549	// The IP address of the VPC subnet (the subnet ID).
550	EndpointId *string
551
552	// The protocols supported by the endpoint group.
553	Protocols []CustomRoutingProtocol
554}
555
556// Override specific listener ports used to route traffic to endpoints that are
557// part of an endpoint group. For example, you can create a port override in which
558// the listener receives user traffic on ports 80 and 443, but your accelerator
559// routes that traffic to ports 1080 and 1443, respectively, on the endpoints. For
560// more information, see  Port overrides
561// (https://docs.aws.amazon.com/global-accelerator/latest/dg/about-endpoint-groups-port-override.html)
562// in the AWS Global Accelerator Developer Guide.
563type PortOverride struct {
564
565	// The endpoint port that you want a listener port to be mapped to. This is the
566	// port on the endpoint, such as the Application Load Balancer or Amazon EC2
567	// instance.
568	EndpointPort *int32
569
570	// The listener port that you want to map to a specific endpoint port. This is the
571	// port that user traffic arrives to the Global Accelerator on.
572	ListenerPort *int32
573}
574
575// A complex type for a range of ports for a listener.
576type PortRange struct {
577
578	// The first port in the range of ports, inclusive.
579	FromPort *int32
580
581	// The last port in the range of ports, inclusive.
582	ToPort *int32
583}
584
585// An IP address/port combination.
586type SocketAddress struct {
587
588	// The IP address for the socket address.
589	IpAddress *string
590
591	// The port for the socket address.
592	Port *int32
593}
594
595// A complex type that contains a Tag key and Tag value.
596type Tag struct {
597
598	// A string that contains a Tag key.
599	//
600	// This member is required.
601	Key *string
602
603	// A string that contains a Tag value.
604	//
605	// This member is required.
606	Value *string
607}
608