diff --git a/ChangeLog.txt b/ChangeLog.txt index bb4bce6b50..d9dc4f12d5 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -1,3 +1,7 @@ +2024-10-25 Version: v1.63.39 +- Generated 2017-11-10 for `Ens`. +undefined + 2024-10-24 Version: v1.63.38 - Generated 2017-05-25 for `Dypnsapi`. - Publish sdk. diff --git a/services/ens/associate_ha_vip.go b/services/ens/associate_ha_vip.go new file mode 100644 index 0000000000..954aea8de7 --- /dev/null +++ b/services/ens/associate_ha_vip.go @@ -0,0 +1,101 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// AssociateHaVip invokes the ens.AssociateHaVip API synchronously +func (client *Client) AssociateHaVip(request *AssociateHaVipRequest) (response *AssociateHaVipResponse, err error) { + response = CreateAssociateHaVipResponse() + err = client.DoAction(request, response) + return +} + +// AssociateHaVipWithChan invokes the ens.AssociateHaVip API asynchronously +func (client *Client) AssociateHaVipWithChan(request *AssociateHaVipRequest) (<-chan *AssociateHaVipResponse, <-chan error) { + responseChan := make(chan *AssociateHaVipResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.AssociateHaVip(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// AssociateHaVipWithCallback invokes the ens.AssociateHaVip API asynchronously +func (client *Client) AssociateHaVipWithCallback(request *AssociateHaVipRequest, callback func(response *AssociateHaVipResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *AssociateHaVipResponse + var err error + defer close(result) + response, err = client.AssociateHaVip(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// AssociateHaVipRequest is the request struct for api AssociateHaVip +type AssociateHaVipRequest struct { + *requests.RpcRequest + InstanceType string `position:"Query" name:"InstanceType"` + HaVipId string `position:"Query" name:"HaVipId"` + InstanceId string `position:"Query" name:"InstanceId"` +} + +// AssociateHaVipResponse is the response struct for api AssociateHaVip +type AssociateHaVipResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` +} + +// CreateAssociateHaVipRequest creates a request to invoke AssociateHaVip API +func CreateAssociateHaVipRequest() (request *AssociateHaVipRequest) { + request = &AssociateHaVipRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "AssociateHaVip", "ens", "openAPI") + request.Method = requests.POST + return +} + +// CreateAssociateHaVipResponse creates a response to parse from AssociateHaVip response +func CreateAssociateHaVipResponse() (response *AssociateHaVipResponse) { + response = &AssociateHaVipResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/attach_network_interface.go b/services/ens/attach_network_interface.go new file mode 100644 index 0000000000..cb02367a4c --- /dev/null +++ b/services/ens/attach_network_interface.go @@ -0,0 +1,100 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// AttachNetworkInterface invokes the ens.AttachNetworkInterface API synchronously +func (client *Client) AttachNetworkInterface(request *AttachNetworkInterfaceRequest) (response *AttachNetworkInterfaceResponse, err error) { + response = CreateAttachNetworkInterfaceResponse() + err = client.DoAction(request, response) + return +} + +// AttachNetworkInterfaceWithChan invokes the ens.AttachNetworkInterface API asynchronously +func (client *Client) AttachNetworkInterfaceWithChan(request *AttachNetworkInterfaceRequest) (<-chan *AttachNetworkInterfaceResponse, <-chan error) { + responseChan := make(chan *AttachNetworkInterfaceResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.AttachNetworkInterface(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// AttachNetworkInterfaceWithCallback invokes the ens.AttachNetworkInterface API asynchronously +func (client *Client) AttachNetworkInterfaceWithCallback(request *AttachNetworkInterfaceRequest, callback func(response *AttachNetworkInterfaceResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *AttachNetworkInterfaceResponse + var err error + defer close(result) + response, err = client.AttachNetworkInterface(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// AttachNetworkInterfaceRequest is the request struct for api AttachNetworkInterface +type AttachNetworkInterfaceRequest struct { + *requests.RpcRequest + InstanceId string `position:"Query" name:"InstanceId"` + NetworkInterfaceId string `position:"Query" name:"NetworkInterfaceId"` +} + +// AttachNetworkInterfaceResponse is the response struct for api AttachNetworkInterface +type AttachNetworkInterfaceResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` +} + +// CreateAttachNetworkInterfaceRequest creates a request to invoke AttachNetworkInterface API +func CreateAttachNetworkInterfaceRequest() (request *AttachNetworkInterfaceRequest) { + request = &AttachNetworkInterfaceRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "AttachNetworkInterface", "ens", "openAPI") + request.Method = requests.POST + return +} + +// CreateAttachNetworkInterfaceResponse creates a response to parse from AttachNetworkInterface response +func CreateAttachNetworkInterfaceResponse() (response *AttachNetworkInterfaceResponse) { + response = &AttachNetworkInterfaceResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/create_cluster.go b/services/ens/create_cluster.go new file mode 100644 index 0000000000..ca4f765e2a --- /dev/null +++ b/services/ens/create_cluster.go @@ -0,0 +1,101 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// CreateCluster invokes the ens.CreateCluster API synchronously +func (client *Client) CreateCluster(request *CreateClusterRequest) (response *CreateClusterResponse, err error) { + response = CreateCreateClusterResponse() + err = client.DoAction(request, response) + return +} + +// CreateClusterWithChan invokes the ens.CreateCluster API asynchronously +func (client *Client) CreateClusterWithChan(request *CreateClusterRequest) (<-chan *CreateClusterResponse, <-chan error) { + responseChan := make(chan *CreateClusterResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.CreateCluster(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// CreateClusterWithCallback invokes the ens.CreateCluster API asynchronously +func (client *Client) CreateClusterWithCallback(request *CreateClusterRequest, callback func(response *CreateClusterResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *CreateClusterResponse + var err error + defer close(result) + response, err = client.CreateCluster(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// CreateClusterRequest is the request struct for api CreateCluster +type CreateClusterRequest struct { + *requests.RpcRequest + ClusterVersion string `position:"Query" name:"ClusterVersion"` + Name string `position:"Query" name:"Name"` +} + +// CreateClusterResponse is the response struct for api CreateCluster +type CreateClusterResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ClusterId string `json:"ClusterId" xml:"ClusterId"` +} + +// CreateCreateClusterRequest creates a request to invoke CreateCluster API +func CreateCreateClusterRequest() (request *CreateClusterRequest) { + request = &CreateClusterRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "CreateCluster", "ens", "openAPI") + request.Method = requests.POST + return +} + +// CreateCreateClusterResponse creates a response to parse from CreateCluster response +func CreateCreateClusterResponse() (response *CreateClusterResponse) { + response = &CreateClusterResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/create_disk.go b/services/ens/create_disk.go index 4c7310b8ab..c6c425d877 100644 --- a/services/ens/create_disk.go +++ b/services/ens/create_disk.go @@ -73,6 +73,7 @@ type CreateDiskRequest struct { *requests.RpcRequest DiskName string `position:"Query" name:"DiskName"` EnsRegionId string `position:"Query" name:"EnsRegionId"` + Tag *[]CreateDiskTag `position:"Query" name:"Tag" type:"Repeated"` Size string `position:"Query" name:"Size"` SnapshotId string `position:"Query" name:"SnapshotId"` InstanceChargeType string `position:"Query" name:"InstanceChargeType"` @@ -81,6 +82,12 @@ type CreateDiskRequest struct { KMSKeyId string `position:"Query" name:"KMSKeyId"` } +// CreateDiskTag is a repeated param struct in CreateDiskRequest +type CreateDiskTag struct { + Value string `name:"Value"` + Key string `name:"Key"` +} + // CreateDiskResponse is the response struct for api CreateDisk type CreateDiskResponse struct { *responses.BaseResponse diff --git a/services/ens/create_eip_instance.go b/services/ens/create_eip_instance.go index 07b1d63acd..547f3e1652 100644 --- a/services/ens/create_eip_instance.go +++ b/services/ens/create_eip_instance.go @@ -71,13 +71,20 @@ func (client *Client) CreateEipInstanceWithCallback(request *CreateEipInstanceRe // CreateEipInstanceRequest is the request struct for api CreateEipInstance type CreateEipInstanceRequest struct { *requests.RpcRequest - Isp string `position:"Query" name:"Isp"` - EnsRegionId string `position:"Query" name:"EnsRegionId"` - InternetChargeType string `position:"Query" name:"InternetChargeType"` - Name string `position:"Query" name:"Name"` - Description string `position:"Query" name:"Description"` - InstanceChargeType string `position:"Query" name:"InstanceChargeType"` - Bandwidth requests.Integer `position:"Query" name:"Bandwidth"` + Isp string `position:"Query" name:"Isp"` + EnsRegionId string `position:"Query" name:"EnsRegionId"` + Tag *[]CreateEipInstanceTag `position:"Query" name:"Tag" type:"Repeated"` + InternetChargeType string `position:"Query" name:"InternetChargeType"` + Name string `position:"Query" name:"Name"` + Description string `position:"Query" name:"Description"` + InstanceChargeType string `position:"Query" name:"InstanceChargeType"` + Bandwidth requests.Integer `position:"Query" name:"Bandwidth"` +} + +// CreateEipInstanceTag is a repeated param struct in CreateEipInstanceRequest +type CreateEipInstanceTag struct { + Value string `name:"Value"` + Key string `name:"Key"` } // CreateEipInstanceResponse is the response struct for api CreateEipInstance diff --git a/services/ens/create_nat_gateway.go b/services/ens/create_nat_gateway.go index 23068f0d1b..37bb9f1957 100644 --- a/services/ens/create_nat_gateway.go +++ b/services/ens/create_nat_gateway.go @@ -71,11 +71,18 @@ func (client *Client) CreateNatGatewayWithCallback(request *CreateNatGatewayRequ // CreateNatGatewayRequest is the request struct for api CreateNatGateway type CreateNatGatewayRequest struct { *requests.RpcRequest - EnsRegionId string `position:"Query" name:"EnsRegionId"` - InstanceType string `position:"Query" name:"InstanceType"` - VSwitchId string `position:"Query" name:"VSwitchId"` - Name string `position:"Query" name:"Name"` - NetworkId string `position:"Query" name:"NetworkId"` + EnsRegionId string `position:"Query" name:"EnsRegionId"` + InstanceType string `position:"Query" name:"InstanceType"` + Tag *[]CreateNatGatewayTag `position:"Query" name:"Tag" type:"Repeated"` + VSwitchId string `position:"Query" name:"VSwitchId"` + Name string `position:"Query" name:"Name"` + NetworkId string `position:"Query" name:"NetworkId"` +} + +// CreateNatGatewayTag is a repeated param struct in CreateNatGatewayRequest +type CreateNatGatewayTag struct { + Value string `name:"Value"` + Key string `name:"Key"` } // CreateNatGatewayResponse is the response struct for api CreateNatGateway diff --git a/services/ens/create_network.go b/services/ens/create_network.go index 2e08498a87..af7124aa02 100644 --- a/services/ens/create_network.go +++ b/services/ens/create_network.go @@ -71,10 +71,17 @@ func (client *Client) CreateNetworkWithCallback(request *CreateNetworkRequest, c // CreateNetworkRequest is the request struct for api CreateNetwork type CreateNetworkRequest struct { *requests.RpcRequest - Description string `position:"Query" name:"Description"` - EnsRegionId string `position:"Query" name:"EnsRegionId"` - NetworkName string `position:"Query" name:"NetworkName"` - CidrBlock string `position:"Query" name:"CidrBlock"` + Description string `position:"Query" name:"Description"` + EnsRegionId string `position:"Query" name:"EnsRegionId"` + NetworkName string `position:"Query" name:"NetworkName"` + Tag *[]CreateNetworkTag `position:"Query" name:"Tag" type:"Repeated"` + CidrBlock string `position:"Query" name:"CidrBlock"` +} + +// CreateNetworkTag is a repeated param struct in CreateNetworkRequest +type CreateNetworkTag struct { + Value string `name:"Value"` + Key string `name:"Key"` } // CreateNetworkResponse is the response struct for api CreateNetwork diff --git a/services/ens/create_v_switch.go b/services/ens/create_v_switch.go index 483d1bbc5d..eef8d96d5a 100644 --- a/services/ens/create_v_switch.go +++ b/services/ens/create_v_switch.go @@ -71,11 +71,18 @@ func (client *Client) CreateVSwitchWithCallback(request *CreateVSwitchRequest, c // CreateVSwitchRequest is the request struct for api CreateVSwitch type CreateVSwitchRequest struct { *requests.RpcRequest - Description string `position:"Query" name:"Description"` - EnsRegionId string `position:"Query" name:"EnsRegionId"` - VSwitchName string `position:"Query" name:"VSwitchName"` - CidrBlock string `position:"Query" name:"CidrBlock"` - NetworkId string `position:"Query" name:"NetworkId"` + Description string `position:"Query" name:"Description"` + EnsRegionId string `position:"Query" name:"EnsRegionId"` + Tag *[]CreateVSwitchTag `position:"Query" name:"Tag" type:"Repeated"` + VSwitchName string `position:"Query" name:"VSwitchName"` + CidrBlock string `position:"Query" name:"CidrBlock"` + NetworkId string `position:"Query" name:"NetworkId"` +} + +// CreateVSwitchTag is a repeated param struct in CreateVSwitchRequest +type CreateVSwitchTag struct { + Value string `name:"Value"` + Key string `name:"Key"` } // CreateVSwitchResponse is the response struct for api CreateVSwitch diff --git a/services/ens/describe_application_resource_summary.go b/services/ens/describe_application_resource_summary.go deleted file mode 100644 index d3332dfb50..0000000000 --- a/services/ens/describe_application_resource_summary.go +++ /dev/null @@ -1,101 +0,0 @@ -package ens - -//Licensed under the Apache License, Version 2.0 (the "License"); -//you may not use this file except in compliance with the License. -//You may obtain a copy of the License at -// -//http://www.apache.org/licenses/LICENSE-2.0 -// -//Unless required by applicable law or agreed to in writing, software -//distributed under the License is distributed on an "AS IS" BASIS, -//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -//See the License for the specific language governing permissions and -//limitations under the License. -// -// Code generated by Alibaba Cloud SDK Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -import ( - "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" - "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" -) - -// DescribeApplicationResourceSummary invokes the ens.DescribeApplicationResourceSummary API synchronously -func (client *Client) DescribeApplicationResourceSummary(request *DescribeApplicationResourceSummaryRequest) (response *DescribeApplicationResourceSummaryResponse, err error) { - response = CreateDescribeApplicationResourceSummaryResponse() - err = client.DoAction(request, response) - return -} - -// DescribeApplicationResourceSummaryWithChan invokes the ens.DescribeApplicationResourceSummary API asynchronously -func (client *Client) DescribeApplicationResourceSummaryWithChan(request *DescribeApplicationResourceSummaryRequest) (<-chan *DescribeApplicationResourceSummaryResponse, <-chan error) { - responseChan := make(chan *DescribeApplicationResourceSummaryResponse, 1) - errChan := make(chan error, 1) - err := client.AddAsyncTask(func() { - defer close(responseChan) - defer close(errChan) - response, err := client.DescribeApplicationResourceSummary(request) - if err != nil { - errChan <- err - } else { - responseChan <- response - } - }) - if err != nil { - errChan <- err - close(responseChan) - close(errChan) - } - return responseChan, errChan -} - -// DescribeApplicationResourceSummaryWithCallback invokes the ens.DescribeApplicationResourceSummary API asynchronously -func (client *Client) DescribeApplicationResourceSummaryWithCallback(request *DescribeApplicationResourceSummaryRequest, callback func(response *DescribeApplicationResourceSummaryResponse, err error)) <-chan int { - result := make(chan int, 1) - err := client.AddAsyncTask(func() { - var response *DescribeApplicationResourceSummaryResponse - var err error - defer close(result) - response, err = client.DescribeApplicationResourceSummary(request) - callback(response, err) - result <- 1 - }) - if err != nil { - defer close(result) - callback(nil, err) - result <- 0 - } - return result -} - -// DescribeApplicationResourceSummaryRequest is the request struct for api DescribeApplicationResourceSummary -type DescribeApplicationResourceSummaryRequest struct { - *requests.RpcRequest - Level string `position:"Query" name:"Level"` - ResourceType string `position:"Query" name:"ResourceType"` -} - -// DescribeApplicationResourceSummaryResponse is the response struct for api DescribeApplicationResourceSummary -type DescribeApplicationResourceSummaryResponse struct { - *responses.BaseResponse - ApplicationResource string `json:"ApplicationResource" xml:"ApplicationResource"` - RequestId string `json:"RequestId" xml:"RequestId"` -} - -// CreateDescribeApplicationResourceSummaryRequest creates a request to invoke DescribeApplicationResourceSummary API -func CreateDescribeApplicationResourceSummaryRequest() (request *DescribeApplicationResourceSummaryRequest) { - request = &DescribeApplicationResourceSummaryRequest{ - RpcRequest: &requests.RpcRequest{}, - } - request.InitWithApiInfo("Ens", "2017-11-10", "DescribeApplicationResourceSummary", "ens", "openAPI") - request.Method = requests.POST - return -} - -// CreateDescribeApplicationResourceSummaryResponse creates a response to parse from DescribeApplicationResourceSummary response -func CreateDescribeApplicationResourceSummaryResponse() (response *DescribeApplicationResourceSummaryResponse) { - response = &DescribeApplicationResourceSummaryResponse{ - BaseResponse: &responses.BaseResponse{}, - } - return -} diff --git a/services/ens/describe_cloud_disk_types.go b/services/ens/describe_cloud_disk_types.go index 86871f06f2..2fdc33aa8f 100644 --- a/services/ens/describe_cloud_disk_types.go +++ b/services/ens/describe_cloud_disk_types.go @@ -71,7 +71,8 @@ func (client *Client) DescribeCloudDiskTypesWithCallback(request *DescribeCloudD // DescribeCloudDiskTypesRequest is the request struct for api DescribeCloudDiskTypes type DescribeCloudDiskTypesRequest struct { *requests.RpcRequest - EnsRegionId string `position:"Query" name:"EnsRegionId"` + EnsRegionId string `position:"Query" name:"EnsRegionId"` + EnsRegionIds *[]string `position:"Query" name:"EnsRegionIds" type:"Json"` } // DescribeCloudDiskTypesResponse is the response struct for api DescribeCloudDiskTypes diff --git a/services/ens/describe_cluster.go b/services/ens/describe_cluster.go new file mode 100644 index 0000000000..e7209ff61a --- /dev/null +++ b/services/ens/describe_cluster.go @@ -0,0 +1,100 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DescribeCluster invokes the ens.DescribeCluster API synchronously +func (client *Client) DescribeCluster(request *DescribeClusterRequest) (response *DescribeClusterResponse, err error) { + response = CreateDescribeClusterResponse() + err = client.DoAction(request, response) + return +} + +// DescribeClusterWithChan invokes the ens.DescribeCluster API asynchronously +func (client *Client) DescribeClusterWithChan(request *DescribeClusterRequest) (<-chan *DescribeClusterResponse, <-chan error) { + responseChan := make(chan *DescribeClusterResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeCluster(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeClusterWithCallback invokes the ens.DescribeCluster API asynchronously +func (client *Client) DescribeClusterWithCallback(request *DescribeClusterRequest, callback func(response *DescribeClusterResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeClusterResponse + var err error + defer close(result) + response, err = client.DescribeCluster(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeClusterRequest is the request struct for api DescribeCluster +type DescribeClusterRequest struct { + *requests.RpcRequest + ClusterId string `position:"Query" name:"ClusterId"` +} + +// DescribeClusterResponse is the response struct for api DescribeCluster +type DescribeClusterResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + Clusters []ClustersItem `json:"Clusters" xml:"Clusters"` +} + +// CreateDescribeClusterRequest creates a request to invoke DescribeCluster API +func CreateDescribeClusterRequest() (request *DescribeClusterRequest) { + request = &DescribeClusterRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "DescribeCluster", "ens", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeClusterResponse creates a response to parse from DescribeCluster response +func CreateDescribeClusterResponse() (response *DescribeClusterResponse) { + response = &DescribeClusterResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/describe_cluster_kube_config.go b/services/ens/describe_cluster_kube_config.go new file mode 100644 index 0000000000..d47e7a7ec7 --- /dev/null +++ b/services/ens/describe_cluster_kube_config.go @@ -0,0 +1,101 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DescribeClusterKubeConfig invokes the ens.DescribeClusterKubeConfig API synchronously +func (client *Client) DescribeClusterKubeConfig(request *DescribeClusterKubeConfigRequest) (response *DescribeClusterKubeConfigResponse, err error) { + response = CreateDescribeClusterKubeConfigResponse() + err = client.DoAction(request, response) + return +} + +// DescribeClusterKubeConfigWithChan invokes the ens.DescribeClusterKubeConfig API asynchronously +func (client *Client) DescribeClusterKubeConfigWithChan(request *DescribeClusterKubeConfigRequest) (<-chan *DescribeClusterKubeConfigResponse, <-chan error) { + responseChan := make(chan *DescribeClusterKubeConfigResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeClusterKubeConfig(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeClusterKubeConfigWithCallback invokes the ens.DescribeClusterKubeConfig API asynchronously +func (client *Client) DescribeClusterKubeConfigWithCallback(request *DescribeClusterKubeConfigRequest, callback func(response *DescribeClusterKubeConfigResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeClusterKubeConfigResponse + var err error + defer close(result) + response, err = client.DescribeClusterKubeConfig(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeClusterKubeConfigRequest is the request struct for api DescribeClusterKubeConfig +type DescribeClusterKubeConfigRequest struct { + *requests.RpcRequest + ClusterId string `position:"Query" name:"ClusterId"` +} + +// DescribeClusterKubeConfigResponse is the response struct for api DescribeClusterKubeConfig +type DescribeClusterKubeConfigResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ClusterId string `json:"ClusterId" xml:"ClusterId"` + Kubeconfig string `json:"Kubeconfig" xml:"Kubeconfig"` +} + +// CreateDescribeClusterKubeConfigRequest creates a request to invoke DescribeClusterKubeConfig API +func CreateDescribeClusterKubeConfigRequest() (request *DescribeClusterKubeConfigRequest) { + request = &DescribeClusterKubeConfigRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "DescribeClusterKubeConfig", "ens", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeClusterKubeConfigResponse creates a response to parse from DescribeClusterKubeConfig response +func CreateDescribeClusterKubeConfigResponse() (response *DescribeClusterKubeConfigResponse) { + response = &DescribeClusterKubeConfigResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/describe_disk_iops_list.go b/services/ens/describe_disk_iops_list.go new file mode 100644 index 0000000000..9781e56f81 --- /dev/null +++ b/services/ens/describe_disk_iops_list.go @@ -0,0 +1,102 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DescribeDiskIopsList invokes the ens.DescribeDiskIopsList API synchronously +func (client *Client) DescribeDiskIopsList(request *DescribeDiskIopsListRequest) (response *DescribeDiskIopsListResponse, err error) { + response = CreateDescribeDiskIopsListResponse() + err = client.DoAction(request, response) + return +} + +// DescribeDiskIopsListWithChan invokes the ens.DescribeDiskIopsList API asynchronously +func (client *Client) DescribeDiskIopsListWithChan(request *DescribeDiskIopsListRequest) (<-chan *DescribeDiskIopsListResponse, <-chan error) { + responseChan := make(chan *DescribeDiskIopsListResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeDiskIopsList(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeDiskIopsListWithCallback invokes the ens.DescribeDiskIopsList API asynchronously +func (client *Client) DescribeDiskIopsListWithCallback(request *DescribeDiskIopsListRequest, callback func(response *DescribeDiskIopsListResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeDiskIopsListResponse + var err error + defer close(result) + response, err = client.DescribeDiskIopsList(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeDiskIopsListRequest is the request struct for api DescribeDiskIopsList +type DescribeDiskIopsListRequest struct { + *requests.RpcRequest + StartTime string `position:"Query" name:"StartTime"` + DiskId string `position:"Query" name:"DiskId"` + EndTime string `position:"Query" name:"EndTime"` +} + +// DescribeDiskIopsListResponse is the response struct for api DescribeDiskIopsList +type DescribeDiskIopsListResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + DiskIopsList []DiskIops `json:"DiskIopsList" xml:"DiskIopsList"` +} + +// CreateDescribeDiskIopsListRequest creates a request to invoke DescribeDiskIopsList API +func CreateDescribeDiskIopsListRequest() (request *DescribeDiskIopsListRequest) { + request = &DescribeDiskIopsListRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "DescribeDiskIopsList", "ens", "openAPI") + request.Method = requests.GET + return +} + +// CreateDescribeDiskIopsListResponse creates a response to parse from DescribeDiskIopsList response +func CreateDescribeDiskIopsListResponse() (response *DescribeDiskIopsListResponse) { + response = &DescribeDiskIopsListResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/describe_eip_addresses.go b/services/ens/describe_eip_addresses.go deleted file mode 100644 index 92e5dd9de8..0000000000 --- a/services/ens/describe_eip_addresses.go +++ /dev/null @@ -1,101 +0,0 @@ -package ens - -//Licensed under the Apache License, Version 2.0 (the "License"); -//you may not use this file except in compliance with the License. -//You may obtain a copy of the License at -// -//http://www.apache.org/licenses/LICENSE-2.0 -// -//Unless required by applicable law or agreed to in writing, software -//distributed under the License is distributed on an "AS IS" BASIS, -//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -//See the License for the specific language governing permissions and -//limitations under the License. -// -// Code generated by Alibaba Cloud SDK Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -import ( - "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" - "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" -) - -// DescribeEipAddresses invokes the ens.DescribeEipAddresses API synchronously -func (client *Client) DescribeEipAddresses(request *DescribeEipAddressesRequest) (response *DescribeEipAddressesResponse, err error) { - response = CreateDescribeEipAddressesResponse() - err = client.DoAction(request, response) - return -} - -// DescribeEipAddressesWithChan invokes the ens.DescribeEipAddresses API asynchronously -func (client *Client) DescribeEipAddressesWithChan(request *DescribeEipAddressesRequest) (<-chan *DescribeEipAddressesResponse, <-chan error) { - responseChan := make(chan *DescribeEipAddressesResponse, 1) - errChan := make(chan error, 1) - err := client.AddAsyncTask(func() { - defer close(responseChan) - defer close(errChan) - response, err := client.DescribeEipAddresses(request) - if err != nil { - errChan <- err - } else { - responseChan <- response - } - }) - if err != nil { - errChan <- err - close(responseChan) - close(errChan) - } - return responseChan, errChan -} - -// DescribeEipAddressesWithCallback invokes the ens.DescribeEipAddresses API asynchronously -func (client *Client) DescribeEipAddressesWithCallback(request *DescribeEipAddressesRequest, callback func(response *DescribeEipAddressesResponse, err error)) <-chan int { - result := make(chan int, 1) - err := client.AddAsyncTask(func() { - var response *DescribeEipAddressesResponse - var err error - defer close(result) - response, err = client.DescribeEipAddresses(request) - callback(response, err) - result <- 1 - }) - if err != nil { - defer close(result) - callback(nil, err) - result <- 0 - } - return result -} - -// DescribeEipAddressesRequest is the request struct for api DescribeEipAddresses -type DescribeEipAddressesRequest struct { - *requests.RpcRequest - Eips string `position:"Query" name:"Eips"` - EnsRegionId string `position:"Query" name:"EnsRegionId"` -} - -// DescribeEipAddressesResponse is the response struct for api DescribeEipAddresses -type DescribeEipAddressesResponse struct { - *responses.BaseResponse - RequestId string `json:"RequestId" xml:"RequestId"` - EipAddresses EipAddressesInDescribeEipAddresses `json:"EipAddresses" xml:"EipAddresses"` -} - -// CreateDescribeEipAddressesRequest creates a request to invoke DescribeEipAddresses API -func CreateDescribeEipAddressesRequest() (request *DescribeEipAddressesRequest) { - request = &DescribeEipAddressesRequest{ - RpcRequest: &requests.RpcRequest{}, - } - request.InitWithApiInfo("Ens", "2017-11-10", "DescribeEipAddresses", "ens", "openAPI") - request.Method = requests.POST - return -} - -// CreateDescribeEipAddressesResponse creates a response to parse from DescribeEipAddresses response -func CreateDescribeEipAddressesResponse() (response *DescribeEipAddressesResponse) { - response = &DescribeEipAddressesResponse{ - BaseResponse: &responses.BaseResponse{}, - } - return -} diff --git a/services/ens/describe_ens_eip_addresses.go b/services/ens/describe_ens_eip_addresses.go index e2d260b036..306c4166aa 100644 --- a/services/ens/describe_ens_eip_addresses.go +++ b/services/ens/describe_ens_eip_addresses.go @@ -86,11 +86,11 @@ type DescribeEnsEipAddressesRequest struct { // DescribeEnsEipAddressesResponse is the response struct for api DescribeEnsEipAddresses type DescribeEnsEipAddressesResponse struct { *responses.BaseResponse - RequestId string `json:"RequestId" xml:"RequestId"` - PageNumber int `json:"PageNumber" xml:"PageNumber"` - PageSize int `json:"PageSize" xml:"PageSize"` - TotalCount int `json:"TotalCount" xml:"TotalCount"` - EipAddresses EipAddressesInDescribeEnsEipAddresses `json:"EipAddresses" xml:"EipAddresses"` + RequestId string `json:"RequestId" xml:"RequestId"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + PageSize int `json:"PageSize" xml:"PageSize"` + TotalCount int `json:"TotalCount" xml:"TotalCount"` + EipAddresses EipAddresses `json:"EipAddresses" xml:"EipAddresses"` } // CreateDescribeEnsEipAddressesRequest creates a request to invoke DescribeEnsEipAddresses API diff --git a/services/ens/describe_ha_vips.go b/services/ens/describe_ha_vips.go new file mode 100644 index 0000000000..d95d6717f3 --- /dev/null +++ b/services/ens/describe_ha_vips.go @@ -0,0 +1,111 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DescribeHaVips invokes the ens.DescribeHaVips API synchronously +func (client *Client) DescribeHaVips(request *DescribeHaVipsRequest) (response *DescribeHaVipsResponse, err error) { + response = CreateDescribeHaVipsResponse() + err = client.DoAction(request, response) + return +} + +// DescribeHaVipsWithChan invokes the ens.DescribeHaVips API asynchronously +func (client *Client) DescribeHaVipsWithChan(request *DescribeHaVipsRequest) (<-chan *DescribeHaVipsResponse, <-chan error) { + responseChan := make(chan *DescribeHaVipsResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeHaVips(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeHaVipsWithCallback invokes the ens.DescribeHaVips API asynchronously +func (client *Client) DescribeHaVipsWithCallback(request *DescribeHaVipsRequest, callback func(response *DescribeHaVipsResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeHaVipsResponse + var err error + defer close(result) + response, err = client.DescribeHaVips(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeHaVipsRequest is the request struct for api DescribeHaVips +type DescribeHaVipsRequest struct { + *requests.RpcRequest + EnsRegionId string `position:"Query" name:"EnsRegionId"` + HaVipId string `position:"Query" name:"HaVipId"` + HaVipAddress string `position:"Query" name:"HaVipAddress"` + VSwitchId string `position:"Query" name:"VSwitchId"` + Name string `position:"Query" name:"Name"` + NetworkId string `position:"Query" name:"NetworkId"` + Status string `position:"Query" name:"Status"` + PageNumber string `position:"Query" name:"PageNumber"` + PageSize string `position:"Query" name:"PageSize"` +} + +// DescribeHaVipsResponse is the response struct for api DescribeHaVips +type DescribeHaVipsResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + TotalCount string `json:"TotalCount" xml:"TotalCount"` + PageSize string `json:"PageSize" xml:"PageSize"` + PageNumber string `json:"PageNumber" xml:"PageNumber"` + HaVips []HaVip `json:"HaVips" xml:"HaVips"` +} + +// CreateDescribeHaVipsRequest creates a request to invoke DescribeHaVips API +func CreateDescribeHaVipsRequest() (request *DescribeHaVipsRequest) { + request = &DescribeHaVipsRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "DescribeHaVips", "ens", "openAPI") + request.Method = requests.GET + return +} + +// CreateDescribeHaVipsResponse creates a response to parse from DescribeHaVips response +func CreateDescribeHaVipsResponse() (response *DescribeHaVipsResponse) { + response = &DescribeHaVipsResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/describe_instance_bandwidth_detail.go b/services/ens/describe_instance_bandwidth_detail.go new file mode 100644 index 0000000000..653d72be38 --- /dev/null +++ b/services/ens/describe_instance_bandwidth_detail.go @@ -0,0 +1,110 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DescribeInstanceBandwidthDetail invokes the ens.DescribeInstanceBandwidthDetail API synchronously +func (client *Client) DescribeInstanceBandwidthDetail(request *DescribeInstanceBandwidthDetailRequest) (response *DescribeInstanceBandwidthDetailResponse, err error) { + response = CreateDescribeInstanceBandwidthDetailResponse() + err = client.DoAction(request, response) + return +} + +// DescribeInstanceBandwidthDetailWithChan invokes the ens.DescribeInstanceBandwidthDetail API asynchronously +func (client *Client) DescribeInstanceBandwidthDetailWithChan(request *DescribeInstanceBandwidthDetailRequest) (<-chan *DescribeInstanceBandwidthDetailResponse, <-chan error) { + responseChan := make(chan *DescribeInstanceBandwidthDetailResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeInstanceBandwidthDetail(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeInstanceBandwidthDetailWithCallback invokes the ens.DescribeInstanceBandwidthDetail API asynchronously +func (client *Client) DescribeInstanceBandwidthDetailWithCallback(request *DescribeInstanceBandwidthDetailRequest, callback func(response *DescribeInstanceBandwidthDetailResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeInstanceBandwidthDetailResponse + var err error + defer close(result) + response, err = client.DescribeInstanceBandwidthDetail(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeInstanceBandwidthDetailRequest is the request struct for api DescribeInstanceBandwidthDetail +type DescribeInstanceBandwidthDetailRequest struct { + *requests.RpcRequest + StartTime string `position:"Query" name:"StartTime"` + EnsRegionId string `position:"Query" name:"EnsRegionId"` + InstanceId string `position:"Query" name:"InstanceId"` + PageNumber requests.Integer `position:"Query" name:"PageNumber"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + InstanceType string `position:"Query" name:"InstanceType"` + EndTime string `position:"Query" name:"EndTime"` + ServiceType string `position:"Query" name:"ServiceType"` +} + +// DescribeInstanceBandwidthDetailResponse is the response struct for api DescribeInstanceBandwidthDetail +type DescribeInstanceBandwidthDetailResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + PageSize int `json:"PageSize" xml:"PageSize"` + TotalCount int `json:"TotalCount" xml:"TotalCount"` + Bandwidths []Bandwidth `json:"Bandwidths" xml:"Bandwidths"` +} + +// CreateDescribeInstanceBandwidthDetailRequest creates a request to invoke DescribeInstanceBandwidthDetail API +func CreateDescribeInstanceBandwidthDetailRequest() (request *DescribeInstanceBandwidthDetailRequest) { + request = &DescribeInstanceBandwidthDetailRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "DescribeInstanceBandwidthDetail", "ens", "openAPI") + request.Method = requests.GET + return +} + +// CreateDescribeInstanceBandwidthDetailResponse creates a response to parse from DescribeInstanceBandwidthDetail response +func CreateDescribeInstanceBandwidthDetailResponse() (response *DescribeInstanceBandwidthDetailResponse) { + response = &DescribeInstanceBandwidthDetailResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/describe_load_balancer_listen_monitor.go b/services/ens/describe_load_balancer_listen_monitor.go new file mode 100644 index 0000000000..b57f5311cc --- /dev/null +++ b/services/ens/describe_load_balancer_listen_monitor.go @@ -0,0 +1,104 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DescribeLoadBalancerListenMonitor invokes the ens.DescribeLoadBalancerListenMonitor API synchronously +func (client *Client) DescribeLoadBalancerListenMonitor(request *DescribeLoadBalancerListenMonitorRequest) (response *DescribeLoadBalancerListenMonitorResponse, err error) { + response = CreateDescribeLoadBalancerListenMonitorResponse() + err = client.DoAction(request, response) + return +} + +// DescribeLoadBalancerListenMonitorWithChan invokes the ens.DescribeLoadBalancerListenMonitor API asynchronously +func (client *Client) DescribeLoadBalancerListenMonitorWithChan(request *DescribeLoadBalancerListenMonitorRequest) (<-chan *DescribeLoadBalancerListenMonitorResponse, <-chan error) { + responseChan := make(chan *DescribeLoadBalancerListenMonitorResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeLoadBalancerListenMonitor(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeLoadBalancerListenMonitorWithCallback invokes the ens.DescribeLoadBalancerListenMonitor API asynchronously +func (client *Client) DescribeLoadBalancerListenMonitorWithCallback(request *DescribeLoadBalancerListenMonitorRequest, callback func(response *DescribeLoadBalancerListenMonitorResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeLoadBalancerListenMonitorResponse + var err error + defer close(result) + response, err = client.DescribeLoadBalancerListenMonitor(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeLoadBalancerListenMonitorRequest is the request struct for api DescribeLoadBalancerListenMonitor +type DescribeLoadBalancerListenMonitorRequest struct { + *requests.RpcRequest + StartTime string `position:"Query" name:"StartTime"` + LoadBalancerId string `position:"Query" name:"LoadBalancerId"` + Proto string `position:"Query" name:"Proto"` + VPort string `position:"Query" name:"VPort"` + EndTime string `position:"Query" name:"EndTime"` +} + +// DescribeLoadBalancerListenMonitorResponse is the response struct for api DescribeLoadBalancerListenMonitor +type DescribeLoadBalancerListenMonitorResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + LoadBalancerMonitorListenData []ElbListenMonitorList `json:"LoadBalancerMonitorListenData" xml:"LoadBalancerMonitorListenData"` +} + +// CreateDescribeLoadBalancerListenMonitorRequest creates a request to invoke DescribeLoadBalancerListenMonitor API +func CreateDescribeLoadBalancerListenMonitorRequest() (request *DescribeLoadBalancerListenMonitorRequest) { + request = &DescribeLoadBalancerListenMonitorRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "DescribeLoadBalancerListenMonitor", "ens", "openAPI") + request.Method = requests.GET + return +} + +// CreateDescribeLoadBalancerListenMonitorResponse creates a response to parse from DescribeLoadBalancerListenMonitor response +func CreateDescribeLoadBalancerListenMonitorResponse() (response *DescribeLoadBalancerListenMonitorResponse) { + response = &DescribeLoadBalancerListenMonitorResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/describe_load_balancer_listeners.go b/services/ens/describe_load_balancer_listeners.go new file mode 100644 index 0000000000..32fe8cc08b --- /dev/null +++ b/services/ens/describe_load_balancer_listeners.go @@ -0,0 +1,105 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DescribeLoadBalancerListeners invokes the ens.DescribeLoadBalancerListeners API synchronously +func (client *Client) DescribeLoadBalancerListeners(request *DescribeLoadBalancerListenersRequest) (response *DescribeLoadBalancerListenersResponse, err error) { + response = CreateDescribeLoadBalancerListenersResponse() + err = client.DoAction(request, response) + return +} + +// DescribeLoadBalancerListenersWithChan invokes the ens.DescribeLoadBalancerListeners API asynchronously +func (client *Client) DescribeLoadBalancerListenersWithChan(request *DescribeLoadBalancerListenersRequest) (<-chan *DescribeLoadBalancerListenersResponse, <-chan error) { + responseChan := make(chan *DescribeLoadBalancerListenersResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeLoadBalancerListeners(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeLoadBalancerListenersWithCallback invokes the ens.DescribeLoadBalancerListeners API asynchronously +func (client *Client) DescribeLoadBalancerListenersWithCallback(request *DescribeLoadBalancerListenersRequest, callback func(response *DescribeLoadBalancerListenersResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeLoadBalancerListenersResponse + var err error + defer close(result) + response, err = client.DescribeLoadBalancerListeners(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeLoadBalancerListenersRequest is the request struct for api DescribeLoadBalancerListeners +type DescribeLoadBalancerListenersRequest struct { + *requests.RpcRequest + PageNumber requests.Integer `position:"Query" name:"PageNumber"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + LoadBalancerId string `position:"Query" name:"LoadBalancerId"` +} + +// DescribeLoadBalancerListenersResponse is the response struct for api DescribeLoadBalancerListeners +type DescribeLoadBalancerListenersResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + PageSize int `json:"PageSize" xml:"PageSize"` + TotalCount int `json:"TotalCount" xml:"TotalCount"` + Listeners Listeners `json:"Listeners" xml:"Listeners"` +} + +// CreateDescribeLoadBalancerListenersRequest creates a request to invoke DescribeLoadBalancerListeners API +func CreateDescribeLoadBalancerListenersRequest() (request *DescribeLoadBalancerListenersRequest) { + request = &DescribeLoadBalancerListenersRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "DescribeLoadBalancerListeners", "ens", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeLoadBalancerListenersResponse creates a response to parse from DescribeLoadBalancerListeners response +func CreateDescribeLoadBalancerListenersResponse() (response *DescribeLoadBalancerListenersResponse) { + response = &DescribeLoadBalancerListenersResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/describe_network_interfaces.go b/services/ens/describe_network_interfaces.go index fd1cd50435..4bd5506965 100644 --- a/services/ens/describe_network_interfaces.go +++ b/services/ens/describe_network_interfaces.go @@ -77,6 +77,7 @@ type DescribeNetworkInterfacesRequest struct { VSwitchId string `position:"Query" name:"VSwitchId"` InstanceId string `position:"Query" name:"InstanceId"` NetworkId string `position:"Query" name:"NetworkId"` + Ipv6Address *[]string `position:"Query" name:"Ipv6Address" type:"Repeated"` Status string `position:"Query" name:"Status"` SecurityGroupId string `position:"Query" name:"SecurityGroupId"` PageNumber string `position:"Query" name:"PageNumber"` diff --git a/services/ens/describe_secondary_public_ip_addresses.go b/services/ens/describe_secondary_public_ip_addresses.go new file mode 100644 index 0000000000..e40c507e96 --- /dev/null +++ b/services/ens/describe_secondary_public_ip_addresses.go @@ -0,0 +1,108 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DescribeSecondaryPublicIpAddresses invokes the ens.DescribeSecondaryPublicIpAddresses API synchronously +func (client *Client) DescribeSecondaryPublicIpAddresses(request *DescribeSecondaryPublicIpAddressesRequest) (response *DescribeSecondaryPublicIpAddressesResponse, err error) { + response = CreateDescribeSecondaryPublicIpAddressesResponse() + err = client.DoAction(request, response) + return +} + +// DescribeSecondaryPublicIpAddressesWithChan invokes the ens.DescribeSecondaryPublicIpAddresses API asynchronously +func (client *Client) DescribeSecondaryPublicIpAddressesWithChan(request *DescribeSecondaryPublicIpAddressesRequest) (<-chan *DescribeSecondaryPublicIpAddressesResponse, <-chan error) { + responseChan := make(chan *DescribeSecondaryPublicIpAddressesResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeSecondaryPublicIpAddresses(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeSecondaryPublicIpAddressesWithCallback invokes the ens.DescribeSecondaryPublicIpAddresses API asynchronously +func (client *Client) DescribeSecondaryPublicIpAddressesWithCallback(request *DescribeSecondaryPublicIpAddressesRequest, callback func(response *DescribeSecondaryPublicIpAddressesResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeSecondaryPublicIpAddressesResponse + var err error + defer close(result) + response, err = client.DescribeSecondaryPublicIpAddresses(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeSecondaryPublicIpAddressesRequest is the request struct for api DescribeSecondaryPublicIpAddresses +type DescribeSecondaryPublicIpAddressesRequest struct { + *requests.RpcRequest + SecondaryPublicIpId string `position:"Query" name:"SecondaryPublicIpId"` + Isp string `position:"Query" name:"Isp"` + PageNumber requests.Integer `position:"Query" name:"PageNumber"` + EnsRegionId string `position:"Query" name:"EnsRegionId"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + SecondaryPublicIpAddress string `position:"Query" name:"SecondaryPublicIpAddress"` +} + +// DescribeSecondaryPublicIpAddressesResponse is the response struct for api DescribeSecondaryPublicIpAddresses +type DescribeSecondaryPublicIpAddressesResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + PageSize int `json:"PageSize" xml:"PageSize"` + TotalCount int `json:"TotalCount" xml:"TotalCount"` + SecondaryPublicIpAddresses []Ip `json:"SecondaryPublicIpAddresses" xml:"SecondaryPublicIpAddresses"` +} + +// CreateDescribeSecondaryPublicIpAddressesRequest creates a request to invoke DescribeSecondaryPublicIpAddresses API +func CreateDescribeSecondaryPublicIpAddressesRequest() (request *DescribeSecondaryPublicIpAddressesRequest) { + request = &DescribeSecondaryPublicIpAddressesRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "DescribeSecondaryPublicIpAddresses", "ens", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeSecondaryPublicIpAddressesResponse creates a response to parse from DescribeSecondaryPublicIpAddresses response +func CreateDescribeSecondaryPublicIpAddressesResponse() (response *DescribeSecondaryPublicIpAddressesResponse) { + response = &DescribeSecondaryPublicIpAddressesResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/describe_server_load_balancer_listen_monitor.go b/services/ens/describe_server_load_balancer_listen_monitor.go new file mode 100644 index 0000000000..525d2368d5 --- /dev/null +++ b/services/ens/describe_server_load_balancer_listen_monitor.go @@ -0,0 +1,104 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DescribeServerLoadBalancerListenMonitor invokes the ens.DescribeServerLoadBalancerListenMonitor API synchronously +func (client *Client) DescribeServerLoadBalancerListenMonitor(request *DescribeServerLoadBalancerListenMonitorRequest) (response *DescribeServerLoadBalancerListenMonitorResponse, err error) { + response = CreateDescribeServerLoadBalancerListenMonitorResponse() + err = client.DoAction(request, response) + return +} + +// DescribeServerLoadBalancerListenMonitorWithChan invokes the ens.DescribeServerLoadBalancerListenMonitor API asynchronously +func (client *Client) DescribeServerLoadBalancerListenMonitorWithChan(request *DescribeServerLoadBalancerListenMonitorRequest) (<-chan *DescribeServerLoadBalancerListenMonitorResponse, <-chan error) { + responseChan := make(chan *DescribeServerLoadBalancerListenMonitorResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeServerLoadBalancerListenMonitor(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeServerLoadBalancerListenMonitorWithCallback invokes the ens.DescribeServerLoadBalancerListenMonitor API asynchronously +func (client *Client) DescribeServerLoadBalancerListenMonitorWithCallback(request *DescribeServerLoadBalancerListenMonitorRequest, callback func(response *DescribeServerLoadBalancerListenMonitorResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeServerLoadBalancerListenMonitorResponse + var err error + defer close(result) + response, err = client.DescribeServerLoadBalancerListenMonitor(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeServerLoadBalancerListenMonitorRequest is the request struct for api DescribeServerLoadBalancerListenMonitor +type DescribeServerLoadBalancerListenMonitorRequest struct { + *requests.RpcRequest + StartTime string `position:"Query" name:"StartTime"` + LoadBalancerId string `position:"Query" name:"LoadBalancerId"` + Proto string `position:"Query" name:"Proto"` + VPort string `position:"Query" name:"VPort"` + EndTime string `position:"Query" name:"EndTime"` +} + +// DescribeServerLoadBalancerListenMonitorResponse is the response struct for api DescribeServerLoadBalancerListenMonitor +type DescribeServerLoadBalancerListenMonitorResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ServerLoadBalancerMonitorData []EslbMonitorList `json:"ServerLoadBalancerMonitorData" xml:"ServerLoadBalancerMonitorData"` +} + +// CreateDescribeServerLoadBalancerListenMonitorRequest creates a request to invoke DescribeServerLoadBalancerListenMonitor API +func CreateDescribeServerLoadBalancerListenMonitorRequest() (request *DescribeServerLoadBalancerListenMonitorRequest) { + request = &DescribeServerLoadBalancerListenMonitorRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "DescribeServerLoadBalancerListenMonitor", "ens", "openAPI") + request.Method = requests.GET + return +} + +// CreateDescribeServerLoadBalancerListenMonitorResponse creates a response to parse from DescribeServerLoadBalancerListenMonitor response +func CreateDescribeServerLoadBalancerListenMonitorResponse() (response *DescribeServerLoadBalancerListenMonitorResponse) { + response = &DescribeServerLoadBalancerListenMonitorResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/describe_server_load_balancer_monitor.go b/services/ens/describe_server_load_balancer_monitor.go new file mode 100644 index 0000000000..e48e114099 --- /dev/null +++ b/services/ens/describe_server_load_balancer_monitor.go @@ -0,0 +1,102 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DescribeServerLoadBalancerMonitor invokes the ens.DescribeServerLoadBalancerMonitor API synchronously +func (client *Client) DescribeServerLoadBalancerMonitor(request *DescribeServerLoadBalancerMonitorRequest) (response *DescribeServerLoadBalancerMonitorResponse, err error) { + response = CreateDescribeServerLoadBalancerMonitorResponse() + err = client.DoAction(request, response) + return +} + +// DescribeServerLoadBalancerMonitorWithChan invokes the ens.DescribeServerLoadBalancerMonitor API asynchronously +func (client *Client) DescribeServerLoadBalancerMonitorWithChan(request *DescribeServerLoadBalancerMonitorRequest) (<-chan *DescribeServerLoadBalancerMonitorResponse, <-chan error) { + responseChan := make(chan *DescribeServerLoadBalancerMonitorResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeServerLoadBalancerMonitor(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeServerLoadBalancerMonitorWithCallback invokes the ens.DescribeServerLoadBalancerMonitor API asynchronously +func (client *Client) DescribeServerLoadBalancerMonitorWithCallback(request *DescribeServerLoadBalancerMonitorRequest, callback func(response *DescribeServerLoadBalancerMonitorResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeServerLoadBalancerMonitorResponse + var err error + defer close(result) + response, err = client.DescribeServerLoadBalancerMonitor(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeServerLoadBalancerMonitorRequest is the request struct for api DescribeServerLoadBalancerMonitor +type DescribeServerLoadBalancerMonitorRequest struct { + *requests.RpcRequest + StartTime string `position:"Query" name:"StartTime"` + EndTime string `position:"Query" name:"EndTime"` + LoadBalancerId string `position:"Query" name:"LoadBalancerId"` +} + +// DescribeServerLoadBalancerMonitorResponse is the response struct for api DescribeServerLoadBalancerMonitor +type DescribeServerLoadBalancerMonitorResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ServerLoadBalancerMonitorData []EslbMonitorList `json:"ServerLoadBalancerMonitorData" xml:"ServerLoadBalancerMonitorData"` +} + +// CreateDescribeServerLoadBalancerMonitorRequest creates a request to invoke DescribeServerLoadBalancerMonitor API +func CreateDescribeServerLoadBalancerMonitorRequest() (request *DescribeServerLoadBalancerMonitorRequest) { + request = &DescribeServerLoadBalancerMonitorRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "DescribeServerLoadBalancerMonitor", "ens", "openAPI") + request.Method = requests.GET + return +} + +// CreateDescribeServerLoadBalancerMonitorResponse creates a response to parse from DescribeServerLoadBalancerMonitor response +func CreateDescribeServerLoadBalancerMonitorResponse() (response *DescribeServerLoadBalancerMonitorResponse) { + response = &DescribeServerLoadBalancerMonitorResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/detach_network_interface.go b/services/ens/detach_network_interface.go new file mode 100644 index 0000000000..210bd37835 --- /dev/null +++ b/services/ens/detach_network_interface.go @@ -0,0 +1,99 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DetachNetworkInterface invokes the ens.DetachNetworkInterface API synchronously +func (client *Client) DetachNetworkInterface(request *DetachNetworkInterfaceRequest) (response *DetachNetworkInterfaceResponse, err error) { + response = CreateDetachNetworkInterfaceResponse() + err = client.DoAction(request, response) + return +} + +// DetachNetworkInterfaceWithChan invokes the ens.DetachNetworkInterface API asynchronously +func (client *Client) DetachNetworkInterfaceWithChan(request *DetachNetworkInterfaceRequest) (<-chan *DetachNetworkInterfaceResponse, <-chan error) { + responseChan := make(chan *DetachNetworkInterfaceResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DetachNetworkInterface(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DetachNetworkInterfaceWithCallback invokes the ens.DetachNetworkInterface API asynchronously +func (client *Client) DetachNetworkInterfaceWithCallback(request *DetachNetworkInterfaceRequest, callback func(response *DetachNetworkInterfaceResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DetachNetworkInterfaceResponse + var err error + defer close(result) + response, err = client.DetachNetworkInterface(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DetachNetworkInterfaceRequest is the request struct for api DetachNetworkInterface +type DetachNetworkInterfaceRequest struct { + *requests.RpcRequest + NetworkInterfaceId string `position:"Query" name:"NetworkInterfaceId"` +} + +// DetachNetworkInterfaceResponse is the response struct for api DetachNetworkInterface +type DetachNetworkInterfaceResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` +} + +// CreateDetachNetworkInterfaceRequest creates a request to invoke DetachNetworkInterface API +func CreateDetachNetworkInterfaceRequest() (request *DetachNetworkInterfaceRequest) { + request = &DetachNetworkInterfaceRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "DetachNetworkInterface", "ens", "openAPI") + request.Method = requests.POST + return +} + +// CreateDetachNetworkInterfaceResponse creates a response to parse from DetachNetworkInterface response +func CreateDetachNetworkInterfaceResponse() (response *DetachNetworkInterfaceResponse) { + response = &DetachNetworkInterfaceResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/get_bucket_acl.go b/services/ens/get_bucket_acl.go index 84f884ab7e..152668257c 100644 --- a/services/ens/get_bucket_acl.go +++ b/services/ens/get_bucket_acl.go @@ -87,7 +87,7 @@ func CreateGetBucketAclRequest() (request *GetBucketAclRequest) { RpcRequest: &requests.RpcRequest{}, } request.InitWithApiInfo("Ens", "2017-11-10", "GetBucketAcl", "ens", "openAPI") - request.Method = requests.GET + request.Method = requests.POST return } diff --git a/services/ens/modify_ha_vip_attribute.go b/services/ens/modify_ha_vip_attribute.go new file mode 100644 index 0000000000..773100cdce --- /dev/null +++ b/services/ens/modify_ha_vip_attribute.go @@ -0,0 +1,100 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// ModifyHaVipAttribute invokes the ens.ModifyHaVipAttribute API synchronously +func (client *Client) ModifyHaVipAttribute(request *ModifyHaVipAttributeRequest) (response *ModifyHaVipAttributeResponse, err error) { + response = CreateModifyHaVipAttributeResponse() + err = client.DoAction(request, response) + return +} + +// ModifyHaVipAttributeWithChan invokes the ens.ModifyHaVipAttribute API asynchronously +func (client *Client) ModifyHaVipAttributeWithChan(request *ModifyHaVipAttributeRequest) (<-chan *ModifyHaVipAttributeResponse, <-chan error) { + responseChan := make(chan *ModifyHaVipAttributeResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifyHaVipAttribute(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifyHaVipAttributeWithCallback invokes the ens.ModifyHaVipAttribute API asynchronously +func (client *Client) ModifyHaVipAttributeWithCallback(request *ModifyHaVipAttributeRequest, callback func(response *ModifyHaVipAttributeResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifyHaVipAttributeResponse + var err error + defer close(result) + response, err = client.ModifyHaVipAttribute(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifyHaVipAttributeRequest is the request struct for api ModifyHaVipAttribute +type ModifyHaVipAttributeRequest struct { + *requests.RpcRequest + HaVipId string `position:"Query" name:"HaVipId"` + Name string `position:"Query" name:"Name"` +} + +// ModifyHaVipAttributeResponse is the response struct for api ModifyHaVipAttribute +type ModifyHaVipAttributeResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` +} + +// CreateModifyHaVipAttributeRequest creates a request to invoke ModifyHaVipAttribute API +func CreateModifyHaVipAttributeRequest() (request *ModifyHaVipAttributeRequest) { + request = &ModifyHaVipAttributeRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "ModifyHaVipAttribute", "ens", "openAPI") + request.Method = requests.POST + return +} + +// CreateModifyHaVipAttributeResponse creates a response to parse from ModifyHaVipAttribute response +func CreateModifyHaVipAttributeResponse() (response *ModifyHaVipAttributeResponse) { + response = &ModifyHaVipAttributeResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/modify_instance_boot_configuration.go b/services/ens/modify_instance_boot_configuration.go new file mode 100644 index 0000000000..60ed33e7d8 --- /dev/null +++ b/services/ens/modify_instance_boot_configuration.go @@ -0,0 +1,102 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// ModifyInstanceBootConfiguration invokes the ens.ModifyInstanceBootConfiguration API synchronously +func (client *Client) ModifyInstanceBootConfiguration(request *ModifyInstanceBootConfigurationRequest) (response *ModifyInstanceBootConfigurationResponse, err error) { + response = CreateModifyInstanceBootConfigurationResponse() + err = client.DoAction(request, response) + return +} + +// ModifyInstanceBootConfigurationWithChan invokes the ens.ModifyInstanceBootConfiguration API asynchronously +func (client *Client) ModifyInstanceBootConfigurationWithChan(request *ModifyInstanceBootConfigurationRequest) (<-chan *ModifyInstanceBootConfigurationResponse, <-chan error) { + responseChan := make(chan *ModifyInstanceBootConfigurationResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifyInstanceBootConfiguration(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifyInstanceBootConfigurationWithCallback invokes the ens.ModifyInstanceBootConfiguration API asynchronously +func (client *Client) ModifyInstanceBootConfigurationWithCallback(request *ModifyInstanceBootConfigurationRequest, callback func(response *ModifyInstanceBootConfigurationResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifyInstanceBootConfigurationResponse + var err error + defer close(result) + response, err = client.ModifyInstanceBootConfiguration(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifyInstanceBootConfigurationRequest is the request struct for api ModifyInstanceBootConfiguration +type ModifyInstanceBootConfigurationRequest struct { + *requests.RpcRequest + DiskSet string `position:"Query" name:"DiskSet"` + BootType string `position:"Query" name:"BootType"` + BootSet string `position:"Query" name:"BootSet"` + InstanceId string `position:"Query" name:"InstanceId"` +} + +// ModifyInstanceBootConfigurationResponse is the response struct for api ModifyInstanceBootConfiguration +type ModifyInstanceBootConfigurationResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` +} + +// CreateModifyInstanceBootConfigurationRequest creates a request to invoke ModifyInstanceBootConfiguration API +func CreateModifyInstanceBootConfigurationRequest() (request *ModifyInstanceBootConfigurationRequest) { + request = &ModifyInstanceBootConfigurationRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "ModifyInstanceBootConfiguration", "ens", "openAPI") + request.Method = requests.GET + return +} + +// CreateModifyInstanceBootConfigurationResponse creates a response to parse from ModifyInstanceBootConfiguration response +func CreateModifyInstanceBootConfigurationResponse() (response *ModifyInstanceBootConfigurationResponse) { + response = &ModifyInstanceBootConfigurationResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/modify_network_interface_attribute.go b/services/ens/modify_network_interface_attribute.go new file mode 100644 index 0000000000..e1dca3cf5e --- /dev/null +++ b/services/ens/modify_network_interface_attribute.go @@ -0,0 +1,101 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// ModifyNetworkInterfaceAttribute invokes the ens.ModifyNetworkInterfaceAttribute API synchronously +func (client *Client) ModifyNetworkInterfaceAttribute(request *ModifyNetworkInterfaceAttributeRequest) (response *ModifyNetworkInterfaceAttributeResponse, err error) { + response = CreateModifyNetworkInterfaceAttributeResponse() + err = client.DoAction(request, response) + return +} + +// ModifyNetworkInterfaceAttributeWithChan invokes the ens.ModifyNetworkInterfaceAttribute API asynchronously +func (client *Client) ModifyNetworkInterfaceAttributeWithChan(request *ModifyNetworkInterfaceAttributeRequest) (<-chan *ModifyNetworkInterfaceAttributeResponse, <-chan error) { + responseChan := make(chan *ModifyNetworkInterfaceAttributeResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifyNetworkInterfaceAttribute(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifyNetworkInterfaceAttributeWithCallback invokes the ens.ModifyNetworkInterfaceAttribute API asynchronously +func (client *Client) ModifyNetworkInterfaceAttributeWithCallback(request *ModifyNetworkInterfaceAttributeRequest, callback func(response *ModifyNetworkInterfaceAttributeResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifyNetworkInterfaceAttributeResponse + var err error + defer close(result) + response, err = client.ModifyNetworkInterfaceAttribute(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifyNetworkInterfaceAttributeRequest is the request struct for api ModifyNetworkInterfaceAttribute +type ModifyNetworkInterfaceAttributeRequest struct { + *requests.RpcRequest + Description string `position:"Query" name:"Description"` + NetworkInterfaceName string `position:"Query" name:"NetworkInterfaceName"` + NetworkInterfaceId string `position:"Query" name:"NetworkInterfaceId"` +} + +// ModifyNetworkInterfaceAttributeResponse is the response struct for api ModifyNetworkInterfaceAttribute +type ModifyNetworkInterfaceAttributeResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` +} + +// CreateModifyNetworkInterfaceAttributeRequest creates a request to invoke ModifyNetworkInterfaceAttribute API +func CreateModifyNetworkInterfaceAttributeRequest() (request *ModifyNetworkInterfaceAttributeRequest) { + request = &ModifyNetworkInterfaceAttributeRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "ModifyNetworkInterfaceAttribute", "ens", "openAPI") + request.Method = requests.POST + return +} + +// CreateModifyNetworkInterfaceAttributeResponse creates a response to parse from ModifyNetworkInterfaceAttribute response +func CreateModifyNetworkInterfaceAttributeResponse() (response *ModifyNetworkInterfaceAttributeResponse) { + response = &ModifyNetworkInterfaceAttributeResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/ens/run_instances.go b/services/ens/run_instances.go index b7aebe6d2d..b55fb5fc10 100644 --- a/services/ens/run_instances.go +++ b/services/ens/run_instances.go @@ -104,6 +104,7 @@ type RunInstancesRequest struct { Amount requests.Integer `position:"Query" name:"Amount"` AutoReleaseTime string `position:"Query" name:"AutoReleaseTime"` IpType string `position:"Query" name:"IpType"` + SpotDuration requests.Integer `position:"Query" name:"SpotDuration"` DataDisk *[]RunInstancesDataDisk `position:"Query" name:"DataDisk" type:"Json"` SchedulingStrategy string `position:"Query" name:"SchedulingStrategy"` Carrier string `position:"Query" name:"Carrier"` diff --git a/services/ens/struct_eip_addresses_in_describe_ens_eip_addresses.go b/services/ens/struct_associated_eip_addresses.go similarity index 78% rename from services/ens/struct_eip_addresses_in_describe_ens_eip_addresses.go rename to services/ens/struct_associated_eip_addresses.go index 2b95e82cf5..7eddf9f183 100644 --- a/services/ens/struct_eip_addresses_in_describe_ens_eip_addresses.go +++ b/services/ens/struct_associated_eip_addresses.go @@ -15,7 +15,7 @@ package ens // Code generated by Alibaba Cloud SDK Code Generator. // Changes may cause incorrect behavior and will be lost if the code is regenerated. -// EipAddressesInDescribeEnsEipAddresses is a nested struct in ens response -type EipAddressesInDescribeEnsEipAddresses struct { - EipAddress []EipAddress `json:"EipAddress" xml:"EipAddress"` +// AssociatedEipAddresses is a nested struct in ens response +type AssociatedEipAddresses struct { + Eip []Eip `json:"eip" xml:"eip"` } diff --git a/services/ens/struct_associated_instances.go b/services/ens/struct_associated_instances.go new file mode 100644 index 0000000000..72c893c4f0 --- /dev/null +++ b/services/ens/struct_associated_instances.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// AssociatedInstances is a nested struct in ens response +type AssociatedInstances struct { + Relation []Relation `json:"relation" xml:"relation"` +} diff --git a/services/ens/struct_bandwidth.go b/services/ens/struct_bandwidth.go index eac38d4185..14eb068acd 100644 --- a/services/ens/struct_bandwidth.go +++ b/services/ens/struct_bandwidth.go @@ -17,16 +17,27 @@ package ens // Bandwidth is a nested struct in ens response type Bandwidth struct { + FlowType int `json:"FlowType" xml:"FlowType"` + UsedRatio int64 `json:"UsedRatio" xml:"UsedRatio"` Display bool `json:"Display" xml:"Display"` - OversellRatio int64 `json:"OversellRatio" xml:"OversellRatio"` + RxBw int64 `json:"RxBw" xml:"RxBw"` + Ip string `json:"Ip" xml:"Ip"` + ReserveDisableTotal int64 `json:"ReserveDisableTotal" xml:"ReserveDisableTotal"` + EnsRegionId string `json:"EnsRegionId" xml:"EnsRegionId"` + TxBw int64 `json:"TxBw" xml:"TxBw"` Remain int64 `json:"Remain" xml:"Remain"` - Reserved int64 `json:"Reserved" xml:"Reserved"` + InstanceType string `json:"InstanceType" xml:"InstanceType"` + StatusDisableTotal int64 `json:"StatusDisableTotal" xml:"StatusDisableTotal"` ReserveDisable bool `json:"ReserveDisable" xml:"ReserveDisable"` - ReserveDisableTotal int64 `json:"ReserveDisableTotal" xml:"ReserveDisableTotal"` + Used int64 `json:"Used" xml:"Used"` + OversellRatio int64 `json:"OversellRatio" xml:"OversellRatio"` StatusDisable bool `json:"StatusDisable" xml:"StatusDisable"` - StatusDisableTotal int64 `json:"StatusDisableTotal" xml:"StatusDisableTotal"` + InstanceId string `json:"InstanceId" xml:"InstanceId"` + AliUid int64 `json:"AliUid" xml:"AliUid"` + Reserved int64 `json:"Reserved" xml:"Reserved"` + BizTime string `json:"BizTime" xml:"BizTime"` + ServiceType string `json:"ServiceType" xml:"ServiceType"` + Isp string `json:"Isp" xml:"Isp"` Total int64 `json:"Total" xml:"Total"` Type string `json:"Type" xml:"Type"` - Used int64 `json:"Used" xml:"Used"` - UsedRatio int64 `json:"UsedRatio" xml:"UsedRatio"` } diff --git a/services/ens/struct_bandwidths.go b/services/ens/struct_bandwidths.go new file mode 100644 index 0000000000..6c6a0b2754 --- /dev/null +++ b/services/ens/struct_bandwidths.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// Bandwidths is a nested struct in ens response +type Bandwidths struct { + Bandwidth []Bandwidth `json:"Bandwidth" xml:"Bandwidth"` +} diff --git a/services/ens/struct_clusters.go b/services/ens/struct_clusters.go new file mode 100644 index 0000000000..66aab0f63c --- /dev/null +++ b/services/ens/struct_clusters.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// Clusters is a nested struct in ens response +type Clusters struct { + ClustersItem []ClustersItem `json:"Clusters" xml:"Clusters"` +} diff --git a/services/ens/struct_clusters_item.go b/services/ens/struct_clusters_item.go new file mode 100644 index 0000000000..99e462f951 --- /dev/null +++ b/services/ens/struct_clusters_item.go @@ -0,0 +1,25 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// ClustersItem is a nested struct in ens response +type ClustersItem struct { + Name string `json:"Name" xml:"Name"` + ClusterId string `json:"ClusterId" xml:"ClusterId"` + CurrentVersion string `json:"CurrentVersion" xml:"CurrentVersion"` + NextVersion string `json:"NextVersion" xml:"NextVersion"` + Status string `json:"Status" xml:"Status"` +} diff --git a/services/ens/struct_disk_device_mapping.go b/services/ens/struct_disk_device_mapping.go new file mode 100644 index 0000000000..b249972e57 --- /dev/null +++ b/services/ens/struct_disk_device_mapping.go @@ -0,0 +1,24 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// DiskDeviceMapping is a nested struct in ens response +type DiskDeviceMapping struct { + Format string `json:"Format" xml:"Format"` + Size string `json:"Size" xml:"Size"` + ImageId string `json:"imageId" xml:"imageId"` + Type string `json:"Type" xml:"Type"` +} diff --git a/services/ens/struct_disk_device_mappings_in_describe_image_infos.go b/services/ens/struct_disk_device_mappings_in_describe_image_infos.go new file mode 100644 index 0000000000..f0e1ff0603 --- /dev/null +++ b/services/ens/struct_disk_device_mappings_in_describe_image_infos.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// DiskDeviceMappingsInDescribeImageInfos is a nested struct in ens response +type DiskDeviceMappingsInDescribeImageInfos struct { + DiskDeviceMapping []DiskDeviceMapping `json:"DiskDeviceMapping" xml:"DiskDeviceMapping"` +} diff --git a/services/ens/struct_disk_device_mappings_in_describe_images.go b/services/ens/struct_disk_device_mappings_in_describe_images.go new file mode 100644 index 0000000000..f6636f2ef8 --- /dev/null +++ b/services/ens/struct_disk_device_mappings_in_describe_images.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// DiskDeviceMappingsInDescribeImages is a nested struct in ens response +type DiskDeviceMappingsInDescribeImages struct { + DiskDeviceMapping []DiskDeviceMapping `json:"DiskDeviceMapping" xml:"DiskDeviceMapping"` +} diff --git a/services/ens/struct_disk_device_mappings_in_describe_self_images.go b/services/ens/struct_disk_device_mappings_in_describe_self_images.go new file mode 100644 index 0000000000..d9a35fef42 --- /dev/null +++ b/services/ens/struct_disk_device_mappings_in_describe_self_images.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// DiskDeviceMappingsInDescribeSelfImages is a nested struct in ens response +type DiskDeviceMappingsInDescribeSelfImages struct { + DiskDeviceMapping []DiskDeviceMapping `json:"DiskDeviceMapping" xml:"DiskDeviceMapping"` +} diff --git a/services/ens/struct_disk_iops.go b/services/ens/struct_disk_iops.go new file mode 100644 index 0000000000..ab4fb8d8a2 --- /dev/null +++ b/services/ens/struct_disk_iops.go @@ -0,0 +1,29 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// DiskIops is a nested struct in ens response +type DiskIops struct { + DiskId string `json:"DiskId" xml:"DiskId"` + RegionId string `json:"RegionId" xml:"RegionId"` + ReadBytes int64 `json:"ReadBytes" xml:"ReadBytes"` + ReadLatency int64 `json:"ReadLatency" xml:"ReadLatency"` + ReadOps int64 `json:"ReadOps" xml:"ReadOps"` + WriteBytes int64 `json:"WriteBytes" xml:"WriteBytes"` + WriteLatency int64 `json:"WriteLatency" xml:"WriteLatency"` + WriteOps int64 `json:"WriteOps" xml:"WriteOps"` + BizTime string `json:"BizTime" xml:"BizTime"` +} diff --git a/services/ens/struct_disk_iops_list.go b/services/ens/struct_disk_iops_list.go new file mode 100644 index 0000000000..71a4809d38 --- /dev/null +++ b/services/ens/struct_disk_iops_list.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// DiskIopsList is a nested struct in ens response +type DiskIopsList struct { + DiskIops []DiskIops `json:"DiskIops" xml:"DiskIops"` +} diff --git a/services/ens/struct_eip.go b/services/ens/struct_eip.go new file mode 100644 index 0000000000..d51e87967f --- /dev/null +++ b/services/ens/struct_eip.go @@ -0,0 +1,22 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// Eip is a nested struct in ens response +type Eip struct { + EipId string `json:"EipId" xml:"EipId"` + Eip string `json:"Eip" xml:"Eip"` +} diff --git a/services/ens/struct_eip_address.go b/services/ens/struct_eip_address.go index b958664686..cb01824847 100644 --- a/services/ens/struct_eip_address.go +++ b/services/ens/struct_eip_address.go @@ -17,21 +17,19 @@ package ens // EipAddress is a nested struct in ens response type EipAddress struct { - Name string `json:"Name" xml:"Name"` - IpStatus string `json:"IpStatus" xml:"IpStatus"` - InstanceIdInternetIp string `json:"InstanceIdInternetIp" xml:"InstanceIdInternetIp"` - IpAddress string `json:"IpAddress" xml:"IpAddress"` - Standby bool `json:"Standby" xml:"Standby"` - ChargeType string `json:"ChargeType" xml:"ChargeType"` - AllocationTime string `json:"AllocationTime" xml:"AllocationTime"` - EnsRegionId string `json:"EnsRegionId" xml:"EnsRegionId"` - InstanceType string `json:"InstanceType" xml:"InstanceType"` - AllocationId string `json:"AllocationId" xml:"AllocationId"` - Bandwidth int `json:"Bandwidth" xml:"Bandwidth"` - InstanceId string `json:"InstanceId" xml:"InstanceId"` - InternetChargeType string `json:"InternetChargeType" xml:"InternetChargeType"` - Eip string `json:"Eip" xml:"Eip"` - Status string `json:"Status" xml:"Status"` - Isp string `json:"Isp" xml:"Isp"` - Description string `json:"Description" xml:"Description"` + AllocationId string `json:"AllocationId" xml:"AllocationId"` + AllocationTime string `json:"AllocationTime" xml:"AllocationTime"` + Bandwidth int `json:"Bandwidth" xml:"Bandwidth"` + ChargeType string `json:"ChargeType" xml:"ChargeType"` + Description string `json:"Description" xml:"Description"` + InstanceId string `json:"InstanceId" xml:"InstanceId"` + InstanceType string `json:"InstanceType" xml:"InstanceType"` + InternetChargeType string `json:"InternetChargeType" xml:"InternetChargeType"` + IpAddress string `json:"IpAddress" xml:"IpAddress"` + Name string `json:"Name" xml:"Name"` + EnsRegionId string `json:"EnsRegionId" xml:"EnsRegionId"` + Status string `json:"Status" xml:"Status"` + Isp string `json:"Isp" xml:"Isp"` + Standby bool `json:"Standby" xml:"Standby"` + IpStatus string `json:"IpStatus" xml:"IpStatus"` } diff --git a/services/ens/struct_eip_addresses_in_describe_eip_addresses.go b/services/ens/struct_eip_addresses.go similarity index 86% rename from services/ens/struct_eip_addresses_in_describe_eip_addresses.go rename to services/ens/struct_eip_addresses.go index f642c8c601..15008e1c31 100644 --- a/services/ens/struct_eip_addresses_in_describe_eip_addresses.go +++ b/services/ens/struct_eip_addresses.go @@ -15,7 +15,7 @@ package ens // Code generated by Alibaba Cloud SDK Code Generator. // Changes may cause incorrect behavior and will be lost if the code is regenerated. -// EipAddressesInDescribeEipAddresses is a nested struct in ens response -type EipAddressesInDescribeEipAddresses struct { +// EipAddresses is a nested struct in ens response +type EipAddresses struct { EipAddress []EipAddress `json:"EipAddress" xml:"EipAddress"` } diff --git a/services/ens/struct_elb_listen_monitor_list.go b/services/ens/struct_elb_listen_monitor_list.go new file mode 100644 index 0000000000..e058c98fee --- /dev/null +++ b/services/ens/struct_elb_listen_monitor_list.go @@ -0,0 +1,41 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// ElbListenMonitorList is a nested struct in ens response +type ElbListenMonitorList struct { + LoadBalancerId string `json:"LoadBalancerId" xml:"LoadBalancerId"` + EnsRegionId string `json:"EnsRegionId" xml:"EnsRegionId"` + Vip string `json:"Vip" xml:"Vip"` + Vni string `json:"Vni" xml:"Vni"` + VPort string `json:"VPort" xml:"VPort"` + Proto string `json:"Proto" xml:"Proto"` + Conns string `json:"Conns" xml:"Conns"` + ActConns string `json:"ActConns" xml:"ActConns"` + InActConns string `json:"InActConns" xml:"InActConns"` + DropConns string `json:"DropConns" xml:"DropConns"` + InPkts string `json:"InPkts" xml:"InPkts"` + OutPkts string `json:"OutPkts" xml:"OutPkts"` + InDropPkts string `json:"InDropPkts" xml:"InDropPkts"` + OutDropPkts string `json:"OutDropPkts" xml:"OutDropPkts"` + InBytes string `json:"InBytes" xml:"InBytes"` + OutBytes string `json:"OutBytes" xml:"OutBytes"` + InDropBytes string `json:"InDropBytes" xml:"InDropBytes"` + OutDropBytes string `json:"OutDropBytes" xml:"OutDropBytes"` + ValidRsNum string `json:"ValidRsNum" xml:"ValidRsNum"` + InValidRsNum string `json:"InValidRsNum" xml:"InValidRsNum"` + BizTime string `json:"BizTime" xml:"BizTime"` +} diff --git a/services/ens/struct_eslb_monitor_list.go b/services/ens/struct_eslb_monitor_list.go new file mode 100644 index 0000000000..6d3830977f --- /dev/null +++ b/services/ens/struct_eslb_monitor_list.go @@ -0,0 +1,35 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// EslbMonitorList is a nested struct in ens response +type EslbMonitorList struct { + Vip string `json:"Vip" xml:"Vip"` + RtAvg int `json:"RtAvg" xml:"RtAvg"` + Vni int `json:"Vni" xml:"Vni"` + Proto string `json:"Proto" xml:"Proto"` + EnsRegionId string `json:"EnsRegionId" xml:"EnsRegionId"` + LoadBalancerSpec string `json:"LoadBalancerSpec" xml:"LoadBalancerSpec"` + Vport int `json:"Vport" xml:"Vport"` + Reqs4xx int `json:"Reqs4xx" xml:"Reqs4xx"` + LoadBalancerId string `json:"LoadBalancerId" xml:"LoadBalancerId"` + Reqs5xx int `json:"Reqs5xx" xml:"Reqs5xx"` + Reqs2xx int `json:"Reqs2xx" xml:"Reqs2xx"` + Reqs3xx int `json:"Reqs3xx" xml:"Reqs3xx"` + LoadBalancerName string `json:"LoadBalancerName" xml:"LoadBalancerName"` + BizTime string `json:"BizTime" xml:"BizTime"` + Acc int `json:"Acc" xml:"Acc"` +} diff --git a/services/ens/struct_ha_vip.go b/services/ens/struct_ha_vip.go new file mode 100644 index 0000000000..732ef99698 --- /dev/null +++ b/services/ens/struct_ha_vip.go @@ -0,0 +1,31 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// HaVip is a nested struct in ens response +type HaVip struct { + Status string `json:"Status" xml:"Status"` + CreationTime string `json:"CreationTime" xml:"CreationTime"` + Description string `json:"Description" xml:"Description"` + HaVipId string `json:"HaVipId" xml:"HaVipId"` + Name string `json:"Name" xml:"Name"` + EnsRegionId string `json:"EnsRegionId" xml:"EnsRegionId"` + NetworkId string `json:"NetworkId" xml:"NetworkId"` + VSwitchId string `json:"VSwitchId" xml:"VSwitchId"` + IpAddress string `json:"IpAddress" xml:"IpAddress"` + AssociatedEipAddresses []Eip `json:"AssociatedEipAddresses" xml:"AssociatedEipAddresses"` + AssociatedInstances []Relation `json:"AssociatedInstances" xml:"AssociatedInstances"` +} diff --git a/services/ens/struct_ha_vips.go b/services/ens/struct_ha_vips.go new file mode 100644 index 0000000000..0bbb6d8164 --- /dev/null +++ b/services/ens/struct_ha_vips.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// HaVips is a nested struct in ens response +type HaVips struct { + HaVip []HaVip `json:"HaVip" xml:"HaVip"` +} diff --git a/services/ens/struct_image_in_describe_image_infos.go b/services/ens/struct_image_in_describe_image_infos.go index 2d6886fc7b..0e622802f2 100644 --- a/services/ens/struct_image_in_describe_image_infos.go +++ b/services/ens/struct_image_in_describe_image_infos.go @@ -17,11 +17,12 @@ package ens // ImageInDescribeImageInfos is a nested struct in ens response type ImageInDescribeImageInfos struct { - Description string `json:"Description" xml:"Description"` - ImageId string `json:"ImageId" xml:"ImageId"` - ImageSize string `json:"ImageSize" xml:"ImageSize"` - ImageVersion string `json:"ImageVersion" xml:"ImageVersion"` - OSName string `json:"OSName" xml:"OSName"` - OSType string `json:"OSType" xml:"OSType"` - ComputeType string `json:"ComputeType" xml:"ComputeType"` + Description string `json:"Description" xml:"Description"` + ImageId string `json:"ImageId" xml:"ImageId"` + ImageSize string `json:"ImageSize" xml:"ImageSize"` + ImageVersion string `json:"ImageVersion" xml:"ImageVersion"` + OSName string `json:"OSName" xml:"OSName"` + OSType string `json:"OSType" xml:"OSType"` + ComputeType string `json:"ComputeType" xml:"ComputeType"` + DiskDeviceMappings DiskDeviceMappingsInDescribeImageInfos `json:"DiskDeviceMappings" xml:"DiskDeviceMappings"` } diff --git a/services/ens/struct_image_in_describe_images.go b/services/ens/struct_image_in_describe_images.go index 23a8df8ee4..ad3144cadf 100644 --- a/services/ens/struct_image_in_describe_images.go +++ b/services/ens/struct_image_in_describe_images.go @@ -17,12 +17,13 @@ package ens // ImageInDescribeImages is a nested struct in ens response type ImageInDescribeImages struct { - Architecture string `json:"Architecture" xml:"Architecture"` - CreationTime string `json:"CreationTime" xml:"CreationTime"` - ImageId string `json:"ImageId" xml:"ImageId"` - ImageName string `json:"ImageName" xml:"ImageName"` - ImageOwnerAlias string `json:"ImageOwnerAlias" xml:"ImageOwnerAlias"` - ImageSize string `json:"ImageSize" xml:"ImageSize"` - Platform string `json:"Platform" xml:"Platform"` - SnapshotId string `json:"SnapshotId" xml:"SnapshotId"` + Architecture string `json:"Architecture" xml:"Architecture"` + CreationTime string `json:"CreationTime" xml:"CreationTime"` + ImageId string `json:"ImageId" xml:"ImageId"` + ImageName string `json:"ImageName" xml:"ImageName"` + ImageOwnerAlias string `json:"ImageOwnerAlias" xml:"ImageOwnerAlias"` + ImageSize string `json:"ImageSize" xml:"ImageSize"` + Platform string `json:"Platform" xml:"Platform"` + SnapshotId string `json:"SnapshotId" xml:"SnapshotId"` + DiskDeviceMappings DiskDeviceMappingsInDescribeImages `json:"DiskDeviceMappings" xml:"DiskDeviceMappings"` } diff --git a/services/ens/struct_image_in_describe_self_images.go b/services/ens/struct_image_in_describe_self_images.go index 726ddb12f5..e40a02b181 100644 --- a/services/ens/struct_image_in_describe_self_images.go +++ b/services/ens/struct_image_in_describe_self_images.go @@ -17,17 +17,18 @@ package ens // ImageInDescribeSelfImages is a nested struct in ens response type ImageInDescribeSelfImages struct { - Architecture string `json:"Architecture" xml:"Architecture"` - CreationTime string `json:"CreationTime" xml:"CreationTime"` - ImageId string `json:"ImageId" xml:"ImageId"` - ImageName string `json:"ImageName" xml:"ImageName"` - ImageOwnerAlias string `json:"ImageOwnerAlias" xml:"ImageOwnerAlias"` - ImageSize string `json:"ImageSize" xml:"ImageSize"` - InstanceId string `json:"InstanceId" xml:"InstanceId"` - OsVersion string `json:"OsVersion" xml:"OsVersion"` - Platform string `json:"Platform" xml:"Platform"` - Status string `json:"Status" xml:"Status"` - ComputeType string `json:"ComputeType" xml:"ComputeType"` - SnapshotId string `json:"SnapshotId" xml:"SnapshotId"` - ImageStorageSize string `json:"ImageStorageSize" xml:"ImageStorageSize"` + Architecture string `json:"Architecture" xml:"Architecture"` + CreationTime string `json:"CreationTime" xml:"CreationTime"` + ImageId string `json:"ImageId" xml:"ImageId"` + ImageName string `json:"ImageName" xml:"ImageName"` + ImageOwnerAlias string `json:"ImageOwnerAlias" xml:"ImageOwnerAlias"` + ImageSize string `json:"ImageSize" xml:"ImageSize"` + InstanceId string `json:"InstanceId" xml:"InstanceId"` + OsVersion string `json:"OsVersion" xml:"OsVersion"` + Platform string `json:"Platform" xml:"Platform"` + Status string `json:"Status" xml:"Status"` + ComputeType string `json:"ComputeType" xml:"ComputeType"` + SnapshotId string `json:"SnapshotId" xml:"SnapshotId"` + ImageStorageSize string `json:"ImageStorageSize" xml:"ImageStorageSize"` + DiskDeviceMappings DiskDeviceMappingsInDescribeSelfImages `json:"DiskDeviceMappings" xml:"DiskDeviceMappings"` } diff --git a/services/ens/struct_instance.go b/services/ens/struct_instance.go index d42e6c952f..b1753da180 100644 --- a/services/ens/struct_instance.go +++ b/services/ens/struct_instance.go @@ -34,6 +34,7 @@ type Instance struct { CreationTime string `json:"CreationTime" xml:"CreationTime"` EnsRegionId string `json:"EnsRegionId" xml:"EnsRegionId"` StartTime string `json:"StartTime" xml:"StartTime"` + KeyPairName string `json:"KeyPairName" xml:"KeyPairName"` InternetMaxBandwidthIn int `json:"InternetMaxBandwidthIn" xml:"InternetMaxBandwidthIn"` Disk int `json:"Disk" xml:"Disk"` HostName string `json:"HostName" xml:"HostName"` @@ -47,5 +48,6 @@ type Instance struct { DataDisk DataDisk `json:"DataDisk" xml:"DataDisk"` Tags Tags `json:"Tags" xml:"Tags"` PublicIpAddresses PublicIpAddresses `json:"PublicIpAddresses" xml:"PublicIpAddresses"` + NetworkInterfaces NetworkInterfaces `json:"NetworkInterfaces" xml:"NetworkInterfaces"` PrivateIpAddresses PrivateIpAddresses `json:"PrivateIpAddresses" xml:"PrivateIpAddresses"` } diff --git a/services/ens/struct_ip.go b/services/ens/struct_ip.go new file mode 100644 index 0000000000..2dd4156df4 --- /dev/null +++ b/services/ens/struct_ip.go @@ -0,0 +1,28 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// Ip is a nested struct in ens response +type Ip struct { + CidrMask int `json:"CidrMask" xml:"CidrMask"` + Gateway string `json:"Gateway" xml:"Gateway"` + SecondaryPublicIpAddress string `json:"SecondaryPublicIpAddress" xml:"SecondaryPublicIpAddress"` + Isp string `json:"Isp" xml:"Isp"` + SecondaryPublicIpId string `json:"SecondaryPublicIpId" xml:"SecondaryPublicIpId"` + EnsRegionId string `json:"EnsRegionId" xml:"EnsRegionId"` + CreationTime string `json:"CreationTime" xml:"CreationTime"` + IpVersion string `json:"IpVersion" xml:"IpVersion"` +} diff --git a/services/ens/struct_ipv6_set.go b/services/ens/struct_ipv6_set.go new file mode 100644 index 0000000000..5695e519d3 --- /dev/null +++ b/services/ens/struct_ipv6_set.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// Ipv6Set is a nested struct in ens response +type Ipv6Set struct { + Ipv6Address string `json:"Ipv6Address" xml:"Ipv6Address"` +} diff --git a/services/ens/struct_ipv6_sets_in_describe_instances.go b/services/ens/struct_ipv6_sets_in_describe_instances.go new file mode 100644 index 0000000000..76c2577e06 --- /dev/null +++ b/services/ens/struct_ipv6_sets_in_describe_instances.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// Ipv6SetsInDescribeInstances is a nested struct in ens response +type Ipv6SetsInDescribeInstances struct { + Ipv6Set []Ipv6Set `json:"Ipv6Set" xml:"Ipv6Set"` +} diff --git a/services/ens/struct_ipv6_sets_in_describe_network_interfaces.go b/services/ens/struct_ipv6_sets_in_describe_network_interfaces.go new file mode 100644 index 0000000000..270b893857 --- /dev/null +++ b/services/ens/struct_ipv6_sets_in_describe_network_interfaces.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// Ipv6SetsInDescribeNetworkInterfaces is a nested struct in ens response +type Ipv6SetsInDescribeNetworkInterfaces struct { + Ipv6Set []Ipv6Set `json:"Ipv6Set" xml:"Ipv6Set"` +} diff --git a/services/ens/struct_listener.go b/services/ens/struct_listener.go index a384b06675..ab854b35eb 100644 --- a/services/ens/struct_listener.go +++ b/services/ens/struct_listener.go @@ -17,9 +17,9 @@ package ens // Listener is a nested struct in ens response type Listener struct { + ForwardPort int `json:"ForwardPort" xml:"ForwardPort"` + ListenerForward string `json:"ListenerForward" xml:"ListenerForward"` ListenerPort int `json:"ListenerPort" xml:"ListenerPort"` ListenerProtocol string `json:"ListenerProtocol" xml:"ListenerProtocol"` Description string `json:"Description" xml:"Description"` - ListenerForward string `json:"ListenerForward" xml:"ListenerForward"` - ForwardPort int `json:"ForwardPort" xml:"ForwardPort"` } diff --git a/services/ens/struct_listener_in_describe_load_balancer_listeners.go b/services/ens/struct_listener_in_describe_load_balancer_listeners.go new file mode 100644 index 0000000000..81fbac4405 --- /dev/null +++ b/services/ens/struct_listener_in_describe_load_balancer_listeners.go @@ -0,0 +1,28 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// ListenerInDescribeLoadBalancerListeners is a nested struct in ens response +type ListenerInDescribeLoadBalancerListeners struct { + LoadBalancerId string `json:"LoadBalancerId" xml:"LoadBalancerId"` + ListenerPort string `json:"ListenerPort" xml:"ListenerPort"` + Protocol string `json:"Protocol" xml:"Protocol"` + Description string `json:"Description" xml:"Description"` + Status string `json:"Status" xml:"Status"` + ListenerForward string `json:"ListenerForward" xml:"ListenerForward"` + ForwardPort string `json:"ForwardPort" xml:"ForwardPort"` + CreateTime string `json:"CreateTime" xml:"CreateTime"` +} diff --git a/services/ens/struct_listeners.go b/services/ens/struct_listeners.go new file mode 100644 index 0000000000..0c31b65aca --- /dev/null +++ b/services/ens/struct_listeners.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// Listeners is a nested struct in ens response +type Listeners struct { + Listener []ListenerInDescribeLoadBalancerListeners `json:"Listener" xml:"Listener"` +} diff --git a/services/ens/struct_load_balancer_monitor_listen_data.go b/services/ens/struct_load_balancer_monitor_listen_data.go new file mode 100644 index 0000000000..c45ae9d3bf --- /dev/null +++ b/services/ens/struct_load_balancer_monitor_listen_data.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// LoadBalancerMonitorListenData is a nested struct in ens response +type LoadBalancerMonitorListenData struct { + ElbListenMonitorList []ElbListenMonitorList `json:"ElbListenMonitorList" xml:"ElbListenMonitorList"` +} diff --git a/services/ens/struct_network_interface_set.go b/services/ens/struct_network_interface_set.go index a081de6e0c..9c3387ba7d 100644 --- a/services/ens/struct_network_interface_set.go +++ b/services/ens/struct_network_interface_set.go @@ -32,5 +32,6 @@ type NetworkInterfaceSet struct { Description string `json:"Description" xml:"Description"` Type string `json:"Type" xml:"Type"` SecurityGroupIds SecurityGroupIdsInDescribeNetworkInterfaces `json:"SecurityGroupIds" xml:"SecurityGroupIds"` - PrivateIpSets PrivateIpSets `json:"PrivateIpSets" xml:"PrivateIpSets"` + PrivateIpSets PrivateIpSetsInDescribeNetworkInterfaces `json:"PrivateIpSets" xml:"PrivateIpSets"` + Ipv6Sets Ipv6SetsInDescribeNetworkInterfaces `json:"Ipv6Sets" xml:"Ipv6Sets"` } diff --git a/services/ens/struct_network_interfaces.go b/services/ens/struct_network_interfaces.go new file mode 100644 index 0000000000..04b8e78013 --- /dev/null +++ b/services/ens/struct_network_interfaces.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// NetworkInterfaces is a nested struct in ens response +type NetworkInterfaces struct { + NetworkInterfacesItem []NetworkInterfacesItem `json:"NetworkInterfaces" xml:"NetworkInterfaces"` +} diff --git a/services/ens/struct_network_interfaces_item.go b/services/ens/struct_network_interfaces_item.go new file mode 100644 index 0000000000..79ae406b70 --- /dev/null +++ b/services/ens/struct_network_interfaces_item.go @@ -0,0 +1,26 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// NetworkInterfacesItem is a nested struct in ens response +type NetworkInterfacesItem struct { + Type string `json:"Type" xml:"Type"` + MacAddress string `json:"MacAddress" xml:"MacAddress"` + PrimaryIpAddress string `json:"PrimaryIpAddress" xml:"PrimaryIpAddress"` + NetworkInterfaceId string `json:"NetworkInterfaceId" xml:"NetworkInterfaceId"` + PrivateIpSets PrivateIpSetsInDescribeInstances `json:"PrivateIpSets" xml:"PrivateIpSets"` + Ipv6Sets Ipv6SetsInDescribeInstances `json:"Ipv6Sets" xml:"Ipv6Sets"` +} diff --git a/services/ens/struct_private_ip_sets.go b/services/ens/struct_private_ip_sets_in_describe_instances.go similarity index 86% rename from services/ens/struct_private_ip_sets.go rename to services/ens/struct_private_ip_sets_in_describe_instances.go index 5b71106c28..089621e320 100644 --- a/services/ens/struct_private_ip_sets.go +++ b/services/ens/struct_private_ip_sets_in_describe_instances.go @@ -15,7 +15,7 @@ package ens // Code generated by Alibaba Cloud SDK Code Generator. // Changes may cause incorrect behavior and will be lost if the code is regenerated. -// PrivateIpSets is a nested struct in ens response -type PrivateIpSets struct { +// PrivateIpSetsInDescribeInstances is a nested struct in ens response +type PrivateIpSetsInDescribeInstances struct { PrivateIpSet []PrivateIpSet `json:"PrivateIpSet" xml:"PrivateIpSet"` } diff --git a/services/ens/struct_private_ip_sets_in_describe_network_interfaces.go b/services/ens/struct_private_ip_sets_in_describe_network_interfaces.go new file mode 100644 index 0000000000..7726a5403b --- /dev/null +++ b/services/ens/struct_private_ip_sets_in_describe_network_interfaces.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// PrivateIpSetsInDescribeNetworkInterfaces is a nested struct in ens response +type PrivateIpSetsInDescribeNetworkInterfaces struct { + PrivateIpSet []PrivateIpSet `json:"PrivateIpSet" xml:"PrivateIpSet"` +} diff --git a/services/ens/struct_relation.go b/services/ens/struct_relation.go new file mode 100644 index 0000000000..4bf90b630d --- /dev/null +++ b/services/ens/struct_relation.go @@ -0,0 +1,25 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// Relation is a nested struct in ens response +type Relation struct { + InstanceId string `json:"InstanceId" xml:"InstanceId"` + InstanceType string `json:"InstanceType" xml:"InstanceType"` + IpAddress string `json:"IpAddress" xml:"IpAddress"` + Status string `json:"Status" xml:"Status"` + CreationTime string `json:"CreationTime" xml:"CreationTime"` +} diff --git a/services/ens/struct_secondary_public_ip_addresses.go b/services/ens/struct_secondary_public_ip_addresses.go new file mode 100644 index 0000000000..5eb8f625e8 --- /dev/null +++ b/services/ens/struct_secondary_public_ip_addresses.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// SecondaryPublicIpAddresses is a nested struct in ens response +type SecondaryPublicIpAddresses struct { + Ip []Ip `json:"ip" xml:"ip"` +} diff --git a/services/ens/struct_server_load_balancer_monitor_data_in_describe_server_load_balancer_listen_monitor.go b/services/ens/struct_server_load_balancer_monitor_data_in_describe_server_load_balancer_listen_monitor.go new file mode 100644 index 0000000000..fb24c88f33 --- /dev/null +++ b/services/ens/struct_server_load_balancer_monitor_data_in_describe_server_load_balancer_listen_monitor.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// ServerLoadBalancerMonitorDataInDescribeServerLoadBalancerListenMonitor is a nested struct in ens response +type ServerLoadBalancerMonitorDataInDescribeServerLoadBalancerListenMonitor struct { + EslbMonitorList []EslbMonitorList `json:"EslbMonitorList" xml:"EslbMonitorList"` +} diff --git a/services/ens/struct_server_load_balancer_monitor_data_in_describe_server_load_balancer_monitor.go b/services/ens/struct_server_load_balancer_monitor_data_in_describe_server_load_balancer_monitor.go new file mode 100644 index 0000000000..d3a3bd7cc7 --- /dev/null +++ b/services/ens/struct_server_load_balancer_monitor_data_in_describe_server_load_balancer_monitor.go @@ -0,0 +1,21 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +// ServerLoadBalancerMonitorDataInDescribeServerLoadBalancerMonitor is a nested struct in ens response +type ServerLoadBalancerMonitorDataInDescribeServerLoadBalancerMonitor struct { + EslbMonitorList []EslbMonitorList `json:"EslbMonitorList" xml:"EslbMonitorList"` +} diff --git a/services/ens/unassociate_ha_vip.go b/services/ens/unassociate_ha_vip.go new file mode 100644 index 0000000000..1ecdbecadc --- /dev/null +++ b/services/ens/unassociate_ha_vip.go @@ -0,0 +1,100 @@ +package ens + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// UnassociateHaVip invokes the ens.UnassociateHaVip API synchronously +func (client *Client) UnassociateHaVip(request *UnassociateHaVipRequest) (response *UnassociateHaVipResponse, err error) { + response = CreateUnassociateHaVipResponse() + err = client.DoAction(request, response) + return +} + +// UnassociateHaVipWithChan invokes the ens.UnassociateHaVip API asynchronously +func (client *Client) UnassociateHaVipWithChan(request *UnassociateHaVipRequest) (<-chan *UnassociateHaVipResponse, <-chan error) { + responseChan := make(chan *UnassociateHaVipResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.UnassociateHaVip(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// UnassociateHaVipWithCallback invokes the ens.UnassociateHaVip API asynchronously +func (client *Client) UnassociateHaVipWithCallback(request *UnassociateHaVipRequest, callback func(response *UnassociateHaVipResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *UnassociateHaVipResponse + var err error + defer close(result) + response, err = client.UnassociateHaVip(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// UnassociateHaVipRequest is the request struct for api UnassociateHaVip +type UnassociateHaVipRequest struct { + *requests.RpcRequest + HaVipId string `position:"Query" name:"HaVipId"` + InstanceId string `position:"Query" name:"InstanceId"` +} + +// UnassociateHaVipResponse is the response struct for api UnassociateHaVip +type UnassociateHaVipResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` +} + +// CreateUnassociateHaVipRequest creates a request to invoke UnassociateHaVip API +func CreateUnassociateHaVipRequest() (request *UnassociateHaVipRequest) { + request = &UnassociateHaVipRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Ens", "2017-11-10", "UnassociateHaVip", "ens", "openAPI") + request.Method = requests.POST + return +} + +// CreateUnassociateHaVipResponse creates a response to parse from UnassociateHaVip response +func CreateUnassociateHaVipResponse() (response *UnassociateHaVipResponse) { + response = &UnassociateHaVipResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +}