| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617 |
- // Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
- package globalaccelerator
- import (
- "fmt"
- "time"
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awsutil"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/private/protocol"
- "github.com/aws/aws-sdk-go/private/protocol/jsonrpc"
- )
- const opCreateAccelerator = "CreateAccelerator"
- // CreateAcceleratorRequest generates a "aws/request.Request" representing the
- // client's request for the CreateAccelerator operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See CreateAccelerator for more information on using the CreateAccelerator
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the CreateAcceleratorRequest method.
- // req, resp := client.CreateAcceleratorRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/CreateAccelerator
- func (c *GlobalAccelerator) CreateAcceleratorRequest(input *CreateAcceleratorInput) (req *request.Request, output *CreateAcceleratorOutput) {
- op := &request.Operation{
- Name: opCreateAccelerator,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &CreateAcceleratorInput{}
- }
- output = &CreateAcceleratorOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // CreateAccelerator API operation for AWS Global Accelerator.
- //
- // Create an accelerator. An accelerator includes one or more listeners that
- // process inbound connections and direct traffic to one or more endpoint groups,
- // each of which includes endpoints, such as Network Load Balancers. To see
- // an AWS CLI example of creating an accelerator, scroll down to Example.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation CreateAccelerator for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // * ErrCodeInvalidArgumentException "InvalidArgumentException"
- // An argument that you specified is invalid.
- //
- // * ErrCodeLimitExceededException "LimitExceededException"
- // Processing your request would cause you to exceed an AWS Global Accelerator
- // limit.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/CreateAccelerator
- func (c *GlobalAccelerator) CreateAccelerator(input *CreateAcceleratorInput) (*CreateAcceleratorOutput, error) {
- req, out := c.CreateAcceleratorRequest(input)
- return out, req.Send()
- }
- // CreateAcceleratorWithContext is the same as CreateAccelerator with the addition of
- // the ability to pass a context and additional request options.
- //
- // See CreateAccelerator for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) CreateAcceleratorWithContext(ctx aws.Context, input *CreateAcceleratorInput, opts ...request.Option) (*CreateAcceleratorOutput, error) {
- req, out := c.CreateAcceleratorRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opCreateEndpointGroup = "CreateEndpointGroup"
- // CreateEndpointGroupRequest generates a "aws/request.Request" representing the
- // client's request for the CreateEndpointGroup operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See CreateEndpointGroup for more information on using the CreateEndpointGroup
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the CreateEndpointGroupRequest method.
- // req, resp := client.CreateEndpointGroupRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/CreateEndpointGroup
- func (c *GlobalAccelerator) CreateEndpointGroupRequest(input *CreateEndpointGroupInput) (req *request.Request, output *CreateEndpointGroupOutput) {
- op := &request.Operation{
- Name: opCreateEndpointGroup,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &CreateEndpointGroupInput{}
- }
- output = &CreateEndpointGroupOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // CreateEndpointGroup API operation for AWS Global Accelerator.
- //
- // Create an endpoint group for the specified listener. An endpoint group is
- // a collection of endpoints in one AWS Region. To see an AWS CLI example of
- // creating an endpoint group, scroll down to Example.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation CreateEndpointGroup for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeAcceleratorNotFoundException "AcceleratorNotFoundException"
- // The accelerator that you specified doesn't exist.
- //
- // * ErrCodeEndpointGroupAlreadyExistsException "EndpointGroupAlreadyExistsException"
- // The endpoint group that you specified already exists.
- //
- // * ErrCodeListenerNotFoundException "ListenerNotFoundException"
- // The listener that you specified doesn't exist.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // * ErrCodeInvalidArgumentException "InvalidArgumentException"
- // An argument that you specified is invalid.
- //
- // * ErrCodeLimitExceededException "LimitExceededException"
- // Processing your request would cause you to exceed an AWS Global Accelerator
- // limit.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/CreateEndpointGroup
- func (c *GlobalAccelerator) CreateEndpointGroup(input *CreateEndpointGroupInput) (*CreateEndpointGroupOutput, error) {
- req, out := c.CreateEndpointGroupRequest(input)
- return out, req.Send()
- }
- // CreateEndpointGroupWithContext is the same as CreateEndpointGroup with the addition of
- // the ability to pass a context and additional request options.
- //
- // See CreateEndpointGroup for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) CreateEndpointGroupWithContext(ctx aws.Context, input *CreateEndpointGroupInput, opts ...request.Option) (*CreateEndpointGroupOutput, error) {
- req, out := c.CreateEndpointGroupRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opCreateListener = "CreateListener"
- // CreateListenerRequest generates a "aws/request.Request" representing the
- // client's request for the CreateListener operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See CreateListener for more information on using the CreateListener
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the CreateListenerRequest method.
- // req, resp := client.CreateListenerRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/CreateListener
- func (c *GlobalAccelerator) CreateListenerRequest(input *CreateListenerInput) (req *request.Request, output *CreateListenerOutput) {
- op := &request.Operation{
- Name: opCreateListener,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &CreateListenerInput{}
- }
- output = &CreateListenerOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // CreateListener API operation for AWS Global Accelerator.
- //
- // Create a listener to process inbound connections from clients to an accelerator.
- // Connections arrive to assigned static IP addresses on a port, port range,
- // or list of port ranges that you specify. To see an AWS CLI example of creating
- // a listener, scroll down to Example.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation CreateListener for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeInvalidArgumentException "InvalidArgumentException"
- // An argument that you specified is invalid.
- //
- // * ErrCodeAcceleratorNotFoundException "AcceleratorNotFoundException"
- // The accelerator that you specified doesn't exist.
- //
- // * ErrCodeInvalidPortRangeException "InvalidPortRangeException"
- // The port numbers that you specified are not valid numbers or are not unique
- // for this accelerator.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // * ErrCodeLimitExceededException "LimitExceededException"
- // Processing your request would cause you to exceed an AWS Global Accelerator
- // limit.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/CreateListener
- func (c *GlobalAccelerator) CreateListener(input *CreateListenerInput) (*CreateListenerOutput, error) {
- req, out := c.CreateListenerRequest(input)
- return out, req.Send()
- }
- // CreateListenerWithContext is the same as CreateListener with the addition of
- // the ability to pass a context and additional request options.
- //
- // See CreateListener for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) CreateListenerWithContext(ctx aws.Context, input *CreateListenerInput, opts ...request.Option) (*CreateListenerOutput, error) {
- req, out := c.CreateListenerRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opDeleteAccelerator = "DeleteAccelerator"
- // DeleteAcceleratorRequest generates a "aws/request.Request" representing the
- // client's request for the DeleteAccelerator operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See DeleteAccelerator for more information on using the DeleteAccelerator
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the DeleteAcceleratorRequest method.
- // req, resp := client.DeleteAcceleratorRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DeleteAccelerator
- func (c *GlobalAccelerator) DeleteAcceleratorRequest(input *DeleteAcceleratorInput) (req *request.Request, output *DeleteAcceleratorOutput) {
- op := &request.Operation{
- Name: opDeleteAccelerator,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &DeleteAcceleratorInput{}
- }
- output = &DeleteAcceleratorOutput{}
- req = c.newRequest(op, input, output)
- req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler)
- return
- }
- // DeleteAccelerator API operation for AWS Global Accelerator.
- //
- // Delete an accelerator. Note: before you can delete an accelerator, you must
- // disable it and remove all dependent resources (listeners and endpoint groups).
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation DeleteAccelerator for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeAcceleratorNotFoundException "AcceleratorNotFoundException"
- // The accelerator that you specified doesn't exist.
- //
- // * ErrCodeAcceleratorNotDisabledException "AcceleratorNotDisabledException"
- // The accelerator that you specified could not be disabled.
- //
- // * ErrCodeAssociatedListenerFoundException "AssociatedListenerFoundException"
- // The accelerator that you specified has a listener associated with it. You
- // must remove all dependent resources from an accelerator before you can delete
- // it.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // * ErrCodeInvalidArgumentException "InvalidArgumentException"
- // An argument that you specified is invalid.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DeleteAccelerator
- func (c *GlobalAccelerator) DeleteAccelerator(input *DeleteAcceleratorInput) (*DeleteAcceleratorOutput, error) {
- req, out := c.DeleteAcceleratorRequest(input)
- return out, req.Send()
- }
- // DeleteAcceleratorWithContext is the same as DeleteAccelerator with the addition of
- // the ability to pass a context and additional request options.
- //
- // See DeleteAccelerator for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) DeleteAcceleratorWithContext(ctx aws.Context, input *DeleteAcceleratorInput, opts ...request.Option) (*DeleteAcceleratorOutput, error) {
- req, out := c.DeleteAcceleratorRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opDeleteEndpointGroup = "DeleteEndpointGroup"
- // DeleteEndpointGroupRequest generates a "aws/request.Request" representing the
- // client's request for the DeleteEndpointGroup operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See DeleteEndpointGroup for more information on using the DeleteEndpointGroup
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the DeleteEndpointGroupRequest method.
- // req, resp := client.DeleteEndpointGroupRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DeleteEndpointGroup
- func (c *GlobalAccelerator) DeleteEndpointGroupRequest(input *DeleteEndpointGroupInput) (req *request.Request, output *DeleteEndpointGroupOutput) {
- op := &request.Operation{
- Name: opDeleteEndpointGroup,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &DeleteEndpointGroupInput{}
- }
- output = &DeleteEndpointGroupOutput{}
- req = c.newRequest(op, input, output)
- req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler)
- return
- }
- // DeleteEndpointGroup API operation for AWS Global Accelerator.
- //
- // Delete an endpoint group from a listener.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation DeleteEndpointGroup for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeEndpointGroupNotFoundException "EndpointGroupNotFoundException"
- // The endpoint group that you specified doesn't exist.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DeleteEndpointGroup
- func (c *GlobalAccelerator) DeleteEndpointGroup(input *DeleteEndpointGroupInput) (*DeleteEndpointGroupOutput, error) {
- req, out := c.DeleteEndpointGroupRequest(input)
- return out, req.Send()
- }
- // DeleteEndpointGroupWithContext is the same as DeleteEndpointGroup with the addition of
- // the ability to pass a context and additional request options.
- //
- // See DeleteEndpointGroup for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) DeleteEndpointGroupWithContext(ctx aws.Context, input *DeleteEndpointGroupInput, opts ...request.Option) (*DeleteEndpointGroupOutput, error) {
- req, out := c.DeleteEndpointGroupRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opDeleteListener = "DeleteListener"
- // DeleteListenerRequest generates a "aws/request.Request" representing the
- // client's request for the DeleteListener operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See DeleteListener for more information on using the DeleteListener
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the DeleteListenerRequest method.
- // req, resp := client.DeleteListenerRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DeleteListener
- func (c *GlobalAccelerator) DeleteListenerRequest(input *DeleteListenerInput) (req *request.Request, output *DeleteListenerOutput) {
- op := &request.Operation{
- Name: opDeleteListener,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &DeleteListenerInput{}
- }
- output = &DeleteListenerOutput{}
- req = c.newRequest(op, input, output)
- req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler)
- return
- }
- // DeleteListener API operation for AWS Global Accelerator.
- //
- // Delete a listener from an accelerator.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation DeleteListener for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeListenerNotFoundException "ListenerNotFoundException"
- // The listener that you specified doesn't exist.
- //
- // * ErrCodeAssociatedEndpointGroupFoundException "AssociatedEndpointGroupFoundException"
- // The listener that you specified has an endpoint group associated with it.
- // You must remove all dependent resources from a listener before you can delete
- // it.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DeleteListener
- func (c *GlobalAccelerator) DeleteListener(input *DeleteListenerInput) (*DeleteListenerOutput, error) {
- req, out := c.DeleteListenerRequest(input)
- return out, req.Send()
- }
- // DeleteListenerWithContext is the same as DeleteListener with the addition of
- // the ability to pass a context and additional request options.
- //
- // See DeleteListener for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) DeleteListenerWithContext(ctx aws.Context, input *DeleteListenerInput, opts ...request.Option) (*DeleteListenerOutput, error) {
- req, out := c.DeleteListenerRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opDescribeAccelerator = "DescribeAccelerator"
- // DescribeAcceleratorRequest generates a "aws/request.Request" representing the
- // client's request for the DescribeAccelerator operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See DescribeAccelerator for more information on using the DescribeAccelerator
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the DescribeAcceleratorRequest method.
- // req, resp := client.DescribeAcceleratorRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DescribeAccelerator
- func (c *GlobalAccelerator) DescribeAcceleratorRequest(input *DescribeAcceleratorInput) (req *request.Request, output *DescribeAcceleratorOutput) {
- op := &request.Operation{
- Name: opDescribeAccelerator,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &DescribeAcceleratorInput{}
- }
- output = &DescribeAcceleratorOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // DescribeAccelerator API operation for AWS Global Accelerator.
- //
- // Describe an accelerator. To see an AWS CLI example of describing an accelerator,
- // scroll down to Example.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation DescribeAccelerator for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeAcceleratorNotFoundException "AcceleratorNotFoundException"
- // The accelerator that you specified doesn't exist.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // * ErrCodeInvalidArgumentException "InvalidArgumentException"
- // An argument that you specified is invalid.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DescribeAccelerator
- func (c *GlobalAccelerator) DescribeAccelerator(input *DescribeAcceleratorInput) (*DescribeAcceleratorOutput, error) {
- req, out := c.DescribeAcceleratorRequest(input)
- return out, req.Send()
- }
- // DescribeAcceleratorWithContext is the same as DescribeAccelerator with the addition of
- // the ability to pass a context and additional request options.
- //
- // See DescribeAccelerator for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) DescribeAcceleratorWithContext(ctx aws.Context, input *DescribeAcceleratorInput, opts ...request.Option) (*DescribeAcceleratorOutput, error) {
- req, out := c.DescribeAcceleratorRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opDescribeAcceleratorAttributes = "DescribeAcceleratorAttributes"
- // DescribeAcceleratorAttributesRequest generates a "aws/request.Request" representing the
- // client's request for the DescribeAcceleratorAttributes operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See DescribeAcceleratorAttributes for more information on using the DescribeAcceleratorAttributes
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the DescribeAcceleratorAttributesRequest method.
- // req, resp := client.DescribeAcceleratorAttributesRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DescribeAcceleratorAttributes
- func (c *GlobalAccelerator) DescribeAcceleratorAttributesRequest(input *DescribeAcceleratorAttributesInput) (req *request.Request, output *DescribeAcceleratorAttributesOutput) {
- op := &request.Operation{
- Name: opDescribeAcceleratorAttributes,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &DescribeAcceleratorAttributesInput{}
- }
- output = &DescribeAcceleratorAttributesOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // DescribeAcceleratorAttributes API operation for AWS Global Accelerator.
- //
- // Describe the attributes of an accelerator.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation DescribeAcceleratorAttributes for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeAcceleratorNotFoundException "AcceleratorNotFoundException"
- // The accelerator that you specified doesn't exist.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // * ErrCodeInvalidArgumentException "InvalidArgumentException"
- // An argument that you specified is invalid.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DescribeAcceleratorAttributes
- func (c *GlobalAccelerator) DescribeAcceleratorAttributes(input *DescribeAcceleratorAttributesInput) (*DescribeAcceleratorAttributesOutput, error) {
- req, out := c.DescribeAcceleratorAttributesRequest(input)
- return out, req.Send()
- }
- // DescribeAcceleratorAttributesWithContext is the same as DescribeAcceleratorAttributes with the addition of
- // the ability to pass a context and additional request options.
- //
- // See DescribeAcceleratorAttributes for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) DescribeAcceleratorAttributesWithContext(ctx aws.Context, input *DescribeAcceleratorAttributesInput, opts ...request.Option) (*DescribeAcceleratorAttributesOutput, error) {
- req, out := c.DescribeAcceleratorAttributesRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opDescribeEndpointGroup = "DescribeEndpointGroup"
- // DescribeEndpointGroupRequest generates a "aws/request.Request" representing the
- // client's request for the DescribeEndpointGroup operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See DescribeEndpointGroup for more information on using the DescribeEndpointGroup
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the DescribeEndpointGroupRequest method.
- // req, resp := client.DescribeEndpointGroupRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DescribeEndpointGroup
- func (c *GlobalAccelerator) DescribeEndpointGroupRequest(input *DescribeEndpointGroupInput) (req *request.Request, output *DescribeEndpointGroupOutput) {
- op := &request.Operation{
- Name: opDescribeEndpointGroup,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &DescribeEndpointGroupInput{}
- }
- output = &DescribeEndpointGroupOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // DescribeEndpointGroup API operation for AWS Global Accelerator.
- //
- // Describe an endpoint group.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation DescribeEndpointGroup for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeEndpointGroupNotFoundException "EndpointGroupNotFoundException"
- // The endpoint group that you specified doesn't exist.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DescribeEndpointGroup
- func (c *GlobalAccelerator) DescribeEndpointGroup(input *DescribeEndpointGroupInput) (*DescribeEndpointGroupOutput, error) {
- req, out := c.DescribeEndpointGroupRequest(input)
- return out, req.Send()
- }
- // DescribeEndpointGroupWithContext is the same as DescribeEndpointGroup with the addition of
- // the ability to pass a context and additional request options.
- //
- // See DescribeEndpointGroup for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) DescribeEndpointGroupWithContext(ctx aws.Context, input *DescribeEndpointGroupInput, opts ...request.Option) (*DescribeEndpointGroupOutput, error) {
- req, out := c.DescribeEndpointGroupRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opDescribeListener = "DescribeListener"
- // DescribeListenerRequest generates a "aws/request.Request" representing the
- // client's request for the DescribeListener operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See DescribeListener for more information on using the DescribeListener
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the DescribeListenerRequest method.
- // req, resp := client.DescribeListenerRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DescribeListener
- func (c *GlobalAccelerator) DescribeListenerRequest(input *DescribeListenerInput) (req *request.Request, output *DescribeListenerOutput) {
- op := &request.Operation{
- Name: opDescribeListener,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &DescribeListenerInput{}
- }
- output = &DescribeListenerOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // DescribeListener API operation for AWS Global Accelerator.
- //
- // Describe a listener.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation DescribeListener for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeInvalidArgumentException "InvalidArgumentException"
- // An argument that you specified is invalid.
- //
- // * ErrCodeListenerNotFoundException "ListenerNotFoundException"
- // The listener that you specified doesn't exist.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/DescribeListener
- func (c *GlobalAccelerator) DescribeListener(input *DescribeListenerInput) (*DescribeListenerOutput, error) {
- req, out := c.DescribeListenerRequest(input)
- return out, req.Send()
- }
- // DescribeListenerWithContext is the same as DescribeListener with the addition of
- // the ability to pass a context and additional request options.
- //
- // See DescribeListener for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) DescribeListenerWithContext(ctx aws.Context, input *DescribeListenerInput, opts ...request.Option) (*DescribeListenerOutput, error) {
- req, out := c.DescribeListenerRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opListAccelerators = "ListAccelerators"
- // ListAcceleratorsRequest generates a "aws/request.Request" representing the
- // client's request for the ListAccelerators operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See ListAccelerators for more information on using the ListAccelerators
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the ListAcceleratorsRequest method.
- // req, resp := client.ListAcceleratorsRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/ListAccelerators
- func (c *GlobalAccelerator) ListAcceleratorsRequest(input *ListAcceleratorsInput) (req *request.Request, output *ListAcceleratorsOutput) {
- op := &request.Operation{
- Name: opListAccelerators,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &ListAcceleratorsInput{}
- }
- output = &ListAcceleratorsOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // ListAccelerators API operation for AWS Global Accelerator.
- //
- // List the accelerators for an AWS account.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation ListAccelerators for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeInvalidNextTokenException "InvalidNextTokenException"
- // There isn't another item to return.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/ListAccelerators
- func (c *GlobalAccelerator) ListAccelerators(input *ListAcceleratorsInput) (*ListAcceleratorsOutput, error) {
- req, out := c.ListAcceleratorsRequest(input)
- return out, req.Send()
- }
- // ListAcceleratorsWithContext is the same as ListAccelerators with the addition of
- // the ability to pass a context and additional request options.
- //
- // See ListAccelerators for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) ListAcceleratorsWithContext(ctx aws.Context, input *ListAcceleratorsInput, opts ...request.Option) (*ListAcceleratorsOutput, error) {
- req, out := c.ListAcceleratorsRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opListEndpointGroups = "ListEndpointGroups"
- // ListEndpointGroupsRequest generates a "aws/request.Request" representing the
- // client's request for the ListEndpointGroups operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See ListEndpointGroups for more information on using the ListEndpointGroups
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the ListEndpointGroupsRequest method.
- // req, resp := client.ListEndpointGroupsRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/ListEndpointGroups
- func (c *GlobalAccelerator) ListEndpointGroupsRequest(input *ListEndpointGroupsInput) (req *request.Request, output *ListEndpointGroupsOutput) {
- op := &request.Operation{
- Name: opListEndpointGroups,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &ListEndpointGroupsInput{}
- }
- output = &ListEndpointGroupsOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // ListEndpointGroups API operation for AWS Global Accelerator.
- //
- // List the endpoint groups that are associated with a listener.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation ListEndpointGroups for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeListenerNotFoundException "ListenerNotFoundException"
- // The listener that you specified doesn't exist.
- //
- // * ErrCodeInvalidNextTokenException "InvalidNextTokenException"
- // There isn't another item to return.
- //
- // * ErrCodeInvalidArgumentException "InvalidArgumentException"
- // An argument that you specified is invalid.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/ListEndpointGroups
- func (c *GlobalAccelerator) ListEndpointGroups(input *ListEndpointGroupsInput) (*ListEndpointGroupsOutput, error) {
- req, out := c.ListEndpointGroupsRequest(input)
- return out, req.Send()
- }
- // ListEndpointGroupsWithContext is the same as ListEndpointGroups with the addition of
- // the ability to pass a context and additional request options.
- //
- // See ListEndpointGroups for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) ListEndpointGroupsWithContext(ctx aws.Context, input *ListEndpointGroupsInput, opts ...request.Option) (*ListEndpointGroupsOutput, error) {
- req, out := c.ListEndpointGroupsRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opListListeners = "ListListeners"
- // ListListenersRequest generates a "aws/request.Request" representing the
- // client's request for the ListListeners operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See ListListeners for more information on using the ListListeners
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the ListListenersRequest method.
- // req, resp := client.ListListenersRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/ListListeners
- func (c *GlobalAccelerator) ListListenersRequest(input *ListListenersInput) (req *request.Request, output *ListListenersOutput) {
- op := &request.Operation{
- Name: opListListeners,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &ListListenersInput{}
- }
- output = &ListListenersOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // ListListeners API operation for AWS Global Accelerator.
- //
- // List the listeners for an accelerator.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation ListListeners for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeAcceleratorNotFoundException "AcceleratorNotFoundException"
- // The accelerator that you specified doesn't exist.
- //
- // * ErrCodeInvalidNextTokenException "InvalidNextTokenException"
- // There isn't another item to return.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/ListListeners
- func (c *GlobalAccelerator) ListListeners(input *ListListenersInput) (*ListListenersOutput, error) {
- req, out := c.ListListenersRequest(input)
- return out, req.Send()
- }
- // ListListenersWithContext is the same as ListListeners with the addition of
- // the ability to pass a context and additional request options.
- //
- // See ListListeners for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) ListListenersWithContext(ctx aws.Context, input *ListListenersInput, opts ...request.Option) (*ListListenersOutput, error) {
- req, out := c.ListListenersRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opUpdateAccelerator = "UpdateAccelerator"
- // UpdateAcceleratorRequest generates a "aws/request.Request" representing the
- // client's request for the UpdateAccelerator operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See UpdateAccelerator for more information on using the UpdateAccelerator
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the UpdateAcceleratorRequest method.
- // req, resp := client.UpdateAcceleratorRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/UpdateAccelerator
- func (c *GlobalAccelerator) UpdateAcceleratorRequest(input *UpdateAcceleratorInput) (req *request.Request, output *UpdateAcceleratorOutput) {
- op := &request.Operation{
- Name: opUpdateAccelerator,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &UpdateAcceleratorInput{}
- }
- output = &UpdateAcceleratorOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // UpdateAccelerator API operation for AWS Global Accelerator.
- //
- // Update an accelerator.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation UpdateAccelerator for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeAcceleratorNotFoundException "AcceleratorNotFoundException"
- // The accelerator that you specified doesn't exist.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // * ErrCodeInvalidArgumentException "InvalidArgumentException"
- // An argument that you specified is invalid.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/UpdateAccelerator
- func (c *GlobalAccelerator) UpdateAccelerator(input *UpdateAcceleratorInput) (*UpdateAcceleratorOutput, error) {
- req, out := c.UpdateAcceleratorRequest(input)
- return out, req.Send()
- }
- // UpdateAcceleratorWithContext is the same as UpdateAccelerator with the addition of
- // the ability to pass a context and additional request options.
- //
- // See UpdateAccelerator for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) UpdateAcceleratorWithContext(ctx aws.Context, input *UpdateAcceleratorInput, opts ...request.Option) (*UpdateAcceleratorOutput, error) {
- req, out := c.UpdateAcceleratorRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opUpdateAcceleratorAttributes = "UpdateAcceleratorAttributes"
- // UpdateAcceleratorAttributesRequest generates a "aws/request.Request" representing the
- // client's request for the UpdateAcceleratorAttributes operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See UpdateAcceleratorAttributes for more information on using the UpdateAcceleratorAttributes
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the UpdateAcceleratorAttributesRequest method.
- // req, resp := client.UpdateAcceleratorAttributesRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/UpdateAcceleratorAttributes
- func (c *GlobalAccelerator) UpdateAcceleratorAttributesRequest(input *UpdateAcceleratorAttributesInput) (req *request.Request, output *UpdateAcceleratorAttributesOutput) {
- op := &request.Operation{
- Name: opUpdateAcceleratorAttributes,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &UpdateAcceleratorAttributesInput{}
- }
- output = &UpdateAcceleratorAttributesOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // UpdateAcceleratorAttributes API operation for AWS Global Accelerator.
- //
- // Update the attributes for an accelerator. To see an AWS CLI example of updating
- // an accelerator to enable flow logs, scroll down to Example.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation UpdateAcceleratorAttributes for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeAcceleratorNotFoundException "AcceleratorNotFoundException"
- // The accelerator that you specified doesn't exist.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // * ErrCodeInvalidArgumentException "InvalidArgumentException"
- // An argument that you specified is invalid.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/UpdateAcceleratorAttributes
- func (c *GlobalAccelerator) UpdateAcceleratorAttributes(input *UpdateAcceleratorAttributesInput) (*UpdateAcceleratorAttributesOutput, error) {
- req, out := c.UpdateAcceleratorAttributesRequest(input)
- return out, req.Send()
- }
- // UpdateAcceleratorAttributesWithContext is the same as UpdateAcceleratorAttributes with the addition of
- // the ability to pass a context and additional request options.
- //
- // See UpdateAcceleratorAttributes for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) UpdateAcceleratorAttributesWithContext(ctx aws.Context, input *UpdateAcceleratorAttributesInput, opts ...request.Option) (*UpdateAcceleratorAttributesOutput, error) {
- req, out := c.UpdateAcceleratorAttributesRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opUpdateEndpointGroup = "UpdateEndpointGroup"
- // UpdateEndpointGroupRequest generates a "aws/request.Request" representing the
- // client's request for the UpdateEndpointGroup operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See UpdateEndpointGroup for more information on using the UpdateEndpointGroup
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the UpdateEndpointGroupRequest method.
- // req, resp := client.UpdateEndpointGroupRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/UpdateEndpointGroup
- func (c *GlobalAccelerator) UpdateEndpointGroupRequest(input *UpdateEndpointGroupInput) (req *request.Request, output *UpdateEndpointGroupOutput) {
- op := &request.Operation{
- Name: opUpdateEndpointGroup,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &UpdateEndpointGroupInput{}
- }
- output = &UpdateEndpointGroupOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // UpdateEndpointGroup API operation for AWS Global Accelerator.
- //
- // Update an endpoint group. To see an AWS CLI example of updating an endpoint
- // group, scroll down to Example.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation UpdateEndpointGroup for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeInvalidArgumentException "InvalidArgumentException"
- // An argument that you specified is invalid.
- //
- // * ErrCodeEndpointGroupNotFoundException "EndpointGroupNotFoundException"
- // The endpoint group that you specified doesn't exist.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // * ErrCodeLimitExceededException "LimitExceededException"
- // Processing your request would cause you to exceed an AWS Global Accelerator
- // limit.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/UpdateEndpointGroup
- func (c *GlobalAccelerator) UpdateEndpointGroup(input *UpdateEndpointGroupInput) (*UpdateEndpointGroupOutput, error) {
- req, out := c.UpdateEndpointGroupRequest(input)
- return out, req.Send()
- }
- // UpdateEndpointGroupWithContext is the same as UpdateEndpointGroup with the addition of
- // the ability to pass a context and additional request options.
- //
- // See UpdateEndpointGroup for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) UpdateEndpointGroupWithContext(ctx aws.Context, input *UpdateEndpointGroupInput, opts ...request.Option) (*UpdateEndpointGroupOutput, error) {
- req, out := c.UpdateEndpointGroupRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- const opUpdateListener = "UpdateListener"
- // UpdateListenerRequest generates a "aws/request.Request" representing the
- // client's request for the UpdateListener operation. The "output" return
- // value will be populated with the request's response once the request completes
- // successfully.
- //
- // Use "Send" method on the returned Request to send the API call to the service.
- // the "output" return value is not valid until after Send returns without error.
- //
- // See UpdateListener for more information on using the UpdateListener
- // API call, and error handling.
- //
- // This method is useful when you want to inject custom logic or configuration
- // into the SDK's request lifecycle. Such as custom headers, or retry logic.
- //
- //
- // // Example sending a request using the UpdateListenerRequest method.
- // req, resp := client.UpdateListenerRequest(params)
- //
- // err := req.Send()
- // if err == nil { // resp is now filled
- // fmt.Println(resp)
- // }
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/UpdateListener
- func (c *GlobalAccelerator) UpdateListenerRequest(input *UpdateListenerInput) (req *request.Request, output *UpdateListenerOutput) {
- op := &request.Operation{
- Name: opUpdateListener,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
- if input == nil {
- input = &UpdateListenerInput{}
- }
- output = &UpdateListenerOutput{}
- req = c.newRequest(op, input, output)
- return
- }
- // UpdateListener API operation for AWS Global Accelerator.
- //
- // Update a listener.
- //
- // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
- // with awserr.Error's Code and Message methods to get detailed information about
- // the error.
- //
- // See the AWS API reference guide for AWS Global Accelerator's
- // API operation UpdateListener for usage and error information.
- //
- // Returned Error Codes:
- // * ErrCodeInvalidArgumentException "InvalidArgumentException"
- // An argument that you specified is invalid.
- //
- // * ErrCodeInvalidPortRangeException "InvalidPortRangeException"
- // The port numbers that you specified are not valid numbers or are not unique
- // for this accelerator.
- //
- // * ErrCodeListenerNotFoundException "ListenerNotFoundException"
- // The listener that you specified doesn't exist.
- //
- // * ErrCodeInternalServiceErrorException "InternalServiceErrorException"
- // There was an internal error for AWS Global Accelerator.
- //
- // * ErrCodeLimitExceededException "LimitExceededException"
- // Processing your request would cause you to exceed an AWS Global Accelerator
- // limit.
- //
- // See also, https://docs.aws.amazon.com/goto/WebAPI/globalaccelerator-2018-08-08/UpdateListener
- func (c *GlobalAccelerator) UpdateListener(input *UpdateListenerInput) (*UpdateListenerOutput, error) {
- req, out := c.UpdateListenerRequest(input)
- return out, req.Send()
- }
- // UpdateListenerWithContext is the same as UpdateListener with the addition of
- // the ability to pass a context and additional request options.
- //
- // See UpdateListener for details on how to use this API operation.
- //
- // The context must be non-nil and will be used for request cancellation. If
- // the context is nil a panic will occur. In the future the SDK may create
- // sub-contexts for http.Requests. See https://golang.org/pkg/context/
- // for more information on using Contexts.
- func (c *GlobalAccelerator) UpdateListenerWithContext(ctx aws.Context, input *UpdateListenerInput, opts ...request.Option) (*UpdateListenerOutput, error) {
- req, out := c.UpdateListenerRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
- }
- // An accelerator is a complex type that includes one or more listeners that
- // process inbound connections and then direct traffic to one or more endpoint
- // groups, each of which includes endpoints, such as load balancers.
- type Accelerator struct {
- _ struct{} `type:"structure"`
- // The Amazon Resource Name (ARN) of the accelerator.
- AcceleratorArn *string `type:"string"`
- // The date and time that the accelerator was created.
- CreatedTime *time.Time `type:"timestamp"`
- // Indicates whether theaccelerator is enabled. The value is true or false.
- // The default value is true.
- //
- // If the value is set to true, the accelerator cannot be deleted. If set to
- // false, accelerator can be deleted.
- Enabled *bool `type:"boolean"`
- // The value for the address type must be IPv4.
- IpAddressType *string `type:"string" enum:"IpAddressType"`
- // IP address set associated with the accelerator.
- IpSets []*IpSet `type:"list"`
- // The date and time that the accelerator was last modified.
- LastModifiedTime *time.Time `type:"timestamp"`
- // The name of the accelerator. The name can have a maximum of 32 characters,
- // must contain only alphanumeric characters or hyphens (-), and must not begin
- // or end with a hyphen.
- Name *string `type:"string"`
- // Describes the deployment status of the accelerator.
- Status *string `type:"string" enum:"AcceleratorStatus"`
- }
- // String returns the string representation
- func (s Accelerator) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s Accelerator) GoString() string {
- return s.String()
- }
- // SetAcceleratorArn sets the AcceleratorArn field's value.
- func (s *Accelerator) SetAcceleratorArn(v string) *Accelerator {
- s.AcceleratorArn = &v
- return s
- }
- // SetCreatedTime sets the CreatedTime field's value.
- func (s *Accelerator) SetCreatedTime(v time.Time) *Accelerator {
- s.CreatedTime = &v
- return s
- }
- // SetEnabled sets the Enabled field's value.
- func (s *Accelerator) SetEnabled(v bool) *Accelerator {
- s.Enabled = &v
- return s
- }
- // SetIpAddressType sets the IpAddressType field's value.
- func (s *Accelerator) SetIpAddressType(v string) *Accelerator {
- s.IpAddressType = &v
- return s
- }
- // SetIpSets sets the IpSets field's value.
- func (s *Accelerator) SetIpSets(v []*IpSet) *Accelerator {
- s.IpSets = v
- return s
- }
- // SetLastModifiedTime sets the LastModifiedTime field's value.
- func (s *Accelerator) SetLastModifiedTime(v time.Time) *Accelerator {
- s.LastModifiedTime = &v
- return s
- }
- // SetName sets the Name field's value.
- func (s *Accelerator) SetName(v string) *Accelerator {
- s.Name = &v
- return s
- }
- // SetStatus sets the Status field's value.
- func (s *Accelerator) SetStatus(v string) *Accelerator {
- s.Status = &v
- return s
- }
- // Attributes of an accelerator.
- type AcceleratorAttributes struct {
- _ struct{} `type:"structure"`
- // Indicates whether flow logs are enabled. The default value is false. If the
- // value is true, FlowLogsS3Bucket and FlowLogsS3Prefix must be specified.
- //
- // For more information, see Flow Logs (https://docs.aws.amazon.com/global-accelerator/latest/dg/monitoring-global-accelerator.flow-logs.html)
- // in the AWS Global Accelerator Developer Guide.
- FlowLogsEnabled *bool `type:"boolean"`
- // The name of the Amazon S3 bucket for the flow logs. Attribute is required
- // if FlowLogsEnabled is true. The bucket must exist and have a bucket policy
- // that grants AWS Global Accelerator permission to write to the bucket.
- FlowLogsS3Bucket *string `type:"string"`
- // The prefix for the location in the Amazon S3 bucket for the flow logs. Attribute
- // is required if FlowLogsEnabled is true. If you don’t specify a prefix, the
- // flow logs are stored in the root of the bucket.
- FlowLogsS3Prefix *string `type:"string"`
- }
- // String returns the string representation
- func (s AcceleratorAttributes) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s AcceleratorAttributes) GoString() string {
- return s.String()
- }
- // SetFlowLogsEnabled sets the FlowLogsEnabled field's value.
- func (s *AcceleratorAttributes) SetFlowLogsEnabled(v bool) *AcceleratorAttributes {
- s.FlowLogsEnabled = &v
- return s
- }
- // SetFlowLogsS3Bucket sets the FlowLogsS3Bucket field's value.
- func (s *AcceleratorAttributes) SetFlowLogsS3Bucket(v string) *AcceleratorAttributes {
- s.FlowLogsS3Bucket = &v
- return s
- }
- // SetFlowLogsS3Prefix sets the FlowLogsS3Prefix field's value.
- func (s *AcceleratorAttributes) SetFlowLogsS3Prefix(v string) *AcceleratorAttributes {
- s.FlowLogsS3Prefix = &v
- return s
- }
- type CreateAcceleratorInput struct {
- _ struct{} `type:"structure"`
- // Indicates whether an accelerator is enabled. The value is true or false.
- // The default value is true.
- //
- // If the value is set to true, an accelerator cannot be deleted. If set to
- // false, the accelerator can be deleted.
- Enabled *bool `type:"boolean"`
- // A unique, case-sensitive identifier that you provide to ensure the idempotency—that
- // is, the uniqueness—of an accelerator.
- //
- // IdempotencyToken is a required field
- IdempotencyToken *string `type:"string" required:"true"`
- // The value for the address type must be IPv4.
- IpAddressType *string `type:"string" enum:"IpAddressType"`
- // The name of an accelerator. The name can have a maximum of 32 characters,
- // must contain only alphanumeric characters or hyphens (-), and must not begin
- // or end with a hyphen.
- //
- // Name is a required field
- Name *string `type:"string" required:"true"`
- }
- // String returns the string representation
- func (s CreateAcceleratorInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s CreateAcceleratorInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *CreateAcceleratorInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "CreateAcceleratorInput"}
- if s.IdempotencyToken == nil {
- invalidParams.Add(request.NewErrParamRequired("IdempotencyToken"))
- }
- if s.Name == nil {
- invalidParams.Add(request.NewErrParamRequired("Name"))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetEnabled sets the Enabled field's value.
- func (s *CreateAcceleratorInput) SetEnabled(v bool) *CreateAcceleratorInput {
- s.Enabled = &v
- return s
- }
- // SetIdempotencyToken sets the IdempotencyToken field's value.
- func (s *CreateAcceleratorInput) SetIdempotencyToken(v string) *CreateAcceleratorInput {
- s.IdempotencyToken = &v
- return s
- }
- // SetIpAddressType sets the IpAddressType field's value.
- func (s *CreateAcceleratorInput) SetIpAddressType(v string) *CreateAcceleratorInput {
- s.IpAddressType = &v
- return s
- }
- // SetName sets the Name field's value.
- func (s *CreateAcceleratorInput) SetName(v string) *CreateAcceleratorInput {
- s.Name = &v
- return s
- }
- type CreateAcceleratorOutput struct {
- _ struct{} `type:"structure"`
- // The accelerator that is created by specifying a listener and the supported
- // IP address types.
- Accelerator *Accelerator `type:"structure"`
- }
- // String returns the string representation
- func (s CreateAcceleratorOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s CreateAcceleratorOutput) GoString() string {
- return s.String()
- }
- // SetAccelerator sets the Accelerator field's value.
- func (s *CreateAcceleratorOutput) SetAccelerator(v *Accelerator) *CreateAcceleratorOutput {
- s.Accelerator = v
- return s
- }
- type CreateEndpointGroupInput struct {
- _ struct{} `type:"structure"`
- // The list of endpoint objects.
- EndpointConfigurations []*EndpointConfiguration `type:"list"`
- // The name of the AWS Region where the endpoint group is located. A listener
- // can have only one endpoint group in a specific Region.
- //
- // EndpointGroupRegion is a required field
- EndpointGroupRegion *string `type:"string" required:"true"`
- // The time—10 seconds or 30 seconds—between each health check for an endpoint.
- // The default value is 30.
- HealthCheckIntervalSeconds *int64 `min:"10" type:"integer"`
- // If the protocol is HTTP/S, then this specifies the path that is the destination
- // for health check targets. The default value is slash (/).
- HealthCheckPath *string `type:"string"`
- // The port that AWS Global Accelerator uses to check the health of endpoints
- // that are part of this endpoint group. The default port is the listener port
- // that this endpoint group is associated with. If listener port is a list of
- // ports, Global Accelerator uses the first port in the list.
- HealthCheckPort *int64 `min:"1" type:"integer"`
- // The protocol that AWS Global Accelerator uses to check the health of endpoints
- // that are part of this endpoint group. The default value is TCP.
- HealthCheckProtocol *string `type:"string" enum:"HealthCheckProtocol"`
- // A unique, case-sensitive identifier that you provide to ensure the idempotency—that
- // is, the uniqueness—of the request.
- //
- // IdempotencyToken is a required field
- IdempotencyToken *string `type:"string" required:"true"`
- // The Amazon Resource Name (ARN) of the listener.
- //
- // ListenerArn is a required field
- ListenerArn *string `type:"string" required:"true"`
- // The number of consecutive health checks required to set the state of a healthy
- // endpoint to unhealthy, or to set an unhealthy endpoint to healthy. The default
- // value is 3.
- ThresholdCount *int64 `min:"1" type:"integer"`
- // The percentage of traffic to send to an AWS Region. Additional traffic is
- // distributed to other endpoint groups for this listener.
- //
- // Use this action to increase (dial up) or decrease (dial down) traffic to
- // a specific Region. The percentage is applied to the traffic that would otherwise
- // have been routed to the Region based on optimal routing.
- //
- // The default value is 100.
- TrafficDialPercentage *float64 `type:"float"`
- }
- // String returns the string representation
- func (s CreateEndpointGroupInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s CreateEndpointGroupInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *CreateEndpointGroupInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "CreateEndpointGroupInput"}
- if s.EndpointGroupRegion == nil {
- invalidParams.Add(request.NewErrParamRequired("EndpointGroupRegion"))
- }
- if s.HealthCheckIntervalSeconds != nil && *s.HealthCheckIntervalSeconds < 10 {
- invalidParams.Add(request.NewErrParamMinValue("HealthCheckIntervalSeconds", 10))
- }
- if s.HealthCheckPort != nil && *s.HealthCheckPort < 1 {
- invalidParams.Add(request.NewErrParamMinValue("HealthCheckPort", 1))
- }
- if s.IdempotencyToken == nil {
- invalidParams.Add(request.NewErrParamRequired("IdempotencyToken"))
- }
- if s.ListenerArn == nil {
- invalidParams.Add(request.NewErrParamRequired("ListenerArn"))
- }
- if s.ThresholdCount != nil && *s.ThresholdCount < 1 {
- invalidParams.Add(request.NewErrParamMinValue("ThresholdCount", 1))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetEndpointConfigurations sets the EndpointConfigurations field's value.
- func (s *CreateEndpointGroupInput) SetEndpointConfigurations(v []*EndpointConfiguration) *CreateEndpointGroupInput {
- s.EndpointConfigurations = v
- return s
- }
- // SetEndpointGroupRegion sets the EndpointGroupRegion field's value.
- func (s *CreateEndpointGroupInput) SetEndpointGroupRegion(v string) *CreateEndpointGroupInput {
- s.EndpointGroupRegion = &v
- return s
- }
- // SetHealthCheckIntervalSeconds sets the HealthCheckIntervalSeconds field's value.
- func (s *CreateEndpointGroupInput) SetHealthCheckIntervalSeconds(v int64) *CreateEndpointGroupInput {
- s.HealthCheckIntervalSeconds = &v
- return s
- }
- // SetHealthCheckPath sets the HealthCheckPath field's value.
- func (s *CreateEndpointGroupInput) SetHealthCheckPath(v string) *CreateEndpointGroupInput {
- s.HealthCheckPath = &v
- return s
- }
- // SetHealthCheckPort sets the HealthCheckPort field's value.
- func (s *CreateEndpointGroupInput) SetHealthCheckPort(v int64) *CreateEndpointGroupInput {
- s.HealthCheckPort = &v
- return s
- }
- // SetHealthCheckProtocol sets the HealthCheckProtocol field's value.
- func (s *CreateEndpointGroupInput) SetHealthCheckProtocol(v string) *CreateEndpointGroupInput {
- s.HealthCheckProtocol = &v
- return s
- }
- // SetIdempotencyToken sets the IdempotencyToken field's value.
- func (s *CreateEndpointGroupInput) SetIdempotencyToken(v string) *CreateEndpointGroupInput {
- s.IdempotencyToken = &v
- return s
- }
- // SetListenerArn sets the ListenerArn field's value.
- func (s *CreateEndpointGroupInput) SetListenerArn(v string) *CreateEndpointGroupInput {
- s.ListenerArn = &v
- return s
- }
- // SetThresholdCount sets the ThresholdCount field's value.
- func (s *CreateEndpointGroupInput) SetThresholdCount(v int64) *CreateEndpointGroupInput {
- s.ThresholdCount = &v
- return s
- }
- // SetTrafficDialPercentage sets the TrafficDialPercentage field's value.
- func (s *CreateEndpointGroupInput) SetTrafficDialPercentage(v float64) *CreateEndpointGroupInput {
- s.TrafficDialPercentage = &v
- return s
- }
- type CreateEndpointGroupOutput struct {
- _ struct{} `type:"structure"`
- // The information about the endpoint group that was created.
- EndpointGroup *EndpointGroup `type:"structure"`
- }
- // String returns the string representation
- func (s CreateEndpointGroupOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s CreateEndpointGroupOutput) GoString() string {
- return s.String()
- }
- // SetEndpointGroup sets the EndpointGroup field's value.
- func (s *CreateEndpointGroupOutput) SetEndpointGroup(v *EndpointGroup) *CreateEndpointGroupOutput {
- s.EndpointGroup = v
- return s
- }
- type CreateListenerInput struct {
- _ struct{} `type:"structure"`
- // The Amazon Resource Name (ARN) of your accelerator.
- //
- // AcceleratorArn is a required field
- AcceleratorArn *string `type:"string" required:"true"`
- // Client affinity lets you direct all requests from a user to the same endpoint,
- // if you have stateful applications, regardless of the port and protocol of
- // the client request. Clienty affinity gives you control over whether to always
- // route each client to the same specific endpoint.
- //
- // AWS Global Accelerator uses a consistent-flow hashing algorithm to choose
- // the optimal endpoint for a connection. If client affinity is NONE, Global
- // Accelerator uses the "five-tuple" (5-tuple) properties—source IP address,
- // source port, destination IP address, destination port, and protocol—to select
- // the hash value, and then chooses the best endpoint. However, with this setting,
- // if someone uses different ports to connect to Global Accelerator, their connections
- // might not be always routed to the same endpoint because the hash value changes.
- //
- // If you want a given client to always be routed to the same endpoint, set
- // client affinity to SOURCE_IP instead. When you use the SOURCE_IP setting,
- // Global Accelerator uses the "two-tuple" (2-tuple) properties— source (client)
- // IP address and destination IP address—to select the hash value.
- //
- // The default value is NONE.
- ClientAffinity *string `type:"string" enum:"ClientAffinity"`
- // A unique, case-sensitive identifier that you provide to ensure the idempotency—that
- // is, the uniqueness—of the request.
- //
- // IdempotencyToken is a required field
- IdempotencyToken *string `type:"string" required:"true"`
- // The list of port ranges to support for connections from clients to your accelerator.
- //
- // PortRanges is a required field
- PortRanges []*PortRange `min:"1" type:"list" required:"true"`
- // The protocol for connections from clients to your accelerator.
- //
- // Protocol is a required field
- Protocol *string `type:"string" required:"true" enum:"Protocol"`
- }
- // String returns the string representation
- func (s CreateListenerInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s CreateListenerInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *CreateListenerInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "CreateListenerInput"}
- if s.AcceleratorArn == nil {
- invalidParams.Add(request.NewErrParamRequired("AcceleratorArn"))
- }
- if s.IdempotencyToken == nil {
- invalidParams.Add(request.NewErrParamRequired("IdempotencyToken"))
- }
- if s.PortRanges == nil {
- invalidParams.Add(request.NewErrParamRequired("PortRanges"))
- }
- if s.PortRanges != nil && len(s.PortRanges) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("PortRanges", 1))
- }
- if s.Protocol == nil {
- invalidParams.Add(request.NewErrParamRequired("Protocol"))
- }
- if s.PortRanges != nil {
- for i, v := range s.PortRanges {
- if v == nil {
- continue
- }
- if err := v.Validate(); err != nil {
- invalidParams.AddNested(fmt.Sprintf("%s[%v]", "PortRanges", i), err.(request.ErrInvalidParams))
- }
- }
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetAcceleratorArn sets the AcceleratorArn field's value.
- func (s *CreateListenerInput) SetAcceleratorArn(v string) *CreateListenerInput {
- s.AcceleratorArn = &v
- return s
- }
- // SetClientAffinity sets the ClientAffinity field's value.
- func (s *CreateListenerInput) SetClientAffinity(v string) *CreateListenerInput {
- s.ClientAffinity = &v
- return s
- }
- // SetIdempotencyToken sets the IdempotencyToken field's value.
- func (s *CreateListenerInput) SetIdempotencyToken(v string) *CreateListenerInput {
- s.IdempotencyToken = &v
- return s
- }
- // SetPortRanges sets the PortRanges field's value.
- func (s *CreateListenerInput) SetPortRanges(v []*PortRange) *CreateListenerInput {
- s.PortRanges = v
- return s
- }
- // SetProtocol sets the Protocol field's value.
- func (s *CreateListenerInput) SetProtocol(v string) *CreateListenerInput {
- s.Protocol = &v
- return s
- }
- type CreateListenerOutput struct {
- _ struct{} `type:"structure"`
- // The listener that you've created.
- Listener *Listener `type:"structure"`
- }
- // String returns the string representation
- func (s CreateListenerOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s CreateListenerOutput) GoString() string {
- return s.String()
- }
- // SetListener sets the Listener field's value.
- func (s *CreateListenerOutput) SetListener(v *Listener) *CreateListenerOutput {
- s.Listener = v
- return s
- }
- type DeleteAcceleratorInput struct {
- _ struct{} `type:"structure"`
- // The Amazon Resource Name (ARN) of an accelerator.
- //
- // AcceleratorArn is a required field
- AcceleratorArn *string `type:"string" required:"true"`
- }
- // String returns the string representation
- func (s DeleteAcceleratorInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DeleteAcceleratorInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *DeleteAcceleratorInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "DeleteAcceleratorInput"}
- if s.AcceleratorArn == nil {
- invalidParams.Add(request.NewErrParamRequired("AcceleratorArn"))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetAcceleratorArn sets the AcceleratorArn field's value.
- func (s *DeleteAcceleratorInput) SetAcceleratorArn(v string) *DeleteAcceleratorInput {
- s.AcceleratorArn = &v
- return s
- }
- type DeleteAcceleratorOutput struct {
- _ struct{} `type:"structure"`
- }
- // String returns the string representation
- func (s DeleteAcceleratorOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DeleteAcceleratorOutput) GoString() string {
- return s.String()
- }
- type DeleteEndpointGroupInput struct {
- _ struct{} `type:"structure"`
- // The Amazon Resource Name (ARN) of the endpoint group to delete.
- //
- // EndpointGroupArn is a required field
- EndpointGroupArn *string `type:"string" required:"true"`
- }
- // String returns the string representation
- func (s DeleteEndpointGroupInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DeleteEndpointGroupInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *DeleteEndpointGroupInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "DeleteEndpointGroupInput"}
- if s.EndpointGroupArn == nil {
- invalidParams.Add(request.NewErrParamRequired("EndpointGroupArn"))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetEndpointGroupArn sets the EndpointGroupArn field's value.
- func (s *DeleteEndpointGroupInput) SetEndpointGroupArn(v string) *DeleteEndpointGroupInput {
- s.EndpointGroupArn = &v
- return s
- }
- type DeleteEndpointGroupOutput struct {
- _ struct{} `type:"structure"`
- }
- // String returns the string representation
- func (s DeleteEndpointGroupOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DeleteEndpointGroupOutput) GoString() string {
- return s.String()
- }
- type DeleteListenerInput struct {
- _ struct{} `type:"structure"`
- // The Amazon Resource Name (ARN) of the listener.
- //
- // ListenerArn is a required field
- ListenerArn *string `type:"string" required:"true"`
- }
- // String returns the string representation
- func (s DeleteListenerInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DeleteListenerInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *DeleteListenerInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "DeleteListenerInput"}
- if s.ListenerArn == nil {
- invalidParams.Add(request.NewErrParamRequired("ListenerArn"))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetListenerArn sets the ListenerArn field's value.
- func (s *DeleteListenerInput) SetListenerArn(v string) *DeleteListenerInput {
- s.ListenerArn = &v
- return s
- }
- type DeleteListenerOutput struct {
- _ struct{} `type:"structure"`
- }
- // String returns the string representation
- func (s DeleteListenerOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DeleteListenerOutput) GoString() string {
- return s.String()
- }
- type DescribeAcceleratorAttributesInput struct {
- _ struct{} `type:"structure"`
- // The Amazon Resource Name (ARN) of the accelerator with the attributes that
- // you want to describe. Value is required.
- AcceleratorArn *string `type:"string"`
- }
- // String returns the string representation
- func (s DescribeAcceleratorAttributesInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DescribeAcceleratorAttributesInput) GoString() string {
- return s.String()
- }
- // SetAcceleratorArn sets the AcceleratorArn field's value.
- func (s *DescribeAcceleratorAttributesInput) SetAcceleratorArn(v string) *DescribeAcceleratorAttributesInput {
- s.AcceleratorArn = &v
- return s
- }
- type DescribeAcceleratorAttributesOutput struct {
- _ struct{} `type:"structure"`
- // The attributes of the accelerator.
- AcceleratorAttributes *AcceleratorAttributes `type:"structure"`
- }
- // String returns the string representation
- func (s DescribeAcceleratorAttributesOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DescribeAcceleratorAttributesOutput) GoString() string {
- return s.String()
- }
- // SetAcceleratorAttributes sets the AcceleratorAttributes field's value.
- func (s *DescribeAcceleratorAttributesOutput) SetAcceleratorAttributes(v *AcceleratorAttributes) *DescribeAcceleratorAttributesOutput {
- s.AcceleratorAttributes = v
- return s
- }
- type DescribeAcceleratorInput struct {
- _ struct{} `type:"structure"`
- // The Amazon Resource Name (ARN) of the accelerator to describe.
- //
- // AcceleratorArn is a required field
- AcceleratorArn *string `type:"string" required:"true"`
- }
- // String returns the string representation
- func (s DescribeAcceleratorInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DescribeAcceleratorInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *DescribeAcceleratorInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "DescribeAcceleratorInput"}
- if s.AcceleratorArn == nil {
- invalidParams.Add(request.NewErrParamRequired("AcceleratorArn"))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetAcceleratorArn sets the AcceleratorArn field's value.
- func (s *DescribeAcceleratorInput) SetAcceleratorArn(v string) *DescribeAcceleratorInput {
- s.AcceleratorArn = &v
- return s
- }
- type DescribeAcceleratorOutput struct {
- _ struct{} `type:"structure"`
- // The description of the accelerator.
- Accelerator *Accelerator `type:"structure"`
- }
- // String returns the string representation
- func (s DescribeAcceleratorOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DescribeAcceleratorOutput) GoString() string {
- return s.String()
- }
- // SetAccelerator sets the Accelerator field's value.
- func (s *DescribeAcceleratorOutput) SetAccelerator(v *Accelerator) *DescribeAcceleratorOutput {
- s.Accelerator = v
- return s
- }
- type DescribeEndpointGroupInput struct {
- _ struct{} `type:"structure"`
- // The Amazon Resource Name (ARN) of the endpoint group to describe.
- //
- // EndpointGroupArn is a required field
- EndpointGroupArn *string `type:"string" required:"true"`
- }
- // String returns the string representation
- func (s DescribeEndpointGroupInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DescribeEndpointGroupInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *DescribeEndpointGroupInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "DescribeEndpointGroupInput"}
- if s.EndpointGroupArn == nil {
- invalidParams.Add(request.NewErrParamRequired("EndpointGroupArn"))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetEndpointGroupArn sets the EndpointGroupArn field's value.
- func (s *DescribeEndpointGroupInput) SetEndpointGroupArn(v string) *DescribeEndpointGroupInput {
- s.EndpointGroupArn = &v
- return s
- }
- type DescribeEndpointGroupOutput struct {
- _ struct{} `type:"structure"`
- // The description of an endpoint group.
- EndpointGroup *EndpointGroup `type:"structure"`
- }
- // String returns the string representation
- func (s DescribeEndpointGroupOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DescribeEndpointGroupOutput) GoString() string {
- return s.String()
- }
- // SetEndpointGroup sets the EndpointGroup field's value.
- func (s *DescribeEndpointGroupOutput) SetEndpointGroup(v *EndpointGroup) *DescribeEndpointGroupOutput {
- s.EndpointGroup = v
- return s
- }
- type DescribeListenerInput struct {
- _ struct{} `type:"structure"`
- // The Amazon Resource Name (ARN) of the listener to describe.
- //
- // ListenerArn is a required field
- ListenerArn *string `type:"string" required:"true"`
- }
- // String returns the string representation
- func (s DescribeListenerInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DescribeListenerInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *DescribeListenerInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "DescribeListenerInput"}
- if s.ListenerArn == nil {
- invalidParams.Add(request.NewErrParamRequired("ListenerArn"))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetListenerArn sets the ListenerArn field's value.
- func (s *DescribeListenerInput) SetListenerArn(v string) *DescribeListenerInput {
- s.ListenerArn = &v
- return s
- }
- type DescribeListenerOutput struct {
- _ struct{} `type:"structure"`
- // The description of a listener.
- Listener *Listener `type:"structure"`
- }
- // String returns the string representation
- func (s DescribeListenerOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s DescribeListenerOutput) GoString() string {
- return s.String()
- }
- // SetListener sets the Listener field's value.
- func (s *DescribeListenerOutput) SetListener(v *Listener) *DescribeListenerOutput {
- s.Listener = v
- return s
- }
- // A complex type for endpoints.
- type EndpointConfiguration struct {
- _ struct{} `type:"structure"`
- // An ID for the endpoint. If the endpoint is a Network Load Balancer or Application
- // Load Balancer, this is the Amazon Resource Name (ARN) of the resource. If
- // the endpoint is an Elastic IP address, this is the Elastic IP address allocation
- // ID.
- EndpointId *string `type:"string"`
- // The weight associated with the endpoint. When you add weights to endpoints,
- // you configure AWS Global Accelerator to route traffic based on proportions
- // that you specify. For example, you might specify endpoint weights of 4, 5,
- // 5, and 6 (sum=20). The result is that 4/20 of your traffic, on average, is
- // routed to the first endpoint, 5/20 is routed both to the second and third
- // endpoints, and 6/20 is routed to the last endpoint. For more information,
- // see Endpoint Weights (https://docs.aws.amazon.com/global-accelerator/latest/dg/about-endpoints-endpoint-weights.html)
- // in the AWS Global Accelerator Developer Guide.
- Weight *int64 `type:"integer"`
- }
- // String returns the string representation
- func (s EndpointConfiguration) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s EndpointConfiguration) GoString() string {
- return s.String()
- }
- // SetEndpointId sets the EndpointId field's value.
- func (s *EndpointConfiguration) SetEndpointId(v string) *EndpointConfiguration {
- s.EndpointId = &v
- return s
- }
- // SetWeight sets the Weight field's value.
- func (s *EndpointConfiguration) SetWeight(v int64) *EndpointConfiguration {
- s.Weight = &v
- return s
- }
- // A complex type for an endpoint. Each endpoint group can include one or more
- // endpoints, such as load balancers.
- type EndpointDescription struct {
- _ struct{} `type:"structure"`
- // An ID for the endpoint. If the endpoint is a Network Load Balancer or Application
- // Load Balancer, this is the Amazon Resource Name (ARN) of the resource. If
- // the endpoint is an Elastic IP address, this is the Elastic IP address allocation
- // ID.
- EndpointId *string `type:"string"`
- // The reason code associated with why the endpoint is not healthy. If the endpoint
- // state is healthy, a reason code is not provided.
- //
- // If the endpoint state is unhealthy, the reason code can be one of the following
- // values:
- //
- // * Timeout: The health check requests to the endpoint are timing out before
- // returning a status.
- //
- // * Failed: The health check failed, for example because the endpoint response
- // was invalid (malformed).
- //
- // If the endpoint state is initial, the reason code can be one of the following
- // values:
- //
- // * ProvisioningInProgress: The endpoint is in the process of being provisioned.
- //
- // * InitialHealthChecking: Global Accelerator is still setting up the minimum
- // number of health checks for the endpoint that are required to determine
- // its health status.
- HealthReason *string `type:"string"`
- // The health status of the endpoint.
- HealthState *string `type:"string" enum:"HealthState"`
- // The weight associated with the endpoint. When you add weights to endpoints,
- // you configure AWS Global Accelerator to route traffic based on proportions
- // that you specify. For example, you might specify endpoint weights of 4, 5,
- // 5, and 6 (sum=20). The result is that 4/20 of your traffic, on average, is
- // routed to the first endpoint, 5/20 is routed both to the second and third
- // endpoints, and 6/20 is routed to the last endpoint. For more information,
- // see Endpoint Weights (https://docs.aws.amazon.com/global-accelerator/latest/dg/about-endpoints-endpoint-weights.html)
- // in the AWS Global Accelerator Developer Guide.
- Weight *int64 `type:"integer"`
- }
- // String returns the string representation
- func (s EndpointDescription) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s EndpointDescription) GoString() string {
- return s.String()
- }
- // SetEndpointId sets the EndpointId field's value.
- func (s *EndpointDescription) SetEndpointId(v string) *EndpointDescription {
- s.EndpointId = &v
- return s
- }
- // SetHealthReason sets the HealthReason field's value.
- func (s *EndpointDescription) SetHealthReason(v string) *EndpointDescription {
- s.HealthReason = &v
- return s
- }
- // SetHealthState sets the HealthState field's value.
- func (s *EndpointDescription) SetHealthState(v string) *EndpointDescription {
- s.HealthState = &v
- return s
- }
- // SetWeight sets the Weight field's value.
- func (s *EndpointDescription) SetWeight(v int64) *EndpointDescription {
- s.Weight = &v
- return s
- }
- // A complex type for the endpoint group. An AWS Region can have only one endpoint
- // group for a specific listener.
- type EndpointGroup struct {
- _ struct{} `type:"structure"`
- // The list of endpoint objects.
- EndpointDescriptions []*EndpointDescription `type:"list"`
- // The Amazon Resource Name (ARN) of the endpoint group.
- EndpointGroupArn *string `type:"string"`
- // The AWS Region that this endpoint group belongs.
- EndpointGroupRegion *string `type:"string"`
- // The time—10 seconds or 30 seconds—between health checks for each endpoint.
- // The default value is 30.
- HealthCheckIntervalSeconds *int64 `min:"10" type:"integer"`
- // If the protocol is HTTP/S, then this value provides the ping path that Global
- // Accelerator uses for the destination on the endpoints for health checks.
- // The default is slash (/).
- HealthCheckPath *string `type:"string"`
- // The port that Global Accelerator uses to perform health checks on endpoints
- // that are part of this endpoint group.
- //
- // The default port is the port for the listener that this endpoint group is
- // associated with. If the listener port is a list, Global Accelerator uses
- // the first specified port in the list of ports.
- HealthCheckPort *int64 `min:"1" type:"integer"`
- // The protocol that Global Accelerator uses to perform health checks on endpoints
- // that are part of this endpoint group. The default value is TCP.
- HealthCheckProtocol *string `type:"string" enum:"HealthCheckProtocol"`
- // The number of consecutive health checks required to set the state of a healthy
- // endpoint to unhealthy, or to set an unhealthy endpoint to healthy. The default
- // value is 3.
- ThresholdCount *int64 `min:"1" type:"integer"`
- // The percentage of traffic to send to an AWS Region. Additional traffic is
- // distributed to other endpoint groups for this listener.
- //
- // Use this action to increase (dial up) or decrease (dial down) traffic to
- // a specific Region. The percentage is applied to the traffic that would otherwise
- // have been routed to the Region based on optimal routing.
- //
- // The default value is 100.
- TrafficDialPercentage *float64 `type:"float"`
- }
- // String returns the string representation
- func (s EndpointGroup) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s EndpointGroup) GoString() string {
- return s.String()
- }
- // SetEndpointDescriptions sets the EndpointDescriptions field's value.
- func (s *EndpointGroup) SetEndpointDescriptions(v []*EndpointDescription) *EndpointGroup {
- s.EndpointDescriptions = v
- return s
- }
- // SetEndpointGroupArn sets the EndpointGroupArn field's value.
- func (s *EndpointGroup) SetEndpointGroupArn(v string) *EndpointGroup {
- s.EndpointGroupArn = &v
- return s
- }
- // SetEndpointGroupRegion sets the EndpointGroupRegion field's value.
- func (s *EndpointGroup) SetEndpointGroupRegion(v string) *EndpointGroup {
- s.EndpointGroupRegion = &v
- return s
- }
- // SetHealthCheckIntervalSeconds sets the HealthCheckIntervalSeconds field's value.
- func (s *EndpointGroup) SetHealthCheckIntervalSeconds(v int64) *EndpointGroup {
- s.HealthCheckIntervalSeconds = &v
- return s
- }
- // SetHealthCheckPath sets the HealthCheckPath field's value.
- func (s *EndpointGroup) SetHealthCheckPath(v string) *EndpointGroup {
- s.HealthCheckPath = &v
- return s
- }
- // SetHealthCheckPort sets the HealthCheckPort field's value.
- func (s *EndpointGroup) SetHealthCheckPort(v int64) *EndpointGroup {
- s.HealthCheckPort = &v
- return s
- }
- // SetHealthCheckProtocol sets the HealthCheckProtocol field's value.
- func (s *EndpointGroup) SetHealthCheckProtocol(v string) *EndpointGroup {
- s.HealthCheckProtocol = &v
- return s
- }
- // SetThresholdCount sets the ThresholdCount field's value.
- func (s *EndpointGroup) SetThresholdCount(v int64) *EndpointGroup {
- s.ThresholdCount = &v
- return s
- }
- // SetTrafficDialPercentage sets the TrafficDialPercentage field's value.
- func (s *EndpointGroup) SetTrafficDialPercentage(v float64) *EndpointGroup {
- s.TrafficDialPercentage = &v
- return s
- }
- // A complex type for the set of IP addresses for an accelerator.
- type IpSet struct {
- _ struct{} `type:"structure"`
- // The array of IP addresses in the IP address set. An IP address set can have
- // a maximum of two IP addresses.
- IpAddresses []*string `type:"list"`
- // The types of IP addresses included in this IP set.
- IpFamily *string `type:"string"`
- }
- // String returns the string representation
- func (s IpSet) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s IpSet) GoString() string {
- return s.String()
- }
- // SetIpAddresses sets the IpAddresses field's value.
- func (s *IpSet) SetIpAddresses(v []*string) *IpSet {
- s.IpAddresses = v
- return s
- }
- // SetIpFamily sets the IpFamily field's value.
- func (s *IpSet) SetIpFamily(v string) *IpSet {
- s.IpFamily = &v
- return s
- }
- type ListAcceleratorsInput struct {
- _ struct{} `type:"structure"`
- // The number of Global Accelerator objects that you want to return with this
- // call. The default value is 10.
- MaxResults *int64 `min:"1" type:"integer"`
- // The token for the next set of results. You receive this token from a previous
- // call.
- NextToken *string `type:"string"`
- }
- // String returns the string representation
- func (s ListAcceleratorsInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s ListAcceleratorsInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *ListAcceleratorsInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "ListAcceleratorsInput"}
- if s.MaxResults != nil && *s.MaxResults < 1 {
- invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetMaxResults sets the MaxResults field's value.
- func (s *ListAcceleratorsInput) SetMaxResults(v int64) *ListAcceleratorsInput {
- s.MaxResults = &v
- return s
- }
- // SetNextToken sets the NextToken field's value.
- func (s *ListAcceleratorsInput) SetNextToken(v string) *ListAcceleratorsInput {
- s.NextToken = &v
- return s
- }
- type ListAcceleratorsOutput struct {
- _ struct{} `type:"structure"`
- // The list of accelerators for a customer account.
- Accelerators []*Accelerator `type:"list"`
- // The token for the next set of results. You receive this token from a previous
- // call.
- NextToken *string `type:"string"`
- }
- // String returns the string representation
- func (s ListAcceleratorsOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s ListAcceleratorsOutput) GoString() string {
- return s.String()
- }
- // SetAccelerators sets the Accelerators field's value.
- func (s *ListAcceleratorsOutput) SetAccelerators(v []*Accelerator) *ListAcceleratorsOutput {
- s.Accelerators = v
- return s
- }
- // SetNextToken sets the NextToken field's value.
- func (s *ListAcceleratorsOutput) SetNextToken(v string) *ListAcceleratorsOutput {
- s.NextToken = &v
- return s
- }
- type ListEndpointGroupsInput struct {
- _ struct{} `type:"structure"`
- // The Amazon Resource Name (ARN) of the listener.
- //
- // ListenerArn is a required field
- ListenerArn *string `type:"string" required:"true"`
- // The number of endpoint group objects that you want to return with this call.
- // The default value is 10.
- MaxResults *int64 `min:"1" type:"integer"`
- // The token for the next set of results. You receive this token from a previous
- // call.
- NextToken *string `type:"string"`
- }
- // String returns the string representation
- func (s ListEndpointGroupsInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s ListEndpointGroupsInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *ListEndpointGroupsInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "ListEndpointGroupsInput"}
- if s.ListenerArn == nil {
- invalidParams.Add(request.NewErrParamRequired("ListenerArn"))
- }
- if s.MaxResults != nil && *s.MaxResults < 1 {
- invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetListenerArn sets the ListenerArn field's value.
- func (s *ListEndpointGroupsInput) SetListenerArn(v string) *ListEndpointGroupsInput {
- s.ListenerArn = &v
- return s
- }
- // SetMaxResults sets the MaxResults field's value.
- func (s *ListEndpointGroupsInput) SetMaxResults(v int64) *ListEndpointGroupsInput {
- s.MaxResults = &v
- return s
- }
- // SetNextToken sets the NextToken field's value.
- func (s *ListEndpointGroupsInput) SetNextToken(v string) *ListEndpointGroupsInput {
- s.NextToken = &v
- return s
- }
- type ListEndpointGroupsOutput struct {
- _ struct{} `type:"structure"`
- // The list of the endpoint groups associated with a listener.
- EndpointGroups []*EndpointGroup `type:"list"`
- // The token for the next set of results. You receive this token from a previous
- // call.
- NextToken *string `type:"string"`
- }
- // String returns the string representation
- func (s ListEndpointGroupsOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s ListEndpointGroupsOutput) GoString() string {
- return s.String()
- }
- // SetEndpointGroups sets the EndpointGroups field's value.
- func (s *ListEndpointGroupsOutput) SetEndpointGroups(v []*EndpointGroup) *ListEndpointGroupsOutput {
- s.EndpointGroups = v
- return s
- }
- // SetNextToken sets the NextToken field's value.
- func (s *ListEndpointGroupsOutput) SetNextToken(v string) *ListEndpointGroupsOutput {
- s.NextToken = &v
- return s
- }
- type ListListenersInput struct {
- _ struct{} `type:"structure"`
- // The Amazon Resource Name (ARN) of the accelerator for which you want to list
- // listener objects.
- //
- // AcceleratorArn is a required field
- AcceleratorArn *string `type:"string" required:"true"`
- // The number of listener objects that you want to return with this call. The
- // default value is 10.
- MaxResults *int64 `min:"1" type:"integer"`
- // The token for the next set of results. You receive this token from a previous
- // call.
- NextToken *string `type:"string"`
- }
- // String returns the string representation
- func (s ListListenersInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s ListListenersInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *ListListenersInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "ListListenersInput"}
- if s.AcceleratorArn == nil {
- invalidParams.Add(request.NewErrParamRequired("AcceleratorArn"))
- }
- if s.MaxResults != nil && *s.MaxResults < 1 {
- invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetAcceleratorArn sets the AcceleratorArn field's value.
- func (s *ListListenersInput) SetAcceleratorArn(v string) *ListListenersInput {
- s.AcceleratorArn = &v
- return s
- }
- // SetMaxResults sets the MaxResults field's value.
- func (s *ListListenersInput) SetMaxResults(v int64) *ListListenersInput {
- s.MaxResults = &v
- return s
- }
- // SetNextToken sets the NextToken field's value.
- func (s *ListListenersInput) SetNextToken(v string) *ListListenersInput {
- s.NextToken = &v
- return s
- }
- type ListListenersOutput struct {
- _ struct{} `type:"structure"`
- // The list of listeners for an accelerator.
- Listeners []*Listener `type:"list"`
- // The token for the next set of results. You receive this token from a previous
- // call.
- NextToken *string `type:"string"`
- }
- // String returns the string representation
- func (s ListListenersOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s ListListenersOutput) GoString() string {
- return s.String()
- }
- // SetListeners sets the Listeners field's value.
- func (s *ListListenersOutput) SetListeners(v []*Listener) *ListListenersOutput {
- s.Listeners = v
- return s
- }
- // SetNextToken sets the NextToken field's value.
- func (s *ListListenersOutput) SetNextToken(v string) *ListListenersOutput {
- s.NextToken = &v
- return s
- }
- // A complex type for a listener.
- type Listener struct {
- _ struct{} `type:"structure"`
- // Client affinity lets you direct all requests from a user to the same endpoint,
- // if you have stateful applications, regardless of the port and protocol of
- // the client request. Clienty affinity gives you control over whether to always
- // route each client to the same specific endpoint.
- //
- // AWS Global Accelerator uses a consistent-flow hashing algorithm to choose
- // the optimal endpoint for a connection. If client affinity is NONE, Global
- // Accelerator uses the "five-tuple" (5-tuple) properties—source IP address,
- // source port, destination IP address, destination port, and protocol—to select
- // the hash value, and then chooses the best endpoint. However, with this setting,
- // if someone uses different ports to connect to Global Accelerator, their connections
- // might not be always routed to the same endpoint because the hash value changes.
- //
- // If you want a given client to always be routed to the same endpoint, set
- // client affinity to SOURCE_IP instead. When you use the SOURCE_IP setting,
- // Global Accelerator uses the "two-tuple" (2-tuple) properties— source (client)
- // IP address and destination IP address—to select the hash value.
- //
- // The default value is NONE.
- ClientAffinity *string `type:"string" enum:"ClientAffinity"`
- // The Amazon Resource Name (ARN) of the listener.
- ListenerArn *string `type:"string"`
- // The list of port ranges for the connections from clients to the accelerator.
- PortRanges []*PortRange `min:"1" type:"list"`
- // The protocol for the connections from clients to the accelerator.
- Protocol *string `type:"string" enum:"Protocol"`
- }
- // String returns the string representation
- func (s Listener) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s Listener) GoString() string {
- return s.String()
- }
- // SetClientAffinity sets the ClientAffinity field's value.
- func (s *Listener) SetClientAffinity(v string) *Listener {
- s.ClientAffinity = &v
- return s
- }
- // SetListenerArn sets the ListenerArn field's value.
- func (s *Listener) SetListenerArn(v string) *Listener {
- s.ListenerArn = &v
- return s
- }
- // SetPortRanges sets the PortRanges field's value.
- func (s *Listener) SetPortRanges(v []*PortRange) *Listener {
- s.PortRanges = v
- return s
- }
- // SetProtocol sets the Protocol field's value.
- func (s *Listener) SetProtocol(v string) *Listener {
- s.Protocol = &v
- return s
- }
- // A complex type for a range of ports for a listener.
- type PortRange struct {
- _ struct{} `type:"structure"`
- // The first port in the range of ports, inclusive.
- FromPort *int64 `min:"1" type:"integer"`
- // The last port in the range of ports, inclusive.
- ToPort *int64 `min:"1" type:"integer"`
- }
- // String returns the string representation
- func (s PortRange) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s PortRange) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *PortRange) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "PortRange"}
- if s.FromPort != nil && *s.FromPort < 1 {
- invalidParams.Add(request.NewErrParamMinValue("FromPort", 1))
- }
- if s.ToPort != nil && *s.ToPort < 1 {
- invalidParams.Add(request.NewErrParamMinValue("ToPort", 1))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetFromPort sets the FromPort field's value.
- func (s *PortRange) SetFromPort(v int64) *PortRange {
- s.FromPort = &v
- return s
- }
- // SetToPort sets the ToPort field's value.
- func (s *PortRange) SetToPort(v int64) *PortRange {
- s.ToPort = &v
- return s
- }
- type UpdateAcceleratorAttributesInput struct {
- _ struct{} `type:"structure"`
- // The Amazon Resource Name (ARN) of the accelerator that you want to update.
- // Attribute is required.
- AcceleratorArn *string `type:"string"`
- // Update whether flow logs are enabled. The default value is false. If the
- // value is true, FlowLogsS3Bucket and FlowLogsS3Prefix must be specified.
- //
- // For more information, see Flow Logs (https://docs.aws.amazon.com/global-accelerator/latest/dg/monitoring-global-accelerator.flow-logs.html)
- // in the AWS Global Accelerator Developer Guide.
- FlowLogsEnabled *bool `type:"boolean"`
- // The name of the Amazon S3 bucket for the flow logs. Attribute is required
- // if FlowLogsEnabled is true. The bucket must exist and have a bucket policy
- // that grants AWS Global Accelerator permission to write to the bucket.
- FlowLogsS3Bucket *string `type:"string"`
- // Update the prefix for the location in the Amazon S3 bucket for the flow logs.
- // Attribute is required if FlowLogsEnabled is true. If you don’t specify a
- // prefix, the flow logs are stored in the root of the bucket.
- FlowLogsS3Prefix *string `type:"string"`
- }
- // String returns the string representation
- func (s UpdateAcceleratorAttributesInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s UpdateAcceleratorAttributesInput) GoString() string {
- return s.String()
- }
- // SetAcceleratorArn sets the AcceleratorArn field's value.
- func (s *UpdateAcceleratorAttributesInput) SetAcceleratorArn(v string) *UpdateAcceleratorAttributesInput {
- s.AcceleratorArn = &v
- return s
- }
- // SetFlowLogsEnabled sets the FlowLogsEnabled field's value.
- func (s *UpdateAcceleratorAttributesInput) SetFlowLogsEnabled(v bool) *UpdateAcceleratorAttributesInput {
- s.FlowLogsEnabled = &v
- return s
- }
- // SetFlowLogsS3Bucket sets the FlowLogsS3Bucket field's value.
- func (s *UpdateAcceleratorAttributesInput) SetFlowLogsS3Bucket(v string) *UpdateAcceleratorAttributesInput {
- s.FlowLogsS3Bucket = &v
- return s
- }
- // SetFlowLogsS3Prefix sets the FlowLogsS3Prefix field's value.
- func (s *UpdateAcceleratorAttributesInput) SetFlowLogsS3Prefix(v string) *UpdateAcceleratorAttributesInput {
- s.FlowLogsS3Prefix = &v
- return s
- }
- type UpdateAcceleratorAttributesOutput struct {
- _ struct{} `type:"structure"`
- // Updated attributes for the accelerator.
- AcceleratorAttributes *AcceleratorAttributes `type:"structure"`
- }
- // String returns the string representation
- func (s UpdateAcceleratorAttributesOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s UpdateAcceleratorAttributesOutput) GoString() string {
- return s.String()
- }
- // SetAcceleratorAttributes sets the AcceleratorAttributes field's value.
- func (s *UpdateAcceleratorAttributesOutput) SetAcceleratorAttributes(v *AcceleratorAttributes) *UpdateAcceleratorAttributesOutput {
- s.AcceleratorAttributes = v
- return s
- }
- type UpdateAcceleratorInput struct {
- _ struct{} `type:"structure"`
- // The Amazon Resource Name (ARN) of the accelerator to update.
- //
- // AcceleratorArn is a required field
- AcceleratorArn *string `type:"string" required:"true"`
- // Indicates whether an accelerator is enabled. The value is true or false.
- // The default value is true.
- //
- // If the value is set to true, the accelerator cannot be deleted. If set to
- // false, the accelerator can be deleted.
- Enabled *bool `type:"boolean"`
- // The value for the address type must be IPv4.
- IpAddressType *string `type:"string" enum:"IpAddressType"`
- // The name of the accelerator. The name can have a maximum of 32 characters,
- // must contain only alphanumeric characters or hyphens (-), and must not begin
- // or end with a hyphen.
- Name *string `type:"string"`
- }
- // String returns the string representation
- func (s UpdateAcceleratorInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s UpdateAcceleratorInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *UpdateAcceleratorInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "UpdateAcceleratorInput"}
- if s.AcceleratorArn == nil {
- invalidParams.Add(request.NewErrParamRequired("AcceleratorArn"))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetAcceleratorArn sets the AcceleratorArn field's value.
- func (s *UpdateAcceleratorInput) SetAcceleratorArn(v string) *UpdateAcceleratorInput {
- s.AcceleratorArn = &v
- return s
- }
- // SetEnabled sets the Enabled field's value.
- func (s *UpdateAcceleratorInput) SetEnabled(v bool) *UpdateAcceleratorInput {
- s.Enabled = &v
- return s
- }
- // SetIpAddressType sets the IpAddressType field's value.
- func (s *UpdateAcceleratorInput) SetIpAddressType(v string) *UpdateAcceleratorInput {
- s.IpAddressType = &v
- return s
- }
- // SetName sets the Name field's value.
- func (s *UpdateAcceleratorInput) SetName(v string) *UpdateAcceleratorInput {
- s.Name = &v
- return s
- }
- type UpdateAcceleratorOutput struct {
- _ struct{} `type:"structure"`
- // Information about the updated accelerator.
- Accelerator *Accelerator `type:"structure"`
- }
- // String returns the string representation
- func (s UpdateAcceleratorOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s UpdateAcceleratorOutput) GoString() string {
- return s.String()
- }
- // SetAccelerator sets the Accelerator field's value.
- func (s *UpdateAcceleratorOutput) SetAccelerator(v *Accelerator) *UpdateAcceleratorOutput {
- s.Accelerator = v
- return s
- }
- type UpdateEndpointGroupInput struct {
- _ struct{} `type:"structure"`
- // The list of endpoint objects.
- EndpointConfigurations []*EndpointConfiguration `type:"list"`
- // The Amazon Resource Name (ARN) of the endpoint group.
- //
- // EndpointGroupArn is a required field
- EndpointGroupArn *string `type:"string" required:"true"`
- // The time—10 seconds or 30 seconds—between each health check for an endpoint.
- // The default value is 30.
- HealthCheckIntervalSeconds *int64 `min:"10" type:"integer"`
- // If the protocol is HTTP/S, then this specifies the path that is the destination
- // for health check targets. The default value is slash (/).
- HealthCheckPath *string `type:"string"`
- // The port that AWS Global Accelerator uses to check the health of endpoints
- // that are part of this endpoint group. The default port is the listener port
- // that this endpoint group is associated with. If the listener port is a list
- // of ports, Global Accelerator uses the first port in the list.
- HealthCheckPort *int64 `min:"1" type:"integer"`
- // The protocol that AWS Global Accelerator uses to check the health of endpoints
- // that are part of this endpoint group. The default value is TCP.
- HealthCheckProtocol *string `type:"string" enum:"HealthCheckProtocol"`
- // The number of consecutive health checks required to set the state of a healthy
- // endpoint to unhealthy, or to set an unhealthy endpoint to healthy. The default
- // value is 3.
- ThresholdCount *int64 `min:"1" type:"integer"`
- // The percentage of traffic to send to an AWS Region. Additional traffic is
- // distributed to other endpoint groups for this listener.
- //
- // Use this action to increase (dial up) or decrease (dial down) traffic to
- // a specific Region. The percentage is applied to the traffic that would otherwise
- // have been routed to the Region based on optimal routing.
- //
- // The default value is 100.
- TrafficDialPercentage *float64 `type:"float"`
- }
- // String returns the string representation
- func (s UpdateEndpointGroupInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s UpdateEndpointGroupInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *UpdateEndpointGroupInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "UpdateEndpointGroupInput"}
- if s.EndpointGroupArn == nil {
- invalidParams.Add(request.NewErrParamRequired("EndpointGroupArn"))
- }
- if s.HealthCheckIntervalSeconds != nil && *s.HealthCheckIntervalSeconds < 10 {
- invalidParams.Add(request.NewErrParamMinValue("HealthCheckIntervalSeconds", 10))
- }
- if s.HealthCheckPort != nil && *s.HealthCheckPort < 1 {
- invalidParams.Add(request.NewErrParamMinValue("HealthCheckPort", 1))
- }
- if s.ThresholdCount != nil && *s.ThresholdCount < 1 {
- invalidParams.Add(request.NewErrParamMinValue("ThresholdCount", 1))
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetEndpointConfigurations sets the EndpointConfigurations field's value.
- func (s *UpdateEndpointGroupInput) SetEndpointConfigurations(v []*EndpointConfiguration) *UpdateEndpointGroupInput {
- s.EndpointConfigurations = v
- return s
- }
- // SetEndpointGroupArn sets the EndpointGroupArn field's value.
- func (s *UpdateEndpointGroupInput) SetEndpointGroupArn(v string) *UpdateEndpointGroupInput {
- s.EndpointGroupArn = &v
- return s
- }
- // SetHealthCheckIntervalSeconds sets the HealthCheckIntervalSeconds field's value.
- func (s *UpdateEndpointGroupInput) SetHealthCheckIntervalSeconds(v int64) *UpdateEndpointGroupInput {
- s.HealthCheckIntervalSeconds = &v
- return s
- }
- // SetHealthCheckPath sets the HealthCheckPath field's value.
- func (s *UpdateEndpointGroupInput) SetHealthCheckPath(v string) *UpdateEndpointGroupInput {
- s.HealthCheckPath = &v
- return s
- }
- // SetHealthCheckPort sets the HealthCheckPort field's value.
- func (s *UpdateEndpointGroupInput) SetHealthCheckPort(v int64) *UpdateEndpointGroupInput {
- s.HealthCheckPort = &v
- return s
- }
- // SetHealthCheckProtocol sets the HealthCheckProtocol field's value.
- func (s *UpdateEndpointGroupInput) SetHealthCheckProtocol(v string) *UpdateEndpointGroupInput {
- s.HealthCheckProtocol = &v
- return s
- }
- // SetThresholdCount sets the ThresholdCount field's value.
- func (s *UpdateEndpointGroupInput) SetThresholdCount(v int64) *UpdateEndpointGroupInput {
- s.ThresholdCount = &v
- return s
- }
- // SetTrafficDialPercentage sets the TrafficDialPercentage field's value.
- func (s *UpdateEndpointGroupInput) SetTrafficDialPercentage(v float64) *UpdateEndpointGroupInput {
- s.TrafficDialPercentage = &v
- return s
- }
- type UpdateEndpointGroupOutput struct {
- _ struct{} `type:"structure"`
- // The information about the endpoint group that was updated.
- EndpointGroup *EndpointGroup `type:"structure"`
- }
- // String returns the string representation
- func (s UpdateEndpointGroupOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s UpdateEndpointGroupOutput) GoString() string {
- return s.String()
- }
- // SetEndpointGroup sets the EndpointGroup field's value.
- func (s *UpdateEndpointGroupOutput) SetEndpointGroup(v *EndpointGroup) *UpdateEndpointGroupOutput {
- s.EndpointGroup = v
- return s
- }
- type UpdateListenerInput struct {
- _ struct{} `type:"structure"`
- // Client affinity lets you direct all requests from a user to the same endpoint,
- // if you have stateful applications, regardless of the port and protocol of
- // the client request. Clienty affinity gives you control over whether to always
- // route each client to the same specific endpoint.
- //
- // AWS Global Accelerator uses a consistent-flow hashing algorithm to choose
- // the optimal endpoint for a connection. If client affinity is NONE, Global
- // Accelerator uses the "five-tuple" (5-tuple) properties—source IP address,
- // source port, destination IP address, destination port, and protocol—to select
- // the hash value, and then chooses the best endpoint. However, with this setting,
- // if someone uses different ports to connect to Global Accelerator, their connections
- // might not be always routed to the same endpoint because the hash value changes.
- //
- // If you want a given client to always be routed to the same endpoint, set
- // client affinity to SOURCE_IP instead. When you use the SOURCE_IP setting,
- // Global Accelerator uses the "two-tuple" (2-tuple) properties— source (client)
- // IP address and destination IP address—to select the hash value.
- //
- // The default value is NONE.
- ClientAffinity *string `type:"string" enum:"ClientAffinity"`
- // The Amazon Resource Name (ARN) of the listener to update.
- //
- // ListenerArn is a required field
- ListenerArn *string `type:"string" required:"true"`
- // The updated list of port ranges for the connections from clients to the accelerator.
- PortRanges []*PortRange `min:"1" type:"list"`
- // The updated protocol for the connections from clients to the accelerator.
- Protocol *string `type:"string" enum:"Protocol"`
- }
- // String returns the string representation
- func (s UpdateListenerInput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s UpdateListenerInput) GoString() string {
- return s.String()
- }
- // Validate inspects the fields of the type to determine if they are valid.
- func (s *UpdateListenerInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "UpdateListenerInput"}
- if s.ListenerArn == nil {
- invalidParams.Add(request.NewErrParamRequired("ListenerArn"))
- }
- if s.PortRanges != nil && len(s.PortRanges) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("PortRanges", 1))
- }
- if s.PortRanges != nil {
- for i, v := range s.PortRanges {
- if v == nil {
- continue
- }
- if err := v.Validate(); err != nil {
- invalidParams.AddNested(fmt.Sprintf("%s[%v]", "PortRanges", i), err.(request.ErrInvalidParams))
- }
- }
- }
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
- }
- // SetClientAffinity sets the ClientAffinity field's value.
- func (s *UpdateListenerInput) SetClientAffinity(v string) *UpdateListenerInput {
- s.ClientAffinity = &v
- return s
- }
- // SetListenerArn sets the ListenerArn field's value.
- func (s *UpdateListenerInput) SetListenerArn(v string) *UpdateListenerInput {
- s.ListenerArn = &v
- return s
- }
- // SetPortRanges sets the PortRanges field's value.
- func (s *UpdateListenerInput) SetPortRanges(v []*PortRange) *UpdateListenerInput {
- s.PortRanges = v
- return s
- }
- // SetProtocol sets the Protocol field's value.
- func (s *UpdateListenerInput) SetProtocol(v string) *UpdateListenerInput {
- s.Protocol = &v
- return s
- }
- type UpdateListenerOutput struct {
- _ struct{} `type:"structure"`
- // Information for the updated listener.
- Listener *Listener `type:"structure"`
- }
- // String returns the string representation
- func (s UpdateListenerOutput) String() string {
- return awsutil.Prettify(s)
- }
- // GoString returns the string representation
- func (s UpdateListenerOutput) GoString() string {
- return s.String()
- }
- // SetListener sets the Listener field's value.
- func (s *UpdateListenerOutput) SetListener(v *Listener) *UpdateListenerOutput {
- s.Listener = v
- return s
- }
- const (
- // AcceleratorStatusDeployed is a AcceleratorStatus enum value
- AcceleratorStatusDeployed = "DEPLOYED"
- // AcceleratorStatusInProgress is a AcceleratorStatus enum value
- AcceleratorStatusInProgress = "IN_PROGRESS"
- )
- const (
- // ClientAffinityNone is a ClientAffinity enum value
- ClientAffinityNone = "NONE"
- // ClientAffinitySourceIp is a ClientAffinity enum value
- ClientAffinitySourceIp = "SOURCE_IP"
- )
- const (
- // HealthCheckProtocolTcp is a HealthCheckProtocol enum value
- HealthCheckProtocolTcp = "TCP"
- // HealthCheckProtocolHttp is a HealthCheckProtocol enum value
- HealthCheckProtocolHttp = "HTTP"
- // HealthCheckProtocolHttps is a HealthCheckProtocol enum value
- HealthCheckProtocolHttps = "HTTPS"
- )
- const (
- // HealthStateInitial is a HealthState enum value
- HealthStateInitial = "INITIAL"
- // HealthStateHealthy is a HealthState enum value
- HealthStateHealthy = "HEALTHY"
- // HealthStateUnhealthy is a HealthState enum value
- HealthStateUnhealthy = "UNHEALTHY"
- )
- const (
- // IpAddressTypeIpv4 is a IpAddressType enum value
- IpAddressTypeIpv4 = "IPV4"
- )
- const (
- // ProtocolTcp is a Protocol enum value
- ProtocolTcp = "TCP"
- // ProtocolUdp is a Protocol enum value
- ProtocolUdp = "UDP"
- )
|