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