1// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. 2 3package servicediscovery 4 5import ( 6 "fmt" 7 "time" 8 9 "github.com/aws/aws-sdk-go/aws" 10 "github.com/aws/aws-sdk-go/aws/awsutil" 11 "github.com/aws/aws-sdk-go/aws/request" 12 "github.com/aws/aws-sdk-go/private/protocol" 13 "github.com/aws/aws-sdk-go/private/protocol/jsonrpc" 14) 15 16const opCreateHttpNamespace = "CreateHttpNamespace" 17 18// CreateHttpNamespaceRequest generates a "aws/request.Request" representing the 19// client's request for the CreateHttpNamespace operation. The "output" return 20// value will be populated with the request's response once the request completes 21// successfully. 22// 23// Use "Send" method on the returned Request to send the API call to the service. 24// the "output" return value is not valid until after Send returns without error. 25// 26// See CreateHttpNamespace for more information on using the CreateHttpNamespace 27// API call, and error handling. 28// 29// This method is useful when you want to inject custom logic or configuration 30// into the SDK's request lifecycle. Such as custom headers, or retry logic. 31// 32// 33// // Example sending a request using the CreateHttpNamespaceRequest method. 34// req, resp := client.CreateHttpNamespaceRequest(params) 35// 36// err := req.Send() 37// if err == nil { // resp is now filled 38// fmt.Println(resp) 39// } 40// 41// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/CreateHttpNamespace 42func (c *ServiceDiscovery) CreateHttpNamespaceRequest(input *CreateHttpNamespaceInput) (req *request.Request, output *CreateHttpNamespaceOutput) { 43 op := &request.Operation{ 44 Name: opCreateHttpNamespace, 45 HTTPMethod: "POST", 46 HTTPPath: "/", 47 } 48 49 if input == nil { 50 input = &CreateHttpNamespaceInput{} 51 } 52 53 output = &CreateHttpNamespaceOutput{} 54 req = c.newRequest(op, input, output) 55 return 56} 57 58// CreateHttpNamespace API operation for AWS Cloud Map. 59// 60// Creates an HTTP namespace. Service instances that you register using an HTTP 61// namespace can be discovered using a DiscoverInstances request but can't be 62// discovered using DNS. 63// 64// For the current limit on the number of namespaces that you can create using 65// the same AWS account, see AWS Cloud Map Limits (http://docs.aws.amazon.com/cloud-map/latest/dg/cloud-map-limits.html) 66// in the AWS Cloud Map Developer Guide. 67// 68// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 69// with awserr.Error's Code and Message methods to get detailed information about 70// the error. 71// 72// See the AWS API reference guide for AWS Cloud Map's 73// API operation CreateHttpNamespace for usage and error information. 74// 75// Returned Error Types: 76// * InvalidInput 77// One or more specified values aren't valid. For example, a required value 78// might be missing, a numeric value might be outside the allowed range, or 79// a string value might exceed length constraints. 80// 81// * NamespaceAlreadyExists 82// The namespace that you're trying to create already exists. 83// 84// * ResourceLimitExceeded 85// The resource can't be created because you've reached the limit on the number 86// of resources. 87// 88// * DuplicateRequest 89// The operation is already in progress. 90// 91// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/CreateHttpNamespace 92func (c *ServiceDiscovery) CreateHttpNamespace(input *CreateHttpNamespaceInput) (*CreateHttpNamespaceOutput, error) { 93 req, out := c.CreateHttpNamespaceRequest(input) 94 return out, req.Send() 95} 96 97// CreateHttpNamespaceWithContext is the same as CreateHttpNamespace with the addition of 98// the ability to pass a context and additional request options. 99// 100// See CreateHttpNamespace for details on how to use this API operation. 101// 102// The context must be non-nil and will be used for request cancellation. If 103// the context is nil a panic will occur. In the future the SDK may create 104// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 105// for more information on using Contexts. 106func (c *ServiceDiscovery) CreateHttpNamespaceWithContext(ctx aws.Context, input *CreateHttpNamespaceInput, opts ...request.Option) (*CreateHttpNamespaceOutput, error) { 107 req, out := c.CreateHttpNamespaceRequest(input) 108 req.SetContext(ctx) 109 req.ApplyOptions(opts...) 110 return out, req.Send() 111} 112 113const opCreatePrivateDnsNamespace = "CreatePrivateDnsNamespace" 114 115// CreatePrivateDnsNamespaceRequest generates a "aws/request.Request" representing the 116// client's request for the CreatePrivateDnsNamespace operation. The "output" return 117// value will be populated with the request's response once the request completes 118// successfully. 119// 120// Use "Send" method on the returned Request to send the API call to the service. 121// the "output" return value is not valid until after Send returns without error. 122// 123// See CreatePrivateDnsNamespace for more information on using the CreatePrivateDnsNamespace 124// API call, and error handling. 125// 126// This method is useful when you want to inject custom logic or configuration 127// into the SDK's request lifecycle. Such as custom headers, or retry logic. 128// 129// 130// // Example sending a request using the CreatePrivateDnsNamespaceRequest method. 131// req, resp := client.CreatePrivateDnsNamespaceRequest(params) 132// 133// err := req.Send() 134// if err == nil { // resp is now filled 135// fmt.Println(resp) 136// } 137// 138// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/CreatePrivateDnsNamespace 139func (c *ServiceDiscovery) CreatePrivateDnsNamespaceRequest(input *CreatePrivateDnsNamespaceInput) (req *request.Request, output *CreatePrivateDnsNamespaceOutput) { 140 op := &request.Operation{ 141 Name: opCreatePrivateDnsNamespace, 142 HTTPMethod: "POST", 143 HTTPPath: "/", 144 } 145 146 if input == nil { 147 input = &CreatePrivateDnsNamespaceInput{} 148 } 149 150 output = &CreatePrivateDnsNamespaceOutput{} 151 req = c.newRequest(op, input, output) 152 return 153} 154 155// CreatePrivateDnsNamespace API operation for AWS Cloud Map. 156// 157// Creates a private namespace based on DNS, which will be visible only inside 158// a specified Amazon VPC. The namespace defines your service naming scheme. 159// For example, if you name your namespace example.com and name your service 160// backend, the resulting DNS name for the service will be backend.example.com. 161// For the current limit on the number of namespaces that you can create using 162// the same AWS account, see AWS Cloud Map Limits (http://docs.aws.amazon.com/cloud-map/latest/dg/cloud-map-limits.html) 163// in the AWS Cloud Map Developer Guide. 164// 165// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 166// with awserr.Error's Code and Message methods to get detailed information about 167// the error. 168// 169// See the AWS API reference guide for AWS Cloud Map's 170// API operation CreatePrivateDnsNamespace for usage and error information. 171// 172// Returned Error Types: 173// * InvalidInput 174// One or more specified values aren't valid. For example, a required value 175// might be missing, a numeric value might be outside the allowed range, or 176// a string value might exceed length constraints. 177// 178// * NamespaceAlreadyExists 179// The namespace that you're trying to create already exists. 180// 181// * ResourceLimitExceeded 182// The resource can't be created because you've reached the limit on the number 183// of resources. 184// 185// * DuplicateRequest 186// The operation is already in progress. 187// 188// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/CreatePrivateDnsNamespace 189func (c *ServiceDiscovery) CreatePrivateDnsNamespace(input *CreatePrivateDnsNamespaceInput) (*CreatePrivateDnsNamespaceOutput, error) { 190 req, out := c.CreatePrivateDnsNamespaceRequest(input) 191 return out, req.Send() 192} 193 194// CreatePrivateDnsNamespaceWithContext is the same as CreatePrivateDnsNamespace with the addition of 195// the ability to pass a context and additional request options. 196// 197// See CreatePrivateDnsNamespace for details on how to use this API operation. 198// 199// The context must be non-nil and will be used for request cancellation. If 200// the context is nil a panic will occur. In the future the SDK may create 201// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 202// for more information on using Contexts. 203func (c *ServiceDiscovery) CreatePrivateDnsNamespaceWithContext(ctx aws.Context, input *CreatePrivateDnsNamespaceInput, opts ...request.Option) (*CreatePrivateDnsNamespaceOutput, error) { 204 req, out := c.CreatePrivateDnsNamespaceRequest(input) 205 req.SetContext(ctx) 206 req.ApplyOptions(opts...) 207 return out, req.Send() 208} 209 210const opCreatePublicDnsNamespace = "CreatePublicDnsNamespace" 211 212// CreatePublicDnsNamespaceRequest generates a "aws/request.Request" representing the 213// client's request for the CreatePublicDnsNamespace operation. The "output" return 214// value will be populated with the request's response once the request completes 215// successfully. 216// 217// Use "Send" method on the returned Request to send the API call to the service. 218// the "output" return value is not valid until after Send returns without error. 219// 220// See CreatePublicDnsNamespace for more information on using the CreatePublicDnsNamespace 221// API call, and error handling. 222// 223// This method is useful when you want to inject custom logic or configuration 224// into the SDK's request lifecycle. Such as custom headers, or retry logic. 225// 226// 227// // Example sending a request using the CreatePublicDnsNamespaceRequest method. 228// req, resp := client.CreatePublicDnsNamespaceRequest(params) 229// 230// err := req.Send() 231// if err == nil { // resp is now filled 232// fmt.Println(resp) 233// } 234// 235// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/CreatePublicDnsNamespace 236func (c *ServiceDiscovery) CreatePublicDnsNamespaceRequest(input *CreatePublicDnsNamespaceInput) (req *request.Request, output *CreatePublicDnsNamespaceOutput) { 237 op := &request.Operation{ 238 Name: opCreatePublicDnsNamespace, 239 HTTPMethod: "POST", 240 HTTPPath: "/", 241 } 242 243 if input == nil { 244 input = &CreatePublicDnsNamespaceInput{} 245 } 246 247 output = &CreatePublicDnsNamespaceOutput{} 248 req = c.newRequest(op, input, output) 249 return 250} 251 252// CreatePublicDnsNamespace API operation for AWS Cloud Map. 253// 254// Creates a public namespace based on DNS, which will be visible on the internet. 255// The namespace defines your service naming scheme. For example, if you name 256// your namespace example.com and name your service backend, the resulting DNS 257// name for the service will be backend.example.com. For the current limit on 258// the number of namespaces that you can create using the same AWS account, 259// see AWS Cloud Map Limits (http://docs.aws.amazon.com/cloud-map/latest/dg/cloud-map-limits.html) 260// in the AWS Cloud Map Developer Guide. 261// 262// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 263// with awserr.Error's Code and Message methods to get detailed information about 264// the error. 265// 266// See the AWS API reference guide for AWS Cloud Map's 267// API operation CreatePublicDnsNamespace for usage and error information. 268// 269// Returned Error Types: 270// * InvalidInput 271// One or more specified values aren't valid. For example, a required value 272// might be missing, a numeric value might be outside the allowed range, or 273// a string value might exceed length constraints. 274// 275// * NamespaceAlreadyExists 276// The namespace that you're trying to create already exists. 277// 278// * ResourceLimitExceeded 279// The resource can't be created because you've reached the limit on the number 280// of resources. 281// 282// * DuplicateRequest 283// The operation is already in progress. 284// 285// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/CreatePublicDnsNamespace 286func (c *ServiceDiscovery) CreatePublicDnsNamespace(input *CreatePublicDnsNamespaceInput) (*CreatePublicDnsNamespaceOutput, error) { 287 req, out := c.CreatePublicDnsNamespaceRequest(input) 288 return out, req.Send() 289} 290 291// CreatePublicDnsNamespaceWithContext is the same as CreatePublicDnsNamespace with the addition of 292// the ability to pass a context and additional request options. 293// 294// See CreatePublicDnsNamespace for details on how to use this API operation. 295// 296// The context must be non-nil and will be used for request cancellation. If 297// the context is nil a panic will occur. In the future the SDK may create 298// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 299// for more information on using Contexts. 300func (c *ServiceDiscovery) CreatePublicDnsNamespaceWithContext(ctx aws.Context, input *CreatePublicDnsNamespaceInput, opts ...request.Option) (*CreatePublicDnsNamespaceOutput, error) { 301 req, out := c.CreatePublicDnsNamespaceRequest(input) 302 req.SetContext(ctx) 303 req.ApplyOptions(opts...) 304 return out, req.Send() 305} 306 307const opCreateService = "CreateService" 308 309// CreateServiceRequest generates a "aws/request.Request" representing the 310// client's request for the CreateService operation. The "output" return 311// value will be populated with the request's response once the request completes 312// successfully. 313// 314// Use "Send" method on the returned Request to send the API call to the service. 315// the "output" return value is not valid until after Send returns without error. 316// 317// See CreateService for more information on using the CreateService 318// API call, and error handling. 319// 320// This method is useful when you want to inject custom logic or configuration 321// into the SDK's request lifecycle. Such as custom headers, or retry logic. 322// 323// 324// // Example sending a request using the CreateServiceRequest method. 325// req, resp := client.CreateServiceRequest(params) 326// 327// err := req.Send() 328// if err == nil { // resp is now filled 329// fmt.Println(resp) 330// } 331// 332// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/CreateService 333func (c *ServiceDiscovery) CreateServiceRequest(input *CreateServiceInput) (req *request.Request, output *CreateServiceOutput) { 334 op := &request.Operation{ 335 Name: opCreateService, 336 HTTPMethod: "POST", 337 HTTPPath: "/", 338 } 339 340 if input == nil { 341 input = &CreateServiceInput{} 342 } 343 344 output = &CreateServiceOutput{} 345 req = c.newRequest(op, input, output) 346 return 347} 348 349// CreateService API operation for AWS Cloud Map. 350// 351// Creates a service, which defines the configuration for the following entities: 352// 353// * For public and private DNS namespaces, one of the following combinations 354// of DNS records in Amazon Route 53: A AAAA A and AAAA SRV CNAME 355// 356// * Optionally, a health check 357// 358// After you create the service, you can submit a RegisterInstance request, 359// and AWS Cloud Map uses the values in the configuration to create the specified 360// entities. 361// 362// For the current limit on the number of instances that you can register using 363// the same namespace and using the same service, see AWS Cloud Map Limits (http://docs.aws.amazon.com/cloud-map/latest/dg/cloud-map-limits.html) 364// in the AWS Cloud Map Developer Guide. 365// 366// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 367// with awserr.Error's Code and Message methods to get detailed information about 368// the error. 369// 370// See the AWS API reference guide for AWS Cloud Map's 371// API operation CreateService for usage and error information. 372// 373// Returned Error Types: 374// * InvalidInput 375// One or more specified values aren't valid. For example, a required value 376// might be missing, a numeric value might be outside the allowed range, or 377// a string value might exceed length constraints. 378// 379// * ResourceLimitExceeded 380// The resource can't be created because you've reached the limit on the number 381// of resources. 382// 383// * NamespaceNotFound 384// No namespace exists with the specified ID. 385// 386// * ServiceAlreadyExists 387// The service can't be created because a service with the same name already 388// exists. 389// 390// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/CreateService 391func (c *ServiceDiscovery) CreateService(input *CreateServiceInput) (*CreateServiceOutput, error) { 392 req, out := c.CreateServiceRequest(input) 393 return out, req.Send() 394} 395 396// CreateServiceWithContext is the same as CreateService with the addition of 397// the ability to pass a context and additional request options. 398// 399// See CreateService for details on how to use this API operation. 400// 401// The context must be non-nil and will be used for request cancellation. If 402// the context is nil a panic will occur. In the future the SDK may create 403// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 404// for more information on using Contexts. 405func (c *ServiceDiscovery) CreateServiceWithContext(ctx aws.Context, input *CreateServiceInput, opts ...request.Option) (*CreateServiceOutput, error) { 406 req, out := c.CreateServiceRequest(input) 407 req.SetContext(ctx) 408 req.ApplyOptions(opts...) 409 return out, req.Send() 410} 411 412const opDeleteNamespace = "DeleteNamespace" 413 414// DeleteNamespaceRequest generates a "aws/request.Request" representing the 415// client's request for the DeleteNamespace operation. The "output" return 416// value will be populated with the request's response once the request completes 417// successfully. 418// 419// Use "Send" method on the returned Request to send the API call to the service. 420// the "output" return value is not valid until after Send returns without error. 421// 422// See DeleteNamespace for more information on using the DeleteNamespace 423// API call, and error handling. 424// 425// This method is useful when you want to inject custom logic or configuration 426// into the SDK's request lifecycle. Such as custom headers, or retry logic. 427// 428// 429// // Example sending a request using the DeleteNamespaceRequest method. 430// req, resp := client.DeleteNamespaceRequest(params) 431// 432// err := req.Send() 433// if err == nil { // resp is now filled 434// fmt.Println(resp) 435// } 436// 437// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/DeleteNamespace 438func (c *ServiceDiscovery) DeleteNamespaceRequest(input *DeleteNamespaceInput) (req *request.Request, output *DeleteNamespaceOutput) { 439 op := &request.Operation{ 440 Name: opDeleteNamespace, 441 HTTPMethod: "POST", 442 HTTPPath: "/", 443 } 444 445 if input == nil { 446 input = &DeleteNamespaceInput{} 447 } 448 449 output = &DeleteNamespaceOutput{} 450 req = c.newRequest(op, input, output) 451 return 452} 453 454// DeleteNamespace API operation for AWS Cloud Map. 455// 456// Deletes a namespace from the current account. If the namespace still contains 457// one or more services, the request fails. 458// 459// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 460// with awserr.Error's Code and Message methods to get detailed information about 461// the error. 462// 463// See the AWS API reference guide for AWS Cloud Map's 464// API operation DeleteNamespace for usage and error information. 465// 466// Returned Error Types: 467// * InvalidInput 468// One or more specified values aren't valid. For example, a required value 469// might be missing, a numeric value might be outside the allowed range, or 470// a string value might exceed length constraints. 471// 472// * NamespaceNotFound 473// No namespace exists with the specified ID. 474// 475// * ResourceInUse 476// The specified resource can't be deleted because it contains other resources. 477// For example, you can't delete a service that contains any instances. 478// 479// * DuplicateRequest 480// The operation is already in progress. 481// 482// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/DeleteNamespace 483func (c *ServiceDiscovery) DeleteNamespace(input *DeleteNamespaceInput) (*DeleteNamespaceOutput, error) { 484 req, out := c.DeleteNamespaceRequest(input) 485 return out, req.Send() 486} 487 488// DeleteNamespaceWithContext is the same as DeleteNamespace with the addition of 489// the ability to pass a context and additional request options. 490// 491// See DeleteNamespace for details on how to use this API operation. 492// 493// The context must be non-nil and will be used for request cancellation. If 494// the context is nil a panic will occur. In the future the SDK may create 495// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 496// for more information on using Contexts. 497func (c *ServiceDiscovery) DeleteNamespaceWithContext(ctx aws.Context, input *DeleteNamespaceInput, opts ...request.Option) (*DeleteNamespaceOutput, error) { 498 req, out := c.DeleteNamespaceRequest(input) 499 req.SetContext(ctx) 500 req.ApplyOptions(opts...) 501 return out, req.Send() 502} 503 504const opDeleteService = "DeleteService" 505 506// DeleteServiceRequest generates a "aws/request.Request" representing the 507// client's request for the DeleteService operation. The "output" return 508// value will be populated with the request's response once the request completes 509// successfully. 510// 511// Use "Send" method on the returned Request to send the API call to the service. 512// the "output" return value is not valid until after Send returns without error. 513// 514// See DeleteService for more information on using the DeleteService 515// API call, and error handling. 516// 517// This method is useful when you want to inject custom logic or configuration 518// into the SDK's request lifecycle. Such as custom headers, or retry logic. 519// 520// 521// // Example sending a request using the DeleteServiceRequest method. 522// req, resp := client.DeleteServiceRequest(params) 523// 524// err := req.Send() 525// if err == nil { // resp is now filled 526// fmt.Println(resp) 527// } 528// 529// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/DeleteService 530func (c *ServiceDiscovery) DeleteServiceRequest(input *DeleteServiceInput) (req *request.Request, output *DeleteServiceOutput) { 531 op := &request.Operation{ 532 Name: opDeleteService, 533 HTTPMethod: "POST", 534 HTTPPath: "/", 535 } 536 537 if input == nil { 538 input = &DeleteServiceInput{} 539 } 540 541 output = &DeleteServiceOutput{} 542 req = c.newRequest(op, input, output) 543 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 544 return 545} 546 547// DeleteService API operation for AWS Cloud Map. 548// 549// Deletes a specified service. If the service still contains one or more registered 550// instances, the request fails. 551// 552// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 553// with awserr.Error's Code and Message methods to get detailed information about 554// the error. 555// 556// See the AWS API reference guide for AWS Cloud Map's 557// API operation DeleteService for usage and error information. 558// 559// Returned Error Types: 560// * InvalidInput 561// One or more specified values aren't valid. For example, a required value 562// might be missing, a numeric value might be outside the allowed range, or 563// a string value might exceed length constraints. 564// 565// * ServiceNotFound 566// No service exists with the specified ID. 567// 568// * ResourceInUse 569// The specified resource can't be deleted because it contains other resources. 570// For example, you can't delete a service that contains any instances. 571// 572// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/DeleteService 573func (c *ServiceDiscovery) DeleteService(input *DeleteServiceInput) (*DeleteServiceOutput, error) { 574 req, out := c.DeleteServiceRequest(input) 575 return out, req.Send() 576} 577 578// DeleteServiceWithContext is the same as DeleteService with the addition of 579// the ability to pass a context and additional request options. 580// 581// See DeleteService for details on how to use this API operation. 582// 583// The context must be non-nil and will be used for request cancellation. If 584// the context is nil a panic will occur. In the future the SDK may create 585// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 586// for more information on using Contexts. 587func (c *ServiceDiscovery) DeleteServiceWithContext(ctx aws.Context, input *DeleteServiceInput, opts ...request.Option) (*DeleteServiceOutput, error) { 588 req, out := c.DeleteServiceRequest(input) 589 req.SetContext(ctx) 590 req.ApplyOptions(opts...) 591 return out, req.Send() 592} 593 594const opDeregisterInstance = "DeregisterInstance" 595 596// DeregisterInstanceRequest generates a "aws/request.Request" representing the 597// client's request for the DeregisterInstance operation. The "output" return 598// value will be populated with the request's response once the request completes 599// successfully. 600// 601// Use "Send" method on the returned Request to send the API call to the service. 602// the "output" return value is not valid until after Send returns without error. 603// 604// See DeregisterInstance for more information on using the DeregisterInstance 605// API call, and error handling. 606// 607// This method is useful when you want to inject custom logic or configuration 608// into the SDK's request lifecycle. Such as custom headers, or retry logic. 609// 610// 611// // Example sending a request using the DeregisterInstanceRequest method. 612// req, resp := client.DeregisterInstanceRequest(params) 613// 614// err := req.Send() 615// if err == nil { // resp is now filled 616// fmt.Println(resp) 617// } 618// 619// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/DeregisterInstance 620func (c *ServiceDiscovery) DeregisterInstanceRequest(input *DeregisterInstanceInput) (req *request.Request, output *DeregisterInstanceOutput) { 621 op := &request.Operation{ 622 Name: opDeregisterInstance, 623 HTTPMethod: "POST", 624 HTTPPath: "/", 625 } 626 627 if input == nil { 628 input = &DeregisterInstanceInput{} 629 } 630 631 output = &DeregisterInstanceOutput{} 632 req = c.newRequest(op, input, output) 633 return 634} 635 636// DeregisterInstance API operation for AWS Cloud Map. 637// 638// Deletes the Amazon Route 53 DNS records and health check, if any, that AWS 639// Cloud Map created for the specified instance. 640// 641// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 642// with awserr.Error's Code and Message methods to get detailed information about 643// the error. 644// 645// See the AWS API reference guide for AWS Cloud Map's 646// API operation DeregisterInstance for usage and error information. 647// 648// Returned Error Types: 649// * DuplicateRequest 650// The operation is already in progress. 651// 652// * InvalidInput 653// One or more specified values aren't valid. For example, a required value 654// might be missing, a numeric value might be outside the allowed range, or 655// a string value might exceed length constraints. 656// 657// * InstanceNotFound 658// No instance exists with the specified ID, or the instance was recently registered, 659// and information about the instance hasn't propagated yet. 660// 661// * ResourceInUse 662// The specified resource can't be deleted because it contains other resources. 663// For example, you can't delete a service that contains any instances. 664// 665// * ServiceNotFound 666// No service exists with the specified ID. 667// 668// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/DeregisterInstance 669func (c *ServiceDiscovery) DeregisterInstance(input *DeregisterInstanceInput) (*DeregisterInstanceOutput, error) { 670 req, out := c.DeregisterInstanceRequest(input) 671 return out, req.Send() 672} 673 674// DeregisterInstanceWithContext is the same as DeregisterInstance with the addition of 675// the ability to pass a context and additional request options. 676// 677// See DeregisterInstance for details on how to use this API operation. 678// 679// The context must be non-nil and will be used for request cancellation. If 680// the context is nil a panic will occur. In the future the SDK may create 681// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 682// for more information on using Contexts. 683func (c *ServiceDiscovery) DeregisterInstanceWithContext(ctx aws.Context, input *DeregisterInstanceInput, opts ...request.Option) (*DeregisterInstanceOutput, error) { 684 req, out := c.DeregisterInstanceRequest(input) 685 req.SetContext(ctx) 686 req.ApplyOptions(opts...) 687 return out, req.Send() 688} 689 690const opDiscoverInstances = "DiscoverInstances" 691 692// DiscoverInstancesRequest generates a "aws/request.Request" representing the 693// client's request for the DiscoverInstances operation. The "output" return 694// value will be populated with the request's response once the request completes 695// successfully. 696// 697// Use "Send" method on the returned Request to send the API call to the service. 698// the "output" return value is not valid until after Send returns without error. 699// 700// See DiscoverInstances for more information on using the DiscoverInstances 701// API call, and error handling. 702// 703// This method is useful when you want to inject custom logic or configuration 704// into the SDK's request lifecycle. Such as custom headers, or retry logic. 705// 706// 707// // Example sending a request using the DiscoverInstancesRequest method. 708// req, resp := client.DiscoverInstancesRequest(params) 709// 710// err := req.Send() 711// if err == nil { // resp is now filled 712// fmt.Println(resp) 713// } 714// 715// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/DiscoverInstances 716func (c *ServiceDiscovery) DiscoverInstancesRequest(input *DiscoverInstancesInput) (req *request.Request, output *DiscoverInstancesOutput) { 717 op := &request.Operation{ 718 Name: opDiscoverInstances, 719 HTTPMethod: "POST", 720 HTTPPath: "/", 721 } 722 723 if input == nil { 724 input = &DiscoverInstancesInput{} 725 } 726 727 output = &DiscoverInstancesOutput{} 728 req = c.newRequest(op, input, output) 729 req.Handlers.Build.PushBackNamed(protocol.NewHostPrefixHandler("data-", nil)) 730 req.Handlers.Build.PushBackNamed(protocol.ValidateEndpointHostHandler) 731 return 732} 733 734// DiscoverInstances API operation for AWS Cloud Map. 735// 736// Discovers registered instances for a specified namespace and service. 737// 738// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 739// with awserr.Error's Code and Message methods to get detailed information about 740// the error. 741// 742// See the AWS API reference guide for AWS Cloud Map's 743// API operation DiscoverInstances for usage and error information. 744// 745// Returned Error Types: 746// * ServiceNotFound 747// No service exists with the specified ID. 748// 749// * NamespaceNotFound 750// No namespace exists with the specified ID. 751// 752// * InvalidInput 753// One or more specified values aren't valid. For example, a required value 754// might be missing, a numeric value might be outside the allowed range, or 755// a string value might exceed length constraints. 756// 757// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/DiscoverInstances 758func (c *ServiceDiscovery) DiscoverInstances(input *DiscoverInstancesInput) (*DiscoverInstancesOutput, error) { 759 req, out := c.DiscoverInstancesRequest(input) 760 return out, req.Send() 761} 762 763// DiscoverInstancesWithContext is the same as DiscoverInstances with the addition of 764// the ability to pass a context and additional request options. 765// 766// See DiscoverInstances for details on how to use this API operation. 767// 768// The context must be non-nil and will be used for request cancellation. If 769// the context is nil a panic will occur. In the future the SDK may create 770// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 771// for more information on using Contexts. 772func (c *ServiceDiscovery) DiscoverInstancesWithContext(ctx aws.Context, input *DiscoverInstancesInput, opts ...request.Option) (*DiscoverInstancesOutput, error) { 773 req, out := c.DiscoverInstancesRequest(input) 774 req.SetContext(ctx) 775 req.ApplyOptions(opts...) 776 return out, req.Send() 777} 778 779const opGetInstance = "GetInstance" 780 781// GetInstanceRequest generates a "aws/request.Request" representing the 782// client's request for the GetInstance operation. The "output" return 783// value will be populated with the request's response once the request completes 784// successfully. 785// 786// Use "Send" method on the returned Request to send the API call to the service. 787// the "output" return value is not valid until after Send returns without error. 788// 789// See GetInstance for more information on using the GetInstance 790// API call, and error handling. 791// 792// This method is useful when you want to inject custom logic or configuration 793// into the SDK's request lifecycle. Such as custom headers, or retry logic. 794// 795// 796// // Example sending a request using the GetInstanceRequest method. 797// req, resp := client.GetInstanceRequest(params) 798// 799// err := req.Send() 800// if err == nil { // resp is now filled 801// fmt.Println(resp) 802// } 803// 804// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/GetInstance 805func (c *ServiceDiscovery) GetInstanceRequest(input *GetInstanceInput) (req *request.Request, output *GetInstanceOutput) { 806 op := &request.Operation{ 807 Name: opGetInstance, 808 HTTPMethod: "POST", 809 HTTPPath: "/", 810 } 811 812 if input == nil { 813 input = &GetInstanceInput{} 814 } 815 816 output = &GetInstanceOutput{} 817 req = c.newRequest(op, input, output) 818 return 819} 820 821// GetInstance API operation for AWS Cloud Map. 822// 823// Gets information about a specified instance. 824// 825// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 826// with awserr.Error's Code and Message methods to get detailed information about 827// the error. 828// 829// See the AWS API reference guide for AWS Cloud Map's 830// API operation GetInstance for usage and error information. 831// 832// Returned Error Types: 833// * InstanceNotFound 834// No instance exists with the specified ID, or the instance was recently registered, 835// and information about the instance hasn't propagated yet. 836// 837// * InvalidInput 838// One or more specified values aren't valid. For example, a required value 839// might be missing, a numeric value might be outside the allowed range, or 840// a string value might exceed length constraints. 841// 842// * ServiceNotFound 843// No service exists with the specified ID. 844// 845// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/GetInstance 846func (c *ServiceDiscovery) GetInstance(input *GetInstanceInput) (*GetInstanceOutput, error) { 847 req, out := c.GetInstanceRequest(input) 848 return out, req.Send() 849} 850 851// GetInstanceWithContext is the same as GetInstance with the addition of 852// the ability to pass a context and additional request options. 853// 854// See GetInstance for details on how to use this API operation. 855// 856// The context must be non-nil and will be used for request cancellation. If 857// the context is nil a panic will occur. In the future the SDK may create 858// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 859// for more information on using Contexts. 860func (c *ServiceDiscovery) GetInstanceWithContext(ctx aws.Context, input *GetInstanceInput, opts ...request.Option) (*GetInstanceOutput, error) { 861 req, out := c.GetInstanceRequest(input) 862 req.SetContext(ctx) 863 req.ApplyOptions(opts...) 864 return out, req.Send() 865} 866 867const opGetInstancesHealthStatus = "GetInstancesHealthStatus" 868 869// GetInstancesHealthStatusRequest generates a "aws/request.Request" representing the 870// client's request for the GetInstancesHealthStatus operation. The "output" return 871// value will be populated with the request's response once the request completes 872// successfully. 873// 874// Use "Send" method on the returned Request to send the API call to the service. 875// the "output" return value is not valid until after Send returns without error. 876// 877// See GetInstancesHealthStatus for more information on using the GetInstancesHealthStatus 878// API call, and error handling. 879// 880// This method is useful when you want to inject custom logic or configuration 881// into the SDK's request lifecycle. Such as custom headers, or retry logic. 882// 883// 884// // Example sending a request using the GetInstancesHealthStatusRequest method. 885// req, resp := client.GetInstancesHealthStatusRequest(params) 886// 887// err := req.Send() 888// if err == nil { // resp is now filled 889// fmt.Println(resp) 890// } 891// 892// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/GetInstancesHealthStatus 893func (c *ServiceDiscovery) GetInstancesHealthStatusRequest(input *GetInstancesHealthStatusInput) (req *request.Request, output *GetInstancesHealthStatusOutput) { 894 op := &request.Operation{ 895 Name: opGetInstancesHealthStatus, 896 HTTPMethod: "POST", 897 HTTPPath: "/", 898 Paginator: &request.Paginator{ 899 InputTokens: []string{"NextToken"}, 900 OutputTokens: []string{"NextToken"}, 901 LimitToken: "MaxResults", 902 TruncationToken: "", 903 }, 904 } 905 906 if input == nil { 907 input = &GetInstancesHealthStatusInput{} 908 } 909 910 output = &GetInstancesHealthStatusOutput{} 911 req = c.newRequest(op, input, output) 912 return 913} 914 915// GetInstancesHealthStatus API operation for AWS Cloud Map. 916// 917// Gets the current health status (Healthy, Unhealthy, or Unknown) of one or 918// more instances that are associated with a specified service. 919// 920// There is a brief delay between when you register an instance and when the 921// health status for the instance is available. 922// 923// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 924// with awserr.Error's Code and Message methods to get detailed information about 925// the error. 926// 927// See the AWS API reference guide for AWS Cloud Map's 928// API operation GetInstancesHealthStatus for usage and error information. 929// 930// Returned Error Types: 931// * InstanceNotFound 932// No instance exists with the specified ID, or the instance was recently registered, 933// and information about the instance hasn't propagated yet. 934// 935// * InvalidInput 936// One or more specified values aren't valid. For example, a required value 937// might be missing, a numeric value might be outside the allowed range, or 938// a string value might exceed length constraints. 939// 940// * ServiceNotFound 941// No service exists with the specified ID. 942// 943// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/GetInstancesHealthStatus 944func (c *ServiceDiscovery) GetInstancesHealthStatus(input *GetInstancesHealthStatusInput) (*GetInstancesHealthStatusOutput, error) { 945 req, out := c.GetInstancesHealthStatusRequest(input) 946 return out, req.Send() 947} 948 949// GetInstancesHealthStatusWithContext is the same as GetInstancesHealthStatus with the addition of 950// the ability to pass a context and additional request options. 951// 952// See GetInstancesHealthStatus for details on how to use this API operation. 953// 954// The context must be non-nil and will be used for request cancellation. If 955// the context is nil a panic will occur. In the future the SDK may create 956// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 957// for more information on using Contexts. 958func (c *ServiceDiscovery) GetInstancesHealthStatusWithContext(ctx aws.Context, input *GetInstancesHealthStatusInput, opts ...request.Option) (*GetInstancesHealthStatusOutput, error) { 959 req, out := c.GetInstancesHealthStatusRequest(input) 960 req.SetContext(ctx) 961 req.ApplyOptions(opts...) 962 return out, req.Send() 963} 964 965// GetInstancesHealthStatusPages iterates over the pages of a GetInstancesHealthStatus operation, 966// calling the "fn" function with the response data for each page. To stop 967// iterating, return false from the fn function. 968// 969// See GetInstancesHealthStatus method for more information on how to use this operation. 970// 971// Note: This operation can generate multiple requests to a service. 972// 973// // Example iterating over at most 3 pages of a GetInstancesHealthStatus operation. 974// pageNum := 0 975// err := client.GetInstancesHealthStatusPages(params, 976// func(page *servicediscovery.GetInstancesHealthStatusOutput, lastPage bool) bool { 977// pageNum++ 978// fmt.Println(page) 979// return pageNum <= 3 980// }) 981// 982func (c *ServiceDiscovery) GetInstancesHealthStatusPages(input *GetInstancesHealthStatusInput, fn func(*GetInstancesHealthStatusOutput, bool) bool) error { 983 return c.GetInstancesHealthStatusPagesWithContext(aws.BackgroundContext(), input, fn) 984} 985 986// GetInstancesHealthStatusPagesWithContext same as GetInstancesHealthStatusPages except 987// it takes a Context and allows setting request options on the pages. 988// 989// The context must be non-nil and will be used for request cancellation. If 990// the context is nil a panic will occur. In the future the SDK may create 991// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 992// for more information on using Contexts. 993func (c *ServiceDiscovery) GetInstancesHealthStatusPagesWithContext(ctx aws.Context, input *GetInstancesHealthStatusInput, fn func(*GetInstancesHealthStatusOutput, bool) bool, opts ...request.Option) error { 994 p := request.Pagination{ 995 NewRequest: func() (*request.Request, error) { 996 var inCpy *GetInstancesHealthStatusInput 997 if input != nil { 998 tmp := *input 999 inCpy = &tmp 1000 } 1001 req, _ := c.GetInstancesHealthStatusRequest(inCpy) 1002 req.SetContext(ctx) 1003 req.ApplyOptions(opts...) 1004 return req, nil 1005 }, 1006 } 1007 1008 for p.Next() { 1009 if !fn(p.Page().(*GetInstancesHealthStatusOutput), !p.HasNextPage()) { 1010 break 1011 } 1012 } 1013 1014 return p.Err() 1015} 1016 1017const opGetNamespace = "GetNamespace" 1018 1019// GetNamespaceRequest generates a "aws/request.Request" representing the 1020// client's request for the GetNamespace operation. The "output" return 1021// value will be populated with the request's response once the request completes 1022// successfully. 1023// 1024// Use "Send" method on the returned Request to send the API call to the service. 1025// the "output" return value is not valid until after Send returns without error. 1026// 1027// See GetNamespace for more information on using the GetNamespace 1028// API call, and error handling. 1029// 1030// This method is useful when you want to inject custom logic or configuration 1031// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1032// 1033// 1034// // Example sending a request using the GetNamespaceRequest method. 1035// req, resp := client.GetNamespaceRequest(params) 1036// 1037// err := req.Send() 1038// if err == nil { // resp is now filled 1039// fmt.Println(resp) 1040// } 1041// 1042// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/GetNamespace 1043func (c *ServiceDiscovery) GetNamespaceRequest(input *GetNamespaceInput) (req *request.Request, output *GetNamespaceOutput) { 1044 op := &request.Operation{ 1045 Name: opGetNamespace, 1046 HTTPMethod: "POST", 1047 HTTPPath: "/", 1048 } 1049 1050 if input == nil { 1051 input = &GetNamespaceInput{} 1052 } 1053 1054 output = &GetNamespaceOutput{} 1055 req = c.newRequest(op, input, output) 1056 return 1057} 1058 1059// GetNamespace API operation for AWS Cloud Map. 1060// 1061// Gets information about a namespace. 1062// 1063// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1064// with awserr.Error's Code and Message methods to get detailed information about 1065// the error. 1066// 1067// See the AWS API reference guide for AWS Cloud Map's 1068// API operation GetNamespace for usage and error information. 1069// 1070// Returned Error Types: 1071// * InvalidInput 1072// One or more specified values aren't valid. For example, a required value 1073// might be missing, a numeric value might be outside the allowed range, or 1074// a string value might exceed length constraints. 1075// 1076// * NamespaceNotFound 1077// No namespace exists with the specified ID. 1078// 1079// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/GetNamespace 1080func (c *ServiceDiscovery) GetNamespace(input *GetNamespaceInput) (*GetNamespaceOutput, error) { 1081 req, out := c.GetNamespaceRequest(input) 1082 return out, req.Send() 1083} 1084 1085// GetNamespaceWithContext is the same as GetNamespace with the addition of 1086// the ability to pass a context and additional request options. 1087// 1088// See GetNamespace for details on how to use this API operation. 1089// 1090// The context must be non-nil and will be used for request cancellation. If 1091// the context is nil a panic will occur. In the future the SDK may create 1092// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1093// for more information on using Contexts. 1094func (c *ServiceDiscovery) GetNamespaceWithContext(ctx aws.Context, input *GetNamespaceInput, opts ...request.Option) (*GetNamespaceOutput, error) { 1095 req, out := c.GetNamespaceRequest(input) 1096 req.SetContext(ctx) 1097 req.ApplyOptions(opts...) 1098 return out, req.Send() 1099} 1100 1101const opGetOperation = "GetOperation" 1102 1103// GetOperationRequest generates a "aws/request.Request" representing the 1104// client's request for the GetOperation operation. The "output" return 1105// value will be populated with the request's response once the request completes 1106// successfully. 1107// 1108// Use "Send" method on the returned Request to send the API call to the service. 1109// the "output" return value is not valid until after Send returns without error. 1110// 1111// See GetOperation for more information on using the GetOperation 1112// API call, and error handling. 1113// 1114// This method is useful when you want to inject custom logic or configuration 1115// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1116// 1117// 1118// // Example sending a request using the GetOperationRequest method. 1119// req, resp := client.GetOperationRequest(params) 1120// 1121// err := req.Send() 1122// if err == nil { // resp is now filled 1123// fmt.Println(resp) 1124// } 1125// 1126// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/GetOperation 1127func (c *ServiceDiscovery) GetOperationRequest(input *GetOperationInput) (req *request.Request, output *GetOperationOutput) { 1128 op := &request.Operation{ 1129 Name: opGetOperation, 1130 HTTPMethod: "POST", 1131 HTTPPath: "/", 1132 } 1133 1134 if input == nil { 1135 input = &GetOperationInput{} 1136 } 1137 1138 output = &GetOperationOutput{} 1139 req = c.newRequest(op, input, output) 1140 return 1141} 1142 1143// GetOperation API operation for AWS Cloud Map. 1144// 1145// Gets information about any operation that returns an operation ID in the 1146// response, such as a CreateService request. 1147// 1148// To get a list of operations that match specified criteria, see ListOperations. 1149// 1150// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1151// with awserr.Error's Code and Message methods to get detailed information about 1152// the error. 1153// 1154// See the AWS API reference guide for AWS Cloud Map's 1155// API operation GetOperation for usage and error information. 1156// 1157// Returned Error Types: 1158// * InvalidInput 1159// One or more specified values aren't valid. For example, a required value 1160// might be missing, a numeric value might be outside the allowed range, or 1161// a string value might exceed length constraints. 1162// 1163// * OperationNotFound 1164// No operation exists with the specified ID. 1165// 1166// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/GetOperation 1167func (c *ServiceDiscovery) GetOperation(input *GetOperationInput) (*GetOperationOutput, error) { 1168 req, out := c.GetOperationRequest(input) 1169 return out, req.Send() 1170} 1171 1172// GetOperationWithContext is the same as GetOperation with the addition of 1173// the ability to pass a context and additional request options. 1174// 1175// See GetOperation for details on how to use this API operation. 1176// 1177// The context must be non-nil and will be used for request cancellation. If 1178// the context is nil a panic will occur. In the future the SDK may create 1179// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1180// for more information on using Contexts. 1181func (c *ServiceDiscovery) GetOperationWithContext(ctx aws.Context, input *GetOperationInput, opts ...request.Option) (*GetOperationOutput, error) { 1182 req, out := c.GetOperationRequest(input) 1183 req.SetContext(ctx) 1184 req.ApplyOptions(opts...) 1185 return out, req.Send() 1186} 1187 1188const opGetService = "GetService" 1189 1190// GetServiceRequest generates a "aws/request.Request" representing the 1191// client's request for the GetService operation. The "output" return 1192// value will be populated with the request's response once the request completes 1193// successfully. 1194// 1195// Use "Send" method on the returned Request to send the API call to the service. 1196// the "output" return value is not valid until after Send returns without error. 1197// 1198// See GetService for more information on using the GetService 1199// API call, and error handling. 1200// 1201// This method is useful when you want to inject custom logic or configuration 1202// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1203// 1204// 1205// // Example sending a request using the GetServiceRequest method. 1206// req, resp := client.GetServiceRequest(params) 1207// 1208// err := req.Send() 1209// if err == nil { // resp is now filled 1210// fmt.Println(resp) 1211// } 1212// 1213// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/GetService 1214func (c *ServiceDiscovery) GetServiceRequest(input *GetServiceInput) (req *request.Request, output *GetServiceOutput) { 1215 op := &request.Operation{ 1216 Name: opGetService, 1217 HTTPMethod: "POST", 1218 HTTPPath: "/", 1219 } 1220 1221 if input == nil { 1222 input = &GetServiceInput{} 1223 } 1224 1225 output = &GetServiceOutput{} 1226 req = c.newRequest(op, input, output) 1227 return 1228} 1229 1230// GetService API operation for AWS Cloud Map. 1231// 1232// Gets the settings for a specified service. 1233// 1234// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1235// with awserr.Error's Code and Message methods to get detailed information about 1236// the error. 1237// 1238// See the AWS API reference guide for AWS Cloud Map's 1239// API operation GetService for usage and error information. 1240// 1241// Returned Error Types: 1242// * InvalidInput 1243// One or more specified values aren't valid. For example, a required value 1244// might be missing, a numeric value might be outside the allowed range, or 1245// a string value might exceed length constraints. 1246// 1247// * ServiceNotFound 1248// No service exists with the specified ID. 1249// 1250// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/GetService 1251func (c *ServiceDiscovery) GetService(input *GetServiceInput) (*GetServiceOutput, error) { 1252 req, out := c.GetServiceRequest(input) 1253 return out, req.Send() 1254} 1255 1256// GetServiceWithContext is the same as GetService with the addition of 1257// the ability to pass a context and additional request options. 1258// 1259// See GetService for details on how to use this API operation. 1260// 1261// The context must be non-nil and will be used for request cancellation. If 1262// the context is nil a panic will occur. In the future the SDK may create 1263// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1264// for more information on using Contexts. 1265func (c *ServiceDiscovery) GetServiceWithContext(ctx aws.Context, input *GetServiceInput, opts ...request.Option) (*GetServiceOutput, error) { 1266 req, out := c.GetServiceRequest(input) 1267 req.SetContext(ctx) 1268 req.ApplyOptions(opts...) 1269 return out, req.Send() 1270} 1271 1272const opListInstances = "ListInstances" 1273 1274// ListInstancesRequest generates a "aws/request.Request" representing the 1275// client's request for the ListInstances operation. The "output" return 1276// value will be populated with the request's response once the request completes 1277// successfully. 1278// 1279// Use "Send" method on the returned Request to send the API call to the service. 1280// the "output" return value is not valid until after Send returns without error. 1281// 1282// See ListInstances for more information on using the ListInstances 1283// API call, and error handling. 1284// 1285// This method is useful when you want to inject custom logic or configuration 1286// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1287// 1288// 1289// // Example sending a request using the ListInstancesRequest method. 1290// req, resp := client.ListInstancesRequest(params) 1291// 1292// err := req.Send() 1293// if err == nil { // resp is now filled 1294// fmt.Println(resp) 1295// } 1296// 1297// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/ListInstances 1298func (c *ServiceDiscovery) ListInstancesRequest(input *ListInstancesInput) (req *request.Request, output *ListInstancesOutput) { 1299 op := &request.Operation{ 1300 Name: opListInstances, 1301 HTTPMethod: "POST", 1302 HTTPPath: "/", 1303 Paginator: &request.Paginator{ 1304 InputTokens: []string{"NextToken"}, 1305 OutputTokens: []string{"NextToken"}, 1306 LimitToken: "MaxResults", 1307 TruncationToken: "", 1308 }, 1309 } 1310 1311 if input == nil { 1312 input = &ListInstancesInput{} 1313 } 1314 1315 output = &ListInstancesOutput{} 1316 req = c.newRequest(op, input, output) 1317 return 1318} 1319 1320// ListInstances API operation for AWS Cloud Map. 1321// 1322// Lists summary information about the instances that you registered by using 1323// a specified service. 1324// 1325// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1326// with awserr.Error's Code and Message methods to get detailed information about 1327// the error. 1328// 1329// See the AWS API reference guide for AWS Cloud Map's 1330// API operation ListInstances for usage and error information. 1331// 1332// Returned Error Types: 1333// * ServiceNotFound 1334// No service exists with the specified ID. 1335// 1336// * InvalidInput 1337// One or more specified values aren't valid. For example, a required value 1338// might be missing, a numeric value might be outside the allowed range, or 1339// a string value might exceed length constraints. 1340// 1341// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/ListInstances 1342func (c *ServiceDiscovery) ListInstances(input *ListInstancesInput) (*ListInstancesOutput, error) { 1343 req, out := c.ListInstancesRequest(input) 1344 return out, req.Send() 1345} 1346 1347// ListInstancesWithContext is the same as ListInstances with the addition of 1348// the ability to pass a context and additional request options. 1349// 1350// See ListInstances for details on how to use this API operation. 1351// 1352// The context must be non-nil and will be used for request cancellation. If 1353// the context is nil a panic will occur. In the future the SDK may create 1354// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1355// for more information on using Contexts. 1356func (c *ServiceDiscovery) ListInstancesWithContext(ctx aws.Context, input *ListInstancesInput, opts ...request.Option) (*ListInstancesOutput, error) { 1357 req, out := c.ListInstancesRequest(input) 1358 req.SetContext(ctx) 1359 req.ApplyOptions(opts...) 1360 return out, req.Send() 1361} 1362 1363// ListInstancesPages iterates over the pages of a ListInstances operation, 1364// calling the "fn" function with the response data for each page. To stop 1365// iterating, return false from the fn function. 1366// 1367// See ListInstances method for more information on how to use this operation. 1368// 1369// Note: This operation can generate multiple requests to a service. 1370// 1371// // Example iterating over at most 3 pages of a ListInstances operation. 1372// pageNum := 0 1373// err := client.ListInstancesPages(params, 1374// func(page *servicediscovery.ListInstancesOutput, lastPage bool) bool { 1375// pageNum++ 1376// fmt.Println(page) 1377// return pageNum <= 3 1378// }) 1379// 1380func (c *ServiceDiscovery) ListInstancesPages(input *ListInstancesInput, fn func(*ListInstancesOutput, bool) bool) error { 1381 return c.ListInstancesPagesWithContext(aws.BackgroundContext(), input, fn) 1382} 1383 1384// ListInstancesPagesWithContext same as ListInstancesPages except 1385// it takes a Context and allows setting request options on the pages. 1386// 1387// The context must be non-nil and will be used for request cancellation. If 1388// the context is nil a panic will occur. In the future the SDK may create 1389// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1390// for more information on using Contexts. 1391func (c *ServiceDiscovery) ListInstancesPagesWithContext(ctx aws.Context, input *ListInstancesInput, fn func(*ListInstancesOutput, bool) bool, opts ...request.Option) error { 1392 p := request.Pagination{ 1393 NewRequest: func() (*request.Request, error) { 1394 var inCpy *ListInstancesInput 1395 if input != nil { 1396 tmp := *input 1397 inCpy = &tmp 1398 } 1399 req, _ := c.ListInstancesRequest(inCpy) 1400 req.SetContext(ctx) 1401 req.ApplyOptions(opts...) 1402 return req, nil 1403 }, 1404 } 1405 1406 for p.Next() { 1407 if !fn(p.Page().(*ListInstancesOutput), !p.HasNextPage()) { 1408 break 1409 } 1410 } 1411 1412 return p.Err() 1413} 1414 1415const opListNamespaces = "ListNamespaces" 1416 1417// ListNamespacesRequest generates a "aws/request.Request" representing the 1418// client's request for the ListNamespaces operation. The "output" return 1419// value will be populated with the request's response once the request completes 1420// successfully. 1421// 1422// Use "Send" method on the returned Request to send the API call to the service. 1423// the "output" return value is not valid until after Send returns without error. 1424// 1425// See ListNamespaces for more information on using the ListNamespaces 1426// API call, and error handling. 1427// 1428// This method is useful when you want to inject custom logic or configuration 1429// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1430// 1431// 1432// // Example sending a request using the ListNamespacesRequest method. 1433// req, resp := client.ListNamespacesRequest(params) 1434// 1435// err := req.Send() 1436// if err == nil { // resp is now filled 1437// fmt.Println(resp) 1438// } 1439// 1440// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/ListNamespaces 1441func (c *ServiceDiscovery) ListNamespacesRequest(input *ListNamespacesInput) (req *request.Request, output *ListNamespacesOutput) { 1442 op := &request.Operation{ 1443 Name: opListNamespaces, 1444 HTTPMethod: "POST", 1445 HTTPPath: "/", 1446 Paginator: &request.Paginator{ 1447 InputTokens: []string{"NextToken"}, 1448 OutputTokens: []string{"NextToken"}, 1449 LimitToken: "MaxResults", 1450 TruncationToken: "", 1451 }, 1452 } 1453 1454 if input == nil { 1455 input = &ListNamespacesInput{} 1456 } 1457 1458 output = &ListNamespacesOutput{} 1459 req = c.newRequest(op, input, output) 1460 return 1461} 1462 1463// ListNamespaces API operation for AWS Cloud Map. 1464// 1465// Lists summary information about the namespaces that were created by the current 1466// AWS account. 1467// 1468// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1469// with awserr.Error's Code and Message methods to get detailed information about 1470// the error. 1471// 1472// See the AWS API reference guide for AWS Cloud Map's 1473// API operation ListNamespaces for usage and error information. 1474// 1475// Returned Error Types: 1476// * InvalidInput 1477// One or more specified values aren't valid. For example, a required value 1478// might be missing, a numeric value might be outside the allowed range, or 1479// a string value might exceed length constraints. 1480// 1481// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/ListNamespaces 1482func (c *ServiceDiscovery) ListNamespaces(input *ListNamespacesInput) (*ListNamespacesOutput, error) { 1483 req, out := c.ListNamespacesRequest(input) 1484 return out, req.Send() 1485} 1486 1487// ListNamespacesWithContext is the same as ListNamespaces with the addition of 1488// the ability to pass a context and additional request options. 1489// 1490// See ListNamespaces for details on how to use this API operation. 1491// 1492// The context must be non-nil and will be used for request cancellation. If 1493// the context is nil a panic will occur. In the future the SDK may create 1494// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1495// for more information on using Contexts. 1496func (c *ServiceDiscovery) ListNamespacesWithContext(ctx aws.Context, input *ListNamespacesInput, opts ...request.Option) (*ListNamespacesOutput, error) { 1497 req, out := c.ListNamespacesRequest(input) 1498 req.SetContext(ctx) 1499 req.ApplyOptions(opts...) 1500 return out, req.Send() 1501} 1502 1503// ListNamespacesPages iterates over the pages of a ListNamespaces operation, 1504// calling the "fn" function with the response data for each page. To stop 1505// iterating, return false from the fn function. 1506// 1507// See ListNamespaces method for more information on how to use this operation. 1508// 1509// Note: This operation can generate multiple requests to a service. 1510// 1511// // Example iterating over at most 3 pages of a ListNamespaces operation. 1512// pageNum := 0 1513// err := client.ListNamespacesPages(params, 1514// func(page *servicediscovery.ListNamespacesOutput, lastPage bool) bool { 1515// pageNum++ 1516// fmt.Println(page) 1517// return pageNum <= 3 1518// }) 1519// 1520func (c *ServiceDiscovery) ListNamespacesPages(input *ListNamespacesInput, fn func(*ListNamespacesOutput, bool) bool) error { 1521 return c.ListNamespacesPagesWithContext(aws.BackgroundContext(), input, fn) 1522} 1523 1524// ListNamespacesPagesWithContext same as ListNamespacesPages except 1525// it takes a Context and allows setting request options on the pages. 1526// 1527// The context must be non-nil and will be used for request cancellation. If 1528// the context is nil a panic will occur. In the future the SDK may create 1529// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1530// for more information on using Contexts. 1531func (c *ServiceDiscovery) ListNamespacesPagesWithContext(ctx aws.Context, input *ListNamespacesInput, fn func(*ListNamespacesOutput, bool) bool, opts ...request.Option) error { 1532 p := request.Pagination{ 1533 NewRequest: func() (*request.Request, error) { 1534 var inCpy *ListNamespacesInput 1535 if input != nil { 1536 tmp := *input 1537 inCpy = &tmp 1538 } 1539 req, _ := c.ListNamespacesRequest(inCpy) 1540 req.SetContext(ctx) 1541 req.ApplyOptions(opts...) 1542 return req, nil 1543 }, 1544 } 1545 1546 for p.Next() { 1547 if !fn(p.Page().(*ListNamespacesOutput), !p.HasNextPage()) { 1548 break 1549 } 1550 } 1551 1552 return p.Err() 1553} 1554 1555const opListOperations = "ListOperations" 1556 1557// ListOperationsRequest generates a "aws/request.Request" representing the 1558// client's request for the ListOperations operation. The "output" return 1559// value will be populated with the request's response once the request completes 1560// successfully. 1561// 1562// Use "Send" method on the returned Request to send the API call to the service. 1563// the "output" return value is not valid until after Send returns without error. 1564// 1565// See ListOperations for more information on using the ListOperations 1566// API call, and error handling. 1567// 1568// This method is useful when you want to inject custom logic or configuration 1569// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1570// 1571// 1572// // Example sending a request using the ListOperationsRequest method. 1573// req, resp := client.ListOperationsRequest(params) 1574// 1575// err := req.Send() 1576// if err == nil { // resp is now filled 1577// fmt.Println(resp) 1578// } 1579// 1580// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/ListOperations 1581func (c *ServiceDiscovery) ListOperationsRequest(input *ListOperationsInput) (req *request.Request, output *ListOperationsOutput) { 1582 op := &request.Operation{ 1583 Name: opListOperations, 1584 HTTPMethod: "POST", 1585 HTTPPath: "/", 1586 Paginator: &request.Paginator{ 1587 InputTokens: []string{"NextToken"}, 1588 OutputTokens: []string{"NextToken"}, 1589 LimitToken: "MaxResults", 1590 TruncationToken: "", 1591 }, 1592 } 1593 1594 if input == nil { 1595 input = &ListOperationsInput{} 1596 } 1597 1598 output = &ListOperationsOutput{} 1599 req = c.newRequest(op, input, output) 1600 return 1601} 1602 1603// ListOperations API operation for AWS Cloud Map. 1604// 1605// Lists operations that match the criteria that you specify. 1606// 1607// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1608// with awserr.Error's Code and Message methods to get detailed information about 1609// the error. 1610// 1611// See the AWS API reference guide for AWS Cloud Map's 1612// API operation ListOperations for usage and error information. 1613// 1614// Returned Error Types: 1615// * InvalidInput 1616// One or more specified values aren't valid. For example, a required value 1617// might be missing, a numeric value might be outside the allowed range, or 1618// a string value might exceed length constraints. 1619// 1620// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/ListOperations 1621func (c *ServiceDiscovery) ListOperations(input *ListOperationsInput) (*ListOperationsOutput, error) { 1622 req, out := c.ListOperationsRequest(input) 1623 return out, req.Send() 1624} 1625 1626// ListOperationsWithContext is the same as ListOperations with the addition of 1627// the ability to pass a context and additional request options. 1628// 1629// See ListOperations for details on how to use this API operation. 1630// 1631// The context must be non-nil and will be used for request cancellation. If 1632// the context is nil a panic will occur. In the future the SDK may create 1633// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1634// for more information on using Contexts. 1635func (c *ServiceDiscovery) ListOperationsWithContext(ctx aws.Context, input *ListOperationsInput, opts ...request.Option) (*ListOperationsOutput, error) { 1636 req, out := c.ListOperationsRequest(input) 1637 req.SetContext(ctx) 1638 req.ApplyOptions(opts...) 1639 return out, req.Send() 1640} 1641 1642// ListOperationsPages iterates over the pages of a ListOperations operation, 1643// calling the "fn" function with the response data for each page. To stop 1644// iterating, return false from the fn function. 1645// 1646// See ListOperations method for more information on how to use this operation. 1647// 1648// Note: This operation can generate multiple requests to a service. 1649// 1650// // Example iterating over at most 3 pages of a ListOperations operation. 1651// pageNum := 0 1652// err := client.ListOperationsPages(params, 1653// func(page *servicediscovery.ListOperationsOutput, lastPage bool) bool { 1654// pageNum++ 1655// fmt.Println(page) 1656// return pageNum <= 3 1657// }) 1658// 1659func (c *ServiceDiscovery) ListOperationsPages(input *ListOperationsInput, fn func(*ListOperationsOutput, bool) bool) error { 1660 return c.ListOperationsPagesWithContext(aws.BackgroundContext(), input, fn) 1661} 1662 1663// ListOperationsPagesWithContext same as ListOperationsPages except 1664// it takes a Context and allows setting request options on the pages. 1665// 1666// The context must be non-nil and will be used for request cancellation. If 1667// the context is nil a panic will occur. In the future the SDK may create 1668// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1669// for more information on using Contexts. 1670func (c *ServiceDiscovery) ListOperationsPagesWithContext(ctx aws.Context, input *ListOperationsInput, fn func(*ListOperationsOutput, bool) bool, opts ...request.Option) error { 1671 p := request.Pagination{ 1672 NewRequest: func() (*request.Request, error) { 1673 var inCpy *ListOperationsInput 1674 if input != nil { 1675 tmp := *input 1676 inCpy = &tmp 1677 } 1678 req, _ := c.ListOperationsRequest(inCpy) 1679 req.SetContext(ctx) 1680 req.ApplyOptions(opts...) 1681 return req, nil 1682 }, 1683 } 1684 1685 for p.Next() { 1686 if !fn(p.Page().(*ListOperationsOutput), !p.HasNextPage()) { 1687 break 1688 } 1689 } 1690 1691 return p.Err() 1692} 1693 1694const opListServices = "ListServices" 1695 1696// ListServicesRequest generates a "aws/request.Request" representing the 1697// client's request for the ListServices operation. The "output" return 1698// value will be populated with the request's response once the request completes 1699// successfully. 1700// 1701// Use "Send" method on the returned Request to send the API call to the service. 1702// the "output" return value is not valid until after Send returns without error. 1703// 1704// See ListServices for more information on using the ListServices 1705// API call, and error handling. 1706// 1707// This method is useful when you want to inject custom logic or configuration 1708// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1709// 1710// 1711// // Example sending a request using the ListServicesRequest method. 1712// req, resp := client.ListServicesRequest(params) 1713// 1714// err := req.Send() 1715// if err == nil { // resp is now filled 1716// fmt.Println(resp) 1717// } 1718// 1719// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/ListServices 1720func (c *ServiceDiscovery) ListServicesRequest(input *ListServicesInput) (req *request.Request, output *ListServicesOutput) { 1721 op := &request.Operation{ 1722 Name: opListServices, 1723 HTTPMethod: "POST", 1724 HTTPPath: "/", 1725 Paginator: &request.Paginator{ 1726 InputTokens: []string{"NextToken"}, 1727 OutputTokens: []string{"NextToken"}, 1728 LimitToken: "MaxResults", 1729 TruncationToken: "", 1730 }, 1731 } 1732 1733 if input == nil { 1734 input = &ListServicesInput{} 1735 } 1736 1737 output = &ListServicesOutput{} 1738 req = c.newRequest(op, input, output) 1739 return 1740} 1741 1742// ListServices API operation for AWS Cloud Map. 1743// 1744// Lists summary information for all the services that are associated with one 1745// or more specified namespaces. 1746// 1747// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1748// with awserr.Error's Code and Message methods to get detailed information about 1749// the error. 1750// 1751// See the AWS API reference guide for AWS Cloud Map's 1752// API operation ListServices for usage and error information. 1753// 1754// Returned Error Types: 1755// * InvalidInput 1756// One or more specified values aren't valid. For example, a required value 1757// might be missing, a numeric value might be outside the allowed range, or 1758// a string value might exceed length constraints. 1759// 1760// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/ListServices 1761func (c *ServiceDiscovery) ListServices(input *ListServicesInput) (*ListServicesOutput, error) { 1762 req, out := c.ListServicesRequest(input) 1763 return out, req.Send() 1764} 1765 1766// ListServicesWithContext is the same as ListServices with the addition of 1767// the ability to pass a context and additional request options. 1768// 1769// See ListServices for details on how to use this API operation. 1770// 1771// The context must be non-nil and will be used for request cancellation. If 1772// the context is nil a panic will occur. In the future the SDK may create 1773// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1774// for more information on using Contexts. 1775func (c *ServiceDiscovery) ListServicesWithContext(ctx aws.Context, input *ListServicesInput, opts ...request.Option) (*ListServicesOutput, error) { 1776 req, out := c.ListServicesRequest(input) 1777 req.SetContext(ctx) 1778 req.ApplyOptions(opts...) 1779 return out, req.Send() 1780} 1781 1782// ListServicesPages iterates over the pages of a ListServices operation, 1783// calling the "fn" function with the response data for each page. To stop 1784// iterating, return false from the fn function. 1785// 1786// See ListServices method for more information on how to use this operation. 1787// 1788// Note: This operation can generate multiple requests to a service. 1789// 1790// // Example iterating over at most 3 pages of a ListServices operation. 1791// pageNum := 0 1792// err := client.ListServicesPages(params, 1793// func(page *servicediscovery.ListServicesOutput, lastPage bool) bool { 1794// pageNum++ 1795// fmt.Println(page) 1796// return pageNum <= 3 1797// }) 1798// 1799func (c *ServiceDiscovery) ListServicesPages(input *ListServicesInput, fn func(*ListServicesOutput, bool) bool) error { 1800 return c.ListServicesPagesWithContext(aws.BackgroundContext(), input, fn) 1801} 1802 1803// ListServicesPagesWithContext same as ListServicesPages except 1804// it takes a Context and allows setting request options on the pages. 1805// 1806// The context must be non-nil and will be used for request cancellation. If 1807// the context is nil a panic will occur. In the future the SDK may create 1808// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1809// for more information on using Contexts. 1810func (c *ServiceDiscovery) ListServicesPagesWithContext(ctx aws.Context, input *ListServicesInput, fn func(*ListServicesOutput, bool) bool, opts ...request.Option) error { 1811 p := request.Pagination{ 1812 NewRequest: func() (*request.Request, error) { 1813 var inCpy *ListServicesInput 1814 if input != nil { 1815 tmp := *input 1816 inCpy = &tmp 1817 } 1818 req, _ := c.ListServicesRequest(inCpy) 1819 req.SetContext(ctx) 1820 req.ApplyOptions(opts...) 1821 return req, nil 1822 }, 1823 } 1824 1825 for p.Next() { 1826 if !fn(p.Page().(*ListServicesOutput), !p.HasNextPage()) { 1827 break 1828 } 1829 } 1830 1831 return p.Err() 1832} 1833 1834const opRegisterInstance = "RegisterInstance" 1835 1836// RegisterInstanceRequest generates a "aws/request.Request" representing the 1837// client's request for the RegisterInstance operation. The "output" return 1838// value will be populated with the request's response once the request completes 1839// successfully. 1840// 1841// Use "Send" method on the returned Request to send the API call to the service. 1842// the "output" return value is not valid until after Send returns without error. 1843// 1844// See RegisterInstance for more information on using the RegisterInstance 1845// API call, and error handling. 1846// 1847// This method is useful when you want to inject custom logic or configuration 1848// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1849// 1850// 1851// // Example sending a request using the RegisterInstanceRequest method. 1852// req, resp := client.RegisterInstanceRequest(params) 1853// 1854// err := req.Send() 1855// if err == nil { // resp is now filled 1856// fmt.Println(resp) 1857// } 1858// 1859// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/RegisterInstance 1860func (c *ServiceDiscovery) RegisterInstanceRequest(input *RegisterInstanceInput) (req *request.Request, output *RegisterInstanceOutput) { 1861 op := &request.Operation{ 1862 Name: opRegisterInstance, 1863 HTTPMethod: "POST", 1864 HTTPPath: "/", 1865 } 1866 1867 if input == nil { 1868 input = &RegisterInstanceInput{} 1869 } 1870 1871 output = &RegisterInstanceOutput{} 1872 req = c.newRequest(op, input, output) 1873 return 1874} 1875 1876// RegisterInstance API operation for AWS Cloud Map. 1877// 1878// Creates or updates one or more records and, optionally, creates a health 1879// check based on the settings in a specified service. When you submit a RegisterInstance 1880// request, the following occurs: 1881// 1882// * For each DNS record that you define in the service that is specified 1883// by ServiceId, a record is created or updated in the hosted zone that is 1884// associated with the corresponding namespace. 1885// 1886// * If the service includes HealthCheckConfig, a health check is created 1887// based on the settings in the health check configuration. 1888// 1889// * The health check, if any, is associated with each of the new or updated 1890// records. 1891// 1892// One RegisterInstance request must complete before you can submit another 1893// request and specify the same service ID and instance ID. 1894// 1895// For more information, see CreateService. 1896// 1897// When AWS Cloud Map receives a DNS query for the specified DNS name, it returns 1898// the applicable value: 1899// 1900// * If the health check is healthy: returns all the records 1901// 1902// * If the health check is unhealthy: returns the applicable value for the 1903// last healthy instance 1904// 1905// * If you didn't specify a health check configuration: returns all the 1906// records 1907// 1908// For the current limit on the number of instances that you can register using 1909// the same namespace and using the same service, see AWS Cloud Map Limits (http://docs.aws.amazon.com/cloud-map/latest/dg/cloud-map-limits.html) 1910// in the AWS Cloud Map Developer Guide. 1911// 1912// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1913// with awserr.Error's Code and Message methods to get detailed information about 1914// the error. 1915// 1916// See the AWS API reference guide for AWS Cloud Map's 1917// API operation RegisterInstance for usage and error information. 1918// 1919// Returned Error Types: 1920// * DuplicateRequest 1921// The operation is already in progress. 1922// 1923// * InvalidInput 1924// One or more specified values aren't valid. For example, a required value 1925// might be missing, a numeric value might be outside the allowed range, or 1926// a string value might exceed length constraints. 1927// 1928// * ResourceInUse 1929// The specified resource can't be deleted because it contains other resources. 1930// For example, you can't delete a service that contains any instances. 1931// 1932// * ResourceLimitExceeded 1933// The resource can't be created because you've reached the limit on the number 1934// of resources. 1935// 1936// * ServiceNotFound 1937// No service exists with the specified ID. 1938// 1939// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/RegisterInstance 1940func (c *ServiceDiscovery) RegisterInstance(input *RegisterInstanceInput) (*RegisterInstanceOutput, error) { 1941 req, out := c.RegisterInstanceRequest(input) 1942 return out, req.Send() 1943} 1944 1945// RegisterInstanceWithContext is the same as RegisterInstance with the addition of 1946// the ability to pass a context and additional request options. 1947// 1948// See RegisterInstance for details on how to use this API operation. 1949// 1950// The context must be non-nil and will be used for request cancellation. If 1951// the context is nil a panic will occur. In the future the SDK may create 1952// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1953// for more information on using Contexts. 1954func (c *ServiceDiscovery) RegisterInstanceWithContext(ctx aws.Context, input *RegisterInstanceInput, opts ...request.Option) (*RegisterInstanceOutput, error) { 1955 req, out := c.RegisterInstanceRequest(input) 1956 req.SetContext(ctx) 1957 req.ApplyOptions(opts...) 1958 return out, req.Send() 1959} 1960 1961const opUpdateInstanceCustomHealthStatus = "UpdateInstanceCustomHealthStatus" 1962 1963// UpdateInstanceCustomHealthStatusRequest generates a "aws/request.Request" representing the 1964// client's request for the UpdateInstanceCustomHealthStatus operation. The "output" return 1965// value will be populated with the request's response once the request completes 1966// successfully. 1967// 1968// Use "Send" method on the returned Request to send the API call to the service. 1969// the "output" return value is not valid until after Send returns without error. 1970// 1971// See UpdateInstanceCustomHealthStatus for more information on using the UpdateInstanceCustomHealthStatus 1972// API call, and error handling. 1973// 1974// This method is useful when you want to inject custom logic or configuration 1975// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1976// 1977// 1978// // Example sending a request using the UpdateInstanceCustomHealthStatusRequest method. 1979// req, resp := client.UpdateInstanceCustomHealthStatusRequest(params) 1980// 1981// err := req.Send() 1982// if err == nil { // resp is now filled 1983// fmt.Println(resp) 1984// } 1985// 1986// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/UpdateInstanceCustomHealthStatus 1987func (c *ServiceDiscovery) UpdateInstanceCustomHealthStatusRequest(input *UpdateInstanceCustomHealthStatusInput) (req *request.Request, output *UpdateInstanceCustomHealthStatusOutput) { 1988 op := &request.Operation{ 1989 Name: opUpdateInstanceCustomHealthStatus, 1990 HTTPMethod: "POST", 1991 HTTPPath: "/", 1992 } 1993 1994 if input == nil { 1995 input = &UpdateInstanceCustomHealthStatusInput{} 1996 } 1997 1998 output = &UpdateInstanceCustomHealthStatusOutput{} 1999 req = c.newRequest(op, input, output) 2000 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 2001 return 2002} 2003 2004// UpdateInstanceCustomHealthStatus API operation for AWS Cloud Map. 2005// 2006// Submits a request to change the health status of a custom health check to 2007// healthy or unhealthy. 2008// 2009// You can use UpdateInstanceCustomHealthStatus to change the status only for 2010// custom health checks, which you define using HealthCheckCustomConfig when 2011// you create a service. You can't use it to change the status for Route 53 2012// health checks, which you define using HealthCheckConfig. 2013// 2014// For more information, see HealthCheckCustomConfig. 2015// 2016// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2017// with awserr.Error's Code and Message methods to get detailed information about 2018// the error. 2019// 2020// See the AWS API reference guide for AWS Cloud Map's 2021// API operation UpdateInstanceCustomHealthStatus for usage and error information. 2022// 2023// Returned Error Types: 2024// * InstanceNotFound 2025// No instance exists with the specified ID, or the instance was recently registered, 2026// and information about the instance hasn't propagated yet. 2027// 2028// * ServiceNotFound 2029// No service exists with the specified ID. 2030// 2031// * CustomHealthNotFound 2032// The health check for the instance that is specified by ServiceId and InstanceId 2033// is not a custom health check. 2034// 2035// * InvalidInput 2036// One or more specified values aren't valid. For example, a required value 2037// might be missing, a numeric value might be outside the allowed range, or 2038// a string value might exceed length constraints. 2039// 2040// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/UpdateInstanceCustomHealthStatus 2041func (c *ServiceDiscovery) UpdateInstanceCustomHealthStatus(input *UpdateInstanceCustomHealthStatusInput) (*UpdateInstanceCustomHealthStatusOutput, error) { 2042 req, out := c.UpdateInstanceCustomHealthStatusRequest(input) 2043 return out, req.Send() 2044} 2045 2046// UpdateInstanceCustomHealthStatusWithContext is the same as UpdateInstanceCustomHealthStatus with the addition of 2047// the ability to pass a context and additional request options. 2048// 2049// See UpdateInstanceCustomHealthStatus for details on how to use this API operation. 2050// 2051// The context must be non-nil and will be used for request cancellation. If 2052// the context is nil a panic will occur. In the future the SDK may create 2053// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2054// for more information on using Contexts. 2055func (c *ServiceDiscovery) UpdateInstanceCustomHealthStatusWithContext(ctx aws.Context, input *UpdateInstanceCustomHealthStatusInput, opts ...request.Option) (*UpdateInstanceCustomHealthStatusOutput, error) { 2056 req, out := c.UpdateInstanceCustomHealthStatusRequest(input) 2057 req.SetContext(ctx) 2058 req.ApplyOptions(opts...) 2059 return out, req.Send() 2060} 2061 2062const opUpdateService = "UpdateService" 2063 2064// UpdateServiceRequest generates a "aws/request.Request" representing the 2065// client's request for the UpdateService operation. The "output" return 2066// value will be populated with the request's response once the request completes 2067// successfully. 2068// 2069// Use "Send" method on the returned Request to send the API call to the service. 2070// the "output" return value is not valid until after Send returns without error. 2071// 2072// See UpdateService for more information on using the UpdateService 2073// API call, and error handling. 2074// 2075// This method is useful when you want to inject custom logic or configuration 2076// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2077// 2078// 2079// // Example sending a request using the UpdateServiceRequest method. 2080// req, resp := client.UpdateServiceRequest(params) 2081// 2082// err := req.Send() 2083// if err == nil { // resp is now filled 2084// fmt.Println(resp) 2085// } 2086// 2087// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/UpdateService 2088func (c *ServiceDiscovery) UpdateServiceRequest(input *UpdateServiceInput) (req *request.Request, output *UpdateServiceOutput) { 2089 op := &request.Operation{ 2090 Name: opUpdateService, 2091 HTTPMethod: "POST", 2092 HTTPPath: "/", 2093 } 2094 2095 if input == nil { 2096 input = &UpdateServiceInput{} 2097 } 2098 2099 output = &UpdateServiceOutput{} 2100 req = c.newRequest(op, input, output) 2101 return 2102} 2103 2104// UpdateService API operation for AWS Cloud Map. 2105// 2106// Submits a request to perform the following operations: 2107// 2108// * Add or delete DnsRecords configurations 2109// 2110// * Update the TTL setting for existing DnsRecords configurations 2111// 2112// * Add, update, or delete HealthCheckConfig for a specified service 2113// 2114// For public and private DNS namespaces, you must specify all DnsRecords configurations 2115// (and, optionally, HealthCheckConfig) that you want to appear in the updated 2116// service. Any current configurations that don't appear in an UpdateService 2117// request are deleted. 2118// 2119// When you update the TTL setting for a service, AWS Cloud Map also updates 2120// the corresponding settings in all the records and health checks that were 2121// created by using the specified service. 2122// 2123// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2124// with awserr.Error's Code and Message methods to get detailed information about 2125// the error. 2126// 2127// See the AWS API reference guide for AWS Cloud Map's 2128// API operation UpdateService for usage and error information. 2129// 2130// Returned Error Types: 2131// * DuplicateRequest 2132// The operation is already in progress. 2133// 2134// * InvalidInput 2135// One or more specified values aren't valid. For example, a required value 2136// might be missing, a numeric value might be outside the allowed range, or 2137// a string value might exceed length constraints. 2138// 2139// * ServiceNotFound 2140// No service exists with the specified ID. 2141// 2142// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/UpdateService 2143func (c *ServiceDiscovery) UpdateService(input *UpdateServiceInput) (*UpdateServiceOutput, error) { 2144 req, out := c.UpdateServiceRequest(input) 2145 return out, req.Send() 2146} 2147 2148// UpdateServiceWithContext is the same as UpdateService with the addition of 2149// the ability to pass a context and additional request options. 2150// 2151// See UpdateService for details on how to use this API operation. 2152// 2153// The context must be non-nil and will be used for request cancellation. If 2154// the context is nil a panic will occur. In the future the SDK may create 2155// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2156// for more information on using Contexts. 2157func (c *ServiceDiscovery) UpdateServiceWithContext(ctx aws.Context, input *UpdateServiceInput, opts ...request.Option) (*UpdateServiceOutput, error) { 2158 req, out := c.UpdateServiceRequest(input) 2159 req.SetContext(ctx) 2160 req.ApplyOptions(opts...) 2161 return out, req.Send() 2162} 2163 2164type CreateHttpNamespaceInput struct { 2165 _ struct{} `type:"structure"` 2166 2167 // A unique string that identifies the request and that allows failed CreateHttpNamespace 2168 // requests to be retried without the risk of executing the operation twice. 2169 // CreatorRequestId can be any unique string, for example, a date/time stamp. 2170 CreatorRequestId *string `type:"string" idempotencyToken:"true"` 2171 2172 // A description for the namespace. 2173 Description *string `type:"string"` 2174 2175 // The name that you want to assign to this namespace. 2176 // 2177 // Name is a required field 2178 Name *string `type:"string" required:"true"` 2179} 2180 2181// String returns the string representation 2182func (s CreateHttpNamespaceInput) String() string { 2183 return awsutil.Prettify(s) 2184} 2185 2186// GoString returns the string representation 2187func (s CreateHttpNamespaceInput) GoString() string { 2188 return s.String() 2189} 2190 2191// Validate inspects the fields of the type to determine if they are valid. 2192func (s *CreateHttpNamespaceInput) Validate() error { 2193 invalidParams := request.ErrInvalidParams{Context: "CreateHttpNamespaceInput"} 2194 if s.Name == nil { 2195 invalidParams.Add(request.NewErrParamRequired("Name")) 2196 } 2197 2198 if invalidParams.Len() > 0 { 2199 return invalidParams 2200 } 2201 return nil 2202} 2203 2204// SetCreatorRequestId sets the CreatorRequestId field's value. 2205func (s *CreateHttpNamespaceInput) SetCreatorRequestId(v string) *CreateHttpNamespaceInput { 2206 s.CreatorRequestId = &v 2207 return s 2208} 2209 2210// SetDescription sets the Description field's value. 2211func (s *CreateHttpNamespaceInput) SetDescription(v string) *CreateHttpNamespaceInput { 2212 s.Description = &v 2213 return s 2214} 2215 2216// SetName sets the Name field's value. 2217func (s *CreateHttpNamespaceInput) SetName(v string) *CreateHttpNamespaceInput { 2218 s.Name = &v 2219 return s 2220} 2221 2222type CreateHttpNamespaceOutput struct { 2223 _ struct{} `type:"structure"` 2224 2225 // A value that you can use to determine whether the request completed successfully. 2226 // To get the status of the operation, see GetOperation. 2227 OperationId *string `type:"string"` 2228} 2229 2230// String returns the string representation 2231func (s CreateHttpNamespaceOutput) String() string { 2232 return awsutil.Prettify(s) 2233} 2234 2235// GoString returns the string representation 2236func (s CreateHttpNamespaceOutput) GoString() string { 2237 return s.String() 2238} 2239 2240// SetOperationId sets the OperationId field's value. 2241func (s *CreateHttpNamespaceOutput) SetOperationId(v string) *CreateHttpNamespaceOutput { 2242 s.OperationId = &v 2243 return s 2244} 2245 2246type CreatePrivateDnsNamespaceInput struct { 2247 _ struct{} `type:"structure"` 2248 2249 // A unique string that identifies the request and that allows failed CreatePrivateDnsNamespace 2250 // requests to be retried without the risk of executing the operation twice. 2251 // CreatorRequestId can be any unique string, for example, a date/time stamp. 2252 CreatorRequestId *string `type:"string" idempotencyToken:"true"` 2253 2254 // A description for the namespace. 2255 Description *string `type:"string"` 2256 2257 // The name that you want to assign to this namespace. When you create a private 2258 // DNS namespace, AWS Cloud Map automatically creates an Amazon Route 53 private 2259 // hosted zone that has the same name as the namespace. 2260 // 2261 // Name is a required field 2262 Name *string `type:"string" required:"true"` 2263 2264 // The ID of the Amazon VPC that you want to associate the namespace with. 2265 // 2266 // Vpc is a required field 2267 Vpc *string `type:"string" required:"true"` 2268} 2269 2270// String returns the string representation 2271func (s CreatePrivateDnsNamespaceInput) String() string { 2272 return awsutil.Prettify(s) 2273} 2274 2275// GoString returns the string representation 2276func (s CreatePrivateDnsNamespaceInput) GoString() string { 2277 return s.String() 2278} 2279 2280// Validate inspects the fields of the type to determine if they are valid. 2281func (s *CreatePrivateDnsNamespaceInput) Validate() error { 2282 invalidParams := request.ErrInvalidParams{Context: "CreatePrivateDnsNamespaceInput"} 2283 if s.Name == nil { 2284 invalidParams.Add(request.NewErrParamRequired("Name")) 2285 } 2286 if s.Vpc == nil { 2287 invalidParams.Add(request.NewErrParamRequired("Vpc")) 2288 } 2289 2290 if invalidParams.Len() > 0 { 2291 return invalidParams 2292 } 2293 return nil 2294} 2295 2296// SetCreatorRequestId sets the CreatorRequestId field's value. 2297func (s *CreatePrivateDnsNamespaceInput) SetCreatorRequestId(v string) *CreatePrivateDnsNamespaceInput { 2298 s.CreatorRequestId = &v 2299 return s 2300} 2301 2302// SetDescription sets the Description field's value. 2303func (s *CreatePrivateDnsNamespaceInput) SetDescription(v string) *CreatePrivateDnsNamespaceInput { 2304 s.Description = &v 2305 return s 2306} 2307 2308// SetName sets the Name field's value. 2309func (s *CreatePrivateDnsNamespaceInput) SetName(v string) *CreatePrivateDnsNamespaceInput { 2310 s.Name = &v 2311 return s 2312} 2313 2314// SetVpc sets the Vpc field's value. 2315func (s *CreatePrivateDnsNamespaceInput) SetVpc(v string) *CreatePrivateDnsNamespaceInput { 2316 s.Vpc = &v 2317 return s 2318} 2319 2320type CreatePrivateDnsNamespaceOutput struct { 2321 _ struct{} `type:"structure"` 2322 2323 // A value that you can use to determine whether the request completed successfully. 2324 // To get the status of the operation, see GetOperation. 2325 OperationId *string `type:"string"` 2326} 2327 2328// String returns the string representation 2329func (s CreatePrivateDnsNamespaceOutput) String() string { 2330 return awsutil.Prettify(s) 2331} 2332 2333// GoString returns the string representation 2334func (s CreatePrivateDnsNamespaceOutput) GoString() string { 2335 return s.String() 2336} 2337 2338// SetOperationId sets the OperationId field's value. 2339func (s *CreatePrivateDnsNamespaceOutput) SetOperationId(v string) *CreatePrivateDnsNamespaceOutput { 2340 s.OperationId = &v 2341 return s 2342} 2343 2344type CreatePublicDnsNamespaceInput struct { 2345 _ struct{} `type:"structure"` 2346 2347 // A unique string that identifies the request and that allows failed CreatePublicDnsNamespace 2348 // requests to be retried without the risk of executing the operation twice. 2349 // CreatorRequestId can be any unique string, for example, a date/time stamp. 2350 CreatorRequestId *string `type:"string" idempotencyToken:"true"` 2351 2352 // A description for the namespace. 2353 Description *string `type:"string"` 2354 2355 // The name that you want to assign to this namespace. 2356 // 2357 // Name is a required field 2358 Name *string `type:"string" required:"true"` 2359} 2360 2361// String returns the string representation 2362func (s CreatePublicDnsNamespaceInput) String() string { 2363 return awsutil.Prettify(s) 2364} 2365 2366// GoString returns the string representation 2367func (s CreatePublicDnsNamespaceInput) GoString() string { 2368 return s.String() 2369} 2370 2371// Validate inspects the fields of the type to determine if they are valid. 2372func (s *CreatePublicDnsNamespaceInput) Validate() error { 2373 invalidParams := request.ErrInvalidParams{Context: "CreatePublicDnsNamespaceInput"} 2374 if s.Name == nil { 2375 invalidParams.Add(request.NewErrParamRequired("Name")) 2376 } 2377 2378 if invalidParams.Len() > 0 { 2379 return invalidParams 2380 } 2381 return nil 2382} 2383 2384// SetCreatorRequestId sets the CreatorRequestId field's value. 2385func (s *CreatePublicDnsNamespaceInput) SetCreatorRequestId(v string) *CreatePublicDnsNamespaceInput { 2386 s.CreatorRequestId = &v 2387 return s 2388} 2389 2390// SetDescription sets the Description field's value. 2391func (s *CreatePublicDnsNamespaceInput) SetDescription(v string) *CreatePublicDnsNamespaceInput { 2392 s.Description = &v 2393 return s 2394} 2395 2396// SetName sets the Name field's value. 2397func (s *CreatePublicDnsNamespaceInput) SetName(v string) *CreatePublicDnsNamespaceInput { 2398 s.Name = &v 2399 return s 2400} 2401 2402type CreatePublicDnsNamespaceOutput struct { 2403 _ struct{} `type:"structure"` 2404 2405 // A value that you can use to determine whether the request completed successfully. 2406 // To get the status of the operation, see GetOperation. 2407 OperationId *string `type:"string"` 2408} 2409 2410// String returns the string representation 2411func (s CreatePublicDnsNamespaceOutput) String() string { 2412 return awsutil.Prettify(s) 2413} 2414 2415// GoString returns the string representation 2416func (s CreatePublicDnsNamespaceOutput) GoString() string { 2417 return s.String() 2418} 2419 2420// SetOperationId sets the OperationId field's value. 2421func (s *CreatePublicDnsNamespaceOutput) SetOperationId(v string) *CreatePublicDnsNamespaceOutput { 2422 s.OperationId = &v 2423 return s 2424} 2425 2426type CreateServiceInput struct { 2427 _ struct{} `type:"structure"` 2428 2429 // A unique string that identifies the request and that allows failed CreateService 2430 // requests to be retried without the risk of executing the operation twice. 2431 // CreatorRequestId can be any unique string, for example, a date/time stamp. 2432 CreatorRequestId *string `type:"string" idempotencyToken:"true"` 2433 2434 // A description for the service. 2435 Description *string `type:"string"` 2436 2437 // A complex type that contains information about the Amazon Route 53 records 2438 // that you want AWS Cloud Map to create when you register an instance. 2439 DnsConfig *DnsConfig `type:"structure"` 2440 2441 // Public DNS namespaces only. A complex type that contains settings for an 2442 // optional Route 53 health check. If you specify settings for a health check, 2443 // AWS Cloud Map associates the health check with all the Route 53 DNS records 2444 // that you specify in DnsConfig. 2445 // 2446 // If you specify a health check configuration, you can specify either HealthCheckCustomConfig 2447 // or HealthCheckConfig but not both. 2448 // 2449 // For information about the charges for health checks, see AWS Cloud Map Pricing 2450 // (http://aws.amazon.com/cloud-map/pricing/). 2451 HealthCheckConfig *HealthCheckConfig `type:"structure"` 2452 2453 // A complex type that contains information about an optional custom health 2454 // check. 2455 // 2456 // If you specify a health check configuration, you can specify either HealthCheckCustomConfig 2457 // or HealthCheckConfig but not both. 2458 HealthCheckCustomConfig *HealthCheckCustomConfig `type:"structure"` 2459 2460 // The name that you want to assign to the service. 2461 // 2462 // Name is a required field 2463 Name *string `type:"string" required:"true"` 2464 2465 // The ID of the namespace that you want to use to create the service. 2466 NamespaceId *string `type:"string"` 2467} 2468 2469// String returns the string representation 2470func (s CreateServiceInput) String() string { 2471 return awsutil.Prettify(s) 2472} 2473 2474// GoString returns the string representation 2475func (s CreateServiceInput) GoString() string { 2476 return s.String() 2477} 2478 2479// Validate inspects the fields of the type to determine if they are valid. 2480func (s *CreateServiceInput) Validate() error { 2481 invalidParams := request.ErrInvalidParams{Context: "CreateServiceInput"} 2482 if s.Name == nil { 2483 invalidParams.Add(request.NewErrParamRequired("Name")) 2484 } 2485 if s.DnsConfig != nil { 2486 if err := s.DnsConfig.Validate(); err != nil { 2487 invalidParams.AddNested("DnsConfig", err.(request.ErrInvalidParams)) 2488 } 2489 } 2490 if s.HealthCheckConfig != nil { 2491 if err := s.HealthCheckConfig.Validate(); err != nil { 2492 invalidParams.AddNested("HealthCheckConfig", err.(request.ErrInvalidParams)) 2493 } 2494 } 2495 if s.HealthCheckCustomConfig != nil { 2496 if err := s.HealthCheckCustomConfig.Validate(); err != nil { 2497 invalidParams.AddNested("HealthCheckCustomConfig", err.(request.ErrInvalidParams)) 2498 } 2499 } 2500 2501 if invalidParams.Len() > 0 { 2502 return invalidParams 2503 } 2504 return nil 2505} 2506 2507// SetCreatorRequestId sets the CreatorRequestId field's value. 2508func (s *CreateServiceInput) SetCreatorRequestId(v string) *CreateServiceInput { 2509 s.CreatorRequestId = &v 2510 return s 2511} 2512 2513// SetDescription sets the Description field's value. 2514func (s *CreateServiceInput) SetDescription(v string) *CreateServiceInput { 2515 s.Description = &v 2516 return s 2517} 2518 2519// SetDnsConfig sets the DnsConfig field's value. 2520func (s *CreateServiceInput) SetDnsConfig(v *DnsConfig) *CreateServiceInput { 2521 s.DnsConfig = v 2522 return s 2523} 2524 2525// SetHealthCheckConfig sets the HealthCheckConfig field's value. 2526func (s *CreateServiceInput) SetHealthCheckConfig(v *HealthCheckConfig) *CreateServiceInput { 2527 s.HealthCheckConfig = v 2528 return s 2529} 2530 2531// SetHealthCheckCustomConfig sets the HealthCheckCustomConfig field's value. 2532func (s *CreateServiceInput) SetHealthCheckCustomConfig(v *HealthCheckCustomConfig) *CreateServiceInput { 2533 s.HealthCheckCustomConfig = v 2534 return s 2535} 2536 2537// SetName sets the Name field's value. 2538func (s *CreateServiceInput) SetName(v string) *CreateServiceInput { 2539 s.Name = &v 2540 return s 2541} 2542 2543// SetNamespaceId sets the NamespaceId field's value. 2544func (s *CreateServiceInput) SetNamespaceId(v string) *CreateServiceInput { 2545 s.NamespaceId = &v 2546 return s 2547} 2548 2549type CreateServiceOutput struct { 2550 _ struct{} `type:"structure"` 2551 2552 // A complex type that contains information about the new service. 2553 Service *Service `type:"structure"` 2554} 2555 2556// String returns the string representation 2557func (s CreateServiceOutput) String() string { 2558 return awsutil.Prettify(s) 2559} 2560 2561// GoString returns the string representation 2562func (s CreateServiceOutput) GoString() string { 2563 return s.String() 2564} 2565 2566// SetService sets the Service field's value. 2567func (s *CreateServiceOutput) SetService(v *Service) *CreateServiceOutput { 2568 s.Service = v 2569 return s 2570} 2571 2572// The health check for the instance that is specified by ServiceId and InstanceId 2573// is not a custom health check. 2574type CustomHealthNotFound struct { 2575 _ struct{} `type:"structure"` 2576 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 2577 2578 Message_ *string `locationName:"Message" type:"string"` 2579} 2580 2581// String returns the string representation 2582func (s CustomHealthNotFound) String() string { 2583 return awsutil.Prettify(s) 2584} 2585 2586// GoString returns the string representation 2587func (s CustomHealthNotFound) GoString() string { 2588 return s.String() 2589} 2590 2591func newErrorCustomHealthNotFound(v protocol.ResponseMetadata) error { 2592 return &CustomHealthNotFound{ 2593 RespMetadata: v, 2594 } 2595} 2596 2597// Code returns the exception type name. 2598func (s *CustomHealthNotFound) Code() string { 2599 return "CustomHealthNotFound" 2600} 2601 2602// Message returns the exception's message. 2603func (s *CustomHealthNotFound) Message() string { 2604 if s.Message_ != nil { 2605 return *s.Message_ 2606 } 2607 return "" 2608} 2609 2610// OrigErr always returns nil, satisfies awserr.Error interface. 2611func (s *CustomHealthNotFound) OrigErr() error { 2612 return nil 2613} 2614 2615func (s *CustomHealthNotFound) Error() string { 2616 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 2617} 2618 2619// Status code returns the HTTP status code for the request's response error. 2620func (s *CustomHealthNotFound) StatusCode() int { 2621 return s.RespMetadata.StatusCode 2622} 2623 2624// RequestID returns the service's response RequestID for request. 2625func (s *CustomHealthNotFound) RequestID() string { 2626 return s.RespMetadata.RequestID 2627} 2628 2629type DeleteNamespaceInput struct { 2630 _ struct{} `type:"structure"` 2631 2632 // The ID of the namespace that you want to delete. 2633 // 2634 // Id is a required field 2635 Id *string `type:"string" required:"true"` 2636} 2637 2638// String returns the string representation 2639func (s DeleteNamespaceInput) String() string { 2640 return awsutil.Prettify(s) 2641} 2642 2643// GoString returns the string representation 2644func (s DeleteNamespaceInput) GoString() string { 2645 return s.String() 2646} 2647 2648// Validate inspects the fields of the type to determine if they are valid. 2649func (s *DeleteNamespaceInput) Validate() error { 2650 invalidParams := request.ErrInvalidParams{Context: "DeleteNamespaceInput"} 2651 if s.Id == nil { 2652 invalidParams.Add(request.NewErrParamRequired("Id")) 2653 } 2654 2655 if invalidParams.Len() > 0 { 2656 return invalidParams 2657 } 2658 return nil 2659} 2660 2661// SetId sets the Id field's value. 2662func (s *DeleteNamespaceInput) SetId(v string) *DeleteNamespaceInput { 2663 s.Id = &v 2664 return s 2665} 2666 2667type DeleteNamespaceOutput struct { 2668 _ struct{} `type:"structure"` 2669 2670 // A value that you can use to determine whether the request completed successfully. 2671 // To get the status of the operation, see GetOperation. 2672 OperationId *string `type:"string"` 2673} 2674 2675// String returns the string representation 2676func (s DeleteNamespaceOutput) String() string { 2677 return awsutil.Prettify(s) 2678} 2679 2680// GoString returns the string representation 2681func (s DeleteNamespaceOutput) GoString() string { 2682 return s.String() 2683} 2684 2685// SetOperationId sets the OperationId field's value. 2686func (s *DeleteNamespaceOutput) SetOperationId(v string) *DeleteNamespaceOutput { 2687 s.OperationId = &v 2688 return s 2689} 2690 2691type DeleteServiceInput struct { 2692 _ struct{} `type:"structure"` 2693 2694 // The ID of the service that you want to delete. 2695 // 2696 // Id is a required field 2697 Id *string `type:"string" required:"true"` 2698} 2699 2700// String returns the string representation 2701func (s DeleteServiceInput) String() string { 2702 return awsutil.Prettify(s) 2703} 2704 2705// GoString returns the string representation 2706func (s DeleteServiceInput) GoString() string { 2707 return s.String() 2708} 2709 2710// Validate inspects the fields of the type to determine if they are valid. 2711func (s *DeleteServiceInput) Validate() error { 2712 invalidParams := request.ErrInvalidParams{Context: "DeleteServiceInput"} 2713 if s.Id == nil { 2714 invalidParams.Add(request.NewErrParamRequired("Id")) 2715 } 2716 2717 if invalidParams.Len() > 0 { 2718 return invalidParams 2719 } 2720 return nil 2721} 2722 2723// SetId sets the Id field's value. 2724func (s *DeleteServiceInput) SetId(v string) *DeleteServiceInput { 2725 s.Id = &v 2726 return s 2727} 2728 2729type DeleteServiceOutput struct { 2730 _ struct{} `type:"structure"` 2731} 2732 2733// String returns the string representation 2734func (s DeleteServiceOutput) String() string { 2735 return awsutil.Prettify(s) 2736} 2737 2738// GoString returns the string representation 2739func (s DeleteServiceOutput) GoString() string { 2740 return s.String() 2741} 2742 2743type DeregisterInstanceInput struct { 2744 _ struct{} `type:"structure"` 2745 2746 // The value that you specified for Id in the RegisterInstance request. 2747 // 2748 // InstanceId is a required field 2749 InstanceId *string `type:"string" required:"true"` 2750 2751 // The ID of the service that the instance is associated with. 2752 // 2753 // ServiceId is a required field 2754 ServiceId *string `type:"string" required:"true"` 2755} 2756 2757// String returns the string representation 2758func (s DeregisterInstanceInput) String() string { 2759 return awsutil.Prettify(s) 2760} 2761 2762// GoString returns the string representation 2763func (s DeregisterInstanceInput) GoString() string { 2764 return s.String() 2765} 2766 2767// Validate inspects the fields of the type to determine if they are valid. 2768func (s *DeregisterInstanceInput) Validate() error { 2769 invalidParams := request.ErrInvalidParams{Context: "DeregisterInstanceInput"} 2770 if s.InstanceId == nil { 2771 invalidParams.Add(request.NewErrParamRequired("InstanceId")) 2772 } 2773 if s.ServiceId == nil { 2774 invalidParams.Add(request.NewErrParamRequired("ServiceId")) 2775 } 2776 2777 if invalidParams.Len() > 0 { 2778 return invalidParams 2779 } 2780 return nil 2781} 2782 2783// SetInstanceId sets the InstanceId field's value. 2784func (s *DeregisterInstanceInput) SetInstanceId(v string) *DeregisterInstanceInput { 2785 s.InstanceId = &v 2786 return s 2787} 2788 2789// SetServiceId sets the ServiceId field's value. 2790func (s *DeregisterInstanceInput) SetServiceId(v string) *DeregisterInstanceInput { 2791 s.ServiceId = &v 2792 return s 2793} 2794 2795type DeregisterInstanceOutput struct { 2796 _ struct{} `type:"structure"` 2797 2798 // A value that you can use to determine whether the request completed successfully. 2799 // For more information, see GetOperation. 2800 OperationId *string `type:"string"` 2801} 2802 2803// String returns the string representation 2804func (s DeregisterInstanceOutput) String() string { 2805 return awsutil.Prettify(s) 2806} 2807 2808// GoString returns the string representation 2809func (s DeregisterInstanceOutput) GoString() string { 2810 return s.String() 2811} 2812 2813// SetOperationId sets the OperationId field's value. 2814func (s *DeregisterInstanceOutput) SetOperationId(v string) *DeregisterInstanceOutput { 2815 s.OperationId = &v 2816 return s 2817} 2818 2819type DiscoverInstancesInput struct { 2820 _ struct{} `type:"structure"` 2821 2822 // The health status of the instances that you want to discover. 2823 HealthStatus *string `type:"string" enum:"HealthStatusFilter"` 2824 2825 // The maximum number of instances that you want Cloud Map to return in the 2826 // response to a DiscoverInstances request. If you don't specify a value for 2827 // MaxResults, Cloud Map returns up to 100 instances. 2828 MaxResults *int64 `min:"1" type:"integer"` 2829 2830 // The name of the namespace that you specified when you registered the instance. 2831 // 2832 // NamespaceName is a required field 2833 NamespaceName *string `type:"string" required:"true"` 2834 2835 // A string map that contains attributes with values that you can use to filter 2836 // instances by any custom attribute that you specified when you registered 2837 // the instance. Only instances that match all the specified key/value pairs 2838 // will be returned. 2839 QueryParameters map[string]*string `type:"map"` 2840 2841 // The name of the service that you specified when you registered the instance. 2842 // 2843 // ServiceName is a required field 2844 ServiceName *string `type:"string" required:"true"` 2845} 2846 2847// String returns the string representation 2848func (s DiscoverInstancesInput) String() string { 2849 return awsutil.Prettify(s) 2850} 2851 2852// GoString returns the string representation 2853func (s DiscoverInstancesInput) GoString() string { 2854 return s.String() 2855} 2856 2857// Validate inspects the fields of the type to determine if they are valid. 2858func (s *DiscoverInstancesInput) Validate() error { 2859 invalidParams := request.ErrInvalidParams{Context: "DiscoverInstancesInput"} 2860 if s.MaxResults != nil && *s.MaxResults < 1 { 2861 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 2862 } 2863 if s.NamespaceName == nil { 2864 invalidParams.Add(request.NewErrParamRequired("NamespaceName")) 2865 } 2866 if s.ServiceName == nil { 2867 invalidParams.Add(request.NewErrParamRequired("ServiceName")) 2868 } 2869 2870 if invalidParams.Len() > 0 { 2871 return invalidParams 2872 } 2873 return nil 2874} 2875 2876// SetHealthStatus sets the HealthStatus field's value. 2877func (s *DiscoverInstancesInput) SetHealthStatus(v string) *DiscoverInstancesInput { 2878 s.HealthStatus = &v 2879 return s 2880} 2881 2882// SetMaxResults sets the MaxResults field's value. 2883func (s *DiscoverInstancesInput) SetMaxResults(v int64) *DiscoverInstancesInput { 2884 s.MaxResults = &v 2885 return s 2886} 2887 2888// SetNamespaceName sets the NamespaceName field's value. 2889func (s *DiscoverInstancesInput) SetNamespaceName(v string) *DiscoverInstancesInput { 2890 s.NamespaceName = &v 2891 return s 2892} 2893 2894// SetQueryParameters sets the QueryParameters field's value. 2895func (s *DiscoverInstancesInput) SetQueryParameters(v map[string]*string) *DiscoverInstancesInput { 2896 s.QueryParameters = v 2897 return s 2898} 2899 2900// SetServiceName sets the ServiceName field's value. 2901func (s *DiscoverInstancesInput) SetServiceName(v string) *DiscoverInstancesInput { 2902 s.ServiceName = &v 2903 return s 2904} 2905 2906type DiscoverInstancesOutput struct { 2907 _ struct{} `type:"structure"` 2908 2909 // A complex type that contains one HttpInstanceSummary for each registered 2910 // instance. 2911 Instances []*HttpInstanceSummary `type:"list"` 2912} 2913 2914// String returns the string representation 2915func (s DiscoverInstancesOutput) String() string { 2916 return awsutil.Prettify(s) 2917} 2918 2919// GoString returns the string representation 2920func (s DiscoverInstancesOutput) GoString() string { 2921 return s.String() 2922} 2923 2924// SetInstances sets the Instances field's value. 2925func (s *DiscoverInstancesOutput) SetInstances(v []*HttpInstanceSummary) *DiscoverInstancesOutput { 2926 s.Instances = v 2927 return s 2928} 2929 2930// A complex type that contains information about the Amazon Route 53 DNS records 2931// that you want AWS Cloud Map to create when you register an instance. 2932type DnsConfig struct { 2933 _ struct{} `type:"structure"` 2934 2935 // An array that contains one DnsRecord object for each Route 53 DNS record 2936 // that you want AWS Cloud Map to create when you register an instance. 2937 // 2938 // DnsRecords is a required field 2939 DnsRecords []*DnsRecord `type:"list" required:"true"` 2940 2941 // The ID of the namespace to use for DNS configuration. 2942 // 2943 // Deprecated: Top level attribute in request should be used to reference namespace-id 2944 NamespaceId *string `deprecated:"true" type:"string"` 2945 2946 // The routing policy that you want to apply to all Route 53 DNS records that 2947 // AWS Cloud Map creates when you register an instance and specify this service. 2948 // 2949 // If you want to use this service to register instances that create alias records, 2950 // specify WEIGHTED for the routing policy. 2951 // 2952 // You can specify the following values: 2953 // 2954 // MULTIVALUE 2955 // 2956 // If you define a health check for the service and the health check is healthy, 2957 // Route 53 returns the applicable value for up to eight instances. 2958 // 2959 // For example, suppose the service includes configurations for one A record 2960 // and a health check, and you use the service to register 10 instances. Route 2961 // 53 responds to DNS queries with IP addresses for up to eight healthy instances. 2962 // If fewer than eight instances are healthy, Route 53 responds to every DNS 2963 // query with the IP addresses for all of the healthy instances. 2964 // 2965 // If you don't define a health check for the service, Route 53 assumes that 2966 // all instances are healthy and returns the values for up to eight instances. 2967 // 2968 // For more information about the multivalue routing policy, see Multivalue 2969 // Answer Routing (http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-policy.html#routing-policy-multivalue) 2970 // in the Route 53 Developer Guide. 2971 // 2972 // WEIGHTED 2973 // 2974 // Route 53 returns the applicable value from one randomly selected instance 2975 // from among the instances that you registered using the same service. Currently, 2976 // all records have the same weight, so you can't route more or less traffic 2977 // to any instances. 2978 // 2979 // For example, suppose the service includes configurations for one A record 2980 // and a health check, and you use the service to register 10 instances. Route 2981 // 53 responds to DNS queries with the IP address for one randomly selected 2982 // instance from among the healthy instances. If no instances are healthy, Route 2983 // 53 responds to DNS queries as if all of the instances were healthy. 2984 // 2985 // If you don't define a health check for the service, Route 53 assumes that 2986 // all instances are healthy and returns the applicable value for one randomly 2987 // selected instance. 2988 // 2989 // For more information about the weighted routing policy, see Weighted Routing 2990 // (http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-policy.html#routing-policy-weighted) 2991 // in the Route 53 Developer Guide. 2992 RoutingPolicy *string `type:"string" enum:"RoutingPolicy"` 2993} 2994 2995// String returns the string representation 2996func (s DnsConfig) String() string { 2997 return awsutil.Prettify(s) 2998} 2999 3000// GoString returns the string representation 3001func (s DnsConfig) GoString() string { 3002 return s.String() 3003} 3004 3005// Validate inspects the fields of the type to determine if they are valid. 3006func (s *DnsConfig) Validate() error { 3007 invalidParams := request.ErrInvalidParams{Context: "DnsConfig"} 3008 if s.DnsRecords == nil { 3009 invalidParams.Add(request.NewErrParamRequired("DnsRecords")) 3010 } 3011 if s.DnsRecords != nil { 3012 for i, v := range s.DnsRecords { 3013 if v == nil { 3014 continue 3015 } 3016 if err := v.Validate(); err != nil { 3017 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "DnsRecords", i), err.(request.ErrInvalidParams)) 3018 } 3019 } 3020 } 3021 3022 if invalidParams.Len() > 0 { 3023 return invalidParams 3024 } 3025 return nil 3026} 3027 3028// SetDnsRecords sets the DnsRecords field's value. 3029func (s *DnsConfig) SetDnsRecords(v []*DnsRecord) *DnsConfig { 3030 s.DnsRecords = v 3031 return s 3032} 3033 3034// SetNamespaceId sets the NamespaceId field's value. 3035func (s *DnsConfig) SetNamespaceId(v string) *DnsConfig { 3036 s.NamespaceId = &v 3037 return s 3038} 3039 3040// SetRoutingPolicy sets the RoutingPolicy field's value. 3041func (s *DnsConfig) SetRoutingPolicy(v string) *DnsConfig { 3042 s.RoutingPolicy = &v 3043 return s 3044} 3045 3046// A complex type that contains information about changes to the Route 53 DNS 3047// records that AWS Cloud Map creates when you register an instance. 3048type DnsConfigChange struct { 3049 _ struct{} `type:"structure"` 3050 3051 // An array that contains one DnsRecord object for each Route 53 record that 3052 // you want AWS Cloud Map to create when you register an instance. 3053 // 3054 // DnsRecords is a required field 3055 DnsRecords []*DnsRecord `type:"list" required:"true"` 3056} 3057 3058// String returns the string representation 3059func (s DnsConfigChange) String() string { 3060 return awsutil.Prettify(s) 3061} 3062 3063// GoString returns the string representation 3064func (s DnsConfigChange) GoString() string { 3065 return s.String() 3066} 3067 3068// Validate inspects the fields of the type to determine if they are valid. 3069func (s *DnsConfigChange) Validate() error { 3070 invalidParams := request.ErrInvalidParams{Context: "DnsConfigChange"} 3071 if s.DnsRecords == nil { 3072 invalidParams.Add(request.NewErrParamRequired("DnsRecords")) 3073 } 3074 if s.DnsRecords != nil { 3075 for i, v := range s.DnsRecords { 3076 if v == nil { 3077 continue 3078 } 3079 if err := v.Validate(); err != nil { 3080 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "DnsRecords", i), err.(request.ErrInvalidParams)) 3081 } 3082 } 3083 } 3084 3085 if invalidParams.Len() > 0 { 3086 return invalidParams 3087 } 3088 return nil 3089} 3090 3091// SetDnsRecords sets the DnsRecords field's value. 3092func (s *DnsConfigChange) SetDnsRecords(v []*DnsRecord) *DnsConfigChange { 3093 s.DnsRecords = v 3094 return s 3095} 3096 3097// A complex type that contains the ID for the Route 53 hosted zone that AWS 3098// Cloud Map creates when you create a namespace. 3099type DnsProperties struct { 3100 _ struct{} `type:"structure"` 3101 3102 // The ID for the Route 53 hosted zone that AWS Cloud Map creates when you create 3103 // a namespace. 3104 HostedZoneId *string `type:"string"` 3105} 3106 3107// String returns the string representation 3108func (s DnsProperties) String() string { 3109 return awsutil.Prettify(s) 3110} 3111 3112// GoString returns the string representation 3113func (s DnsProperties) GoString() string { 3114 return s.String() 3115} 3116 3117// SetHostedZoneId sets the HostedZoneId field's value. 3118func (s *DnsProperties) SetHostedZoneId(v string) *DnsProperties { 3119 s.HostedZoneId = &v 3120 return s 3121} 3122 3123// A complex type that contains information about the Route 53 DNS records that 3124// you want AWS Cloud Map to create when you register an instance. 3125type DnsRecord struct { 3126 _ struct{} `type:"structure"` 3127 3128 // The amount of time, in seconds, that you want DNS resolvers to cache the 3129 // settings for this record. 3130 // 3131 // Alias records don't include a TTL because Route 53 uses the TTL for the AWS 3132 // resource that an alias record routes traffic to. If you include the AWS_ALIAS_DNS_NAME 3133 // attribute when you submit a RegisterInstance request, the TTL value is ignored. 3134 // Always specify a TTL for the service; you can use a service to register instances 3135 // that create either alias or non-alias records. 3136 // 3137 // TTL is a required field 3138 TTL *int64 `type:"long" required:"true"` 3139 3140 // The type of the resource, which indicates the type of value that Route 53 3141 // returns in response to DNS queries. 3142 // 3143 // Note the following: 3144 // 3145 // * A, AAAA, and SRV records: You can specify settings for a maximum of 3146 // one A, one AAAA, and one SRV record. You can specify them in any combination. 3147 // 3148 // * CNAME records: If you specify CNAME for Type, you can't define any other 3149 // records. This is a limitation of DNS: you can't create a CNAME record 3150 // and any other type of record that has the same name as a CNAME record. 3151 // 3152 // * Alias records: If you want AWS Cloud Map to create a Route 53 alias 3153 // record when you register an instance, specify A or AAAA for Type. 3154 // 3155 // * All records: You specify settings other than TTL and Type when you register 3156 // an instance. 3157 // 3158 // The following values are supported: 3159 // 3160 // A 3161 // 3162 // Route 53 returns the IP address of the resource in IPv4 format, such as 192.0.2.44. 3163 // 3164 // AAAA 3165 // 3166 // Route 53 returns the IP address of the resource in IPv6 format, such as 2001:0db8:85a3:0000:0000:abcd:0001:2345. 3167 // 3168 // CNAME 3169 // 3170 // Route 53 returns the domain name of the resource, such as www.example.com. 3171 // Note the following: 3172 // 3173 // * You specify the domain name that you want to route traffic to when you 3174 // register an instance. For more information, see RegisterInstanceRequest$Attributes. 3175 // 3176 // * You must specify WEIGHTED for the value of RoutingPolicy. 3177 // 3178 // * You can't specify both CNAME for Type and settings for HealthCheckConfig. 3179 // If you do, the request will fail with an InvalidInput error. 3180 // 3181 // SRV 3182 // 3183 // Route 53 returns the value for an SRV record. The value for an SRV record 3184 // uses the following values: 3185 // 3186 // priority weight port service-hostname 3187 // 3188 // Note the following about the values: 3189 // 3190 // * The values of priority and weight are both set to 1 and can't be changed. 3191 // 3192 // * The value of port comes from the value that you specify for the AWS_INSTANCE_PORT 3193 // attribute when you submit a RegisterInstance request. 3194 // 3195 // * The value of service-hostname is a concatenation of the following values: 3196 // The value that you specify for InstanceId when you register an instance. 3197 // The name of the service. The name of the namespace. For example, if the 3198 // value of InstanceId is test, the name of the service is backend, and the 3199 // name of the namespace is example.com, the value of service-hostname is: 3200 // test.backend.example.com 3201 // 3202 // If you specify settings for an SRV record and if you specify values for AWS_INSTANCE_IPV4, 3203 // AWS_INSTANCE_IPV6, or both in the RegisterInstance request, AWS Cloud Map 3204 // automatically creates A and/or AAAA records that have the same name as the 3205 // value of service-hostname in the SRV record. You can ignore these records. 3206 // 3207 // Type is a required field 3208 Type *string `type:"string" required:"true" enum:"RecordType"` 3209} 3210 3211// String returns the string representation 3212func (s DnsRecord) String() string { 3213 return awsutil.Prettify(s) 3214} 3215 3216// GoString returns the string representation 3217func (s DnsRecord) GoString() string { 3218 return s.String() 3219} 3220 3221// Validate inspects the fields of the type to determine if they are valid. 3222func (s *DnsRecord) Validate() error { 3223 invalidParams := request.ErrInvalidParams{Context: "DnsRecord"} 3224 if s.TTL == nil { 3225 invalidParams.Add(request.NewErrParamRequired("TTL")) 3226 } 3227 if s.Type == nil { 3228 invalidParams.Add(request.NewErrParamRequired("Type")) 3229 } 3230 3231 if invalidParams.Len() > 0 { 3232 return invalidParams 3233 } 3234 return nil 3235} 3236 3237// SetTTL sets the TTL field's value. 3238func (s *DnsRecord) SetTTL(v int64) *DnsRecord { 3239 s.TTL = &v 3240 return s 3241} 3242 3243// SetType sets the Type field's value. 3244func (s *DnsRecord) SetType(v string) *DnsRecord { 3245 s.Type = &v 3246 return s 3247} 3248 3249// The operation is already in progress. 3250type DuplicateRequest struct { 3251 _ struct{} `type:"structure"` 3252 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 3253 3254 // The ID of the operation that is already in progress. 3255 DuplicateOperationId *string `type:"string"` 3256 3257 Message_ *string `locationName:"Message" type:"string"` 3258} 3259 3260// String returns the string representation 3261func (s DuplicateRequest) String() string { 3262 return awsutil.Prettify(s) 3263} 3264 3265// GoString returns the string representation 3266func (s DuplicateRequest) GoString() string { 3267 return s.String() 3268} 3269 3270func newErrorDuplicateRequest(v protocol.ResponseMetadata) error { 3271 return &DuplicateRequest{ 3272 RespMetadata: v, 3273 } 3274} 3275 3276// Code returns the exception type name. 3277func (s *DuplicateRequest) Code() string { 3278 return "DuplicateRequest" 3279} 3280 3281// Message returns the exception's message. 3282func (s *DuplicateRequest) Message() string { 3283 if s.Message_ != nil { 3284 return *s.Message_ 3285 } 3286 return "" 3287} 3288 3289// OrigErr always returns nil, satisfies awserr.Error interface. 3290func (s *DuplicateRequest) OrigErr() error { 3291 return nil 3292} 3293 3294func (s *DuplicateRequest) Error() string { 3295 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 3296} 3297 3298// Status code returns the HTTP status code for the request's response error. 3299func (s *DuplicateRequest) StatusCode() int { 3300 return s.RespMetadata.StatusCode 3301} 3302 3303// RequestID returns the service's response RequestID for request. 3304func (s *DuplicateRequest) RequestID() string { 3305 return s.RespMetadata.RequestID 3306} 3307 3308type GetInstanceInput struct { 3309 _ struct{} `type:"structure"` 3310 3311 // The ID of the instance that you want to get information about. 3312 // 3313 // InstanceId is a required field 3314 InstanceId *string `type:"string" required:"true"` 3315 3316 // The ID of the service that the instance is associated with. 3317 // 3318 // ServiceId is a required field 3319 ServiceId *string `type:"string" required:"true"` 3320} 3321 3322// String returns the string representation 3323func (s GetInstanceInput) String() string { 3324 return awsutil.Prettify(s) 3325} 3326 3327// GoString returns the string representation 3328func (s GetInstanceInput) GoString() string { 3329 return s.String() 3330} 3331 3332// Validate inspects the fields of the type to determine if they are valid. 3333func (s *GetInstanceInput) Validate() error { 3334 invalidParams := request.ErrInvalidParams{Context: "GetInstanceInput"} 3335 if s.InstanceId == nil { 3336 invalidParams.Add(request.NewErrParamRequired("InstanceId")) 3337 } 3338 if s.ServiceId == nil { 3339 invalidParams.Add(request.NewErrParamRequired("ServiceId")) 3340 } 3341 3342 if invalidParams.Len() > 0 { 3343 return invalidParams 3344 } 3345 return nil 3346} 3347 3348// SetInstanceId sets the InstanceId field's value. 3349func (s *GetInstanceInput) SetInstanceId(v string) *GetInstanceInput { 3350 s.InstanceId = &v 3351 return s 3352} 3353 3354// SetServiceId sets the ServiceId field's value. 3355func (s *GetInstanceInput) SetServiceId(v string) *GetInstanceInput { 3356 s.ServiceId = &v 3357 return s 3358} 3359 3360type GetInstanceOutput struct { 3361 _ struct{} `type:"structure"` 3362 3363 // A complex type that contains information about a specified instance. 3364 Instance *Instance `type:"structure"` 3365} 3366 3367// String returns the string representation 3368func (s GetInstanceOutput) String() string { 3369 return awsutil.Prettify(s) 3370} 3371 3372// GoString returns the string representation 3373func (s GetInstanceOutput) GoString() string { 3374 return s.String() 3375} 3376 3377// SetInstance sets the Instance field's value. 3378func (s *GetInstanceOutput) SetInstance(v *Instance) *GetInstanceOutput { 3379 s.Instance = v 3380 return s 3381} 3382 3383type GetInstancesHealthStatusInput struct { 3384 _ struct{} `type:"structure"` 3385 3386 // An array that contains the IDs of all the instances that you want to get 3387 // the health status for. 3388 // 3389 // If you omit Instances, AWS Cloud Map returns the health status for all the 3390 // instances that are associated with the specified service. 3391 // 3392 // To get the IDs for the instances that you've registered by using a specified 3393 // service, submit a ListInstances request. 3394 Instances []*string `min:"1" type:"list"` 3395 3396 // The maximum number of instances that you want AWS Cloud Map to return in 3397 // the response to a GetInstancesHealthStatus request. If you don't specify 3398 // a value for MaxResults, AWS Cloud Map returns up to 100 instances. 3399 MaxResults *int64 `min:"1" type:"integer"` 3400 3401 // For the first GetInstancesHealthStatus request, omit this value. 3402 // 3403 // If more than MaxResults instances match the specified criteria, you can submit 3404 // another GetInstancesHealthStatus request to get the next group of results. 3405 // Specify the value of NextToken from the previous response in the next request. 3406 NextToken *string `type:"string"` 3407 3408 // The ID of the service that the instance is associated with. 3409 // 3410 // ServiceId is a required field 3411 ServiceId *string `type:"string" required:"true"` 3412} 3413 3414// String returns the string representation 3415func (s GetInstancesHealthStatusInput) String() string { 3416 return awsutil.Prettify(s) 3417} 3418 3419// GoString returns the string representation 3420func (s GetInstancesHealthStatusInput) GoString() string { 3421 return s.String() 3422} 3423 3424// Validate inspects the fields of the type to determine if they are valid. 3425func (s *GetInstancesHealthStatusInput) Validate() error { 3426 invalidParams := request.ErrInvalidParams{Context: "GetInstancesHealthStatusInput"} 3427 if s.Instances != nil && len(s.Instances) < 1 { 3428 invalidParams.Add(request.NewErrParamMinLen("Instances", 1)) 3429 } 3430 if s.MaxResults != nil && *s.MaxResults < 1 { 3431 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 3432 } 3433 if s.ServiceId == nil { 3434 invalidParams.Add(request.NewErrParamRequired("ServiceId")) 3435 } 3436 3437 if invalidParams.Len() > 0 { 3438 return invalidParams 3439 } 3440 return nil 3441} 3442 3443// SetInstances sets the Instances field's value. 3444func (s *GetInstancesHealthStatusInput) SetInstances(v []*string) *GetInstancesHealthStatusInput { 3445 s.Instances = v 3446 return s 3447} 3448 3449// SetMaxResults sets the MaxResults field's value. 3450func (s *GetInstancesHealthStatusInput) SetMaxResults(v int64) *GetInstancesHealthStatusInput { 3451 s.MaxResults = &v 3452 return s 3453} 3454 3455// SetNextToken sets the NextToken field's value. 3456func (s *GetInstancesHealthStatusInput) SetNextToken(v string) *GetInstancesHealthStatusInput { 3457 s.NextToken = &v 3458 return s 3459} 3460 3461// SetServiceId sets the ServiceId field's value. 3462func (s *GetInstancesHealthStatusInput) SetServiceId(v string) *GetInstancesHealthStatusInput { 3463 s.ServiceId = &v 3464 return s 3465} 3466 3467type GetInstancesHealthStatusOutput struct { 3468 _ struct{} `type:"structure"` 3469 3470 // If more than MaxResults instances match the specified criteria, you can submit 3471 // another GetInstancesHealthStatus request to get the next group of results. 3472 // Specify the value of NextToken from the previous response in the next request. 3473 NextToken *string `type:"string"` 3474 3475 // A complex type that contains the IDs and the health status of the instances 3476 // that you specified in the GetInstancesHealthStatus request. 3477 Status map[string]*string `type:"map"` 3478} 3479 3480// String returns the string representation 3481func (s GetInstancesHealthStatusOutput) String() string { 3482 return awsutil.Prettify(s) 3483} 3484 3485// GoString returns the string representation 3486func (s GetInstancesHealthStatusOutput) GoString() string { 3487 return s.String() 3488} 3489 3490// SetNextToken sets the NextToken field's value. 3491func (s *GetInstancesHealthStatusOutput) SetNextToken(v string) *GetInstancesHealthStatusOutput { 3492 s.NextToken = &v 3493 return s 3494} 3495 3496// SetStatus sets the Status field's value. 3497func (s *GetInstancesHealthStatusOutput) SetStatus(v map[string]*string) *GetInstancesHealthStatusOutput { 3498 s.Status = v 3499 return s 3500} 3501 3502type GetNamespaceInput struct { 3503 _ struct{} `type:"structure"` 3504 3505 // The ID of the namespace that you want to get information about. 3506 // 3507 // Id is a required field 3508 Id *string `type:"string" required:"true"` 3509} 3510 3511// String returns the string representation 3512func (s GetNamespaceInput) String() string { 3513 return awsutil.Prettify(s) 3514} 3515 3516// GoString returns the string representation 3517func (s GetNamespaceInput) GoString() string { 3518 return s.String() 3519} 3520 3521// Validate inspects the fields of the type to determine if they are valid. 3522func (s *GetNamespaceInput) Validate() error { 3523 invalidParams := request.ErrInvalidParams{Context: "GetNamespaceInput"} 3524 if s.Id == nil { 3525 invalidParams.Add(request.NewErrParamRequired("Id")) 3526 } 3527 3528 if invalidParams.Len() > 0 { 3529 return invalidParams 3530 } 3531 return nil 3532} 3533 3534// SetId sets the Id field's value. 3535func (s *GetNamespaceInput) SetId(v string) *GetNamespaceInput { 3536 s.Id = &v 3537 return s 3538} 3539 3540type GetNamespaceOutput struct { 3541 _ struct{} `type:"structure"` 3542 3543 // A complex type that contains information about the specified namespace. 3544 Namespace *Namespace `type:"structure"` 3545} 3546 3547// String returns the string representation 3548func (s GetNamespaceOutput) String() string { 3549 return awsutil.Prettify(s) 3550} 3551 3552// GoString returns the string representation 3553func (s GetNamespaceOutput) GoString() string { 3554 return s.String() 3555} 3556 3557// SetNamespace sets the Namespace field's value. 3558func (s *GetNamespaceOutput) SetNamespace(v *Namespace) *GetNamespaceOutput { 3559 s.Namespace = v 3560 return s 3561} 3562 3563type GetOperationInput struct { 3564 _ struct{} `type:"structure"` 3565 3566 // The ID of the operation that you want to get more information about. 3567 // 3568 // OperationId is a required field 3569 OperationId *string `type:"string" required:"true"` 3570} 3571 3572// String returns the string representation 3573func (s GetOperationInput) String() string { 3574 return awsutil.Prettify(s) 3575} 3576 3577// GoString returns the string representation 3578func (s GetOperationInput) GoString() string { 3579 return s.String() 3580} 3581 3582// Validate inspects the fields of the type to determine if they are valid. 3583func (s *GetOperationInput) Validate() error { 3584 invalidParams := request.ErrInvalidParams{Context: "GetOperationInput"} 3585 if s.OperationId == nil { 3586 invalidParams.Add(request.NewErrParamRequired("OperationId")) 3587 } 3588 3589 if invalidParams.Len() > 0 { 3590 return invalidParams 3591 } 3592 return nil 3593} 3594 3595// SetOperationId sets the OperationId field's value. 3596func (s *GetOperationInput) SetOperationId(v string) *GetOperationInput { 3597 s.OperationId = &v 3598 return s 3599} 3600 3601type GetOperationOutput struct { 3602 _ struct{} `type:"structure"` 3603 3604 // A complex type that contains information about the operation. 3605 Operation *Operation `type:"structure"` 3606} 3607 3608// String returns the string representation 3609func (s GetOperationOutput) String() string { 3610 return awsutil.Prettify(s) 3611} 3612 3613// GoString returns the string representation 3614func (s GetOperationOutput) GoString() string { 3615 return s.String() 3616} 3617 3618// SetOperation sets the Operation field's value. 3619func (s *GetOperationOutput) SetOperation(v *Operation) *GetOperationOutput { 3620 s.Operation = v 3621 return s 3622} 3623 3624type GetServiceInput struct { 3625 _ struct{} `type:"structure"` 3626 3627 // The ID of the service that you want to get settings for. 3628 // 3629 // Id is a required field 3630 Id *string `type:"string" required:"true"` 3631} 3632 3633// String returns the string representation 3634func (s GetServiceInput) String() string { 3635 return awsutil.Prettify(s) 3636} 3637 3638// GoString returns the string representation 3639func (s GetServiceInput) GoString() string { 3640 return s.String() 3641} 3642 3643// Validate inspects the fields of the type to determine if they are valid. 3644func (s *GetServiceInput) Validate() error { 3645 invalidParams := request.ErrInvalidParams{Context: "GetServiceInput"} 3646 if s.Id == nil { 3647 invalidParams.Add(request.NewErrParamRequired("Id")) 3648 } 3649 3650 if invalidParams.Len() > 0 { 3651 return invalidParams 3652 } 3653 return nil 3654} 3655 3656// SetId sets the Id field's value. 3657func (s *GetServiceInput) SetId(v string) *GetServiceInput { 3658 s.Id = &v 3659 return s 3660} 3661 3662type GetServiceOutput struct { 3663 _ struct{} `type:"structure"` 3664 3665 // A complex type that contains information about the service. 3666 Service *Service `type:"structure"` 3667} 3668 3669// String returns the string representation 3670func (s GetServiceOutput) String() string { 3671 return awsutil.Prettify(s) 3672} 3673 3674// GoString returns the string representation 3675func (s GetServiceOutput) GoString() string { 3676 return s.String() 3677} 3678 3679// SetService sets the Service field's value. 3680func (s *GetServiceOutput) SetService(v *Service) *GetServiceOutput { 3681 s.Service = v 3682 return s 3683} 3684 3685// Public DNS namespaces only. A complex type that contains settings for an 3686// optional health check. If you specify settings for a health check, AWS Cloud 3687// Map associates the health check with the records that you specify in DnsConfig. 3688// 3689// If you specify a health check configuration, you can specify either HealthCheckCustomConfig 3690// or HealthCheckConfig but not both. 3691// 3692// Health checks are basic Route 53 health checks that monitor an AWS endpoint. 3693// For information about pricing for health checks, see Amazon Route 53 Pricing 3694// (http://aws.amazon.com/route53/pricing/). 3695// 3696// Note the following about configuring health checks. 3697// 3698// A and AAAA records 3699// 3700// If DnsConfig includes configurations for both A and AAAA records, AWS Cloud 3701// Map creates a health check that uses the IPv4 address to check the health 3702// of the resource. If the endpoint that is specified by the IPv4 address is 3703// unhealthy, Route 53 considers both the A and AAAA records to be unhealthy. 3704// 3705// CNAME records 3706// 3707// You can't specify settings for HealthCheckConfig when the DNSConfig includes 3708// CNAME for the value of Type. If you do, the CreateService request will fail 3709// with an InvalidInput error. 3710// 3711// Request interval 3712// 3713// A Route 53 health checker in each health-checking region sends a health check 3714// request to an endpoint every 30 seconds. On average, your endpoint receives 3715// a health check request about every two seconds. However, health checkers 3716// don't coordinate with one another, so you'll sometimes see several requests 3717// per second followed by a few seconds with no health checks at all. 3718// 3719// Health checking regions 3720// 3721// Health checkers perform checks from all Route 53 health-checking regions. 3722// For a list of the current regions, see Regions (http://docs.aws.amazon.com/Route53/latest/APIReference/API_HealthCheckConfig.html#Route53-Type-HealthCheckConfig-Regions). 3723// 3724// Alias records 3725// 3726// When you register an instance, if you include the AWS_ALIAS_DNS_NAME attribute, 3727// AWS Cloud Map creates a Route 53 alias record. Note the following: 3728// 3729// * Route 53 automatically sets EvaluateTargetHealth to true for alias records. 3730// When EvaluateTargetHealth is true, the alias record inherits the health 3731// of the referenced AWS resource. such as an ELB load balancer. For more 3732// information, see EvaluateTargetHealth (http://docs.aws.amazon.com/Route53/latest/APIReference/API_AliasTarget.html#Route53-Type-AliasTarget-EvaluateTargetHealth). 3733// 3734// * If you include HealthCheckConfig and then use the service to register 3735// an instance that creates an alias record, Route 53 doesn't create the 3736// health check. 3737// 3738// Charges for health checks 3739// 3740// Health checks are basic Route 53 health checks that monitor an AWS endpoint. 3741// For information about pricing for health checks, see Amazon Route 53 Pricing 3742// (http://aws.amazon.com/route53/pricing/). 3743type HealthCheckConfig struct { 3744 _ struct{} `type:"structure"` 3745 3746 // The number of consecutive health checks that an endpoint must pass or fail 3747 // for Route 53 to change the current status of the endpoint from unhealthy 3748 // to healthy or vice versa. For more information, see How Route 53 Determines 3749 // Whether an Endpoint Is Healthy (http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html) 3750 // in the Route 53 Developer Guide. 3751 FailureThreshold *int64 `min:"1" type:"integer"` 3752 3753 // The path that you want Route 53 to request when performing health checks. 3754 // The path can be any value for which your endpoint will return an HTTP status 3755 // code of 2xx or 3xx when the endpoint is healthy, such as the file /docs/route53-health-check.html. 3756 // Route 53 automatically adds the DNS name for the service. If you don't specify 3757 // a value for ResourcePath, the default value is /. 3758 // 3759 // If you specify TCP for Type, you must not specify a value for ResourcePath. 3760 ResourcePath *string `type:"string"` 3761 3762 // The type of health check that you want to create, which indicates how Route 3763 // 53 determines whether an endpoint is healthy. 3764 // 3765 // You can't change the value of Type after you create a health check. 3766 // 3767 // You can create the following types of health checks: 3768 // 3769 // * HTTP: Route 53 tries to establish a TCP connection. If successful, Route 3770 // 53 submits an HTTP request and waits for an HTTP status code of 200 or 3771 // greater and less than 400. 3772 // 3773 // * HTTPS: Route 53 tries to establish a TCP connection. If successful, 3774 // Route 53 submits an HTTPS request and waits for an HTTP status code of 3775 // 200 or greater and less than 400. If you specify HTTPS for the value of 3776 // Type, the endpoint must support TLS v1.0 or later. 3777 // 3778 // * TCP: Route 53 tries to establish a TCP connection. If you specify TCP 3779 // for Type, don't specify a value for ResourcePath. 3780 // 3781 // For more information, see How Route 53 Determines Whether an Endpoint Is 3782 // Healthy (http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html) 3783 // in the Route 53 Developer Guide. 3784 // 3785 // Type is a required field 3786 Type *string `type:"string" required:"true" enum:"HealthCheckType"` 3787} 3788 3789// String returns the string representation 3790func (s HealthCheckConfig) String() string { 3791 return awsutil.Prettify(s) 3792} 3793 3794// GoString returns the string representation 3795func (s HealthCheckConfig) GoString() string { 3796 return s.String() 3797} 3798 3799// Validate inspects the fields of the type to determine if they are valid. 3800func (s *HealthCheckConfig) Validate() error { 3801 invalidParams := request.ErrInvalidParams{Context: "HealthCheckConfig"} 3802 if s.FailureThreshold != nil && *s.FailureThreshold < 1 { 3803 invalidParams.Add(request.NewErrParamMinValue("FailureThreshold", 1)) 3804 } 3805 if s.Type == nil { 3806 invalidParams.Add(request.NewErrParamRequired("Type")) 3807 } 3808 3809 if invalidParams.Len() > 0 { 3810 return invalidParams 3811 } 3812 return nil 3813} 3814 3815// SetFailureThreshold sets the FailureThreshold field's value. 3816func (s *HealthCheckConfig) SetFailureThreshold(v int64) *HealthCheckConfig { 3817 s.FailureThreshold = &v 3818 return s 3819} 3820 3821// SetResourcePath sets the ResourcePath field's value. 3822func (s *HealthCheckConfig) SetResourcePath(v string) *HealthCheckConfig { 3823 s.ResourcePath = &v 3824 return s 3825} 3826 3827// SetType sets the Type field's value. 3828func (s *HealthCheckConfig) SetType(v string) *HealthCheckConfig { 3829 s.Type = &v 3830 return s 3831} 3832 3833// A complex type that contains information about an optional custom health 3834// check. A custom health check, which requires that you use a third-party health 3835// checker to evaluate the health of your resources, is useful in the following 3836// circumstances: 3837// 3838// * You can't use a health check that is defined by HealthCheckConfig because 3839// the resource isn't available over the internet. For example, you can use 3840// a custom health check when the instance is in an Amazon VPC. (To check 3841// the health of resources in a VPC, the health checker must also be in the 3842// VPC.) 3843// 3844// * You want to use a third-party health checker regardless of where your 3845// resources are. 3846// 3847// If you specify a health check configuration, you can specify either HealthCheckCustomConfig 3848// or HealthCheckConfig but not both. 3849// 3850// To change the status of a custom health check, submit an UpdateInstanceCustomHealthStatus 3851// request. Cloud Map doesn't monitor the status of the resource, it just keeps 3852// a record of the status specified in the most recent UpdateInstanceCustomHealthStatus 3853// request. 3854// 3855// Here's how custom health checks work: 3856// 3857// You create a service and specify a value for FailureThreshold. 3858// 3859// The failure threshold indicates the number of 30-second intervals you want 3860// AWS Cloud Map to wait between the time that your application sends an UpdateInstanceCustomHealthStatus 3861// request and the time that AWS Cloud Map stops routing internet traffic to 3862// the corresponding resource. 3863// 3864// You register an instance. 3865// 3866// You configure a third-party health checker to monitor the resource that is 3867// associated with the new instance. 3868// 3869// AWS Cloud Map doesn't check the health of the resource directly. 3870// 3871// The third-party health-checker determines that the resource is unhealthy 3872// and notifies your application. 3873// 3874// Your application submits an UpdateInstanceCustomHealthStatus request. 3875// 3876// AWS Cloud Map waits for (FailureThreshold x 30) seconds. 3877// 3878// If another UpdateInstanceCustomHealthStatus request doesn't arrive during 3879// that time to change the status back to healthy, AWS Cloud Map stops routing 3880// traffic to the resource. 3881// 3882// Note the following about configuring custom health checks. 3883type HealthCheckCustomConfig struct { 3884 _ struct{} `type:"structure"` 3885 3886 // The number of 30-second intervals that you want Cloud Map to wait after receiving 3887 // an UpdateInstanceCustomHealthStatus request before it changes the health 3888 // status of a service instance. For example, suppose you specify a value of 3889 // 2 for FailureTheshold, and then your application sends an UpdateInstanceCustomHealthStatus 3890 // request. Cloud Map waits for approximately 60 seconds (2 x 30) before changing 3891 // the status of the service instance based on that request. 3892 // 3893 // Sending a second or subsequent UpdateInstanceCustomHealthStatus request with 3894 // the same value before FailureThreshold x 30 seconds has passed doesn't accelerate 3895 // the change. Cloud Map still waits FailureThreshold x 30 seconds after the 3896 // first request to make the change. 3897 FailureThreshold *int64 `min:"1" type:"integer"` 3898} 3899 3900// String returns the string representation 3901func (s HealthCheckCustomConfig) String() string { 3902 return awsutil.Prettify(s) 3903} 3904 3905// GoString returns the string representation 3906func (s HealthCheckCustomConfig) GoString() string { 3907 return s.String() 3908} 3909 3910// Validate inspects the fields of the type to determine if they are valid. 3911func (s *HealthCheckCustomConfig) Validate() error { 3912 invalidParams := request.ErrInvalidParams{Context: "HealthCheckCustomConfig"} 3913 if s.FailureThreshold != nil && *s.FailureThreshold < 1 { 3914 invalidParams.Add(request.NewErrParamMinValue("FailureThreshold", 1)) 3915 } 3916 3917 if invalidParams.Len() > 0 { 3918 return invalidParams 3919 } 3920 return nil 3921} 3922 3923// SetFailureThreshold sets the FailureThreshold field's value. 3924func (s *HealthCheckCustomConfig) SetFailureThreshold(v int64) *HealthCheckCustomConfig { 3925 s.FailureThreshold = &v 3926 return s 3927} 3928 3929// In a response to a DiscoverInstance request, HttpInstanceSummary contains 3930// information about one instance that matches the values that you specified 3931// in the request. 3932type HttpInstanceSummary struct { 3933 _ struct{} `type:"structure"` 3934 3935 // If you included any attributes when you registered the instance, the values 3936 // of those attributes. 3937 Attributes map[string]*string `type:"map"` 3938 3939 // If you configured health checking in the service, the current health status 3940 // of the service instance. 3941 HealthStatus *string `type:"string" enum:"HealthStatus"` 3942 3943 // The ID of an instance that matches the values that you specified in the request. 3944 InstanceId *string `type:"string"` 3945 3946 // The name of the namespace that you specified when you registered the instance. 3947 NamespaceName *string `type:"string"` 3948 3949 // The name of the service that you specified when you registered the instance. 3950 ServiceName *string `type:"string"` 3951} 3952 3953// String returns the string representation 3954func (s HttpInstanceSummary) String() string { 3955 return awsutil.Prettify(s) 3956} 3957 3958// GoString returns the string representation 3959func (s HttpInstanceSummary) GoString() string { 3960 return s.String() 3961} 3962 3963// SetAttributes sets the Attributes field's value. 3964func (s *HttpInstanceSummary) SetAttributes(v map[string]*string) *HttpInstanceSummary { 3965 s.Attributes = v 3966 return s 3967} 3968 3969// SetHealthStatus sets the HealthStatus field's value. 3970func (s *HttpInstanceSummary) SetHealthStatus(v string) *HttpInstanceSummary { 3971 s.HealthStatus = &v 3972 return s 3973} 3974 3975// SetInstanceId sets the InstanceId field's value. 3976func (s *HttpInstanceSummary) SetInstanceId(v string) *HttpInstanceSummary { 3977 s.InstanceId = &v 3978 return s 3979} 3980 3981// SetNamespaceName sets the NamespaceName field's value. 3982func (s *HttpInstanceSummary) SetNamespaceName(v string) *HttpInstanceSummary { 3983 s.NamespaceName = &v 3984 return s 3985} 3986 3987// SetServiceName sets the ServiceName field's value. 3988func (s *HttpInstanceSummary) SetServiceName(v string) *HttpInstanceSummary { 3989 s.ServiceName = &v 3990 return s 3991} 3992 3993// A complex type that contains the name of an HTTP namespace. 3994type HttpProperties struct { 3995 _ struct{} `type:"structure"` 3996 3997 // The name of an HTTP namespace. 3998 HttpName *string `type:"string"` 3999} 4000 4001// String returns the string representation 4002func (s HttpProperties) String() string { 4003 return awsutil.Prettify(s) 4004} 4005 4006// GoString returns the string representation 4007func (s HttpProperties) GoString() string { 4008 return s.String() 4009} 4010 4011// SetHttpName sets the HttpName field's value. 4012func (s *HttpProperties) SetHttpName(v string) *HttpProperties { 4013 s.HttpName = &v 4014 return s 4015} 4016 4017// A complex type that contains information about an instance that AWS Cloud 4018// Map creates when you submit a RegisterInstance request. 4019type Instance struct { 4020 _ struct{} `type:"structure"` 4021 4022 // A string map that contains the following information for the service that 4023 // you specify in ServiceId: 4024 // 4025 // * The attributes that apply to the records that are defined in the service. 4026 // 4027 // * For each attribute, the applicable value. 4028 // 4029 // Supported attribute keys include the following: 4030 // 4031 // AWS_ALIAS_DNS_NAME 4032 // 4033 // If you want AWS Cloud Map to create a Route 53 alias record that routes traffic 4034 // to an Elastic Load Balancing load balancer, specify the DNS name that is 4035 // associated with the load balancer. For information about how to get the DNS 4036 // name, see "DNSName" in the topic AliasTarget (http://docs.aws.amazon.com/Route53/latest/APIReference/API_AliasTarget.html). 4037 // 4038 // Note the following: 4039 // 4040 // * The configuration for the service that is specified by ServiceId must 4041 // include settings for an A record, an AAAA record, or both. 4042 // 4043 // * In the service that is specified by ServiceId, the value of RoutingPolicy 4044 // must be WEIGHTED. 4045 // 4046 // * If the service that is specified by ServiceId includes HealthCheckConfig 4047 // settings, AWS Cloud Map will create the health check, but it won't associate 4048 // the health check with the alias record. 4049 // 4050 // * Auto naming currently doesn't support creating alias records that route 4051 // traffic to AWS resources other than ELB load balancers. 4052 // 4053 // * If you specify a value for AWS_ALIAS_DNS_NAME, don't specify values 4054 // for any of the AWS_INSTANCE attributes. 4055 // 4056 // AWS_INSTANCE_CNAME 4057 // 4058 // If the service configuration includes a CNAME record, the domain name that 4059 // you want Route 53 to return in response to DNS queries, for example, example.com. 4060 // 4061 // This value is required if the service specified by ServiceId includes settings 4062 // for an CNAME record. 4063 // 4064 // AWS_INSTANCE_IPV4 4065 // 4066 // If the service configuration includes an A record, the IPv4 address that 4067 // you want Route 53 to return in response to DNS queries, for example, 192.0.2.44. 4068 // 4069 // This value is required if the service specified by ServiceId includes settings 4070 // for an A record. If the service includes settings for an SRV record, you 4071 // must specify a value for AWS_INSTANCE_IPV4, AWS_INSTANCE_IPV6, or both. 4072 // 4073 // AWS_INSTANCE_IPV6 4074 // 4075 // If the service configuration includes an AAAA record, the IPv6 address that 4076 // you want Route 53 to return in response to DNS queries, for example, 2001:0db8:85a3:0000:0000:abcd:0001:2345. 4077 // 4078 // This value is required if the service specified by ServiceId includes settings 4079 // for an AAAA record. If the service includes settings for an SRV record, you 4080 // must specify a value for AWS_INSTANCE_IPV4, AWS_INSTANCE_IPV6, or both. 4081 // 4082 // AWS_INSTANCE_PORT 4083 // 4084 // If the service includes an SRV record, the value that you want Route 53 to 4085 // return for the port. 4086 // 4087 // If the service includes HealthCheckConfig, the port on the endpoint that 4088 // you want Route 53 to send requests to. 4089 // 4090 // This value is required if you specified settings for an SRV record when you 4091 // created the service. 4092 Attributes map[string]*string `type:"map"` 4093 4094 // A unique string that identifies the request and that allows failed RegisterInstance 4095 // requests to be retried without the risk of executing the operation twice. 4096 // You must use a unique CreatorRequestId string every time you submit a RegisterInstance 4097 // request if you're registering additional instances for the same namespace 4098 // and service. CreatorRequestId can be any unique string, for example, a date/time 4099 // stamp. 4100 CreatorRequestId *string `type:"string"` 4101 4102 // An identifier that you want to associate with the instance. Note the following: 4103 // 4104 // * If the service that is specified by ServiceId includes settings for 4105 // an SRV record, the value of InstanceId is automatically included as part 4106 // of the value for the SRV record. For more information, see DnsRecord$Type. 4107 // 4108 // * You can use this value to update an existing instance. 4109 // 4110 // * To register a new instance, you must specify a value that is unique 4111 // among instances that you register by using the same service. 4112 // 4113 // * If you specify an existing InstanceId and ServiceId, AWS Cloud Map updates 4114 // the existing DNS records. If there's also an existing health check, AWS 4115 // Cloud Map deletes the old health check and creates a new one. The health 4116 // check isn't deleted immediately, so it will still appear for a while if 4117 // you submit a ListHealthChecks request, for example. 4118 // 4119 // Id is a required field 4120 Id *string `type:"string" required:"true"` 4121} 4122 4123// String returns the string representation 4124func (s Instance) String() string { 4125 return awsutil.Prettify(s) 4126} 4127 4128// GoString returns the string representation 4129func (s Instance) GoString() string { 4130 return s.String() 4131} 4132 4133// SetAttributes sets the Attributes field's value. 4134func (s *Instance) SetAttributes(v map[string]*string) *Instance { 4135 s.Attributes = v 4136 return s 4137} 4138 4139// SetCreatorRequestId sets the CreatorRequestId field's value. 4140func (s *Instance) SetCreatorRequestId(v string) *Instance { 4141 s.CreatorRequestId = &v 4142 return s 4143} 4144 4145// SetId sets the Id field's value. 4146func (s *Instance) SetId(v string) *Instance { 4147 s.Id = &v 4148 return s 4149} 4150 4151// No instance exists with the specified ID, or the instance was recently registered, 4152// and information about the instance hasn't propagated yet. 4153type InstanceNotFound struct { 4154 _ struct{} `type:"structure"` 4155 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 4156 4157 Message_ *string `locationName:"Message" type:"string"` 4158} 4159 4160// String returns the string representation 4161func (s InstanceNotFound) String() string { 4162 return awsutil.Prettify(s) 4163} 4164 4165// GoString returns the string representation 4166func (s InstanceNotFound) GoString() string { 4167 return s.String() 4168} 4169 4170func newErrorInstanceNotFound(v protocol.ResponseMetadata) error { 4171 return &InstanceNotFound{ 4172 RespMetadata: v, 4173 } 4174} 4175 4176// Code returns the exception type name. 4177func (s *InstanceNotFound) Code() string { 4178 return "InstanceNotFound" 4179} 4180 4181// Message returns the exception's message. 4182func (s *InstanceNotFound) Message() string { 4183 if s.Message_ != nil { 4184 return *s.Message_ 4185 } 4186 return "" 4187} 4188 4189// OrigErr always returns nil, satisfies awserr.Error interface. 4190func (s *InstanceNotFound) OrigErr() error { 4191 return nil 4192} 4193 4194func (s *InstanceNotFound) Error() string { 4195 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 4196} 4197 4198// Status code returns the HTTP status code for the request's response error. 4199func (s *InstanceNotFound) StatusCode() int { 4200 return s.RespMetadata.StatusCode 4201} 4202 4203// RequestID returns the service's response RequestID for request. 4204func (s *InstanceNotFound) RequestID() string { 4205 return s.RespMetadata.RequestID 4206} 4207 4208// A complex type that contains information about the instances that you registered 4209// by using a specified service. 4210type InstanceSummary struct { 4211 _ struct{} `type:"structure"` 4212 4213 // A string map that contains the following information: 4214 // 4215 // * The attributes that are associate with the instance. 4216 // 4217 // * For each attribute, the applicable value. 4218 // 4219 // Supported attribute keys include the following: 4220 // 4221 // * AWS_ALIAS_DNS_NAME: For an alias record that routes traffic to an Elastic 4222 // Load Balancing load balancer, the DNS name that is associated with the 4223 // load balancer. 4224 // 4225 // * AWS_INSTANCE_CNAME: For a CNAME record, the domain name that Route 53 4226 // returns in response to DNS queries, for example, example.com. 4227 // 4228 // * AWS_INSTANCE_IPV4: For an A record, the IPv4 address that Route 53 returns 4229 // in response to DNS queries, for example, 192.0.2.44. 4230 // 4231 // * AWS_INSTANCE_IPV6: For an AAAA record, the IPv6 address that Route 53 4232 // returns in response to DNS queries, for example, 2001:0db8:85a3:0000:0000:abcd:0001:2345. 4233 // 4234 // * AWS_INSTANCE_PORT: For an SRV record, the value that Route 53 returns 4235 // for the port. In addition, if the service includes HealthCheckConfig, 4236 // the port on the endpoint that Route 53 sends requests to. 4237 Attributes map[string]*string `type:"map"` 4238 4239 // The ID for an instance that you created by using a specified service. 4240 Id *string `type:"string"` 4241} 4242 4243// String returns the string representation 4244func (s InstanceSummary) String() string { 4245 return awsutil.Prettify(s) 4246} 4247 4248// GoString returns the string representation 4249func (s InstanceSummary) GoString() string { 4250 return s.String() 4251} 4252 4253// SetAttributes sets the Attributes field's value. 4254func (s *InstanceSummary) SetAttributes(v map[string]*string) *InstanceSummary { 4255 s.Attributes = v 4256 return s 4257} 4258 4259// SetId sets the Id field's value. 4260func (s *InstanceSummary) SetId(v string) *InstanceSummary { 4261 s.Id = &v 4262 return s 4263} 4264 4265// One or more specified values aren't valid. For example, a required value 4266// might be missing, a numeric value might be outside the allowed range, or 4267// a string value might exceed length constraints. 4268type InvalidInput struct { 4269 _ struct{} `type:"structure"` 4270 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 4271 4272 Message_ *string `locationName:"Message" type:"string"` 4273} 4274 4275// String returns the string representation 4276func (s InvalidInput) String() string { 4277 return awsutil.Prettify(s) 4278} 4279 4280// GoString returns the string representation 4281func (s InvalidInput) GoString() string { 4282 return s.String() 4283} 4284 4285func newErrorInvalidInput(v protocol.ResponseMetadata) error { 4286 return &InvalidInput{ 4287 RespMetadata: v, 4288 } 4289} 4290 4291// Code returns the exception type name. 4292func (s *InvalidInput) Code() string { 4293 return "InvalidInput" 4294} 4295 4296// Message returns the exception's message. 4297func (s *InvalidInput) Message() string { 4298 if s.Message_ != nil { 4299 return *s.Message_ 4300 } 4301 return "" 4302} 4303 4304// OrigErr always returns nil, satisfies awserr.Error interface. 4305func (s *InvalidInput) OrigErr() error { 4306 return nil 4307} 4308 4309func (s *InvalidInput) Error() string { 4310 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 4311} 4312 4313// Status code returns the HTTP status code for the request's response error. 4314func (s *InvalidInput) StatusCode() int { 4315 return s.RespMetadata.StatusCode 4316} 4317 4318// RequestID returns the service's response RequestID for request. 4319func (s *InvalidInput) RequestID() string { 4320 return s.RespMetadata.RequestID 4321} 4322 4323type ListInstancesInput struct { 4324 _ struct{} `type:"structure"` 4325 4326 // The maximum number of instances that you want AWS Cloud Map to return in 4327 // the response to a ListInstances request. If you don't specify a value for 4328 // MaxResults, AWS Cloud Map returns up to 100 instances. 4329 MaxResults *int64 `min:"1" type:"integer"` 4330 4331 // For the first ListInstances request, omit this value. 4332 // 4333 // If more than MaxResults instances match the specified criteria, you can submit 4334 // another ListInstances request to get the next group of results. Specify the 4335 // value of NextToken from the previous response in the next request. 4336 NextToken *string `type:"string"` 4337 4338 // The ID of the service that you want to list instances for. 4339 // 4340 // ServiceId is a required field 4341 ServiceId *string `type:"string" required:"true"` 4342} 4343 4344// String returns the string representation 4345func (s ListInstancesInput) String() string { 4346 return awsutil.Prettify(s) 4347} 4348 4349// GoString returns the string representation 4350func (s ListInstancesInput) GoString() string { 4351 return s.String() 4352} 4353 4354// Validate inspects the fields of the type to determine if they are valid. 4355func (s *ListInstancesInput) Validate() error { 4356 invalidParams := request.ErrInvalidParams{Context: "ListInstancesInput"} 4357 if s.MaxResults != nil && *s.MaxResults < 1 { 4358 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 4359 } 4360 if s.ServiceId == nil { 4361 invalidParams.Add(request.NewErrParamRequired("ServiceId")) 4362 } 4363 4364 if invalidParams.Len() > 0 { 4365 return invalidParams 4366 } 4367 return nil 4368} 4369 4370// SetMaxResults sets the MaxResults field's value. 4371func (s *ListInstancesInput) SetMaxResults(v int64) *ListInstancesInput { 4372 s.MaxResults = &v 4373 return s 4374} 4375 4376// SetNextToken sets the NextToken field's value. 4377func (s *ListInstancesInput) SetNextToken(v string) *ListInstancesInput { 4378 s.NextToken = &v 4379 return s 4380} 4381 4382// SetServiceId sets the ServiceId field's value. 4383func (s *ListInstancesInput) SetServiceId(v string) *ListInstancesInput { 4384 s.ServiceId = &v 4385 return s 4386} 4387 4388type ListInstancesOutput struct { 4389 _ struct{} `type:"structure"` 4390 4391 // Summary information about the instances that are associated with the specified 4392 // service. 4393 Instances []*InstanceSummary `type:"list"` 4394 4395 // If more than MaxResults instances match the specified criteria, you can submit 4396 // another ListInstances request to get the next group of results. Specify the 4397 // value of NextToken from the previous response in the next request. 4398 NextToken *string `type:"string"` 4399} 4400 4401// String returns the string representation 4402func (s ListInstancesOutput) String() string { 4403 return awsutil.Prettify(s) 4404} 4405 4406// GoString returns the string representation 4407func (s ListInstancesOutput) GoString() string { 4408 return s.String() 4409} 4410 4411// SetInstances sets the Instances field's value. 4412func (s *ListInstancesOutput) SetInstances(v []*InstanceSummary) *ListInstancesOutput { 4413 s.Instances = v 4414 return s 4415} 4416 4417// SetNextToken sets the NextToken field's value. 4418func (s *ListInstancesOutput) SetNextToken(v string) *ListInstancesOutput { 4419 s.NextToken = &v 4420 return s 4421} 4422 4423type ListNamespacesInput struct { 4424 _ struct{} `type:"structure"` 4425 4426 // A complex type that contains specifications for the namespaces that you want 4427 // to list. 4428 // 4429 // If you specify more than one filter, a namespace must match all filters to 4430 // be returned by ListNamespaces. 4431 Filters []*NamespaceFilter `type:"list"` 4432 4433 // The maximum number of namespaces that you want AWS Cloud Map to return in 4434 // the response to a ListNamespaces request. If you don't specify a value for 4435 // MaxResults, AWS Cloud Map returns up to 100 namespaces. 4436 MaxResults *int64 `min:"1" type:"integer"` 4437 4438 // For the first ListNamespaces request, omit this value. 4439 // 4440 // If the response contains NextToken, submit another ListNamespaces request 4441 // to get the next group of results. Specify the value of NextToken from the 4442 // previous response in the next request. 4443 // 4444 // AWS Cloud Map gets MaxResults namespaces and then filters them based on the 4445 // specified criteria. It's possible that no namespaces in the first MaxResults 4446 // namespaces matched the specified criteria but that subsequent groups of MaxResults 4447 // namespaces do contain namespaces that match the criteria. 4448 NextToken *string `type:"string"` 4449} 4450 4451// String returns the string representation 4452func (s ListNamespacesInput) String() string { 4453 return awsutil.Prettify(s) 4454} 4455 4456// GoString returns the string representation 4457func (s ListNamespacesInput) GoString() string { 4458 return s.String() 4459} 4460 4461// Validate inspects the fields of the type to determine if they are valid. 4462func (s *ListNamespacesInput) Validate() error { 4463 invalidParams := request.ErrInvalidParams{Context: "ListNamespacesInput"} 4464 if s.MaxResults != nil && *s.MaxResults < 1 { 4465 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 4466 } 4467 if s.Filters != nil { 4468 for i, v := range s.Filters { 4469 if v == nil { 4470 continue 4471 } 4472 if err := v.Validate(); err != nil { 4473 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Filters", i), err.(request.ErrInvalidParams)) 4474 } 4475 } 4476 } 4477 4478 if invalidParams.Len() > 0 { 4479 return invalidParams 4480 } 4481 return nil 4482} 4483 4484// SetFilters sets the Filters field's value. 4485func (s *ListNamespacesInput) SetFilters(v []*NamespaceFilter) *ListNamespacesInput { 4486 s.Filters = v 4487 return s 4488} 4489 4490// SetMaxResults sets the MaxResults field's value. 4491func (s *ListNamespacesInput) SetMaxResults(v int64) *ListNamespacesInput { 4492 s.MaxResults = &v 4493 return s 4494} 4495 4496// SetNextToken sets the NextToken field's value. 4497func (s *ListNamespacesInput) SetNextToken(v string) *ListNamespacesInput { 4498 s.NextToken = &v 4499 return s 4500} 4501 4502type ListNamespacesOutput struct { 4503 _ struct{} `type:"structure"` 4504 4505 // An array that contains one NamespaceSummary object for each namespace that 4506 // matches the specified filter criteria. 4507 Namespaces []*NamespaceSummary `type:"list"` 4508 4509 // If the response contains NextToken, submit another ListNamespaces request 4510 // to get the next group of results. Specify the value of NextToken from the 4511 // previous response in the next request. 4512 // 4513 // AWS Cloud Map gets MaxResults namespaces and then filters them based on the 4514 // specified criteria. It's possible that no namespaces in the first MaxResults 4515 // namespaces matched the specified criteria but that subsequent groups of MaxResults 4516 // namespaces do contain namespaces that match the criteria. 4517 NextToken *string `type:"string"` 4518} 4519 4520// String returns the string representation 4521func (s ListNamespacesOutput) String() string { 4522 return awsutil.Prettify(s) 4523} 4524 4525// GoString returns the string representation 4526func (s ListNamespacesOutput) GoString() string { 4527 return s.String() 4528} 4529 4530// SetNamespaces sets the Namespaces field's value. 4531func (s *ListNamespacesOutput) SetNamespaces(v []*NamespaceSummary) *ListNamespacesOutput { 4532 s.Namespaces = v 4533 return s 4534} 4535 4536// SetNextToken sets the NextToken field's value. 4537func (s *ListNamespacesOutput) SetNextToken(v string) *ListNamespacesOutput { 4538 s.NextToken = &v 4539 return s 4540} 4541 4542type ListOperationsInput struct { 4543 _ struct{} `type:"structure"` 4544 4545 // A complex type that contains specifications for the operations that you want 4546 // to list, for example, operations that you started between a specified start 4547 // date and end date. 4548 // 4549 // If you specify more than one filter, an operation must match all filters 4550 // to be returned by ListOperations. 4551 Filters []*OperationFilter `type:"list"` 4552 4553 // The maximum number of items that you want AWS Cloud Map to return in the 4554 // response to a ListOperations request. If you don't specify a value for MaxResults, 4555 // AWS Cloud Map returns up to 100 operations. 4556 MaxResults *int64 `min:"1" type:"integer"` 4557 4558 // For the first ListOperations request, omit this value. 4559 // 4560 // If the response contains NextToken, submit another ListOperations request 4561 // to get the next group of results. Specify the value of NextToken from the 4562 // previous response in the next request. 4563 // 4564 // AWS Cloud Map gets MaxResults operations and then filters them based on the 4565 // specified criteria. It's possible that no operations in the first MaxResults 4566 // operations matched the specified criteria but that subsequent groups of MaxResults 4567 // operations do contain operations that match the criteria. 4568 NextToken *string `type:"string"` 4569} 4570 4571// String returns the string representation 4572func (s ListOperationsInput) String() string { 4573 return awsutil.Prettify(s) 4574} 4575 4576// GoString returns the string representation 4577func (s ListOperationsInput) GoString() string { 4578 return s.String() 4579} 4580 4581// Validate inspects the fields of the type to determine if they are valid. 4582func (s *ListOperationsInput) Validate() error { 4583 invalidParams := request.ErrInvalidParams{Context: "ListOperationsInput"} 4584 if s.MaxResults != nil && *s.MaxResults < 1 { 4585 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 4586 } 4587 if s.Filters != nil { 4588 for i, v := range s.Filters { 4589 if v == nil { 4590 continue 4591 } 4592 if err := v.Validate(); err != nil { 4593 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Filters", i), err.(request.ErrInvalidParams)) 4594 } 4595 } 4596 } 4597 4598 if invalidParams.Len() > 0 { 4599 return invalidParams 4600 } 4601 return nil 4602} 4603 4604// SetFilters sets the Filters field's value. 4605func (s *ListOperationsInput) SetFilters(v []*OperationFilter) *ListOperationsInput { 4606 s.Filters = v 4607 return s 4608} 4609 4610// SetMaxResults sets the MaxResults field's value. 4611func (s *ListOperationsInput) SetMaxResults(v int64) *ListOperationsInput { 4612 s.MaxResults = &v 4613 return s 4614} 4615 4616// SetNextToken sets the NextToken field's value. 4617func (s *ListOperationsInput) SetNextToken(v string) *ListOperationsInput { 4618 s.NextToken = &v 4619 return s 4620} 4621 4622type ListOperationsOutput struct { 4623 _ struct{} `type:"structure"` 4624 4625 // If the response contains NextToken, submit another ListOperations request 4626 // to get the next group of results. Specify the value of NextToken from the 4627 // previous response in the next request. 4628 // 4629 // AWS Cloud Map gets MaxResults operations and then filters them based on the 4630 // specified criteria. It's possible that no operations in the first MaxResults 4631 // operations matched the specified criteria but that subsequent groups of MaxResults 4632 // operations do contain operations that match the criteria. 4633 NextToken *string `type:"string"` 4634 4635 // Summary information about the operations that match the specified criteria. 4636 Operations []*OperationSummary `type:"list"` 4637} 4638 4639// String returns the string representation 4640func (s ListOperationsOutput) String() string { 4641 return awsutil.Prettify(s) 4642} 4643 4644// GoString returns the string representation 4645func (s ListOperationsOutput) GoString() string { 4646 return s.String() 4647} 4648 4649// SetNextToken sets the NextToken field's value. 4650func (s *ListOperationsOutput) SetNextToken(v string) *ListOperationsOutput { 4651 s.NextToken = &v 4652 return s 4653} 4654 4655// SetOperations sets the Operations field's value. 4656func (s *ListOperationsOutput) SetOperations(v []*OperationSummary) *ListOperationsOutput { 4657 s.Operations = v 4658 return s 4659} 4660 4661type ListServicesInput struct { 4662 _ struct{} `type:"structure"` 4663 4664 // A complex type that contains specifications for the namespaces that you want 4665 // to list services for. 4666 // 4667 // If you specify more than one filter, an operation must match all filters 4668 // to be returned by ListServices. 4669 Filters []*ServiceFilter `type:"list"` 4670 4671 // The maximum number of services that you want AWS Cloud Map to return in the 4672 // response to a ListServices request. If you don't specify a value for MaxResults, 4673 // AWS Cloud Map returns up to 100 services. 4674 MaxResults *int64 `min:"1" type:"integer"` 4675 4676 // For the first ListServices request, omit this value. 4677 // 4678 // If the response contains NextToken, submit another ListServices request to 4679 // get the next group of results. Specify the value of NextToken from the previous 4680 // response in the next request. 4681 // 4682 // AWS Cloud Map gets MaxResults services and then filters them based on the 4683 // specified criteria. It's possible that no services in the first MaxResults 4684 // services matched the specified criteria but that subsequent groups of MaxResults 4685 // services do contain services that match the criteria. 4686 NextToken *string `type:"string"` 4687} 4688 4689// String returns the string representation 4690func (s ListServicesInput) String() string { 4691 return awsutil.Prettify(s) 4692} 4693 4694// GoString returns the string representation 4695func (s ListServicesInput) GoString() string { 4696 return s.String() 4697} 4698 4699// Validate inspects the fields of the type to determine if they are valid. 4700func (s *ListServicesInput) Validate() error { 4701 invalidParams := request.ErrInvalidParams{Context: "ListServicesInput"} 4702 if s.MaxResults != nil && *s.MaxResults < 1 { 4703 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 4704 } 4705 if s.Filters != nil { 4706 for i, v := range s.Filters { 4707 if v == nil { 4708 continue 4709 } 4710 if err := v.Validate(); err != nil { 4711 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Filters", i), err.(request.ErrInvalidParams)) 4712 } 4713 } 4714 } 4715 4716 if invalidParams.Len() > 0 { 4717 return invalidParams 4718 } 4719 return nil 4720} 4721 4722// SetFilters sets the Filters field's value. 4723func (s *ListServicesInput) SetFilters(v []*ServiceFilter) *ListServicesInput { 4724 s.Filters = v 4725 return s 4726} 4727 4728// SetMaxResults sets the MaxResults field's value. 4729func (s *ListServicesInput) SetMaxResults(v int64) *ListServicesInput { 4730 s.MaxResults = &v 4731 return s 4732} 4733 4734// SetNextToken sets the NextToken field's value. 4735func (s *ListServicesInput) SetNextToken(v string) *ListServicesInput { 4736 s.NextToken = &v 4737 return s 4738} 4739 4740type ListServicesOutput struct { 4741 _ struct{} `type:"structure"` 4742 4743 // If the response contains NextToken, submit another ListServices request to 4744 // get the next group of results. Specify the value of NextToken from the previous 4745 // response in the next request. 4746 // 4747 // AWS Cloud Map gets MaxResults services and then filters them based on the 4748 // specified criteria. It's possible that no services in the first MaxResults 4749 // services matched the specified criteria but that subsequent groups of MaxResults 4750 // services do contain services that match the criteria. 4751 NextToken *string `type:"string"` 4752 4753 // An array that contains one ServiceSummary object for each service that matches 4754 // the specified filter criteria. 4755 Services []*ServiceSummary `type:"list"` 4756} 4757 4758// String returns the string representation 4759func (s ListServicesOutput) String() string { 4760 return awsutil.Prettify(s) 4761} 4762 4763// GoString returns the string representation 4764func (s ListServicesOutput) GoString() string { 4765 return s.String() 4766} 4767 4768// SetNextToken sets the NextToken field's value. 4769func (s *ListServicesOutput) SetNextToken(v string) *ListServicesOutput { 4770 s.NextToken = &v 4771 return s 4772} 4773 4774// SetServices sets the Services field's value. 4775func (s *ListServicesOutput) SetServices(v []*ServiceSummary) *ListServicesOutput { 4776 s.Services = v 4777 return s 4778} 4779 4780// A complex type that contains information about a specified namespace. 4781type Namespace struct { 4782 _ struct{} `type:"structure"` 4783 4784 // The Amazon Resource Name (ARN) that AWS Cloud Map assigns to the namespace 4785 // when you create it. 4786 Arn *string `type:"string"` 4787 4788 // The date that the namespace was created, in Unix date/time format and Coordinated 4789 // Universal Time (UTC). The value of CreateDate is accurate to milliseconds. 4790 // For example, the value 1516925490.087 represents Friday, January 26, 2018 4791 // 12:11:30.087 AM. 4792 CreateDate *time.Time `type:"timestamp"` 4793 4794 // A unique string that identifies the request and that allows failed requests 4795 // to be retried without the risk of executing an operation twice. 4796 CreatorRequestId *string `type:"string"` 4797 4798 // The description that you specify for the namespace when you create it. 4799 Description *string `type:"string"` 4800 4801 // The ID of a namespace. 4802 Id *string `type:"string"` 4803 4804 // The name of the namespace, such as example.com. 4805 Name *string `type:"string"` 4806 4807 // A complex type that contains information that's specific to the type of the 4808 // namespace. 4809 Properties *NamespaceProperties `type:"structure"` 4810 4811 // The number of services that are associated with the namespace. 4812 ServiceCount *int64 `type:"integer"` 4813 4814 // The type of the namespace. Valid values are DNS_PUBLIC and DNS_PRIVATE. 4815 Type *string `type:"string" enum:"NamespaceType"` 4816} 4817 4818// String returns the string representation 4819func (s Namespace) String() string { 4820 return awsutil.Prettify(s) 4821} 4822 4823// GoString returns the string representation 4824func (s Namespace) GoString() string { 4825 return s.String() 4826} 4827 4828// SetArn sets the Arn field's value. 4829func (s *Namespace) SetArn(v string) *Namespace { 4830 s.Arn = &v 4831 return s 4832} 4833 4834// SetCreateDate sets the CreateDate field's value. 4835func (s *Namespace) SetCreateDate(v time.Time) *Namespace { 4836 s.CreateDate = &v 4837 return s 4838} 4839 4840// SetCreatorRequestId sets the CreatorRequestId field's value. 4841func (s *Namespace) SetCreatorRequestId(v string) *Namespace { 4842 s.CreatorRequestId = &v 4843 return s 4844} 4845 4846// SetDescription sets the Description field's value. 4847func (s *Namespace) SetDescription(v string) *Namespace { 4848 s.Description = &v 4849 return s 4850} 4851 4852// SetId sets the Id field's value. 4853func (s *Namespace) SetId(v string) *Namespace { 4854 s.Id = &v 4855 return s 4856} 4857 4858// SetName sets the Name field's value. 4859func (s *Namespace) SetName(v string) *Namespace { 4860 s.Name = &v 4861 return s 4862} 4863 4864// SetProperties sets the Properties field's value. 4865func (s *Namespace) SetProperties(v *NamespaceProperties) *Namespace { 4866 s.Properties = v 4867 return s 4868} 4869 4870// SetServiceCount sets the ServiceCount field's value. 4871func (s *Namespace) SetServiceCount(v int64) *Namespace { 4872 s.ServiceCount = &v 4873 return s 4874} 4875 4876// SetType sets the Type field's value. 4877func (s *Namespace) SetType(v string) *Namespace { 4878 s.Type = &v 4879 return s 4880} 4881 4882// The namespace that you're trying to create already exists. 4883type NamespaceAlreadyExists struct { 4884 _ struct{} `type:"structure"` 4885 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 4886 4887 // The CreatorRequestId that was used to create the namespace. 4888 CreatorRequestId *string `type:"string"` 4889 4890 Message_ *string `locationName:"Message" type:"string"` 4891 4892 // The ID of the existing namespace. 4893 NamespaceId *string `type:"string"` 4894} 4895 4896// String returns the string representation 4897func (s NamespaceAlreadyExists) String() string { 4898 return awsutil.Prettify(s) 4899} 4900 4901// GoString returns the string representation 4902func (s NamespaceAlreadyExists) GoString() string { 4903 return s.String() 4904} 4905 4906func newErrorNamespaceAlreadyExists(v protocol.ResponseMetadata) error { 4907 return &NamespaceAlreadyExists{ 4908 RespMetadata: v, 4909 } 4910} 4911 4912// Code returns the exception type name. 4913func (s *NamespaceAlreadyExists) Code() string { 4914 return "NamespaceAlreadyExists" 4915} 4916 4917// Message returns the exception's message. 4918func (s *NamespaceAlreadyExists) Message() string { 4919 if s.Message_ != nil { 4920 return *s.Message_ 4921 } 4922 return "" 4923} 4924 4925// OrigErr always returns nil, satisfies awserr.Error interface. 4926func (s *NamespaceAlreadyExists) OrigErr() error { 4927 return nil 4928} 4929 4930func (s *NamespaceAlreadyExists) Error() string { 4931 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 4932} 4933 4934// Status code returns the HTTP status code for the request's response error. 4935func (s *NamespaceAlreadyExists) StatusCode() int { 4936 return s.RespMetadata.StatusCode 4937} 4938 4939// RequestID returns the service's response RequestID for request. 4940func (s *NamespaceAlreadyExists) RequestID() string { 4941 return s.RespMetadata.RequestID 4942} 4943 4944// A complex type that identifies the namespaces that you want to list. You 4945// can choose to list public or private namespaces. 4946type NamespaceFilter struct { 4947 _ struct{} `type:"structure"` 4948 4949 // The operator that you want to use to determine whether ListNamespaces returns 4950 // a namespace. Valid values for condition include: 4951 // 4952 // * EQ: When you specify EQ for the condition, you can choose to list only 4953 // public namespaces or private namespaces, but not both. EQ is the default 4954 // condition and can be omitted. 4955 // 4956 // * IN: When you specify IN for the condition, you can choose to list public 4957 // namespaces, private namespaces, or both. 4958 // 4959 // * BETWEEN: Not applicable 4960 Condition *string `type:"string" enum:"FilterCondition"` 4961 4962 // Specify TYPE. 4963 // 4964 // Name is a required field 4965 Name *string `type:"string" required:"true" enum:"NamespaceFilterName"` 4966 4967 // If you specify EQ for Condition, specify either DNS_PUBLIC or DNS_PRIVATE. 4968 // 4969 // If you specify IN for Condition, you can specify DNS_PUBLIC, DNS_PRIVATE, 4970 // or both. 4971 // 4972 // Values is a required field 4973 Values []*string `type:"list" required:"true"` 4974} 4975 4976// String returns the string representation 4977func (s NamespaceFilter) String() string { 4978 return awsutil.Prettify(s) 4979} 4980 4981// GoString returns the string representation 4982func (s NamespaceFilter) GoString() string { 4983 return s.String() 4984} 4985 4986// Validate inspects the fields of the type to determine if they are valid. 4987func (s *NamespaceFilter) Validate() error { 4988 invalidParams := request.ErrInvalidParams{Context: "NamespaceFilter"} 4989 if s.Name == nil { 4990 invalidParams.Add(request.NewErrParamRequired("Name")) 4991 } 4992 if s.Values == nil { 4993 invalidParams.Add(request.NewErrParamRequired("Values")) 4994 } 4995 4996 if invalidParams.Len() > 0 { 4997 return invalidParams 4998 } 4999 return nil 5000} 5001 5002// SetCondition sets the Condition field's value. 5003func (s *NamespaceFilter) SetCondition(v string) *NamespaceFilter { 5004 s.Condition = &v 5005 return s 5006} 5007 5008// SetName sets the Name field's value. 5009func (s *NamespaceFilter) SetName(v string) *NamespaceFilter { 5010 s.Name = &v 5011 return s 5012} 5013 5014// SetValues sets the Values field's value. 5015func (s *NamespaceFilter) SetValues(v []*string) *NamespaceFilter { 5016 s.Values = v 5017 return s 5018} 5019 5020// No namespace exists with the specified ID. 5021type NamespaceNotFound struct { 5022 _ struct{} `type:"structure"` 5023 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 5024 5025 Message_ *string `locationName:"Message" type:"string"` 5026} 5027 5028// String returns the string representation 5029func (s NamespaceNotFound) String() string { 5030 return awsutil.Prettify(s) 5031} 5032 5033// GoString returns the string representation 5034func (s NamespaceNotFound) GoString() string { 5035 return s.String() 5036} 5037 5038func newErrorNamespaceNotFound(v protocol.ResponseMetadata) error { 5039 return &NamespaceNotFound{ 5040 RespMetadata: v, 5041 } 5042} 5043 5044// Code returns the exception type name. 5045func (s *NamespaceNotFound) Code() string { 5046 return "NamespaceNotFound" 5047} 5048 5049// Message returns the exception's message. 5050func (s *NamespaceNotFound) Message() string { 5051 if s.Message_ != nil { 5052 return *s.Message_ 5053 } 5054 return "" 5055} 5056 5057// OrigErr always returns nil, satisfies awserr.Error interface. 5058func (s *NamespaceNotFound) OrigErr() error { 5059 return nil 5060} 5061 5062func (s *NamespaceNotFound) Error() string { 5063 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 5064} 5065 5066// Status code returns the HTTP status code for the request's response error. 5067func (s *NamespaceNotFound) StatusCode() int { 5068 return s.RespMetadata.StatusCode 5069} 5070 5071// RequestID returns the service's response RequestID for request. 5072func (s *NamespaceNotFound) RequestID() string { 5073 return s.RespMetadata.RequestID 5074} 5075 5076// A complex type that contains information that is specific to the namespace 5077// type. 5078type NamespaceProperties struct { 5079 _ struct{} `type:"structure"` 5080 5081 // A complex type that contains the ID for the Route 53 hosted zone that AWS 5082 // Cloud Map creates when you create a namespace. 5083 DnsProperties *DnsProperties `type:"structure"` 5084 5085 // A complex type that contains the name of an HTTP namespace. 5086 HttpProperties *HttpProperties `type:"structure"` 5087} 5088 5089// String returns the string representation 5090func (s NamespaceProperties) String() string { 5091 return awsutil.Prettify(s) 5092} 5093 5094// GoString returns the string representation 5095func (s NamespaceProperties) GoString() string { 5096 return s.String() 5097} 5098 5099// SetDnsProperties sets the DnsProperties field's value. 5100func (s *NamespaceProperties) SetDnsProperties(v *DnsProperties) *NamespaceProperties { 5101 s.DnsProperties = v 5102 return s 5103} 5104 5105// SetHttpProperties sets the HttpProperties field's value. 5106func (s *NamespaceProperties) SetHttpProperties(v *HttpProperties) *NamespaceProperties { 5107 s.HttpProperties = v 5108 return s 5109} 5110 5111// A complex type that contains information about a namespace. 5112type NamespaceSummary struct { 5113 _ struct{} `type:"structure"` 5114 5115 // The Amazon Resource Name (ARN) that AWS Cloud Map assigns to the namespace 5116 // when you create it. 5117 Arn *string `type:"string"` 5118 5119 // The date and time that the namespace was created. 5120 CreateDate *time.Time `type:"timestamp"` 5121 5122 // A description for the namespace. 5123 Description *string `type:"string"` 5124 5125 // The ID of the namespace. 5126 Id *string `type:"string"` 5127 5128 // The name of the namespace. When you create a namespace, AWS Cloud Map automatically 5129 // creates a Route 53 hosted zone that has the same name as the namespace. 5130 Name *string `type:"string"` 5131 5132 // A complex type that contains information that is specific to the namespace 5133 // type. 5134 Properties *NamespaceProperties `type:"structure"` 5135 5136 // The number of services that were created using the namespace. 5137 ServiceCount *int64 `type:"integer"` 5138 5139 // The type of the namespace, either public or private. 5140 Type *string `type:"string" enum:"NamespaceType"` 5141} 5142 5143// String returns the string representation 5144func (s NamespaceSummary) String() string { 5145 return awsutil.Prettify(s) 5146} 5147 5148// GoString returns the string representation 5149func (s NamespaceSummary) GoString() string { 5150 return s.String() 5151} 5152 5153// SetArn sets the Arn field's value. 5154func (s *NamespaceSummary) SetArn(v string) *NamespaceSummary { 5155 s.Arn = &v 5156 return s 5157} 5158 5159// SetCreateDate sets the CreateDate field's value. 5160func (s *NamespaceSummary) SetCreateDate(v time.Time) *NamespaceSummary { 5161 s.CreateDate = &v 5162 return s 5163} 5164 5165// SetDescription sets the Description field's value. 5166func (s *NamespaceSummary) SetDescription(v string) *NamespaceSummary { 5167 s.Description = &v 5168 return s 5169} 5170 5171// SetId sets the Id field's value. 5172func (s *NamespaceSummary) SetId(v string) *NamespaceSummary { 5173 s.Id = &v 5174 return s 5175} 5176 5177// SetName sets the Name field's value. 5178func (s *NamespaceSummary) SetName(v string) *NamespaceSummary { 5179 s.Name = &v 5180 return s 5181} 5182 5183// SetProperties sets the Properties field's value. 5184func (s *NamespaceSummary) SetProperties(v *NamespaceProperties) *NamespaceSummary { 5185 s.Properties = v 5186 return s 5187} 5188 5189// SetServiceCount sets the ServiceCount field's value. 5190func (s *NamespaceSummary) SetServiceCount(v int64) *NamespaceSummary { 5191 s.ServiceCount = &v 5192 return s 5193} 5194 5195// SetType sets the Type field's value. 5196func (s *NamespaceSummary) SetType(v string) *NamespaceSummary { 5197 s.Type = &v 5198 return s 5199} 5200 5201// A complex type that contains information about a specified operation. 5202type Operation struct { 5203 _ struct{} `type:"structure"` 5204 5205 // The date and time that the request was submitted, in Unix date/time format 5206 // and Coordinated Universal Time (UTC). The value of CreateDate is accurate 5207 // to milliseconds. For example, the value 1516925490.087 represents Friday, 5208 // January 26, 2018 12:11:30.087 AM. 5209 CreateDate *time.Time `type:"timestamp"` 5210 5211 // The code associated with ErrorMessage. Values for ErrorCode include the following: 5212 // 5213 // * ACCESS_DENIED 5214 // 5215 // * CANNOT_CREATE_HOSTED_ZONE 5216 // 5217 // * EXPIRED_TOKEN 5218 // 5219 // * HOSTED_ZONE_NOT_FOUND 5220 // 5221 // * INTERNAL_FAILURE 5222 // 5223 // * INVALID_CHANGE_BATCH 5224 // 5225 // * THROTTLED_REQUEST 5226 ErrorCode *string `type:"string"` 5227 5228 // If the value of Status is FAIL, the reason that the operation failed. 5229 ErrorMessage *string `type:"string"` 5230 5231 // The ID of the operation that you want to get information about. 5232 Id *string `type:"string"` 5233 5234 // The status of the operation. Values include the following: 5235 // 5236 // * SUBMITTED: This is the initial state immediately after you submit a 5237 // request. 5238 // 5239 // * PENDING: AWS Cloud Map is performing the operation. 5240 // 5241 // * SUCCESS: The operation succeeded. 5242 // 5243 // * FAIL: The operation failed. For the failure reason, see ErrorMessage. 5244 Status *string `type:"string" enum:"OperationStatus"` 5245 5246 // The name of the target entity that is associated with the operation: 5247 // 5248 // * NAMESPACE: The namespace ID is returned in the ResourceId property. 5249 // 5250 // * SERVICE: The service ID is returned in the ResourceId property. 5251 // 5252 // * INSTANCE: The instance ID is returned in the ResourceId property. 5253 Targets map[string]*string `type:"map"` 5254 5255 // The name of the operation that is associated with the specified ID. 5256 Type *string `type:"string" enum:"OperationType"` 5257 5258 // The date and time that the value of Status changed to the current value, 5259 // in Unix date/time format and Coordinated Universal Time (UTC). The value 5260 // of UpdateDate is accurate to milliseconds. For example, the value 1516925490.087 5261 // represents Friday, January 26, 2018 12:11:30.087 AM. 5262 UpdateDate *time.Time `type:"timestamp"` 5263} 5264 5265// String returns the string representation 5266func (s Operation) String() string { 5267 return awsutil.Prettify(s) 5268} 5269 5270// GoString returns the string representation 5271func (s Operation) GoString() string { 5272 return s.String() 5273} 5274 5275// SetCreateDate sets the CreateDate field's value. 5276func (s *Operation) SetCreateDate(v time.Time) *Operation { 5277 s.CreateDate = &v 5278 return s 5279} 5280 5281// SetErrorCode sets the ErrorCode field's value. 5282func (s *Operation) SetErrorCode(v string) *Operation { 5283 s.ErrorCode = &v 5284 return s 5285} 5286 5287// SetErrorMessage sets the ErrorMessage field's value. 5288func (s *Operation) SetErrorMessage(v string) *Operation { 5289 s.ErrorMessage = &v 5290 return s 5291} 5292 5293// SetId sets the Id field's value. 5294func (s *Operation) SetId(v string) *Operation { 5295 s.Id = &v 5296 return s 5297} 5298 5299// SetStatus sets the Status field's value. 5300func (s *Operation) SetStatus(v string) *Operation { 5301 s.Status = &v 5302 return s 5303} 5304 5305// SetTargets sets the Targets field's value. 5306func (s *Operation) SetTargets(v map[string]*string) *Operation { 5307 s.Targets = v 5308 return s 5309} 5310 5311// SetType sets the Type field's value. 5312func (s *Operation) SetType(v string) *Operation { 5313 s.Type = &v 5314 return s 5315} 5316 5317// SetUpdateDate sets the UpdateDate field's value. 5318func (s *Operation) SetUpdateDate(v time.Time) *Operation { 5319 s.UpdateDate = &v 5320 return s 5321} 5322 5323// A complex type that lets you select the operations that you want to list. 5324type OperationFilter struct { 5325 _ struct{} `type:"structure"` 5326 5327 // The operator that you want to use to determine whether an operation matches 5328 // the specified value. Valid values for condition include: 5329 // 5330 // * EQ: When you specify EQ for the condition, you can specify only one 5331 // value. EQ is supported for NAMESPACE_ID, SERVICE_ID, STATUS, and TYPE. 5332 // EQ is the default condition and can be omitted. 5333 // 5334 // * IN: When you specify IN for the condition, you can specify a list of 5335 // one or more values. IN is supported for STATUS and TYPE. An operation 5336 // must match one of the specified values to be returned in the response. 5337 // 5338 // * BETWEEN: Specify a start date and an end date in Unix date/time format 5339 // and Coordinated Universal Time (UTC). The start date must be the first 5340 // value. BETWEEN is supported for UPDATE_DATE. 5341 Condition *string `type:"string" enum:"FilterCondition"` 5342 5343 // Specify the operations that you want to get: 5344 // 5345 // * NAMESPACE_ID: Gets operations related to specified namespaces. 5346 // 5347 // * SERVICE_ID: Gets operations related to specified services. 5348 // 5349 // * STATUS: Gets operations based on the status of the operations: SUBMITTED, 5350 // PENDING, SUCCEED, or FAIL. 5351 // 5352 // * TYPE: Gets specified types of operation. 5353 // 5354 // * UPDATE_DATE: Gets operations that changed status during a specified 5355 // date/time range. 5356 // 5357 // Name is a required field 5358 Name *string `type:"string" required:"true" enum:"OperationFilterName"` 5359 5360 // Specify values that are applicable to the value that you specify for Name: 5361 // 5362 // * NAMESPACE_ID: Specify one namespace ID. 5363 // 5364 // * SERVICE_ID: Specify one service ID. 5365 // 5366 // * STATUS: Specify one or more statuses: SUBMITTED, PENDING, SUCCEED, or 5367 // FAIL. 5368 // 5369 // * TYPE: Specify one or more of the following types: CREATE_NAMESPACE, 5370 // DELETE_NAMESPACE, UPDATE_SERVICE, REGISTER_INSTANCE, or DEREGISTER_INSTANCE. 5371 // 5372 // * UPDATE_DATE: Specify a start date and an end date in Unix date/time 5373 // format and Coordinated Universal Time (UTC). The start date must be the 5374 // first value. 5375 // 5376 // Values is a required field 5377 Values []*string `type:"list" required:"true"` 5378} 5379 5380// String returns the string representation 5381func (s OperationFilter) String() string { 5382 return awsutil.Prettify(s) 5383} 5384 5385// GoString returns the string representation 5386func (s OperationFilter) GoString() string { 5387 return s.String() 5388} 5389 5390// Validate inspects the fields of the type to determine if they are valid. 5391func (s *OperationFilter) Validate() error { 5392 invalidParams := request.ErrInvalidParams{Context: "OperationFilter"} 5393 if s.Name == nil { 5394 invalidParams.Add(request.NewErrParamRequired("Name")) 5395 } 5396 if s.Values == nil { 5397 invalidParams.Add(request.NewErrParamRequired("Values")) 5398 } 5399 5400 if invalidParams.Len() > 0 { 5401 return invalidParams 5402 } 5403 return nil 5404} 5405 5406// SetCondition sets the Condition field's value. 5407func (s *OperationFilter) SetCondition(v string) *OperationFilter { 5408 s.Condition = &v 5409 return s 5410} 5411 5412// SetName sets the Name field's value. 5413func (s *OperationFilter) SetName(v string) *OperationFilter { 5414 s.Name = &v 5415 return s 5416} 5417 5418// SetValues sets the Values field's value. 5419func (s *OperationFilter) SetValues(v []*string) *OperationFilter { 5420 s.Values = v 5421 return s 5422} 5423 5424// No operation exists with the specified ID. 5425type OperationNotFound struct { 5426 _ struct{} `type:"structure"` 5427 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 5428 5429 Message_ *string `locationName:"Message" type:"string"` 5430} 5431 5432// String returns the string representation 5433func (s OperationNotFound) String() string { 5434 return awsutil.Prettify(s) 5435} 5436 5437// GoString returns the string representation 5438func (s OperationNotFound) GoString() string { 5439 return s.String() 5440} 5441 5442func newErrorOperationNotFound(v protocol.ResponseMetadata) error { 5443 return &OperationNotFound{ 5444 RespMetadata: v, 5445 } 5446} 5447 5448// Code returns the exception type name. 5449func (s *OperationNotFound) Code() string { 5450 return "OperationNotFound" 5451} 5452 5453// Message returns the exception's message. 5454func (s *OperationNotFound) Message() string { 5455 if s.Message_ != nil { 5456 return *s.Message_ 5457 } 5458 return "" 5459} 5460 5461// OrigErr always returns nil, satisfies awserr.Error interface. 5462func (s *OperationNotFound) OrigErr() error { 5463 return nil 5464} 5465 5466func (s *OperationNotFound) Error() string { 5467 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 5468} 5469 5470// Status code returns the HTTP status code for the request's response error. 5471func (s *OperationNotFound) StatusCode() int { 5472 return s.RespMetadata.StatusCode 5473} 5474 5475// RequestID returns the service's response RequestID for request. 5476func (s *OperationNotFound) RequestID() string { 5477 return s.RespMetadata.RequestID 5478} 5479 5480// A complex type that contains information about an operation that matches 5481// the criteria that you specified in a ListOperations request. 5482type OperationSummary struct { 5483 _ struct{} `type:"structure"` 5484 5485 // The ID for an operation. 5486 Id *string `type:"string"` 5487 5488 // The status of the operation. Values include the following: 5489 // 5490 // * SUBMITTED: This is the initial state immediately after you submit a 5491 // request. 5492 // 5493 // * PENDING: AWS Cloud Map is performing the operation. 5494 // 5495 // * SUCCESS: The operation succeeded. 5496 // 5497 // * FAIL: The operation failed. For the failure reason, see ErrorMessage. 5498 Status *string `type:"string" enum:"OperationStatus"` 5499} 5500 5501// String returns the string representation 5502func (s OperationSummary) String() string { 5503 return awsutil.Prettify(s) 5504} 5505 5506// GoString returns the string representation 5507func (s OperationSummary) GoString() string { 5508 return s.String() 5509} 5510 5511// SetId sets the Id field's value. 5512func (s *OperationSummary) SetId(v string) *OperationSummary { 5513 s.Id = &v 5514 return s 5515} 5516 5517// SetStatus sets the Status field's value. 5518func (s *OperationSummary) SetStatus(v string) *OperationSummary { 5519 s.Status = &v 5520 return s 5521} 5522 5523type RegisterInstanceInput struct { 5524 _ struct{} `type:"structure"` 5525 5526 // A string map that contains the following information for the service that 5527 // you specify in ServiceId: 5528 // 5529 // * The attributes that apply to the records that are defined in the service. 5530 // 5531 // * For each attribute, the applicable value. 5532 // 5533 // Supported attribute keys include the following: 5534 // 5535 // AWS_ALIAS_DNS_NAME 5536 // 5537 // If you want AWS Cloud Map to create an Amazon Route 53 alias record that 5538 // routes traffic to an Elastic Load Balancing load balancer, specify the DNS 5539 // name that is associated with the load balancer. For information about how 5540 // to get the DNS name, see "DNSName" in the topic AliasTarget (http://docs.aws.amazon.com/Route53/latest/APIReference/API_AliasTarget.html) 5541 // in the Route 53 API Reference. 5542 // 5543 // Note the following: 5544 // 5545 // * The configuration for the service that is specified by ServiceId must 5546 // include settings for an A record, an AAAA record, or both. 5547 // 5548 // * In the service that is specified by ServiceId, the value of RoutingPolicy 5549 // must be WEIGHTED. 5550 // 5551 // * If the service that is specified by ServiceId includes HealthCheckConfig 5552 // settings, AWS Cloud Map will create the Route 53 health check, but it 5553 // won't associate the health check with the alias record. 5554 // 5555 // * Auto naming currently doesn't support creating alias records that route 5556 // traffic to AWS resources other than ELB load balancers. 5557 // 5558 // * If you specify a value for AWS_ALIAS_DNS_NAME, don't specify values 5559 // for any of the AWS_INSTANCE attributes. 5560 // 5561 // AWS_INIT_HEALTH_STATUS 5562 // 5563 // If the service configuration includes HealthCheckCustomConfig, you can optionally 5564 // use AWS_INIT_HEALTH_STATUS to specify the initial status of the custom health 5565 // check, HEALTHY or UNHEALTHY. If you don't specify a value for AWS_INIT_HEALTH_STATUS, 5566 // the initial status is HEALTHY. 5567 // 5568 // AWS_INSTANCE_CNAME 5569 // 5570 // If the service configuration includes a CNAME record, the domain name that 5571 // you want Route 53 to return in response to DNS queries, for example, example.com. 5572 // 5573 // This value is required if the service specified by ServiceId includes settings 5574 // for an CNAME record. 5575 // 5576 // AWS_INSTANCE_IPV4 5577 // 5578 // If the service configuration includes an A record, the IPv4 address that 5579 // you want Route 53 to return in response to DNS queries, for example, 192.0.2.44. 5580 // 5581 // This value is required if the service specified by ServiceId includes settings 5582 // for an A record. If the service includes settings for an SRV record, you 5583 // must specify a value for AWS_INSTANCE_IPV4, AWS_INSTANCE_IPV6, or both. 5584 // 5585 // AWS_INSTANCE_IPV6 5586 // 5587 // If the service configuration includes an AAAA record, the IPv6 address that 5588 // you want Route 53 to return in response to DNS queries, for example, 2001:0db8:85a3:0000:0000:abcd:0001:2345. 5589 // 5590 // This value is required if the service specified by ServiceId includes settings 5591 // for an AAAA record. If the service includes settings for an SRV record, you 5592 // must specify a value for AWS_INSTANCE_IPV4, AWS_INSTANCE_IPV6, or both. 5593 // 5594 // AWS_INSTANCE_PORT 5595 // 5596 // If the service includes an SRV record, the value that you want Route 53 to 5597 // return for the port. 5598 // 5599 // If the service includes HealthCheckConfig, the port on the endpoint that 5600 // you want Route 53 to send requests to. 5601 // 5602 // This value is required if you specified settings for an SRV record when you 5603 // created the service. 5604 // 5605 // Custom attributes 5606 // 5607 // You can add up to 30 custom attributes. For each key-value pair, the maximum 5608 // length of the attribute name is 255 characters, and the maximum length of 5609 // the attribute value is 1,024 characters. 5610 // 5611 // Attributes is a required field 5612 Attributes map[string]*string `type:"map" required:"true"` 5613 5614 // A unique string that identifies the request and that allows failed RegisterInstance 5615 // requests to be retried without the risk of executing the operation twice. 5616 // You must use a unique CreatorRequestId string every time you submit a RegisterInstance 5617 // request if you're registering additional instances for the same namespace 5618 // and service. CreatorRequestId can be any unique string, for example, a date/time 5619 // stamp. 5620 CreatorRequestId *string `type:"string" idempotencyToken:"true"` 5621 5622 // An identifier that you want to associate with the instance. Note the following: 5623 // 5624 // * If the service that is specified by ServiceId includes settings for 5625 // an SRV record, the value of InstanceId is automatically included as part 5626 // of the value for the SRV record. For more information, see DnsRecord$Type. 5627 // 5628 // * You can use this value to update an existing instance. 5629 // 5630 // * To register a new instance, you must specify a value that is unique 5631 // among instances that you register by using the same service. 5632 // 5633 // * If you specify an existing InstanceId and ServiceId, AWS Cloud Map updates 5634 // the existing DNS records, if any. If there's also an existing health check, 5635 // AWS Cloud Map deletes the old health check and creates a new one. The 5636 // health check isn't deleted immediately, so it will still appear for a 5637 // while if you submit a ListHealthChecks request, for example. 5638 // 5639 // InstanceId is a required field 5640 InstanceId *string `type:"string" required:"true"` 5641 5642 // The ID of the service that you want to use for settings for the instance. 5643 // 5644 // ServiceId is a required field 5645 ServiceId *string `type:"string" required:"true"` 5646} 5647 5648// String returns the string representation 5649func (s RegisterInstanceInput) String() string { 5650 return awsutil.Prettify(s) 5651} 5652 5653// GoString returns the string representation 5654func (s RegisterInstanceInput) GoString() string { 5655 return s.String() 5656} 5657 5658// Validate inspects the fields of the type to determine if they are valid. 5659func (s *RegisterInstanceInput) Validate() error { 5660 invalidParams := request.ErrInvalidParams{Context: "RegisterInstanceInput"} 5661 if s.Attributes == nil { 5662 invalidParams.Add(request.NewErrParamRequired("Attributes")) 5663 } 5664 if s.InstanceId == nil { 5665 invalidParams.Add(request.NewErrParamRequired("InstanceId")) 5666 } 5667 if s.ServiceId == nil { 5668 invalidParams.Add(request.NewErrParamRequired("ServiceId")) 5669 } 5670 5671 if invalidParams.Len() > 0 { 5672 return invalidParams 5673 } 5674 return nil 5675} 5676 5677// SetAttributes sets the Attributes field's value. 5678func (s *RegisterInstanceInput) SetAttributes(v map[string]*string) *RegisterInstanceInput { 5679 s.Attributes = v 5680 return s 5681} 5682 5683// SetCreatorRequestId sets the CreatorRequestId field's value. 5684func (s *RegisterInstanceInput) SetCreatorRequestId(v string) *RegisterInstanceInput { 5685 s.CreatorRequestId = &v 5686 return s 5687} 5688 5689// SetInstanceId sets the InstanceId field's value. 5690func (s *RegisterInstanceInput) SetInstanceId(v string) *RegisterInstanceInput { 5691 s.InstanceId = &v 5692 return s 5693} 5694 5695// SetServiceId sets the ServiceId field's value. 5696func (s *RegisterInstanceInput) SetServiceId(v string) *RegisterInstanceInput { 5697 s.ServiceId = &v 5698 return s 5699} 5700 5701type RegisterInstanceOutput struct { 5702 _ struct{} `type:"structure"` 5703 5704 // A value that you can use to determine whether the request completed successfully. 5705 // To get the status of the operation, see GetOperation. 5706 OperationId *string `type:"string"` 5707} 5708 5709// String returns the string representation 5710func (s RegisterInstanceOutput) String() string { 5711 return awsutil.Prettify(s) 5712} 5713 5714// GoString returns the string representation 5715func (s RegisterInstanceOutput) GoString() string { 5716 return s.String() 5717} 5718 5719// SetOperationId sets the OperationId field's value. 5720func (s *RegisterInstanceOutput) SetOperationId(v string) *RegisterInstanceOutput { 5721 s.OperationId = &v 5722 return s 5723} 5724 5725// The specified resource can't be deleted because it contains other resources. 5726// For example, you can't delete a service that contains any instances. 5727type ResourceInUse struct { 5728 _ struct{} `type:"structure"` 5729 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 5730 5731 Message_ *string `locationName:"Message" type:"string"` 5732} 5733 5734// String returns the string representation 5735func (s ResourceInUse) String() string { 5736 return awsutil.Prettify(s) 5737} 5738 5739// GoString returns the string representation 5740func (s ResourceInUse) GoString() string { 5741 return s.String() 5742} 5743 5744func newErrorResourceInUse(v protocol.ResponseMetadata) error { 5745 return &ResourceInUse{ 5746 RespMetadata: v, 5747 } 5748} 5749 5750// Code returns the exception type name. 5751func (s *ResourceInUse) Code() string { 5752 return "ResourceInUse" 5753} 5754 5755// Message returns the exception's message. 5756func (s *ResourceInUse) Message() string { 5757 if s.Message_ != nil { 5758 return *s.Message_ 5759 } 5760 return "" 5761} 5762 5763// OrigErr always returns nil, satisfies awserr.Error interface. 5764func (s *ResourceInUse) OrigErr() error { 5765 return nil 5766} 5767 5768func (s *ResourceInUse) Error() string { 5769 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 5770} 5771 5772// Status code returns the HTTP status code for the request's response error. 5773func (s *ResourceInUse) StatusCode() int { 5774 return s.RespMetadata.StatusCode 5775} 5776 5777// RequestID returns the service's response RequestID for request. 5778func (s *ResourceInUse) RequestID() string { 5779 return s.RespMetadata.RequestID 5780} 5781 5782// The resource can't be created because you've reached the limit on the number 5783// of resources. 5784type ResourceLimitExceeded struct { 5785 _ struct{} `type:"structure"` 5786 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 5787 5788 Message_ *string `locationName:"Message" type:"string"` 5789} 5790 5791// String returns the string representation 5792func (s ResourceLimitExceeded) String() string { 5793 return awsutil.Prettify(s) 5794} 5795 5796// GoString returns the string representation 5797func (s ResourceLimitExceeded) GoString() string { 5798 return s.String() 5799} 5800 5801func newErrorResourceLimitExceeded(v protocol.ResponseMetadata) error { 5802 return &ResourceLimitExceeded{ 5803 RespMetadata: v, 5804 } 5805} 5806 5807// Code returns the exception type name. 5808func (s *ResourceLimitExceeded) Code() string { 5809 return "ResourceLimitExceeded" 5810} 5811 5812// Message returns the exception's message. 5813func (s *ResourceLimitExceeded) Message() string { 5814 if s.Message_ != nil { 5815 return *s.Message_ 5816 } 5817 return "" 5818} 5819 5820// OrigErr always returns nil, satisfies awserr.Error interface. 5821func (s *ResourceLimitExceeded) OrigErr() error { 5822 return nil 5823} 5824 5825func (s *ResourceLimitExceeded) Error() string { 5826 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 5827} 5828 5829// Status code returns the HTTP status code for the request's response error. 5830func (s *ResourceLimitExceeded) StatusCode() int { 5831 return s.RespMetadata.StatusCode 5832} 5833 5834// RequestID returns the service's response RequestID for request. 5835func (s *ResourceLimitExceeded) RequestID() string { 5836 return s.RespMetadata.RequestID 5837} 5838 5839// A complex type that contains information about the specified service. 5840type Service struct { 5841 _ struct{} `type:"structure"` 5842 5843 // The Amazon Resource Name (ARN) that AWS Cloud Map assigns to the service 5844 // when you create it. 5845 Arn *string `type:"string"` 5846 5847 // The date and time that the service was created, in Unix format and Coordinated 5848 // Universal Time (UTC). The value of CreateDate is accurate to milliseconds. 5849 // For example, the value 1516925490.087 represents Friday, January 26, 2018 5850 // 12:11:30.087 AM. 5851 CreateDate *time.Time `type:"timestamp"` 5852 5853 // A unique string that identifies the request and that allows failed requests 5854 // to be retried without the risk of executing the operation twice. CreatorRequestId 5855 // can be any unique string, for example, a date/time stamp. 5856 CreatorRequestId *string `type:"string"` 5857 5858 // The description of the service. 5859 Description *string `type:"string"` 5860 5861 // A complex type that contains information about the Route 53 DNS records that 5862 // you want AWS Cloud Map to create when you register an instance. 5863 DnsConfig *DnsConfig `type:"structure"` 5864 5865 // Public DNS namespaces only. A complex type that contains settings for an 5866 // optional health check. If you specify settings for a health check, AWS Cloud 5867 // Map associates the health check with the records that you specify in DnsConfig. 5868 // 5869 // For information about the charges for health checks, see Amazon Route 53 5870 // Pricing (http://aws.amazon.com/route53/pricing/). 5871 HealthCheckConfig *HealthCheckConfig `type:"structure"` 5872 5873 // A complex type that contains information about an optional custom health 5874 // check. 5875 // 5876 // If you specify a health check configuration, you can specify either HealthCheckCustomConfig 5877 // or HealthCheckConfig but not both. 5878 HealthCheckCustomConfig *HealthCheckCustomConfig `type:"structure"` 5879 5880 // The ID that AWS Cloud Map assigned to the service when you created it. 5881 Id *string `type:"string"` 5882 5883 // The number of instances that are currently associated with the service. Instances 5884 // that were previously associated with the service but that have been deleted 5885 // are not included in the count. 5886 InstanceCount *int64 `type:"integer"` 5887 5888 // The name of the service. 5889 Name *string `type:"string"` 5890 5891 // The ID of the namespace that was used to create the service. 5892 NamespaceId *string `type:"string"` 5893} 5894 5895// String returns the string representation 5896func (s Service) String() string { 5897 return awsutil.Prettify(s) 5898} 5899 5900// GoString returns the string representation 5901func (s Service) GoString() string { 5902 return s.String() 5903} 5904 5905// SetArn sets the Arn field's value. 5906func (s *Service) SetArn(v string) *Service { 5907 s.Arn = &v 5908 return s 5909} 5910 5911// SetCreateDate sets the CreateDate field's value. 5912func (s *Service) SetCreateDate(v time.Time) *Service { 5913 s.CreateDate = &v 5914 return s 5915} 5916 5917// SetCreatorRequestId sets the CreatorRequestId field's value. 5918func (s *Service) SetCreatorRequestId(v string) *Service { 5919 s.CreatorRequestId = &v 5920 return s 5921} 5922 5923// SetDescription sets the Description field's value. 5924func (s *Service) SetDescription(v string) *Service { 5925 s.Description = &v 5926 return s 5927} 5928 5929// SetDnsConfig sets the DnsConfig field's value. 5930func (s *Service) SetDnsConfig(v *DnsConfig) *Service { 5931 s.DnsConfig = v 5932 return s 5933} 5934 5935// SetHealthCheckConfig sets the HealthCheckConfig field's value. 5936func (s *Service) SetHealthCheckConfig(v *HealthCheckConfig) *Service { 5937 s.HealthCheckConfig = v 5938 return s 5939} 5940 5941// SetHealthCheckCustomConfig sets the HealthCheckCustomConfig field's value. 5942func (s *Service) SetHealthCheckCustomConfig(v *HealthCheckCustomConfig) *Service { 5943 s.HealthCheckCustomConfig = v 5944 return s 5945} 5946 5947// SetId sets the Id field's value. 5948func (s *Service) SetId(v string) *Service { 5949 s.Id = &v 5950 return s 5951} 5952 5953// SetInstanceCount sets the InstanceCount field's value. 5954func (s *Service) SetInstanceCount(v int64) *Service { 5955 s.InstanceCount = &v 5956 return s 5957} 5958 5959// SetName sets the Name field's value. 5960func (s *Service) SetName(v string) *Service { 5961 s.Name = &v 5962 return s 5963} 5964 5965// SetNamespaceId sets the NamespaceId field's value. 5966func (s *Service) SetNamespaceId(v string) *Service { 5967 s.NamespaceId = &v 5968 return s 5969} 5970 5971// The service can't be created because a service with the same name already 5972// exists. 5973type ServiceAlreadyExists struct { 5974 _ struct{} `type:"structure"` 5975 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 5976 5977 // The CreatorRequestId that was used to create the service. 5978 CreatorRequestId *string `type:"string"` 5979 5980 Message_ *string `locationName:"Message" type:"string"` 5981 5982 // The ID of the existing service. 5983 ServiceId *string `type:"string"` 5984} 5985 5986// String returns the string representation 5987func (s ServiceAlreadyExists) String() string { 5988 return awsutil.Prettify(s) 5989} 5990 5991// GoString returns the string representation 5992func (s ServiceAlreadyExists) GoString() string { 5993 return s.String() 5994} 5995 5996func newErrorServiceAlreadyExists(v protocol.ResponseMetadata) error { 5997 return &ServiceAlreadyExists{ 5998 RespMetadata: v, 5999 } 6000} 6001 6002// Code returns the exception type name. 6003func (s *ServiceAlreadyExists) Code() string { 6004 return "ServiceAlreadyExists" 6005} 6006 6007// Message returns the exception's message. 6008func (s *ServiceAlreadyExists) Message() string { 6009 if s.Message_ != nil { 6010 return *s.Message_ 6011 } 6012 return "" 6013} 6014 6015// OrigErr always returns nil, satisfies awserr.Error interface. 6016func (s *ServiceAlreadyExists) OrigErr() error { 6017 return nil 6018} 6019 6020func (s *ServiceAlreadyExists) Error() string { 6021 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 6022} 6023 6024// Status code returns the HTTP status code for the request's response error. 6025func (s *ServiceAlreadyExists) StatusCode() int { 6026 return s.RespMetadata.StatusCode 6027} 6028 6029// RequestID returns the service's response RequestID for request. 6030func (s *ServiceAlreadyExists) RequestID() string { 6031 return s.RespMetadata.RequestID 6032} 6033 6034// A complex type that contains changes to an existing service. 6035type ServiceChange struct { 6036 _ struct{} `type:"structure"` 6037 6038 // A description for the service. 6039 Description *string `type:"string"` 6040 6041 // A complex type that contains information about the Route 53 DNS records that 6042 // you want AWS Cloud Map to create when you register an instance. 6043 // 6044 // DnsConfig is a required field 6045 DnsConfig *DnsConfigChange `type:"structure" required:"true"` 6046 6047 // Public DNS namespaces only. A complex type that contains settings for an 6048 // optional health check. If you specify settings for a health check, AWS Cloud 6049 // Map associates the health check with the records that you specify in DnsConfig. 6050 // 6051 // If you specify a health check configuration, you can specify either HealthCheckCustomConfig 6052 // or HealthCheckConfig but not both. 6053 // 6054 // Health checks are basic Route 53 health checks that monitor an AWS endpoint. 6055 // For information about pricing for health checks, see Amazon Route 53 Pricing 6056 // (http://aws.amazon.com/route53/pricing/). 6057 // 6058 // Note the following about configuring health checks. 6059 // 6060 // A and AAAA records 6061 // 6062 // If DnsConfig includes configurations for both A and AAAA records, AWS Cloud 6063 // Map creates a health check that uses the IPv4 address to check the health 6064 // of the resource. If the endpoint that is specified by the IPv4 address is 6065 // unhealthy, Route 53 considers both the A and AAAA records to be unhealthy. 6066 // 6067 // CNAME records 6068 // 6069 // You can't specify settings for HealthCheckConfig when the DNSConfig includes 6070 // CNAME for the value of Type. If you do, the CreateService request will fail 6071 // with an InvalidInput error. 6072 // 6073 // Request interval 6074 // 6075 // A Route 53 health checker in each health-checking region sends a health check 6076 // request to an endpoint every 30 seconds. On average, your endpoint receives 6077 // a health check request about every two seconds. However, health checkers 6078 // don't coordinate with one another, so you'll sometimes see several requests 6079 // per second followed by a few seconds with no health checks at all. 6080 // 6081 // Health checking regions 6082 // 6083 // Health checkers perform checks from all Route 53 health-checking regions. 6084 // For a list of the current regions, see Regions (http://docs.aws.amazon.com/Route53/latest/APIReference/API_HealthCheckConfig.html#Route53-Type-HealthCheckConfig-Regions). 6085 // 6086 // Alias records 6087 // 6088 // When you register an instance, if you include the AWS_ALIAS_DNS_NAME attribute, 6089 // AWS Cloud Map creates a Route 53 alias record. Note the following: 6090 // 6091 // * Route 53 automatically sets EvaluateTargetHealth to true for alias records. 6092 // When EvaluateTargetHealth is true, the alias record inherits the health 6093 // of the referenced AWS resource. such as an ELB load balancer. For more 6094 // information, see EvaluateTargetHealth (http://docs.aws.amazon.com/Route53/latest/APIReference/API_AliasTarget.html#Route53-Type-AliasTarget-EvaluateTargetHealth). 6095 // 6096 // * If you include HealthCheckConfig and then use the service to register 6097 // an instance that creates an alias record, Route 53 doesn't create the 6098 // health check. 6099 // 6100 // Charges for health checks 6101 // 6102 // Health checks are basic Route 53 health checks that monitor an AWS endpoint. 6103 // For information about pricing for health checks, see Amazon Route 53 Pricing 6104 // (http://aws.amazon.com/route53/pricing/). 6105 HealthCheckConfig *HealthCheckConfig `type:"structure"` 6106} 6107 6108// String returns the string representation 6109func (s ServiceChange) String() string { 6110 return awsutil.Prettify(s) 6111} 6112 6113// GoString returns the string representation 6114func (s ServiceChange) GoString() string { 6115 return s.String() 6116} 6117 6118// Validate inspects the fields of the type to determine if they are valid. 6119func (s *ServiceChange) Validate() error { 6120 invalidParams := request.ErrInvalidParams{Context: "ServiceChange"} 6121 if s.DnsConfig == nil { 6122 invalidParams.Add(request.NewErrParamRequired("DnsConfig")) 6123 } 6124 if s.DnsConfig != nil { 6125 if err := s.DnsConfig.Validate(); err != nil { 6126 invalidParams.AddNested("DnsConfig", err.(request.ErrInvalidParams)) 6127 } 6128 } 6129 if s.HealthCheckConfig != nil { 6130 if err := s.HealthCheckConfig.Validate(); err != nil { 6131 invalidParams.AddNested("HealthCheckConfig", err.(request.ErrInvalidParams)) 6132 } 6133 } 6134 6135 if invalidParams.Len() > 0 { 6136 return invalidParams 6137 } 6138 return nil 6139} 6140 6141// SetDescription sets the Description field's value. 6142func (s *ServiceChange) SetDescription(v string) *ServiceChange { 6143 s.Description = &v 6144 return s 6145} 6146 6147// SetDnsConfig sets the DnsConfig field's value. 6148func (s *ServiceChange) SetDnsConfig(v *DnsConfigChange) *ServiceChange { 6149 s.DnsConfig = v 6150 return s 6151} 6152 6153// SetHealthCheckConfig sets the HealthCheckConfig field's value. 6154func (s *ServiceChange) SetHealthCheckConfig(v *HealthCheckConfig) *ServiceChange { 6155 s.HealthCheckConfig = v 6156 return s 6157} 6158 6159// A complex type that lets you specify the namespaces that you want to list 6160// services for. 6161type ServiceFilter struct { 6162 _ struct{} `type:"structure"` 6163 6164 // The operator that you want to use to determine whether a service is returned 6165 // by ListServices. Valid values for Condition include the following: 6166 // 6167 // * EQ: When you specify EQ, specify one namespace ID for Values. EQ is 6168 // the default condition and can be omitted. 6169 // 6170 // * IN: When you specify IN, specify a list of the IDs for the namespaces 6171 // that you want ListServices to return a list of services for. 6172 // 6173 // * BETWEEN: Not applicable. 6174 Condition *string `type:"string" enum:"FilterCondition"` 6175 6176 // Specify NAMESPACE_ID. 6177 // 6178 // Name is a required field 6179 Name *string `type:"string" required:"true" enum:"ServiceFilterName"` 6180 6181 // The values that are applicable to the value that you specify for Condition 6182 // to filter the list of services. 6183 // 6184 // Values is a required field 6185 Values []*string `type:"list" required:"true"` 6186} 6187 6188// String returns the string representation 6189func (s ServiceFilter) String() string { 6190 return awsutil.Prettify(s) 6191} 6192 6193// GoString returns the string representation 6194func (s ServiceFilter) GoString() string { 6195 return s.String() 6196} 6197 6198// Validate inspects the fields of the type to determine if they are valid. 6199func (s *ServiceFilter) Validate() error { 6200 invalidParams := request.ErrInvalidParams{Context: "ServiceFilter"} 6201 if s.Name == nil { 6202 invalidParams.Add(request.NewErrParamRequired("Name")) 6203 } 6204 if s.Values == nil { 6205 invalidParams.Add(request.NewErrParamRequired("Values")) 6206 } 6207 6208 if invalidParams.Len() > 0 { 6209 return invalidParams 6210 } 6211 return nil 6212} 6213 6214// SetCondition sets the Condition field's value. 6215func (s *ServiceFilter) SetCondition(v string) *ServiceFilter { 6216 s.Condition = &v 6217 return s 6218} 6219 6220// SetName sets the Name field's value. 6221func (s *ServiceFilter) SetName(v string) *ServiceFilter { 6222 s.Name = &v 6223 return s 6224} 6225 6226// SetValues sets the Values field's value. 6227func (s *ServiceFilter) SetValues(v []*string) *ServiceFilter { 6228 s.Values = v 6229 return s 6230} 6231 6232// No service exists with the specified ID. 6233type ServiceNotFound struct { 6234 _ struct{} `type:"structure"` 6235 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 6236 6237 Message_ *string `locationName:"Message" type:"string"` 6238} 6239 6240// String returns the string representation 6241func (s ServiceNotFound) String() string { 6242 return awsutil.Prettify(s) 6243} 6244 6245// GoString returns the string representation 6246func (s ServiceNotFound) GoString() string { 6247 return s.String() 6248} 6249 6250func newErrorServiceNotFound(v protocol.ResponseMetadata) error { 6251 return &ServiceNotFound{ 6252 RespMetadata: v, 6253 } 6254} 6255 6256// Code returns the exception type name. 6257func (s *ServiceNotFound) Code() string { 6258 return "ServiceNotFound" 6259} 6260 6261// Message returns the exception's message. 6262func (s *ServiceNotFound) Message() string { 6263 if s.Message_ != nil { 6264 return *s.Message_ 6265 } 6266 return "" 6267} 6268 6269// OrigErr always returns nil, satisfies awserr.Error interface. 6270func (s *ServiceNotFound) OrigErr() error { 6271 return nil 6272} 6273 6274func (s *ServiceNotFound) Error() string { 6275 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 6276} 6277 6278// Status code returns the HTTP status code for the request's response error. 6279func (s *ServiceNotFound) StatusCode() int { 6280 return s.RespMetadata.StatusCode 6281} 6282 6283// RequestID returns the service's response RequestID for request. 6284func (s *ServiceNotFound) RequestID() string { 6285 return s.RespMetadata.RequestID 6286} 6287 6288// A complex type that contains information about a specified service. 6289type ServiceSummary struct { 6290 _ struct{} `type:"structure"` 6291 6292 // The Amazon Resource Name (ARN) that AWS Cloud Map assigns to the service 6293 // when you create it. 6294 Arn *string `type:"string"` 6295 6296 // The date and time that the service was created. 6297 CreateDate *time.Time `type:"timestamp"` 6298 6299 // The description that you specify when you create the service. 6300 Description *string `type:"string"` 6301 6302 // A complex type that contains information about the Amazon Route 53 DNS records 6303 // that you want AWS Cloud Map to create when you register an instance. 6304 DnsConfig *DnsConfig `type:"structure"` 6305 6306 // Public DNS namespaces only. A complex type that contains settings for an 6307 // optional health check. If you specify settings for a health check, AWS Cloud 6308 // Map associates the health check with the records that you specify in DnsConfig. 6309 // 6310 // If you specify a health check configuration, you can specify either HealthCheckCustomConfig 6311 // or HealthCheckConfig but not both. 6312 // 6313 // Health checks are basic Route 53 health checks that monitor an AWS endpoint. 6314 // For information about pricing for health checks, see Amazon Route 53 Pricing 6315 // (http://aws.amazon.com/route53/pricing/). 6316 // 6317 // Note the following about configuring health checks. 6318 // 6319 // A and AAAA records 6320 // 6321 // If DnsConfig includes configurations for both A and AAAA records, AWS Cloud 6322 // Map creates a health check that uses the IPv4 address to check the health 6323 // of the resource. If the endpoint that is specified by the IPv4 address is 6324 // unhealthy, Route 53 considers both the A and AAAA records to be unhealthy. 6325 // 6326 // CNAME records 6327 // 6328 // You can't specify settings for HealthCheckConfig when the DNSConfig includes 6329 // CNAME for the value of Type. If you do, the CreateService request will fail 6330 // with an InvalidInput error. 6331 // 6332 // Request interval 6333 // 6334 // A Route 53 health checker in each health-checking region sends a health check 6335 // request to an endpoint every 30 seconds. On average, your endpoint receives 6336 // a health check request about every two seconds. However, health checkers 6337 // don't coordinate with one another, so you'll sometimes see several requests 6338 // per second followed by a few seconds with no health checks at all. 6339 // 6340 // Health checking regions 6341 // 6342 // Health checkers perform checks from all Route 53 health-checking regions. 6343 // For a list of the current regions, see Regions (http://docs.aws.amazon.com/Route53/latest/APIReference/API_HealthCheckConfig.html#Route53-Type-HealthCheckConfig-Regions). 6344 // 6345 // Alias records 6346 // 6347 // When you register an instance, if you include the AWS_ALIAS_DNS_NAME attribute, 6348 // AWS Cloud Map creates a Route 53 alias record. Note the following: 6349 // 6350 // * Route 53 automatically sets EvaluateTargetHealth to true for alias records. 6351 // When EvaluateTargetHealth is true, the alias record inherits the health 6352 // of the referenced AWS resource. such as an ELB load balancer. For more 6353 // information, see EvaluateTargetHealth (http://docs.aws.amazon.com/Route53/latest/APIReference/API_AliasTarget.html#Route53-Type-AliasTarget-EvaluateTargetHealth). 6354 // 6355 // * If you include HealthCheckConfig and then use the service to register 6356 // an instance that creates an alias record, Route 53 doesn't create the 6357 // health check. 6358 // 6359 // Charges for health checks 6360 // 6361 // Health checks are basic Route 53 health checks that monitor an AWS endpoint. 6362 // For information about pricing for health checks, see Amazon Route 53 Pricing 6363 // (http://aws.amazon.com/route53/pricing/). 6364 HealthCheckConfig *HealthCheckConfig `type:"structure"` 6365 6366 // A complex type that contains information about an optional custom health 6367 // check. A custom health check, which requires that you use a third-party health 6368 // checker to evaluate the health of your resources, is useful in the following 6369 // circumstances: 6370 // 6371 // * You can't use a health check that is defined by HealthCheckConfig because 6372 // the resource isn't available over the internet. For example, you can use 6373 // a custom health check when the instance is in an Amazon VPC. (To check 6374 // the health of resources in a VPC, the health checker must also be in the 6375 // VPC.) 6376 // 6377 // * You want to use a third-party health checker regardless of where your 6378 // resources are. 6379 // 6380 // If you specify a health check configuration, you can specify either HealthCheckCustomConfig 6381 // or HealthCheckConfig but not both. 6382 // 6383 // To change the status of a custom health check, submit an UpdateInstanceCustomHealthStatus 6384 // request. Cloud Map doesn't monitor the status of the resource, it just keeps 6385 // a record of the status specified in the most recent UpdateInstanceCustomHealthStatus 6386 // request. 6387 // 6388 // Here's how custom health checks work: 6389 // 6390 // You create a service and specify a value for FailureThreshold. 6391 // 6392 // The failure threshold indicates the number of 30-second intervals you want 6393 // AWS Cloud Map to wait between the time that your application sends an UpdateInstanceCustomHealthStatus 6394 // request and the time that AWS Cloud Map stops routing internet traffic to 6395 // the corresponding resource. 6396 // 6397 // You register an instance. 6398 // 6399 // You configure a third-party health checker to monitor the resource that is 6400 // associated with the new instance. 6401 // 6402 // AWS Cloud Map doesn't check the health of the resource directly. 6403 // 6404 // The third-party health-checker determines that the resource is unhealthy 6405 // and notifies your application. 6406 // 6407 // Your application submits an UpdateInstanceCustomHealthStatus request. 6408 // 6409 // AWS Cloud Map waits for (FailureThreshold x 30) seconds. 6410 // 6411 // If another UpdateInstanceCustomHealthStatus request doesn't arrive during 6412 // that time to change the status back to healthy, AWS Cloud Map stops routing 6413 // traffic to the resource. 6414 // 6415 // Note the following about configuring custom health checks. 6416 HealthCheckCustomConfig *HealthCheckCustomConfig `type:"structure"` 6417 6418 // The ID that AWS Cloud Map assigned to the service when you created it. 6419 Id *string `type:"string"` 6420 6421 // The number of instances that are currently associated with the service. Instances 6422 // that were previously associated with the service but that have been deleted 6423 // are not included in the count. 6424 InstanceCount *int64 `type:"integer"` 6425 6426 // The name of the service. 6427 Name *string `type:"string"` 6428} 6429 6430// String returns the string representation 6431func (s ServiceSummary) String() string { 6432 return awsutil.Prettify(s) 6433} 6434 6435// GoString returns the string representation 6436func (s ServiceSummary) GoString() string { 6437 return s.String() 6438} 6439 6440// SetArn sets the Arn field's value. 6441func (s *ServiceSummary) SetArn(v string) *ServiceSummary { 6442 s.Arn = &v 6443 return s 6444} 6445 6446// SetCreateDate sets the CreateDate field's value. 6447func (s *ServiceSummary) SetCreateDate(v time.Time) *ServiceSummary { 6448 s.CreateDate = &v 6449 return s 6450} 6451 6452// SetDescription sets the Description field's value. 6453func (s *ServiceSummary) SetDescription(v string) *ServiceSummary { 6454 s.Description = &v 6455 return s 6456} 6457 6458// SetDnsConfig sets the DnsConfig field's value. 6459func (s *ServiceSummary) SetDnsConfig(v *DnsConfig) *ServiceSummary { 6460 s.DnsConfig = v 6461 return s 6462} 6463 6464// SetHealthCheckConfig sets the HealthCheckConfig field's value. 6465func (s *ServiceSummary) SetHealthCheckConfig(v *HealthCheckConfig) *ServiceSummary { 6466 s.HealthCheckConfig = v 6467 return s 6468} 6469 6470// SetHealthCheckCustomConfig sets the HealthCheckCustomConfig field's value. 6471func (s *ServiceSummary) SetHealthCheckCustomConfig(v *HealthCheckCustomConfig) *ServiceSummary { 6472 s.HealthCheckCustomConfig = v 6473 return s 6474} 6475 6476// SetId sets the Id field's value. 6477func (s *ServiceSummary) SetId(v string) *ServiceSummary { 6478 s.Id = &v 6479 return s 6480} 6481 6482// SetInstanceCount sets the InstanceCount field's value. 6483func (s *ServiceSummary) SetInstanceCount(v int64) *ServiceSummary { 6484 s.InstanceCount = &v 6485 return s 6486} 6487 6488// SetName sets the Name field's value. 6489func (s *ServiceSummary) SetName(v string) *ServiceSummary { 6490 s.Name = &v 6491 return s 6492} 6493 6494type UpdateInstanceCustomHealthStatusInput struct { 6495 _ struct{} `type:"structure"` 6496 6497 // The ID of the instance that you want to change the health status for. 6498 // 6499 // InstanceId is a required field 6500 InstanceId *string `type:"string" required:"true"` 6501 6502 // The ID of the service that includes the configuration for the custom health 6503 // check that you want to change the status for. 6504 // 6505 // ServiceId is a required field 6506 ServiceId *string `type:"string" required:"true"` 6507 6508 // The new status of the instance, HEALTHY or UNHEALTHY. 6509 // 6510 // Status is a required field 6511 Status *string `type:"string" required:"true" enum:"CustomHealthStatus"` 6512} 6513 6514// String returns the string representation 6515func (s UpdateInstanceCustomHealthStatusInput) String() string { 6516 return awsutil.Prettify(s) 6517} 6518 6519// GoString returns the string representation 6520func (s UpdateInstanceCustomHealthStatusInput) GoString() string { 6521 return s.String() 6522} 6523 6524// Validate inspects the fields of the type to determine if they are valid. 6525func (s *UpdateInstanceCustomHealthStatusInput) Validate() error { 6526 invalidParams := request.ErrInvalidParams{Context: "UpdateInstanceCustomHealthStatusInput"} 6527 if s.InstanceId == nil { 6528 invalidParams.Add(request.NewErrParamRequired("InstanceId")) 6529 } 6530 if s.ServiceId == nil { 6531 invalidParams.Add(request.NewErrParamRequired("ServiceId")) 6532 } 6533 if s.Status == nil { 6534 invalidParams.Add(request.NewErrParamRequired("Status")) 6535 } 6536 6537 if invalidParams.Len() > 0 { 6538 return invalidParams 6539 } 6540 return nil 6541} 6542 6543// SetInstanceId sets the InstanceId field's value. 6544func (s *UpdateInstanceCustomHealthStatusInput) SetInstanceId(v string) *UpdateInstanceCustomHealthStatusInput { 6545 s.InstanceId = &v 6546 return s 6547} 6548 6549// SetServiceId sets the ServiceId field's value. 6550func (s *UpdateInstanceCustomHealthStatusInput) SetServiceId(v string) *UpdateInstanceCustomHealthStatusInput { 6551 s.ServiceId = &v 6552 return s 6553} 6554 6555// SetStatus sets the Status field's value. 6556func (s *UpdateInstanceCustomHealthStatusInput) SetStatus(v string) *UpdateInstanceCustomHealthStatusInput { 6557 s.Status = &v 6558 return s 6559} 6560 6561type UpdateInstanceCustomHealthStatusOutput struct { 6562 _ struct{} `type:"structure"` 6563} 6564 6565// String returns the string representation 6566func (s UpdateInstanceCustomHealthStatusOutput) String() string { 6567 return awsutil.Prettify(s) 6568} 6569 6570// GoString returns the string representation 6571func (s UpdateInstanceCustomHealthStatusOutput) GoString() string { 6572 return s.String() 6573} 6574 6575type UpdateServiceInput struct { 6576 _ struct{} `type:"structure"` 6577 6578 // The ID of the service that you want to update. 6579 // 6580 // Id is a required field 6581 Id *string `type:"string" required:"true"` 6582 6583 // A complex type that contains the new settings for the service. 6584 // 6585 // Service is a required field 6586 Service *ServiceChange `type:"structure" required:"true"` 6587} 6588 6589// String returns the string representation 6590func (s UpdateServiceInput) String() string { 6591 return awsutil.Prettify(s) 6592} 6593 6594// GoString returns the string representation 6595func (s UpdateServiceInput) GoString() string { 6596 return s.String() 6597} 6598 6599// Validate inspects the fields of the type to determine if they are valid. 6600func (s *UpdateServiceInput) Validate() error { 6601 invalidParams := request.ErrInvalidParams{Context: "UpdateServiceInput"} 6602 if s.Id == nil { 6603 invalidParams.Add(request.NewErrParamRequired("Id")) 6604 } 6605 if s.Service == nil { 6606 invalidParams.Add(request.NewErrParamRequired("Service")) 6607 } 6608 if s.Service != nil { 6609 if err := s.Service.Validate(); err != nil { 6610 invalidParams.AddNested("Service", err.(request.ErrInvalidParams)) 6611 } 6612 } 6613 6614 if invalidParams.Len() > 0 { 6615 return invalidParams 6616 } 6617 return nil 6618} 6619 6620// SetId sets the Id field's value. 6621func (s *UpdateServiceInput) SetId(v string) *UpdateServiceInput { 6622 s.Id = &v 6623 return s 6624} 6625 6626// SetService sets the Service field's value. 6627func (s *UpdateServiceInput) SetService(v *ServiceChange) *UpdateServiceInput { 6628 s.Service = v 6629 return s 6630} 6631 6632type UpdateServiceOutput struct { 6633 _ struct{} `type:"structure"` 6634 6635 // A value that you can use to determine whether the request completed successfully. 6636 // To get the status of the operation, see GetOperation. 6637 OperationId *string `type:"string"` 6638} 6639 6640// String returns the string representation 6641func (s UpdateServiceOutput) String() string { 6642 return awsutil.Prettify(s) 6643} 6644 6645// GoString returns the string representation 6646func (s UpdateServiceOutput) GoString() string { 6647 return s.String() 6648} 6649 6650// SetOperationId sets the OperationId field's value. 6651func (s *UpdateServiceOutput) SetOperationId(v string) *UpdateServiceOutput { 6652 s.OperationId = &v 6653 return s 6654} 6655 6656const ( 6657 // CustomHealthStatusHealthy is a CustomHealthStatus enum value 6658 CustomHealthStatusHealthy = "HEALTHY" 6659 6660 // CustomHealthStatusUnhealthy is a CustomHealthStatus enum value 6661 CustomHealthStatusUnhealthy = "UNHEALTHY" 6662) 6663 6664const ( 6665 // FilterConditionEq is a FilterCondition enum value 6666 FilterConditionEq = "EQ" 6667 6668 // FilterConditionIn is a FilterCondition enum value 6669 FilterConditionIn = "IN" 6670 6671 // FilterConditionBetween is a FilterCondition enum value 6672 FilterConditionBetween = "BETWEEN" 6673) 6674 6675const ( 6676 // HealthCheckTypeHttp is a HealthCheckType enum value 6677 HealthCheckTypeHttp = "HTTP" 6678 6679 // HealthCheckTypeHttps is a HealthCheckType enum value 6680 HealthCheckTypeHttps = "HTTPS" 6681 6682 // HealthCheckTypeTcp is a HealthCheckType enum value 6683 HealthCheckTypeTcp = "TCP" 6684) 6685 6686const ( 6687 // HealthStatusHealthy is a HealthStatus enum value 6688 HealthStatusHealthy = "HEALTHY" 6689 6690 // HealthStatusUnhealthy is a HealthStatus enum value 6691 HealthStatusUnhealthy = "UNHEALTHY" 6692 6693 // HealthStatusUnknown is a HealthStatus enum value 6694 HealthStatusUnknown = "UNKNOWN" 6695) 6696 6697const ( 6698 // HealthStatusFilterHealthy is a HealthStatusFilter enum value 6699 HealthStatusFilterHealthy = "HEALTHY" 6700 6701 // HealthStatusFilterUnhealthy is a HealthStatusFilter enum value 6702 HealthStatusFilterUnhealthy = "UNHEALTHY" 6703 6704 // HealthStatusFilterAll is a HealthStatusFilter enum value 6705 HealthStatusFilterAll = "ALL" 6706) 6707 6708const ( 6709 // NamespaceFilterNameType is a NamespaceFilterName enum value 6710 NamespaceFilterNameType = "TYPE" 6711) 6712 6713const ( 6714 // NamespaceTypeDnsPublic is a NamespaceType enum value 6715 NamespaceTypeDnsPublic = "DNS_PUBLIC" 6716 6717 // NamespaceTypeDnsPrivate is a NamespaceType enum value 6718 NamespaceTypeDnsPrivate = "DNS_PRIVATE" 6719 6720 // NamespaceTypeHttp is a NamespaceType enum value 6721 NamespaceTypeHttp = "HTTP" 6722) 6723 6724const ( 6725 // OperationFilterNameNamespaceId is a OperationFilterName enum value 6726 OperationFilterNameNamespaceId = "NAMESPACE_ID" 6727 6728 // OperationFilterNameServiceId is a OperationFilterName enum value 6729 OperationFilterNameServiceId = "SERVICE_ID" 6730 6731 // OperationFilterNameStatus is a OperationFilterName enum value 6732 OperationFilterNameStatus = "STATUS" 6733 6734 // OperationFilterNameType is a OperationFilterName enum value 6735 OperationFilterNameType = "TYPE" 6736 6737 // OperationFilterNameUpdateDate is a OperationFilterName enum value 6738 OperationFilterNameUpdateDate = "UPDATE_DATE" 6739) 6740 6741const ( 6742 // OperationStatusSubmitted is a OperationStatus enum value 6743 OperationStatusSubmitted = "SUBMITTED" 6744 6745 // OperationStatusPending is a OperationStatus enum value 6746 OperationStatusPending = "PENDING" 6747 6748 // OperationStatusSuccess is a OperationStatus enum value 6749 OperationStatusSuccess = "SUCCESS" 6750 6751 // OperationStatusFail is a OperationStatus enum value 6752 OperationStatusFail = "FAIL" 6753) 6754 6755const ( 6756 // OperationTargetTypeNamespace is a OperationTargetType enum value 6757 OperationTargetTypeNamespace = "NAMESPACE" 6758 6759 // OperationTargetTypeService is a OperationTargetType enum value 6760 OperationTargetTypeService = "SERVICE" 6761 6762 // OperationTargetTypeInstance is a OperationTargetType enum value 6763 OperationTargetTypeInstance = "INSTANCE" 6764) 6765 6766const ( 6767 // OperationTypeCreateNamespace is a OperationType enum value 6768 OperationTypeCreateNamespace = "CREATE_NAMESPACE" 6769 6770 // OperationTypeDeleteNamespace is a OperationType enum value 6771 OperationTypeDeleteNamespace = "DELETE_NAMESPACE" 6772 6773 // OperationTypeUpdateService is a OperationType enum value 6774 OperationTypeUpdateService = "UPDATE_SERVICE" 6775 6776 // OperationTypeRegisterInstance is a OperationType enum value 6777 OperationTypeRegisterInstance = "REGISTER_INSTANCE" 6778 6779 // OperationTypeDeregisterInstance is a OperationType enum value 6780 OperationTypeDeregisterInstance = "DEREGISTER_INSTANCE" 6781) 6782 6783const ( 6784 // RecordTypeSrv is a RecordType enum value 6785 RecordTypeSrv = "SRV" 6786 6787 // RecordTypeA is a RecordType enum value 6788 RecordTypeA = "A" 6789 6790 // RecordTypeAaaa is a RecordType enum value 6791 RecordTypeAaaa = "AAAA" 6792 6793 // RecordTypeCname is a RecordType enum value 6794 RecordTypeCname = "CNAME" 6795) 6796 6797const ( 6798 // RoutingPolicyMultivalue is a RoutingPolicy enum value 6799 RoutingPolicyMultivalue = "MULTIVALUE" 6800 6801 // RoutingPolicyWeighted is a RoutingPolicy enum value 6802 RoutingPolicyWeighted = "WEIGHTED" 6803) 6804 6805const ( 6806 // ServiceFilterNameNamespaceId is a ServiceFilterName enum value 6807 ServiceFilterNameNamespaceId = "NAMESPACE_ID" 6808) 6809