diff --git a/ChangeLog.txt b/ChangeLog.txt index e6ea7b4663..b3b43b83c8 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -1,3 +1,7 @@ +2023-07-19 Version: v1.62.455 +- Generated 2020-01-01 for `Dts`. +- Update SDK version. + 2023-07-19 Version: v1.62.454 - Generated 2019-09-01 for `Dts`. - Update SDK version. diff --git a/services/dts/configure_dts_job.go b/services/dts/configure_dts_job.go new file mode 100644 index 0000000000..b07a7b0b29 --- /dev/null +++ b/services/dts/configure_dts_job.go @@ -0,0 +1,151 @@ +package dts + +//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" +) + +// ConfigureDtsJob invokes the dts.ConfigureDtsJob API synchronously +func (client *Client) ConfigureDtsJob(request *ConfigureDtsJobRequest) (response *ConfigureDtsJobResponse, err error) { + response = CreateConfigureDtsJobResponse() + err = client.DoAction(request, response) + return +} + +// ConfigureDtsJobWithChan invokes the dts.ConfigureDtsJob API asynchronously +func (client *Client) ConfigureDtsJobWithChan(request *ConfigureDtsJobRequest) (<-chan *ConfigureDtsJobResponse, <-chan error) { + responseChan := make(chan *ConfigureDtsJobResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ConfigureDtsJob(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ConfigureDtsJobWithCallback invokes the dts.ConfigureDtsJob API asynchronously +func (client *Client) ConfigureDtsJobWithCallback(request *ConfigureDtsJobRequest, callback func(response *ConfigureDtsJobResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ConfigureDtsJobResponse + var err error + defer close(result) + response, err = client.ConfigureDtsJob(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ConfigureDtsJobRequest is the request struct for api ConfigureDtsJob +type ConfigureDtsJobRequest struct { + *requests.RpcRequest + Checkpoint string `position:"Query" name:"Checkpoint"` + SourceEndpointUserName string `position:"Query" name:"SourceEndpointUserName"` + DestinationEndpointOwnerID string `position:"Query" name:"DestinationEndpointOwnerID"` + DelayPhone string `position:"Query" name:"DelayPhone"` + DtsBisLabel string `position:"Query" name:"DtsBisLabel"` + SourceEndpointIP string `position:"Query" name:"SourceEndpointIP"` + ErrorPhone string `position:"Query" name:"ErrorPhone"` + DestinationEndpointUserName string `position:"Query" name:"DestinationEndpointUserName"` + DtsJobId string `position:"Query" name:"DtsJobId"` + DestinationEndpointRole string `position:"Query" name:"DestinationEndpointRole"` + DbList string `position:"Body" name:"DbList"` + DestinationEndpointOracleSID string `position:"Query" name:"DestinationEndpointOracleSID"` + DestinationEndpointPort string `position:"Query" name:"DestinationEndpointPort"` + SourceEndpointPassword string `position:"Query" name:"SourceEndpointPassword"` + OwnerId string `position:"Query" name:"OwnerId"` + JobType string `position:"Query" name:"JobType"` + DelayRuleTime requests.Integer `position:"Query" name:"DelayRuleTime"` + DisasterRecoveryJob requests.Boolean `position:"Query" name:"DisasterRecoveryJob"` + DestinationEndpointIP string `position:"Query" name:"DestinationEndpointIP"` + SourceEndpointInstanceType string `position:"Query" name:"SourceEndpointInstanceType"` + DtsJobName string `position:"Query" name:"DtsJobName"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` + SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` + SourceEndpointRegion string `position:"Query" name:"SourceEndpointRegion"` + DelayNotice requests.Boolean `position:"Query" name:"DelayNotice"` + DestinationEndpointInstanceType string `position:"Query" name:"DestinationEndpointInstanceType"` + DataInitialization requests.Boolean `position:"Query" name:"DataInitialization"` + SourceEndpointInstanceID string `position:"Query" name:"SourceEndpointInstanceID"` + StructureInitialization requests.Boolean `position:"Query" name:"StructureInitialization"` + SourceEndpointOwnerID string `position:"Query" name:"SourceEndpointOwnerID"` + DedicatedClusterId string `position:"Query" name:"DedicatedClusterId"` + SourceEndpointDatabaseName string `position:"Query" name:"SourceEndpointDatabaseName"` + DestinationEndpointRegion string `position:"Query" name:"DestinationEndpointRegion"` + DataCheckConfigure string `position:"Query" name:"DataCheckConfigure"` + Reserve string `position:"Body" name:"Reserve"` + SourceEndpointVSwitchID string `position:"Query" name:"SourceEndpointVSwitchID"` + DataSynchronization requests.Boolean `position:"Query" name:"DataSynchronization"` + FileOssUrl string `position:"Query" name:"FileOssUrl"` + DestinationEndpointEngineName string `position:"Query" name:"DestinationEndpointEngineName"` + DestinationEndpointInstanceID string `position:"Query" name:"DestinationEndpointInstanceID"` + SourceEndpointPort string `position:"Query" name:"SourceEndpointPort"` + SourceEndpointOracleSID string `position:"Query" name:"SourceEndpointOracleSID"` + DestinationEndpointDataBaseName string `position:"Query" name:"DestinationEndpointDataBaseName"` + ErrorNotice requests.Boolean `position:"Query" name:"ErrorNotice"` + SourceEndpointRole string `position:"Query" name:"SourceEndpointRole"` + DestinationEndpointPassword string `position:"Query" name:"DestinationEndpointPassword"` + SourceEndpointEngineName string `position:"Query" name:"SourceEndpointEngineName"` +} + +// ConfigureDtsJobResponse is the response struct for api ConfigureDtsJob +type ConfigureDtsJobResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + DtsInstanceId string `json:"DtsInstanceId" xml:"DtsInstanceId"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateConfigureDtsJobRequest creates a request to invoke ConfigureDtsJob API +func CreateConfigureDtsJobRequest() (request *ConfigureDtsJobRequest) { + request = &ConfigureDtsJobRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ConfigureDtsJob", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateConfigureDtsJobResponse creates a response to parse from ConfigureDtsJob response +func CreateConfigureDtsJobResponse() (response *ConfigureDtsJobResponse) { + response = &ConfigureDtsJobResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/configure_migration_job.go b/services/dts/configure_migration_job.go new file mode 100644 index 0000000000..28fb93578d --- /dev/null +++ b/services/dts/configure_migration_job.go @@ -0,0 +1,133 @@ +package dts + +//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" +) + +// ConfigureMigrationJob invokes the dts.ConfigureMigrationJob API synchronously +func (client *Client) ConfigureMigrationJob(request *ConfigureMigrationJobRequest) (response *ConfigureMigrationJobResponse, err error) { + response = CreateConfigureMigrationJobResponse() + err = client.DoAction(request, response) + return +} + +// ConfigureMigrationJobWithChan invokes the dts.ConfigureMigrationJob API asynchronously +func (client *Client) ConfigureMigrationJobWithChan(request *ConfigureMigrationJobRequest) (<-chan *ConfigureMigrationJobResponse, <-chan error) { + responseChan := make(chan *ConfigureMigrationJobResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ConfigureMigrationJob(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ConfigureMigrationJobWithCallback invokes the dts.ConfigureMigrationJob API asynchronously +func (client *Client) ConfigureMigrationJobWithCallback(request *ConfigureMigrationJobRequest, callback func(response *ConfigureMigrationJobResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ConfigureMigrationJobResponse + var err error + defer close(result) + response, err = client.ConfigureMigrationJob(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ConfigureMigrationJobRequest is the request struct for api ConfigureMigrationJob +type ConfigureMigrationJobRequest struct { + *requests.RpcRequest + SourceEndpointInstanceID string `position:"Query" name:"SourceEndpoint.InstanceID"` + Checkpoint string `position:"Query" name:"Checkpoint"` + DestinationEndpointInstanceID string `position:"Query" name:"DestinationEndpoint.InstanceID"` + SourceEndpointIP string `position:"Query" name:"SourceEndpoint.IP"` + DestinationEndpointPassword string `position:"Query" name:"DestinationEndpoint.Password"` + MigrationModeDataIntialization requests.Boolean `position:"Query" name:"MigrationMode.DataIntialization"` + AccountId string `position:"Query" name:"AccountId"` + MigrationModeStructureIntialization requests.Boolean `position:"Query" name:"MigrationMode.StructureIntialization"` + MigrationModeDataSynchronization requests.Boolean `position:"Query" name:"MigrationMode.DataSynchronization"` + DestinationEndpointRegion string `position:"Query" name:"DestinationEndpoint.Region"` + SourceEndpointUserName string `position:"Query" name:"SourceEndpoint.UserName"` + SourceEndpointDatabaseName string `position:"Query" name:"SourceEndpoint.DatabaseName"` + SourceEndpointPort string `position:"Query" name:"SourceEndpoint.Port"` + SourceEndpointOwnerID string `position:"Query" name:"SourceEndpoint.OwnerID"` + DestinationEndpointPort string `position:"Query" name:"DestinationEndpoint.Port"` + SourceEndpointRole string `position:"Query" name:"SourceEndpoint.Role"` + OwnerId string `position:"Query" name:"OwnerId"` + SourceEndpointPassword string `position:"Query" name:"SourceEndpoint.Password"` + DestinationEndpointIP string `position:"Query" name:"DestinationEndpoint.IP"` + MigrationJobName string `position:"Query" name:"MigrationJobName"` + DestinationEndpointInstanceType string `position:"Query" name:"DestinationEndpoint.InstanceType"` + SourceEndpointEngineName string `position:"Query" name:"SourceEndpoint.EngineName"` + SourceEndpointOracleSID string `position:"Query" name:"SourceEndpoint.OracleSID"` + MigrationObject string `position:"Body" name:"MigrationObject"` + MigrationJobId string `position:"Query" name:"MigrationJobId"` + SourceEndpointInstanceType string `position:"Query" name:"SourceEndpoint.InstanceType"` + DestinationEndpointEngineName string `position:"Query" name:"DestinationEndpoint.EngineName"` + DestinationEndpointUserName string `position:"Query" name:"DestinationEndpoint.UserName"` + DestinationEndpointOracleSID string `position:"Query" name:"DestinationEndpoint.OracleSID"` + SourceEndpointRegion string `position:"Query" name:"SourceEndpoint.Region"` + DestinationEndpointDataBaseName string `position:"Query" name:"DestinationEndpoint.DataBaseName"` + MigrationReserved string `position:"Query" name:"MigrationReserved"` +} + +// ConfigureMigrationJobResponse is the response struct for api ConfigureMigrationJob +type ConfigureMigrationJobResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateConfigureMigrationJobRequest creates a request to invoke ConfigureMigrationJob API +func CreateConfigureMigrationJobRequest() (request *ConfigureMigrationJobRequest) { + request = &ConfigureMigrationJobRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ConfigureMigrationJob", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateConfigureMigrationJobResponse creates a response to parse from ConfigureMigrationJob response +func CreateConfigureMigrationJobResponse() (response *ConfigureMigrationJobResponse) { + response = &ConfigureMigrationJobResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/configure_migration_job_alert.go b/services/dts/configure_migration_job_alert.go new file mode 100644 index 0000000000..c6b666e16e --- /dev/null +++ b/services/dts/configure_migration_job_alert.go @@ -0,0 +1,109 @@ +package dts + +//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" +) + +// ConfigureMigrationJobAlert invokes the dts.ConfigureMigrationJobAlert API synchronously +func (client *Client) ConfigureMigrationJobAlert(request *ConfigureMigrationJobAlertRequest) (response *ConfigureMigrationJobAlertResponse, err error) { + response = CreateConfigureMigrationJobAlertResponse() + err = client.DoAction(request, response) + return +} + +// ConfigureMigrationJobAlertWithChan invokes the dts.ConfigureMigrationJobAlert API asynchronously +func (client *Client) ConfigureMigrationJobAlertWithChan(request *ConfigureMigrationJobAlertRequest) (<-chan *ConfigureMigrationJobAlertResponse, <-chan error) { + responseChan := make(chan *ConfigureMigrationJobAlertResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ConfigureMigrationJobAlert(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ConfigureMigrationJobAlertWithCallback invokes the dts.ConfigureMigrationJobAlert API asynchronously +func (client *Client) ConfigureMigrationJobAlertWithCallback(request *ConfigureMigrationJobAlertRequest, callback func(response *ConfigureMigrationJobAlertResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ConfigureMigrationJobAlertResponse + var err error + defer close(result) + response, err = client.ConfigureMigrationJobAlert(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ConfigureMigrationJobAlertRequest is the request struct for api ConfigureMigrationJobAlert +type ConfigureMigrationJobAlertRequest struct { + *requests.RpcRequest + MigrationJobId string `position:"Query" name:"MigrationJobId"` + AccountId string `position:"Query" name:"AccountId"` + DelayAlertPhone string `position:"Query" name:"DelayAlertPhone"` + DelayOverSeconds string `position:"Query" name:"DelayOverSeconds"` + DelayAlertStatus string `position:"Query" name:"DelayAlertStatus"` + OwnerId string `position:"Query" name:"OwnerId"` + ErrorAlertPhone string `position:"Query" name:"ErrorAlertPhone"` + ErrorAlertStatus string `position:"Query" name:"ErrorAlertStatus"` +} + +// ConfigureMigrationJobAlertResponse is the response struct for api ConfigureMigrationJobAlert +type ConfigureMigrationJobAlertResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateConfigureMigrationJobAlertRequest creates a request to invoke ConfigureMigrationJobAlert API +func CreateConfigureMigrationJobAlertRequest() (request *ConfigureMigrationJobAlertRequest) { + request = &ConfigureMigrationJobAlertRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ConfigureMigrationJobAlert", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateConfigureMigrationJobAlertResponse creates a response to parse from ConfigureMigrationJobAlert response +func CreateConfigureMigrationJobAlertResponse() (response *ConfigureMigrationJobAlertResponse) { + response = &ConfigureMigrationJobAlertResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/configure_subscription.go b/services/dts/configure_subscription.go new file mode 100644 index 0000000000..74f027e8a4 --- /dev/null +++ b/services/dts/configure_subscription.go @@ -0,0 +1,134 @@ +package dts + +//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" +) + +// ConfigureSubscription invokes the dts.ConfigureSubscription API synchronously +func (client *Client) ConfigureSubscription(request *ConfigureSubscriptionRequest) (response *ConfigureSubscriptionResponse, err error) { + response = CreateConfigureSubscriptionResponse() + err = client.DoAction(request, response) + return +} + +// ConfigureSubscriptionWithChan invokes the dts.ConfigureSubscription API asynchronously +func (client *Client) ConfigureSubscriptionWithChan(request *ConfigureSubscriptionRequest) (<-chan *ConfigureSubscriptionResponse, <-chan error) { + responseChan := make(chan *ConfigureSubscriptionResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ConfigureSubscription(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ConfigureSubscriptionWithCallback invokes the dts.ConfigureSubscription API asynchronously +func (client *Client) ConfigureSubscriptionWithCallback(request *ConfigureSubscriptionRequest, callback func(response *ConfigureSubscriptionResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ConfigureSubscriptionResponse + var err error + defer close(result) + response, err = client.ConfigureSubscription(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ConfigureSubscriptionRequest is the request struct for api ConfigureSubscription +type ConfigureSubscriptionRequest struct { + *requests.RpcRequest + Checkpoint string `position:"Query" name:"Checkpoint"` + SubscriptionInstanceVSwitchId string `position:"Query" name:"SubscriptionInstanceVSwitchId"` + SourceEndpointUserName string `position:"Query" name:"SourceEndpointUserName"` + DelayPhone string `position:"Query" name:"DelayPhone"` + DtsBisLabel string `position:"Query" name:"DtsBisLabel"` + SourceEndpointIP string `position:"Query" name:"SourceEndpointIP"` + ErrorPhone string `position:"Query" name:"ErrorPhone"` + DtsJobId string `position:"Query" name:"DtsJobId"` + DbList string `position:"Query" name:"DbList"` + SubscriptionInstanceNetworkType string `position:"Query" name:"SubscriptionInstanceNetworkType"` + SourceEndpointPassword string `position:"Query" name:"SourceEndpointPassword"` + SubscriptionInstanceVPCId string `position:"Query" name:"SubscriptionInstanceVPCId"` + DelayRuleTime requests.Integer `position:"Query" name:"DelayRuleTime"` + SourceEndpointInstanceType string `position:"Query" name:"SourceEndpointInstanceType"` + DtsJobName string `position:"Query" name:"DtsJobName"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` + SourceEndpointRegion string `position:"Query" name:"SourceEndpointRegion"` + DelayNotice requests.Boolean `position:"Query" name:"DelayNotice"` + SourceEndpointInstanceID string `position:"Query" name:"SourceEndpointInstanceID"` + SourceEndpointOwnerID string `position:"Query" name:"SourceEndpointOwnerID"` + DedicatedClusterId string `position:"Query" name:"DedicatedClusterId"` + SubscriptionDataTypeDML requests.Boolean `position:"Query" name:"SubscriptionDataTypeDML"` + SourceEndpointDatabaseName string `position:"Query" name:"SourceEndpointDatabaseName"` + Reserve string `position:"Query" name:"Reserve"` + SubscriptionDataTypeDDL requests.Boolean `position:"Query" name:"SubscriptionDataTypeDDL"` + SourceEndpointPort string `position:"Query" name:"SourceEndpointPort"` + SourceEndpointOracleSID string `position:"Query" name:"SourceEndpointOracleSID"` + ErrorNotice requests.Boolean `position:"Query" name:"ErrorNotice"` + SourceEndpointRole string `position:"Query" name:"SourceEndpointRole"` + SourceEndpointEngineName string `position:"Query" name:"SourceEndpointEngineName"` +} + +// ConfigureSubscriptionResponse is the response struct for api ConfigureSubscription +type ConfigureSubscriptionResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + Success string `json:"Success" xml:"Success"` + DtsInstanceId string `json:"DtsInstanceId" xml:"DtsInstanceId"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateConfigureSubscriptionRequest creates a request to invoke ConfigureSubscription API +func CreateConfigureSubscriptionRequest() (request *ConfigureSubscriptionRequest) { + request = &ConfigureSubscriptionRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ConfigureSubscription", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateConfigureSubscriptionResponse creates a response to parse from ConfigureSubscription response +func CreateConfigureSubscriptionResponse() (response *ConfigureSubscriptionResponse) { + response = &ConfigureSubscriptionResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/configure_subscription_instance.go b/services/dts/configure_subscription_instance.go new file mode 100644 index 0000000000..95884442a4 --- /dev/null +++ b/services/dts/configure_subscription_instance.go @@ -0,0 +1,121 @@ +package dts + +//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" +) + +// ConfigureSubscriptionInstance invokes the dts.ConfigureSubscriptionInstance API synchronously +func (client *Client) ConfigureSubscriptionInstance(request *ConfigureSubscriptionInstanceRequest) (response *ConfigureSubscriptionInstanceResponse, err error) { + response = CreateConfigureSubscriptionInstanceResponse() + err = client.DoAction(request, response) + return +} + +// ConfigureSubscriptionInstanceWithChan invokes the dts.ConfigureSubscriptionInstance API asynchronously +func (client *Client) ConfigureSubscriptionInstanceWithChan(request *ConfigureSubscriptionInstanceRequest) (<-chan *ConfigureSubscriptionInstanceResponse, <-chan error) { + responseChan := make(chan *ConfigureSubscriptionInstanceResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ConfigureSubscriptionInstance(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ConfigureSubscriptionInstanceWithCallback invokes the dts.ConfigureSubscriptionInstance API asynchronously +func (client *Client) ConfigureSubscriptionInstanceWithCallback(request *ConfigureSubscriptionInstanceRequest, callback func(response *ConfigureSubscriptionInstanceResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ConfigureSubscriptionInstanceResponse + var err error + defer close(result) + response, err = client.ConfigureSubscriptionInstance(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ConfigureSubscriptionInstanceRequest is the request struct for api ConfigureSubscriptionInstance +type ConfigureSubscriptionInstanceRequest struct { + *requests.RpcRequest + SourceEndpointInstanceID string `position:"Query" name:"SourceEndpoint.InstanceID"` + SourceEndpointOracleSID string `position:"Query" name:"SourceEndpoint.OracleSID"` + SourceEndpointIP string `position:"Query" name:"SourceEndpoint.IP"` + SubscriptionDataTypeDML requests.Boolean `position:"Query" name:"SubscriptionDataType.DML"` + SourceEndpointInstanceType string `position:"Query" name:"SourceEndpoint.InstanceType"` + AccountId string `position:"Query" name:"AccountId"` + SubscriptionObject string `position:"Body" name:"SubscriptionObject"` + SubscriptionInstanceVSwitchId string `position:"Query" name:"SubscriptionInstance.VSwitchId"` + SourceEndpointUserName string `position:"Query" name:"SourceEndpoint.UserName"` + SourceEndpointDatabaseName string `position:"Query" name:"SourceEndpoint.DatabaseName"` + SourceEndpointPort string `position:"Query" name:"SourceEndpoint.Port"` + SourceEndpointOwnerID string `position:"Query" name:"SourceEndpoint.OwnerID"` + SubscriptionInstanceVPCId string `position:"Query" name:"SubscriptionInstance.VPCId"` + SubscriptionInstanceNetworkType string `position:"Query" name:"SubscriptionInstanceNetworkType"` + SubscriptionInstanceId string `position:"Query" name:"SubscriptionInstanceId"` + SourceEndpointRole string `position:"Query" name:"SourceEndpoint.Role"` + OwnerId string `position:"Query" name:"OwnerId"` + SubscriptionDataTypeDDL requests.Boolean `position:"Query" name:"SubscriptionDataType.DDL"` + SourceEndpointPassword string `position:"Query" name:"SourceEndpoint.Password"` + SubscriptionInstanceName string `position:"Query" name:"SubscriptionInstanceName"` +} + +// ConfigureSubscriptionInstanceResponse is the response struct for api ConfigureSubscriptionInstance +type ConfigureSubscriptionInstanceResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateConfigureSubscriptionInstanceRequest creates a request to invoke ConfigureSubscriptionInstance API +func CreateConfigureSubscriptionInstanceRequest() (request *ConfigureSubscriptionInstanceRequest) { + request = &ConfigureSubscriptionInstanceRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ConfigureSubscriptionInstance", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateConfigureSubscriptionInstanceResponse creates a response to parse from ConfigureSubscriptionInstance response +func CreateConfigureSubscriptionInstanceResponse() (response *ConfigureSubscriptionInstanceResponse) { + response = &ConfigureSubscriptionInstanceResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/configure_subscription_instance_alert.go b/services/dts/configure_subscription_instance_alert.go new file mode 100644 index 0000000000..29e45f4a2d --- /dev/null +++ b/services/dts/configure_subscription_instance_alert.go @@ -0,0 +1,109 @@ +package dts + +//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" +) + +// ConfigureSubscriptionInstanceAlert invokes the dts.ConfigureSubscriptionInstanceAlert API synchronously +func (client *Client) ConfigureSubscriptionInstanceAlert(request *ConfigureSubscriptionInstanceAlertRequest) (response *ConfigureSubscriptionInstanceAlertResponse, err error) { + response = CreateConfigureSubscriptionInstanceAlertResponse() + err = client.DoAction(request, response) + return +} + +// ConfigureSubscriptionInstanceAlertWithChan invokes the dts.ConfigureSubscriptionInstanceAlert API asynchronously +func (client *Client) ConfigureSubscriptionInstanceAlertWithChan(request *ConfigureSubscriptionInstanceAlertRequest) (<-chan *ConfigureSubscriptionInstanceAlertResponse, <-chan error) { + responseChan := make(chan *ConfigureSubscriptionInstanceAlertResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ConfigureSubscriptionInstanceAlert(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ConfigureSubscriptionInstanceAlertWithCallback invokes the dts.ConfigureSubscriptionInstanceAlert API asynchronously +func (client *Client) ConfigureSubscriptionInstanceAlertWithCallback(request *ConfigureSubscriptionInstanceAlertRequest, callback func(response *ConfigureSubscriptionInstanceAlertResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ConfigureSubscriptionInstanceAlertResponse + var err error + defer close(result) + response, err = client.ConfigureSubscriptionInstanceAlert(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ConfigureSubscriptionInstanceAlertRequest is the request struct for api ConfigureSubscriptionInstanceAlert +type ConfigureSubscriptionInstanceAlertRequest struct { + *requests.RpcRequest + AccountId string `position:"Query" name:"AccountId"` + DelayAlertPhone string `position:"Query" name:"DelayAlertPhone"` + DelayOverSeconds string `position:"Query" name:"DelayOverSeconds"` + DelayAlertStatus string `position:"Query" name:"DelayAlertStatus"` + SubscriptionInstanceId string `position:"Query" name:"SubscriptionInstanceId"` + OwnerId string `position:"Query" name:"OwnerId"` + ErrorAlertPhone string `position:"Query" name:"ErrorAlertPhone"` + ErrorAlertStatus string `position:"Query" name:"ErrorAlertStatus"` +} + +// ConfigureSubscriptionInstanceAlertResponse is the response struct for api ConfigureSubscriptionInstanceAlert +type ConfigureSubscriptionInstanceAlertResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateConfigureSubscriptionInstanceAlertRequest creates a request to invoke ConfigureSubscriptionInstanceAlert API +func CreateConfigureSubscriptionInstanceAlertRequest() (request *ConfigureSubscriptionInstanceAlertRequest) { + request = &ConfigureSubscriptionInstanceAlertRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ConfigureSubscriptionInstanceAlert", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateConfigureSubscriptionInstanceAlertResponse creates a response to parse from ConfigureSubscriptionInstanceAlert response +func CreateConfigureSubscriptionInstanceAlertResponse() (response *ConfigureSubscriptionInstanceAlertResponse) { + response = &ConfigureSubscriptionInstanceAlertResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/configure_synchronization_job.go b/services/dts/configure_synchronization_job.go index ee0ee42c74..4428268804 100644 --- a/services/dts/configure_synchronization_job.go +++ b/services/dts/configure_synchronization_job.go @@ -75,30 +75,33 @@ type ConfigureSynchronizationJobRequest struct { Checkpoint string `position:"Query" name:"Checkpoint"` DestinationEndpointInstanceId string `position:"Query" name:"DestinationEndpoint.InstanceId"` SourceEndpointIP string `position:"Query" name:"SourceEndpoint.IP"` - SynchronizationObjects string `position:"Query" name:"SynchronizationObjects"` + SynchronizationObjects string `position:"Body" name:"SynchronizationObjects"` DestinationEndpointPassword string `position:"Query" name:"DestinationEndpoint.Password"` - DataInitialization requests.Boolean `position:"Query" name:"DataInitialization"` - StructureInitialization requests.Boolean `position:"Query" name:"StructureInitialization"` PartitionKeyModifyTimeMinute requests.Boolean `position:"Query" name:"PartitionKey.ModifyTime_Minute"` PartitionKeyModifyTimeDay requests.Boolean `position:"Query" name:"PartitionKey.ModifyTime_Day"` - SourceEndpointInstanceType string `position:"Query" name:"SourceEndpoint.InstanceType"` SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` SynchronizationJobName string `position:"Query" name:"SynchronizationJobName"` + AccountId string `position:"Query" name:"AccountId"` SourceEndpointUserName string `position:"Query" name:"SourceEndpoint.UserName"` - PartitionKeyModifyTimeMonth requests.Boolean `position:"Query" name:"PartitionKey.ModifyTime_Month"` + SourceEndpointDatabaseName string `position:"Query" name:"SourceEndpoint.DatabaseName"` SourceEndpointPort string `position:"Query" name:"SourceEndpoint.Port"` SourceEndpointOwnerID string `position:"Query" name:"SourceEndpoint.OwnerID"` - DestinationEndpointUserName string `position:"Query" name:"DestinationEndpoint.UserName"` DestinationEndpointPort string `position:"Query" name:"DestinationEndpoint.Port"` PartitionKeyModifyTimeYear requests.Boolean `position:"Query" name:"PartitionKey.ModifyTime_Year"` SourceEndpointRole string `position:"Query" name:"SourceEndpoint.Role"` OwnerId string `position:"Query" name:"OwnerId"` - PartitionKeyModifyTimeHour requests.Boolean `position:"Query" name:"PartitionKey.ModifyTime_Hour"` SourceEndpointPassword string `position:"Query" name:"SourceEndpoint.Password"` - MigrationReserved string `position:"Query" name:"MigrationReserved"` DestinationEndpointIP string `position:"Query" name:"DestinationEndpoint.IP"` DestinationEndpointInstanceType string `position:"Query" name:"DestinationEndpoint.InstanceType"` SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` + DataInitialization requests.Boolean `position:"Query" name:"DataInitialization"` + StructureInitialization requests.Boolean `position:"Query" name:"StructureInitialization"` + SourceEndpointInstanceType string `position:"Query" name:"SourceEndpoint.InstanceType"` + PartitionKeyModifyTimeMonth requests.Boolean `position:"Query" name:"PartitionKey.ModifyTime_Month"` + DestinationEndpointUserName string `position:"Query" name:"DestinationEndpoint.UserName"` + PartitionKeyModifyTimeHour requests.Boolean `position:"Query" name:"PartitionKey.ModifyTime_Hour"` + DestinationEndpointDataBaseName string `position:"Query" name:"DestinationEndpoint.DataBaseName"` + MigrationReserved string `position:"Query" name:"MigrationReserved"` } // ConfigureSynchronizationJobResponse is the response struct for api ConfigureSynchronizationJob @@ -115,7 +118,7 @@ func CreateConfigureSynchronizationJobRequest() (request *ConfigureSynchronizati request = &ConfigureSynchronizationJobRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "ConfigureSynchronizationJob", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "ConfigureSynchronizationJob", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/configure_synchronization_job_alert.go b/services/dts/configure_synchronization_job_alert.go index f46e9cf8c3..2e368ca53e 100644 --- a/services/dts/configure_synchronization_job_alert.go +++ b/services/dts/configure_synchronization_job_alert.go @@ -71,12 +71,13 @@ func (client *Client) ConfigureSynchronizationJobAlertWithCallback(request *Conf // ConfigureSynchronizationJobAlertRequest is the request struct for api ConfigureSynchronizationJobAlert type ConfigureSynchronizationJobAlertRequest struct { *requests.RpcRequest + SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` + AccountId string `position:"Query" name:"AccountId"` + DelayAlertPhone string `position:"Query" name:"DelayAlertPhone"` DelayOverSeconds string `position:"Query" name:"DelayOverSeconds"` DelayAlertStatus string `position:"Query" name:"DelayAlertStatus"` OwnerId string `position:"Query" name:"OwnerId"` - SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` ErrorAlertPhone string `position:"Query" name:"ErrorAlertPhone"` - DelayAlertPhone string `position:"Query" name:"DelayAlertPhone"` ErrorAlertStatus string `position:"Query" name:"ErrorAlertStatus"` SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` } @@ -95,7 +96,7 @@ func CreateConfigureSynchronizationJobAlertRequest() (request *ConfigureSynchron request = &ConfigureSynchronizationJobAlertRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "ConfigureSynchronizationJobAlert", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "ConfigureSynchronizationJobAlert", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/configure_synchronization_job_replicator_compare.go b/services/dts/configure_synchronization_job_replicator_compare.go new file mode 100644 index 0000000000..5565b1f93a --- /dev/null +++ b/services/dts/configure_synchronization_job_replicator_compare.go @@ -0,0 +1,107 @@ +package dts + +//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" +) + +// ConfigureSynchronizationJobReplicatorCompare invokes the dts.ConfigureSynchronizationJobReplicatorCompare API synchronously +func (client *Client) ConfigureSynchronizationJobReplicatorCompare(request *ConfigureSynchronizationJobReplicatorCompareRequest) (response *ConfigureSynchronizationJobReplicatorCompareResponse, err error) { + response = CreateConfigureSynchronizationJobReplicatorCompareResponse() + err = client.DoAction(request, response) + return +} + +// ConfigureSynchronizationJobReplicatorCompareWithChan invokes the dts.ConfigureSynchronizationJobReplicatorCompare API asynchronously +func (client *Client) ConfigureSynchronizationJobReplicatorCompareWithChan(request *ConfigureSynchronizationJobReplicatorCompareRequest) (<-chan *ConfigureSynchronizationJobReplicatorCompareResponse, <-chan error) { + responseChan := make(chan *ConfigureSynchronizationJobReplicatorCompareResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ConfigureSynchronizationJobReplicatorCompare(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ConfigureSynchronizationJobReplicatorCompareWithCallback invokes the dts.ConfigureSynchronizationJobReplicatorCompare API asynchronously +func (client *Client) ConfigureSynchronizationJobReplicatorCompareWithCallback(request *ConfigureSynchronizationJobReplicatorCompareRequest, callback func(response *ConfigureSynchronizationJobReplicatorCompareResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ConfigureSynchronizationJobReplicatorCompareResponse + var err error + defer close(result) + response, err = client.ConfigureSynchronizationJobReplicatorCompare(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ConfigureSynchronizationJobReplicatorCompareRequest is the request struct for api ConfigureSynchronizationJobReplicatorCompare +type ConfigureSynchronizationJobReplicatorCompareRequest struct { + *requests.RpcRequest + ClientToken string `position:"Query" name:"ClientToken"` + SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` + AccountId string `position:"Query" name:"AccountId"` + OwnerId string `position:"Query" name:"OwnerId"` + SynchronizationReplicatorCompareEnable requests.Boolean `position:"Query" name:"SynchronizationReplicatorCompareEnable"` + SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` +} + +// ConfigureSynchronizationJobReplicatorCompareResponse is the response struct for api ConfigureSynchronizationJobReplicatorCompare +type ConfigureSynchronizationJobReplicatorCompareResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateConfigureSynchronizationJobReplicatorCompareRequest creates a request to invoke ConfigureSynchronizationJobReplicatorCompare API +func CreateConfigureSynchronizationJobReplicatorCompareRequest() (request *ConfigureSynchronizationJobReplicatorCompareRequest) { + request = &ConfigureSynchronizationJobReplicatorCompareRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ConfigureSynchronizationJobReplicatorCompare", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateConfigureSynchronizationJobReplicatorCompareResponse creates a response to parse from ConfigureSynchronizationJobReplicatorCompare response +func CreateConfigureSynchronizationJobReplicatorCompareResponse() (response *ConfigureSynchronizationJobReplicatorCompareResponse) { + response = &ConfigureSynchronizationJobReplicatorCompareResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/count_job_by_condition.go b/services/dts/count_job_by_condition.go new file mode 100644 index 0000000000..3e567ac343 --- /dev/null +++ b/services/dts/count_job_by_condition.go @@ -0,0 +1,113 @@ +package dts + +//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" +) + +// CountJobByCondition invokes the dts.CountJobByCondition API synchronously +func (client *Client) CountJobByCondition(request *CountJobByConditionRequest) (response *CountJobByConditionResponse, err error) { + response = CreateCountJobByConditionResponse() + err = client.DoAction(request, response) + return +} + +// CountJobByConditionWithChan invokes the dts.CountJobByCondition API asynchronously +func (client *Client) CountJobByConditionWithChan(request *CountJobByConditionRequest) (<-chan *CountJobByConditionResponse, <-chan error) { + responseChan := make(chan *CountJobByConditionResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.CountJobByCondition(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// CountJobByConditionWithCallback invokes the dts.CountJobByCondition API asynchronously +func (client *Client) CountJobByConditionWithCallback(request *CountJobByConditionRequest, callback func(response *CountJobByConditionResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *CountJobByConditionResponse + var err error + defer close(result) + response, err = client.CountJobByCondition(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// CountJobByConditionRequest is the request struct for api CountJobByCondition +type CountJobByConditionRequest struct { + *requests.RpcRequest + Type string `position:"Query" name:"Type"` + SrcDbType string `position:"Query" name:"SrcDbType"` + GroupId string `position:"Query" name:"GroupId"` + Params string `position:"Query" name:"Params"` + JobType string `position:"Query" name:"JobType"` + DestDbType string `position:"Query" name:"DestDbType"` + Region string `position:"Query" name:"Region"` + Status string `position:"Query" name:"Status"` +} + +// CountJobByConditionResponse is the response struct for api CountJobByCondition +type CountJobByConditionResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` + TotalRecordCount int64 `json:"TotalRecordCount" xml:"TotalRecordCount"` +} + +// CreateCountJobByConditionRequest creates a request to invoke CountJobByCondition API +func CreateCountJobByConditionRequest() (request *CountJobByConditionRequest) { + request = &CountJobByConditionRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "CountJobByCondition", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateCountJobByConditionResponse creates a response to parse from CountJobByCondition response +func CreateCountJobByConditionResponse() (response *CountJobByConditionResponse) { + response = &CountJobByConditionResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/create_consumer_channel.go b/services/dts/create_consumer_channel.go new file mode 100644 index 0000000000..ce7e6125c8 --- /dev/null +++ b/services/dts/create_consumer_channel.go @@ -0,0 +1,108 @@ +package dts + +//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" +) + +// CreateConsumerChannel invokes the dts.CreateConsumerChannel API synchronously +func (client *Client) CreateConsumerChannel(request *CreateConsumerChannelRequest) (response *CreateConsumerChannelResponse, err error) { + response = CreateCreateConsumerChannelResponse() + err = client.DoAction(request, response) + return +} + +// CreateConsumerChannelWithChan invokes the dts.CreateConsumerChannel API asynchronously +func (client *Client) CreateConsumerChannelWithChan(request *CreateConsumerChannelRequest) (<-chan *CreateConsumerChannelResponse, <-chan error) { + responseChan := make(chan *CreateConsumerChannelResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.CreateConsumerChannel(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// CreateConsumerChannelWithCallback invokes the dts.CreateConsumerChannel API asynchronously +func (client *Client) CreateConsumerChannelWithCallback(request *CreateConsumerChannelRequest, callback func(response *CreateConsumerChannelResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *CreateConsumerChannelResponse + var err error + defer close(result) + response, err = client.CreateConsumerChannel(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// CreateConsumerChannelRequest is the request struct for api CreateConsumerChannel +type CreateConsumerChannelRequest struct { + *requests.RpcRequest + ConsumerGroupName string `position:"Query" name:"ConsumerGroupName"` + ConsumerGroupPassword string `position:"Query" name:"ConsumerGroupPassword"` + ConsumerGroupUserName string `position:"Query" name:"ConsumerGroupUserName"` + DtsJobId string `position:"Query" name:"DtsJobId"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` +} + +// CreateConsumerChannelResponse is the response struct for api CreateConsumerChannel +type CreateConsumerChannelResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + ConsumerGroupID string `json:"ConsumerGroupID" xml:"ConsumerGroupID"` +} + +// CreateCreateConsumerChannelRequest creates a request to invoke CreateConsumerChannel API +func CreateCreateConsumerChannelRequest() (request *CreateConsumerChannelRequest) { + request = &CreateConsumerChannelRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "CreateConsumerChannel", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateCreateConsumerChannelResponse creates a response to parse from CreateConsumerChannel response +func CreateCreateConsumerChannelResponse() (response *CreateConsumerChannelResponse) { + response = &CreateConsumerChannelResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/create_consumer_group.go b/services/dts/create_consumer_group.go new file mode 100644 index 0000000000..618bb62afd --- /dev/null +++ b/services/dts/create_consumer_group.go @@ -0,0 +1,108 @@ +package dts + +//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" +) + +// CreateConsumerGroup invokes the dts.CreateConsumerGroup API synchronously +func (client *Client) CreateConsumerGroup(request *CreateConsumerGroupRequest) (response *CreateConsumerGroupResponse, err error) { + response = CreateCreateConsumerGroupResponse() + err = client.DoAction(request, response) + return +} + +// CreateConsumerGroupWithChan invokes the dts.CreateConsumerGroup API asynchronously +func (client *Client) CreateConsumerGroupWithChan(request *CreateConsumerGroupRequest) (<-chan *CreateConsumerGroupResponse, <-chan error) { + responseChan := make(chan *CreateConsumerGroupResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.CreateConsumerGroup(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// CreateConsumerGroupWithCallback invokes the dts.CreateConsumerGroup API asynchronously +func (client *Client) CreateConsumerGroupWithCallback(request *CreateConsumerGroupRequest, callback func(response *CreateConsumerGroupResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *CreateConsumerGroupResponse + var err error + defer close(result) + response, err = client.CreateConsumerGroup(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// CreateConsumerGroupRequest is the request struct for api CreateConsumerGroup +type CreateConsumerGroupRequest struct { + *requests.RpcRequest + ConsumerGroupPassword string `position:"Query" name:"ConsumerGroupPassword"` + AccountId string `position:"Query" name:"AccountId"` + ConsumerGroupUserName string `position:"Query" name:"ConsumerGroupUserName"` + ConsumerGroupName string `position:"Query" name:"ConsumerGroupName"` + SubscriptionInstanceId string `position:"Query" name:"SubscriptionInstanceId"` + OwnerId string `position:"Query" name:"OwnerId"` +} + +// CreateConsumerGroupResponse is the response struct for api CreateConsumerGroup +type CreateConsumerGroupResponse struct { + *responses.BaseResponse + ConsumerGroupID string `json:"ConsumerGroupID" xml:"ConsumerGroupID"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateCreateConsumerGroupRequest creates a request to invoke CreateConsumerGroup API +func CreateCreateConsumerGroupRequest() (request *CreateConsumerGroupRequest) { + request = &CreateConsumerGroupRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "CreateConsumerGroup", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateCreateConsumerGroupResponse creates a response to parse from CreateConsumerGroup response +func CreateCreateConsumerGroupResponse() (response *CreateConsumerGroupResponse) { + response = &CreateConsumerGroupResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/create_dedicated_cluster_monitor_rule.go b/services/dts/create_dedicated_cluster_monitor_rule.go new file mode 100644 index 0000000000..5ef695863f --- /dev/null +++ b/services/dts/create_dedicated_cluster_monitor_rule.go @@ -0,0 +1,111 @@ +package dts + +//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" +) + +// CreateDedicatedClusterMonitorRule invokes the dts.CreateDedicatedClusterMonitorRule API synchronously +func (client *Client) CreateDedicatedClusterMonitorRule(request *CreateDedicatedClusterMonitorRuleRequest) (response *CreateDedicatedClusterMonitorRuleResponse, err error) { + response = CreateCreateDedicatedClusterMonitorRuleResponse() + err = client.DoAction(request, response) + return +} + +// CreateDedicatedClusterMonitorRuleWithChan invokes the dts.CreateDedicatedClusterMonitorRule API asynchronously +func (client *Client) CreateDedicatedClusterMonitorRuleWithChan(request *CreateDedicatedClusterMonitorRuleRequest) (<-chan *CreateDedicatedClusterMonitorRuleResponse, <-chan error) { + responseChan := make(chan *CreateDedicatedClusterMonitorRuleResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.CreateDedicatedClusterMonitorRule(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// CreateDedicatedClusterMonitorRuleWithCallback invokes the dts.CreateDedicatedClusterMonitorRule API asynchronously +func (client *Client) CreateDedicatedClusterMonitorRuleWithCallback(request *CreateDedicatedClusterMonitorRuleRequest, callback func(response *CreateDedicatedClusterMonitorRuleResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *CreateDedicatedClusterMonitorRuleResponse + var err error + defer close(result) + response, err = client.CreateDedicatedClusterMonitorRule(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// CreateDedicatedClusterMonitorRuleRequest is the request struct for api CreateDedicatedClusterMonitorRule +type CreateDedicatedClusterMonitorRuleRequest struct { + *requests.RpcRequest + CpuAlarmThreshold requests.Integer `position:"Query" name:"CpuAlarmThreshold"` + Phones string `position:"Query" name:"Phones"` + DedicatedClusterId string `position:"Query" name:"DedicatedClusterId"` + DiskAlarmThreshold requests.Integer `position:"Query" name:"DiskAlarmThreshold"` + MemAlarmThreshold requests.Integer `position:"Query" name:"MemAlarmThreshold"` + DuAlarmThreshold requests.Integer `position:"Query" name:"DuAlarmThreshold"` + OwnerId string `position:"Query" name:"OwnerId"` + NoticeSwitch requests.Integer `position:"Query" name:"NoticeSwitch"` + InstanceId string `position:"Query" name:"InstanceId"` +} + +// CreateDedicatedClusterMonitorRuleResponse is the response struct for api CreateDedicatedClusterMonitorRule +type CreateDedicatedClusterMonitorRuleResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateCreateDedicatedClusterMonitorRuleRequest creates a request to invoke CreateDedicatedClusterMonitorRule API +func CreateCreateDedicatedClusterMonitorRuleRequest() (request *CreateDedicatedClusterMonitorRuleRequest) { + request = &CreateDedicatedClusterMonitorRuleRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "CreateDedicatedClusterMonitorRule", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateCreateDedicatedClusterMonitorRuleResponse creates a response to parse from CreateDedicatedClusterMonitorRule response +func CreateCreateDedicatedClusterMonitorRuleResponse() (response *CreateDedicatedClusterMonitorRuleResponse) { + response = &CreateDedicatedClusterMonitorRuleResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/create_dts_instance.go b/services/dts/create_dts_instance.go new file mode 100644 index 0000000000..e030408422 --- /dev/null +++ b/services/dts/create_dts_instance.go @@ -0,0 +1,122 @@ +package dts + +//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" +) + +// CreateDtsInstance invokes the dts.CreateDtsInstance API synchronously +func (client *Client) CreateDtsInstance(request *CreateDtsInstanceRequest) (response *CreateDtsInstanceResponse, err error) { + response = CreateCreateDtsInstanceResponse() + err = client.DoAction(request, response) + return +} + +// CreateDtsInstanceWithChan invokes the dts.CreateDtsInstance API asynchronously +func (client *Client) CreateDtsInstanceWithChan(request *CreateDtsInstanceRequest) (<-chan *CreateDtsInstanceResponse, <-chan error) { + responseChan := make(chan *CreateDtsInstanceResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.CreateDtsInstance(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// CreateDtsInstanceWithCallback invokes the dts.CreateDtsInstance API asynchronously +func (client *Client) CreateDtsInstanceWithCallback(request *CreateDtsInstanceRequest, callback func(response *CreateDtsInstanceResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *CreateDtsInstanceResponse + var err error + defer close(result) + response, err = client.CreateDtsInstance(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// CreateDtsInstanceRequest is the request struct for api CreateDtsInstance +type CreateDtsInstanceRequest struct { + *requests.RpcRequest + AutoStart requests.Boolean `position:"Query" name:"AutoStart"` + Type string `position:"Query" name:"Type"` + InstanceClass string `position:"Query" name:"InstanceClass"` + DatabaseCount requests.Integer `position:"Query" name:"DatabaseCount"` + JobId string `position:"Query" name:"JobId"` + Du requests.Integer `position:"Query" name:"Du"` + ResourceGroupId string `position:"Query" name:"ResourceGroupId"` + ComputeUnit requests.Integer `position:"Query" name:"ComputeUnit"` + FeeType string `position:"Query" name:"FeeType"` + DestinationRegion string `position:"Query" name:"DestinationRegion"` + Period string `position:"Query" name:"Period"` + DestinationEndpointEngineName string `position:"Query" name:"DestinationEndpointEngineName"` + Quantity requests.Integer `position:"Query" name:"Quantity"` + AutoPay requests.Boolean `position:"Query" name:"AutoPay"` + UsedTime requests.Integer `position:"Query" name:"UsedTime"` + SyncArchitecture string `position:"Query" name:"SyncArchitecture"` + PayType string `position:"Query" name:"PayType"` + SourceRegion string `position:"Query" name:"SourceRegion"` + SourceEndpointEngineName string `position:"Query" name:"SourceEndpointEngineName"` +} + +// CreateDtsInstanceResponse is the response struct for api CreateDtsInstance +type CreateDtsInstanceResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + JobId string `json:"JobId" xml:"JobId"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + InstanceId string `json:"InstanceId" xml:"InstanceId"` +} + +// CreateCreateDtsInstanceRequest creates a request to invoke CreateDtsInstance API +func CreateCreateDtsInstanceRequest() (request *CreateDtsInstanceRequest) { + request = &CreateDtsInstanceRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "CreateDtsInstance", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateCreateDtsInstanceResponse creates a response to parse from CreateDtsInstance response +func CreateCreateDtsInstanceResponse() (response *CreateDtsInstanceResponse) { + response = &CreateDtsInstanceResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/create_job_monitor_rule.go b/services/dts/create_job_monitor_rule.go new file mode 100644 index 0000000000..3336e3bcd3 --- /dev/null +++ b/services/dts/create_job_monitor_rule.go @@ -0,0 +1,113 @@ +package dts + +//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" +) + +// CreateJobMonitorRule invokes the dts.CreateJobMonitorRule API synchronously +func (client *Client) CreateJobMonitorRule(request *CreateJobMonitorRuleRequest) (response *CreateJobMonitorRuleResponse, err error) { + response = CreateCreateJobMonitorRuleResponse() + err = client.DoAction(request, response) + return +} + +// CreateJobMonitorRuleWithChan invokes the dts.CreateJobMonitorRule API asynchronously +func (client *Client) CreateJobMonitorRuleWithChan(request *CreateJobMonitorRuleRequest) (<-chan *CreateJobMonitorRuleResponse, <-chan error) { + responseChan := make(chan *CreateJobMonitorRuleResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.CreateJobMonitorRule(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// CreateJobMonitorRuleWithCallback invokes the dts.CreateJobMonitorRule API asynchronously +func (client *Client) CreateJobMonitorRuleWithCallback(request *CreateJobMonitorRuleRequest, callback func(response *CreateJobMonitorRuleResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *CreateJobMonitorRuleResponse + var err error + defer close(result) + response, err = client.CreateJobMonitorRule(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// CreateJobMonitorRuleRequest is the request struct for api CreateJobMonitorRule +type CreateJobMonitorRuleRequest struct { + *requests.RpcRequest + Type string `position:"Query" name:"Type"` + NoticeValue requests.Integer `position:"Query" name:"NoticeValue"` + Times requests.Integer `position:"Query" name:"Times"` + DtsJobId string `position:"Query" name:"DtsJobId"` + State string `position:"Query" name:"State"` + Period requests.Integer `position:"Query" name:"Period"` + DelayRuleTime requests.Integer `position:"Query" name:"DelayRuleTime"` + Phone string `position:"Query" name:"Phone"` +} + +// CreateJobMonitorRuleResponse is the response struct for api CreateJobMonitorRule +type CreateJobMonitorRuleResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + Code string `json:"Code" xml:"Code"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` +} + +// CreateCreateJobMonitorRuleRequest creates a request to invoke CreateJobMonitorRule API +func CreateCreateJobMonitorRuleRequest() (request *CreateJobMonitorRuleRequest) { + request = &CreateJobMonitorRuleRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "CreateJobMonitorRule", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateCreateJobMonitorRuleResponse creates a response to parse from CreateJobMonitorRule response +func CreateCreateJobMonitorRuleResponse() (response *CreateJobMonitorRuleResponse) { + response = &CreateJobMonitorRuleResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/create_migration_job.go b/services/dts/create_migration_job.go new file mode 100644 index 0000000000..85f022e561 --- /dev/null +++ b/services/dts/create_migration_job.go @@ -0,0 +1,107 @@ +package dts + +//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" +) + +// CreateMigrationJob invokes the dts.CreateMigrationJob API synchronously +func (client *Client) CreateMigrationJob(request *CreateMigrationJobRequest) (response *CreateMigrationJobResponse, err error) { + response = CreateCreateMigrationJobResponse() + err = client.DoAction(request, response) + return +} + +// CreateMigrationJobWithChan invokes the dts.CreateMigrationJob API asynchronously +func (client *Client) CreateMigrationJobWithChan(request *CreateMigrationJobRequest) (<-chan *CreateMigrationJobResponse, <-chan error) { + responseChan := make(chan *CreateMigrationJobResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.CreateMigrationJob(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// CreateMigrationJobWithCallback invokes the dts.CreateMigrationJob API asynchronously +func (client *Client) CreateMigrationJobWithCallback(request *CreateMigrationJobRequest, callback func(response *CreateMigrationJobResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *CreateMigrationJobResponse + var err error + defer close(result) + response, err = client.CreateMigrationJob(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// CreateMigrationJobRequest is the request struct for api CreateMigrationJob +type CreateMigrationJobRequest struct { + *requests.RpcRequest + ClientToken string `position:"Query" name:"ClientToken"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` + Region string `position:"Query" name:"Region"` + MigrationJobClass string `position:"Query" name:"MigrationJobClass"` +} + +// CreateMigrationJobResponse is the response struct for api CreateMigrationJob +type CreateMigrationJobResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + MigrationJobId string `json:"MigrationJobId" xml:"MigrationJobId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateCreateMigrationJobRequest creates a request to invoke CreateMigrationJob API +func CreateCreateMigrationJobRequest() (request *CreateMigrationJobRequest) { + request = &CreateMigrationJobRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "CreateMigrationJob", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateCreateMigrationJobResponse creates a response to parse from CreateMigrationJob response +func CreateCreateMigrationJobResponse() (response *CreateMigrationJobResponse) { + response = &CreateMigrationJobResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/create_subscription_instance.go b/services/dts/create_subscription_instance.go new file mode 100644 index 0000000000..5220959297 --- /dev/null +++ b/services/dts/create_subscription_instance.go @@ -0,0 +1,110 @@ +package dts + +//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" +) + +// CreateSubscriptionInstance invokes the dts.CreateSubscriptionInstance API synchronously +func (client *Client) CreateSubscriptionInstance(request *CreateSubscriptionInstanceRequest) (response *CreateSubscriptionInstanceResponse, err error) { + response = CreateCreateSubscriptionInstanceResponse() + err = client.DoAction(request, response) + return +} + +// CreateSubscriptionInstanceWithChan invokes the dts.CreateSubscriptionInstance API asynchronously +func (client *Client) CreateSubscriptionInstanceWithChan(request *CreateSubscriptionInstanceRequest) (<-chan *CreateSubscriptionInstanceResponse, <-chan error) { + responseChan := make(chan *CreateSubscriptionInstanceResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.CreateSubscriptionInstance(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// CreateSubscriptionInstanceWithCallback invokes the dts.CreateSubscriptionInstance API asynchronously +func (client *Client) CreateSubscriptionInstanceWithCallback(request *CreateSubscriptionInstanceRequest, callback func(response *CreateSubscriptionInstanceResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *CreateSubscriptionInstanceResponse + var err error + defer close(result) + response, err = client.CreateSubscriptionInstance(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// CreateSubscriptionInstanceRequest is the request struct for api CreateSubscriptionInstance +type CreateSubscriptionInstanceRequest struct { + *requests.RpcRequest + ClientToken string `position:"Query" name:"ClientToken"` + SourceEndpointInstanceType string `position:"Query" name:"SourceEndpoint.InstanceType"` + AccountId string `position:"Query" name:"AccountId"` + Period string `position:"Query" name:"Period"` + OwnerId string `position:"Query" name:"OwnerId"` + UsedTime requests.Integer `position:"Query" name:"UsedTime"` + Region string `position:"Query" name:"Region"` + PayType string `position:"Query" name:"PayType"` +} + +// CreateSubscriptionInstanceResponse is the response struct for api CreateSubscriptionInstance +type CreateSubscriptionInstanceResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + SubscriptionInstanceId string `json:"SubscriptionInstanceId" xml:"SubscriptionInstanceId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateCreateSubscriptionInstanceRequest creates a request to invoke CreateSubscriptionInstance API +func CreateCreateSubscriptionInstanceRequest() (request *CreateSubscriptionInstanceRequest) { + request = &CreateSubscriptionInstanceRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "CreateSubscriptionInstance", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateCreateSubscriptionInstanceResponse creates a response to parse from CreateSubscriptionInstance response +func CreateCreateSubscriptionInstanceResponse() (response *CreateSubscriptionInstanceResponse) { + response = &CreateSubscriptionInstanceResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/create_synchronization_job.go b/services/dts/create_synchronization_job.go index 46976fd76f..f68766f97f 100644 --- a/services/dts/create_synchronization_job.go +++ b/services/dts/create_synchronization_job.go @@ -71,15 +71,17 @@ func (client *Client) CreateSynchronizationJobWithCallback(request *CreateSynchr // CreateSynchronizationJobRequest is the request struct for api CreateSynchronizationJob type CreateSynchronizationJobRequest struct { *requests.RpcRequest + ClientToken string `position:"Query" name:"ClientToken"` + NetworkType string `position:"Query" name:"networkType"` + SourceEndpointInstanceType string `position:"Query" name:"SourceEndpoint.InstanceType"` + AccountId string `position:"Query" name:"AccountId"` + SynchronizationJobClass string `position:"Query" name:"SynchronizationJobClass"` Period string `position:"Query" name:"Period"` DestRegion string `position:"Query" name:"DestRegion"` - ClientToken string `position:"Query" name:"ClientToken"` Topology string `position:"Query" name:"Topology"` - NetworkType string `position:"Query" name:"networkType"` OwnerId string `position:"Query" name:"OwnerId"` UsedTime requests.Integer `position:"Query" name:"UsedTime"` - SourceEndpointInstanceType string `position:"Query" name:"SourceEndpoint.InstanceType"` - SynchronizationJobClass string `position:"Query" name:"SynchronizationJobClass"` + DBInstanceCount requests.Integer `position:"Query" name:"DBInstanceCount"` SourceRegion string `position:"Query" name:"SourceRegion"` PayType string `position:"Query" name:"PayType"` DestinationEndpointInstanceType string `position:"Query" name:"DestinationEndpoint.InstanceType"` @@ -100,7 +102,7 @@ func CreateCreateSynchronizationJobRequest() (request *CreateSynchronizationJobR request = &CreateSynchronizationJobRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "CreateSynchronizationJob", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "CreateSynchronizationJob", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/delete_consumer_channel.go b/services/dts/delete_consumer_channel.go new file mode 100644 index 0000000000..eea52b2521 --- /dev/null +++ b/services/dts/delete_consumer_channel.go @@ -0,0 +1,105 @@ +package dts + +//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" +) + +// DeleteConsumerChannel invokes the dts.DeleteConsumerChannel API synchronously +func (client *Client) DeleteConsumerChannel(request *DeleteConsumerChannelRequest) (response *DeleteConsumerChannelResponse, err error) { + response = CreateDeleteConsumerChannelResponse() + err = client.DoAction(request, response) + return +} + +// DeleteConsumerChannelWithChan invokes the dts.DeleteConsumerChannel API asynchronously +func (client *Client) DeleteConsumerChannelWithChan(request *DeleteConsumerChannelRequest) (<-chan *DeleteConsumerChannelResponse, <-chan error) { + responseChan := make(chan *DeleteConsumerChannelResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DeleteConsumerChannel(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DeleteConsumerChannelWithCallback invokes the dts.DeleteConsumerChannel API asynchronously +func (client *Client) DeleteConsumerChannelWithCallback(request *DeleteConsumerChannelRequest, callback func(response *DeleteConsumerChannelResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DeleteConsumerChannelResponse + var err error + defer close(result) + response, err = client.DeleteConsumerChannel(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DeleteConsumerChannelRequest is the request struct for api DeleteConsumerChannel +type DeleteConsumerChannelRequest struct { + *requests.RpcRequest + ConsumerGroupId string `position:"Query" name:"ConsumerGroupId"` + DtsJobId string `position:"Query" name:"DtsJobId"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` +} + +// DeleteConsumerChannelResponse is the response struct for api DeleteConsumerChannel +type DeleteConsumerChannelResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateDeleteConsumerChannelRequest creates a request to invoke DeleteConsumerChannel API +func CreateDeleteConsumerChannelRequest() (request *DeleteConsumerChannelRequest) { + request = &DeleteConsumerChannelRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DeleteConsumerChannel", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDeleteConsumerChannelResponse creates a response to parse from DeleteConsumerChannel response +func CreateDeleteConsumerChannelResponse() (response *DeleteConsumerChannelResponse) { + response = &DeleteConsumerChannelResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/delete_consumer_group.go b/services/dts/delete_consumer_group.go new file mode 100644 index 0000000000..009f3865c8 --- /dev/null +++ b/services/dts/delete_consumer_group.go @@ -0,0 +1,105 @@ +package dts + +//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" +) + +// DeleteConsumerGroup invokes the dts.DeleteConsumerGroup API synchronously +func (client *Client) DeleteConsumerGroup(request *DeleteConsumerGroupRequest) (response *DeleteConsumerGroupResponse, err error) { + response = CreateDeleteConsumerGroupResponse() + err = client.DoAction(request, response) + return +} + +// DeleteConsumerGroupWithChan invokes the dts.DeleteConsumerGroup API asynchronously +func (client *Client) DeleteConsumerGroupWithChan(request *DeleteConsumerGroupRequest) (<-chan *DeleteConsumerGroupResponse, <-chan error) { + responseChan := make(chan *DeleteConsumerGroupResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DeleteConsumerGroup(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DeleteConsumerGroupWithCallback invokes the dts.DeleteConsumerGroup API asynchronously +func (client *Client) DeleteConsumerGroupWithCallback(request *DeleteConsumerGroupRequest, callback func(response *DeleteConsumerGroupResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DeleteConsumerGroupResponse + var err error + defer close(result) + response, err = client.DeleteConsumerGroup(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DeleteConsumerGroupRequest is the request struct for api DeleteConsumerGroup +type DeleteConsumerGroupRequest struct { + *requests.RpcRequest + ConsumerGroupID string `position:"Query" name:"ConsumerGroupID"` + SubscriptionInstanceId string `position:"Query" name:"SubscriptionInstanceId"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` +} + +// DeleteConsumerGroupResponse is the response struct for api DeleteConsumerGroup +type DeleteConsumerGroupResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateDeleteConsumerGroupRequest creates a request to invoke DeleteConsumerGroup API +func CreateDeleteConsumerGroupRequest() (request *DeleteConsumerGroupRequest) { + request = &DeleteConsumerGroupRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DeleteConsumerGroup", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDeleteConsumerGroupResponse creates a response to parse from DeleteConsumerGroup response +func CreateDeleteConsumerGroupResponse() (response *DeleteConsumerGroupResponse) { + response = &DeleteConsumerGroupResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/delete_dts_job.go b/services/dts/delete_dts_job.go new file mode 100644 index 0000000000..d327345d4d --- /dev/null +++ b/services/dts/delete_dts_job.go @@ -0,0 +1,108 @@ +package dts + +//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" +) + +// DeleteDtsJob invokes the dts.DeleteDtsJob API synchronously +func (client *Client) DeleteDtsJob(request *DeleteDtsJobRequest) (response *DeleteDtsJobResponse, err error) { + response = CreateDeleteDtsJobResponse() + err = client.DoAction(request, response) + return +} + +// DeleteDtsJobWithChan invokes the dts.DeleteDtsJob API asynchronously +func (client *Client) DeleteDtsJobWithChan(request *DeleteDtsJobRequest) (<-chan *DeleteDtsJobResponse, <-chan error) { + responseChan := make(chan *DeleteDtsJobResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DeleteDtsJob(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DeleteDtsJobWithCallback invokes the dts.DeleteDtsJob API asynchronously +func (client *Client) DeleteDtsJobWithCallback(request *DeleteDtsJobRequest, callback func(response *DeleteDtsJobResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DeleteDtsJobResponse + var err error + defer close(result) + response, err = client.DeleteDtsJob(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DeleteDtsJobRequest is the request struct for api DeleteDtsJob +type DeleteDtsJobRequest struct { + *requests.RpcRequest + JobType string `position:"Query" name:"JobType"` + DtsJobId string `position:"Query" name:"DtsJobId"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` + SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` +} + +// DeleteDtsJobResponse is the response struct for api DeleteDtsJob +type DeleteDtsJobResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` +} + +// CreateDeleteDtsJobRequest creates a request to invoke DeleteDtsJob API +func CreateDeleteDtsJobRequest() (request *DeleteDtsJobRequest) { + request = &DeleteDtsJobRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DeleteDtsJob", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDeleteDtsJobResponse creates a response to parse from DeleteDtsJob response +func CreateDeleteDtsJobResponse() (response *DeleteDtsJobResponse) { + response = &DeleteDtsJobResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/delete_dts_jobs.go b/services/dts/delete_dts_jobs.go new file mode 100644 index 0000000000..6164cae2ec --- /dev/null +++ b/services/dts/delete_dts_jobs.go @@ -0,0 +1,105 @@ +package dts + +//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" +) + +// DeleteDtsJobs invokes the dts.DeleteDtsJobs API synchronously +func (client *Client) DeleteDtsJobs(request *DeleteDtsJobsRequest) (response *DeleteDtsJobsResponse, err error) { + response = CreateDeleteDtsJobsResponse() + err = client.DoAction(request, response) + return +} + +// DeleteDtsJobsWithChan invokes the dts.DeleteDtsJobs API asynchronously +func (client *Client) DeleteDtsJobsWithChan(request *DeleteDtsJobsRequest) (<-chan *DeleteDtsJobsResponse, <-chan error) { + responseChan := make(chan *DeleteDtsJobsResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DeleteDtsJobs(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DeleteDtsJobsWithCallback invokes the dts.DeleteDtsJobs API asynchronously +func (client *Client) DeleteDtsJobsWithCallback(request *DeleteDtsJobsRequest, callback func(response *DeleteDtsJobsResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DeleteDtsJobsResponse + var err error + defer close(result) + response, err = client.DeleteDtsJobs(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DeleteDtsJobsRequest is the request struct for api DeleteDtsJobs +type DeleteDtsJobsRequest struct { + *requests.RpcRequest + DtsJobIds string `position:"Query" name:"DtsJobIds"` +} + +// DeleteDtsJobsResponse is the response struct for api DeleteDtsJobs +type DeleteDtsJobsResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` +} + +// CreateDeleteDtsJobsRequest creates a request to invoke DeleteDtsJobs API +func CreateDeleteDtsJobsRequest() (request *DeleteDtsJobsRequest) { + request = &DeleteDtsJobsRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DeleteDtsJobs", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDeleteDtsJobsResponse creates a response to parse from DeleteDtsJobs response +func CreateDeleteDtsJobsResponse() (response *DeleteDtsJobsResponse) { + response = &DeleteDtsJobsResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/delete_migration_job.go b/services/dts/delete_migration_job.go new file mode 100644 index 0000000000..a737faff79 --- /dev/null +++ b/services/dts/delete_migration_job.go @@ -0,0 +1,104 @@ +package dts + +//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" +) + +// DeleteMigrationJob invokes the dts.DeleteMigrationJob API synchronously +func (client *Client) DeleteMigrationJob(request *DeleteMigrationJobRequest) (response *DeleteMigrationJobResponse, err error) { + response = CreateDeleteMigrationJobResponse() + err = client.DoAction(request, response) + return +} + +// DeleteMigrationJobWithChan invokes the dts.DeleteMigrationJob API asynchronously +func (client *Client) DeleteMigrationJobWithChan(request *DeleteMigrationJobRequest) (<-chan *DeleteMigrationJobResponse, <-chan error) { + responseChan := make(chan *DeleteMigrationJobResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DeleteMigrationJob(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DeleteMigrationJobWithCallback invokes the dts.DeleteMigrationJob API asynchronously +func (client *Client) DeleteMigrationJobWithCallback(request *DeleteMigrationJobRequest, callback func(response *DeleteMigrationJobResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DeleteMigrationJobResponse + var err error + defer close(result) + response, err = client.DeleteMigrationJob(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DeleteMigrationJobRequest is the request struct for api DeleteMigrationJob +type DeleteMigrationJobRequest struct { + *requests.RpcRequest + MigrationJobId string `position:"Query" name:"MigrationJobId"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` +} + +// DeleteMigrationJobResponse is the response struct for api DeleteMigrationJob +type DeleteMigrationJobResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateDeleteMigrationJobRequest creates a request to invoke DeleteMigrationJob API +func CreateDeleteMigrationJobRequest() (request *DeleteMigrationJobRequest) { + request = &DeleteMigrationJobRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DeleteMigrationJob", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDeleteMigrationJobResponse creates a response to parse from DeleteMigrationJob response +func CreateDeleteMigrationJobResponse() (response *DeleteMigrationJobResponse) { + response = &DeleteMigrationJobResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/delete_subscription_instance.go b/services/dts/delete_subscription_instance.go new file mode 100644 index 0000000000..a0bffcfaee --- /dev/null +++ b/services/dts/delete_subscription_instance.go @@ -0,0 +1,104 @@ +package dts + +//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" +) + +// DeleteSubscriptionInstance invokes the dts.DeleteSubscriptionInstance API synchronously +func (client *Client) DeleteSubscriptionInstance(request *DeleteSubscriptionInstanceRequest) (response *DeleteSubscriptionInstanceResponse, err error) { + response = CreateDeleteSubscriptionInstanceResponse() + err = client.DoAction(request, response) + return +} + +// DeleteSubscriptionInstanceWithChan invokes the dts.DeleteSubscriptionInstance API asynchronously +func (client *Client) DeleteSubscriptionInstanceWithChan(request *DeleteSubscriptionInstanceRequest) (<-chan *DeleteSubscriptionInstanceResponse, <-chan error) { + responseChan := make(chan *DeleteSubscriptionInstanceResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DeleteSubscriptionInstance(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DeleteSubscriptionInstanceWithCallback invokes the dts.DeleteSubscriptionInstance API asynchronously +func (client *Client) DeleteSubscriptionInstanceWithCallback(request *DeleteSubscriptionInstanceRequest, callback func(response *DeleteSubscriptionInstanceResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DeleteSubscriptionInstanceResponse + var err error + defer close(result) + response, err = client.DeleteSubscriptionInstance(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DeleteSubscriptionInstanceRequest is the request struct for api DeleteSubscriptionInstance +type DeleteSubscriptionInstanceRequest struct { + *requests.RpcRequest + SubscriptionInstanceId string `position:"Query" name:"SubscriptionInstanceId"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` +} + +// DeleteSubscriptionInstanceResponse is the response struct for api DeleteSubscriptionInstance +type DeleteSubscriptionInstanceResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateDeleteSubscriptionInstanceRequest creates a request to invoke DeleteSubscriptionInstance API +func CreateDeleteSubscriptionInstanceRequest() (request *DeleteSubscriptionInstanceRequest) { + request = &DeleteSubscriptionInstanceRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DeleteSubscriptionInstance", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDeleteSubscriptionInstanceResponse creates a response to parse from DeleteSubscriptionInstance response +func CreateDeleteSubscriptionInstanceResponse() (response *DeleteSubscriptionInstanceResponse) { + response = &DeleteSubscriptionInstanceResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/delete_synchronization_job.go b/services/dts/delete_synchronization_job.go index 1550587952..638863a74c 100644 --- a/services/dts/delete_synchronization_job.go +++ b/services/dts/delete_synchronization_job.go @@ -73,6 +73,7 @@ type DeleteSynchronizationJobRequest struct { *requests.RpcRequest OwnerId string `position:"Query" name:"OwnerId"` SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` + AccountId string `position:"Query" name:"AccountId"` } // DeleteSynchronizationJobResponse is the response struct for api DeleteSynchronizationJob @@ -89,7 +90,7 @@ func CreateDeleteSynchronizationJobRequest() (request *DeleteSynchronizationJobR request = &DeleteSynchronizationJobRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "DeleteSynchronizationJob", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "DeleteSynchronizationJob", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/describe_channel_account.go b/services/dts/describe_channel_account.go new file mode 100644 index 0000000000..97e16320f7 --- /dev/null +++ b/services/dts/describe_channel_account.go @@ -0,0 +1,113 @@ +package dts + +//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" +) + +// DescribeChannelAccount invokes the dts.DescribeChannelAccount API synchronously +func (client *Client) DescribeChannelAccount(request *DescribeChannelAccountRequest) (response *DescribeChannelAccountResponse, err error) { + response = CreateDescribeChannelAccountResponse() + err = client.DoAction(request, response) + return +} + +// DescribeChannelAccountWithChan invokes the dts.DescribeChannelAccount API asynchronously +func (client *Client) DescribeChannelAccountWithChan(request *DescribeChannelAccountRequest) (<-chan *DescribeChannelAccountResponse, <-chan error) { + responseChan := make(chan *DescribeChannelAccountResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeChannelAccount(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeChannelAccountWithCallback invokes the dts.DescribeChannelAccount API asynchronously +func (client *Client) DescribeChannelAccountWithCallback(request *DescribeChannelAccountRequest, callback func(response *DescribeChannelAccountResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeChannelAccountResponse + var err error + defer close(result) + response, err = client.DescribeChannelAccount(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeChannelAccountRequest is the request struct for api DescribeChannelAccount +type DescribeChannelAccountRequest struct { + *requests.RpcRequest + Type string `position:"Query" name:"Type"` + ResourceGroupId string `position:"Query" name:"ResourceGroupId"` + DtsJobId string `position:"Query" name:"DtsJobId"` + OriginType string `position:"Query" name:"OriginType"` + OwnerId string `position:"Query" name:"OwnerId"` + Tags string `position:"Query" name:"Tags"` + Region string `position:"Query" name:"Region"` +} + +// DescribeChannelAccountResponse is the response struct for api DescribeChannelAccount +type DescribeChannelAccountResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` + Username string `json:"Username" xml:"Username"` + Password string `json:"Password" xml:"Password"` +} + +// CreateDescribeChannelAccountRequest creates a request to invoke DescribeChannelAccount API +func CreateDescribeChannelAccountRequest() (request *DescribeChannelAccountRequest) { + request = &DescribeChannelAccountRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeChannelAccount", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeChannelAccountResponse creates a response to parse from DescribeChannelAccount response +func CreateDescribeChannelAccountResponse() (response *DescribeChannelAccountResponse) { + response = &DescribeChannelAccountResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_check_jobs.go b/services/dts/describe_check_jobs.go new file mode 100644 index 0000000000..4509fd2216 --- /dev/null +++ b/services/dts/describe_check_jobs.go @@ -0,0 +1,113 @@ +package dts + +//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" +) + +// DescribeCheckJobs invokes the dts.DescribeCheckJobs API synchronously +func (client *Client) DescribeCheckJobs(request *DescribeCheckJobsRequest) (response *DescribeCheckJobsResponse, err error) { + response = CreateDescribeCheckJobsResponse() + err = client.DoAction(request, response) + return +} + +// DescribeCheckJobsWithChan invokes the dts.DescribeCheckJobs API asynchronously +func (client *Client) DescribeCheckJobsWithChan(request *DescribeCheckJobsRequest) (<-chan *DescribeCheckJobsResponse, <-chan error) { + responseChan := make(chan *DescribeCheckJobsResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeCheckJobs(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeCheckJobsWithCallback invokes the dts.DescribeCheckJobs API asynchronously +func (client *Client) DescribeCheckJobsWithCallback(request *DescribeCheckJobsRequest, callback func(response *DescribeCheckJobsResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeCheckJobsResponse + var err error + defer close(result) + response, err = client.DescribeCheckJobs(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeCheckJobsRequest is the request struct for api DescribeCheckJobs +type DescribeCheckJobsRequest struct { + *requests.RpcRequest + PageNumber requests.Integer `position:"Query" name:"PageNumber"` + CheckType requests.Integer `position:"Query" name:"CheckType"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + JobName string `position:"Query" name:"JobName"` + InstanceId string `position:"Query" name:"InstanceId"` +} + +// DescribeCheckJobsResponse is the response struct for api DescribeCheckJobs +type DescribeCheckJobsResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + PageRecordCount int64 `json:"PageRecordCount" xml:"PageRecordCount"` + TotalRecordCount int64 `json:"TotalRecordCount" xml:"TotalRecordCount"` + CheckJobs []CheckJobsItem `json:"CheckJobs" xml:"CheckJobs"` +} + +// CreateDescribeCheckJobsRequest creates a request to invoke DescribeCheckJobs API +func CreateDescribeCheckJobsRequest() (request *DescribeCheckJobsRequest) { + request = &DescribeCheckJobsRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeCheckJobs", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeCheckJobsResponse creates a response to parse from DescribeCheckJobs response +func CreateDescribeCheckJobsResponse() (response *DescribeCheckJobsResponse) { + response = &DescribeCheckJobsResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_cluster_operate_logs.go b/services/dts/describe_cluster_operate_logs.go new file mode 100644 index 0000000000..fdc7bb45b2 --- /dev/null +++ b/services/dts/describe_cluster_operate_logs.go @@ -0,0 +1,117 @@ +package dts + +//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" +) + +// DescribeClusterOperateLogs invokes the dts.DescribeClusterOperateLogs API synchronously +func (client *Client) DescribeClusterOperateLogs(request *DescribeClusterOperateLogsRequest) (response *DescribeClusterOperateLogsResponse, err error) { + response = CreateDescribeClusterOperateLogsResponse() + err = client.DoAction(request, response) + return +} + +// DescribeClusterOperateLogsWithChan invokes the dts.DescribeClusterOperateLogs API asynchronously +func (client *Client) DescribeClusterOperateLogsWithChan(request *DescribeClusterOperateLogsRequest) (<-chan *DescribeClusterOperateLogsResponse, <-chan error) { + responseChan := make(chan *DescribeClusterOperateLogsResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeClusterOperateLogs(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeClusterOperateLogsWithCallback invokes the dts.DescribeClusterOperateLogs API asynchronously +func (client *Client) DescribeClusterOperateLogsWithCallback(request *DescribeClusterOperateLogsRequest, callback func(response *DescribeClusterOperateLogsResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeClusterOperateLogsResponse + var err error + defer close(result) + response, err = client.DescribeClusterOperateLogs(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeClusterOperateLogsRequest is the request struct for api DescribeClusterOperateLogs +type DescribeClusterOperateLogsRequest struct { + *requests.RpcRequest + ClientToken string `position:"Body" name:"ClientToken"` + DedicatedClusterId string `position:"Body" name:"DedicatedClusterId"` + StartTime requests.Integer `position:"Body" name:"StartTime"` + PageNumber requests.Integer `position:"Body" name:"PageNumber"` + AccountId string `position:"Body" name:"AccountId"` + PageSize requests.Integer `position:"Body" name:"PageSize"` + DtsJobId string `position:"Body" name:"DtsJobId"` + EndTime requests.Integer `position:"Body" name:"EndTime"` + OwnerID string `position:"Body" name:"OwnerID"` +} + +// DescribeClusterOperateLogsResponse is the response struct for api DescribeClusterOperateLogs +type DescribeClusterOperateLogsResponse struct { + *responses.BaseResponse + PageNumber int `json:"PageNumber" xml:"PageNumber"` + PageRecordCount int `json:"PageRecordCount" xml:"PageRecordCount"` + TotalRecordCount int64 `json:"TotalRecordCount" xml:"TotalRecordCount"` + Success bool `json:"Success" xml:"Success"` + Code string `json:"Code" xml:"Code"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + DataPoints []DataPoint `json:"DataPoints" xml:"DataPoints"` +} + +// CreateDescribeClusterOperateLogsRequest creates a request to invoke DescribeClusterOperateLogs API +func CreateDescribeClusterOperateLogsRequest() (request *DescribeClusterOperateLogsRequest) { + request = &DescribeClusterOperateLogsRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeClusterOperateLogs", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeClusterOperateLogsResponse creates a response to parse from DescribeClusterOperateLogs response +func CreateDescribeClusterOperateLogsResponse() (response *DescribeClusterOperateLogsResponse) { + response = &DescribeClusterOperateLogsResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_cluster_used_utilization.go b/services/dts/describe_cluster_used_utilization.go new file mode 100644 index 0000000000..809aa16506 --- /dev/null +++ b/services/dts/describe_cluster_used_utilization.go @@ -0,0 +1,122 @@ +package dts + +//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" +) + +// DescribeClusterUsedUtilization invokes the dts.DescribeClusterUsedUtilization API synchronously +func (client *Client) DescribeClusterUsedUtilization(request *DescribeClusterUsedUtilizationRequest) (response *DescribeClusterUsedUtilizationResponse, err error) { + response = CreateDescribeClusterUsedUtilizationResponse() + err = client.DoAction(request, response) + return +} + +// DescribeClusterUsedUtilizationWithChan invokes the dts.DescribeClusterUsedUtilization API asynchronously +func (client *Client) DescribeClusterUsedUtilizationWithChan(request *DescribeClusterUsedUtilizationRequest) (<-chan *DescribeClusterUsedUtilizationResponse, <-chan error) { + responseChan := make(chan *DescribeClusterUsedUtilizationResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeClusterUsedUtilization(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeClusterUsedUtilizationWithCallback invokes the dts.DescribeClusterUsedUtilization API asynchronously +func (client *Client) DescribeClusterUsedUtilizationWithCallback(request *DescribeClusterUsedUtilizationRequest, callback func(response *DescribeClusterUsedUtilizationResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeClusterUsedUtilizationResponse + var err error + defer close(result) + response, err = client.DescribeClusterUsedUtilization(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeClusterUsedUtilizationRequest is the request struct for api DescribeClusterUsedUtilization +type DescribeClusterUsedUtilizationRequest struct { + *requests.RpcRequest + MetricType string `position:"Body" name:"MetricType"` + ClientToken string `position:"Body" name:"ClientToken"` + DedicatedClusterId string `position:"Body" name:"DedicatedClusterId"` + AccountId string `position:"Body" name:"AccountId"` + SecurityToken string `position:"Body" name:"SecurityToken"` + DtsJobId string `position:"Body" name:"DtsJobId"` + Env string `position:"Body" name:"Env"` + OwnerID string `position:"Body" name:"OwnerID"` +} + +// DescribeClusterUsedUtilizationResponse is the response struct for api DescribeClusterUsedUtilization +type DescribeClusterUsedUtilizationResponse struct { + *responses.BaseResponse + DedicatedClusterId string `json:"DedicatedClusterId" xml:"DedicatedClusterId"` + CpuTotal float64 `json:"CpuTotal" xml:"CpuTotal"` + MemoryUsed float64 `json:"MemoryUsed" xml:"MemoryUsed"` + MemoryTotal float64 `json:"MemoryTotal" xml:"MemoryTotal"` + DiskTotal float64 `json:"DiskTotal" xml:"DiskTotal"` + DiskUsed float64 `json:"DiskUsed" xml:"DiskUsed"` + DuTotal int `json:"DuTotal" xml:"DuTotal"` + DuUsed int `json:"DuUsed" xml:"DuUsed"` + TaskRunning int `json:"TaskRunning" xml:"TaskRunning"` + Success bool `json:"Success" xml:"Success"` + Code string `json:"Code" xml:"Code"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + MemoryUsedPercentage float64 `json:"MemoryUsedPercentage" xml:"MemoryUsedPercentage"` +} + +// CreateDescribeClusterUsedUtilizationRequest creates a request to invoke DescribeClusterUsedUtilization API +func CreateDescribeClusterUsedUtilizationRequest() (request *DescribeClusterUsedUtilizationRequest) { + request = &DescribeClusterUsedUtilizationRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeClusterUsedUtilization", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeClusterUsedUtilizationResponse creates a response to parse from DescribeClusterUsedUtilization response +func CreateDescribeClusterUsedUtilizationResponse() (response *DescribeClusterUsedUtilizationResponse) { + response = &DescribeClusterUsedUtilizationResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_connection_status.go b/services/dts/describe_connection_status.go new file mode 100644 index 0000000000..65a8c10895 --- /dev/null +++ b/services/dts/describe_connection_status.go @@ -0,0 +1,125 @@ +package dts + +//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" +) + +// DescribeConnectionStatus invokes the dts.DescribeConnectionStatus API synchronously +func (client *Client) DescribeConnectionStatus(request *DescribeConnectionStatusRequest) (response *DescribeConnectionStatusResponse, err error) { + response = CreateDescribeConnectionStatusResponse() + err = client.DoAction(request, response) + return +} + +// DescribeConnectionStatusWithChan invokes the dts.DescribeConnectionStatus API asynchronously +func (client *Client) DescribeConnectionStatusWithChan(request *DescribeConnectionStatusRequest) (<-chan *DescribeConnectionStatusResponse, <-chan error) { + responseChan := make(chan *DescribeConnectionStatusResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeConnectionStatus(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeConnectionStatusWithCallback invokes the dts.DescribeConnectionStatus API asynchronously +func (client *Client) DescribeConnectionStatusWithCallback(request *DescribeConnectionStatusRequest, callback func(response *DescribeConnectionStatusResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeConnectionStatusResponse + var err error + defer close(result) + response, err = client.DescribeConnectionStatus(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeConnectionStatusRequest is the request struct for api DescribeConnectionStatus +type DescribeConnectionStatusRequest struct { + *requests.RpcRequest + SourceEndpointRegion string `position:"Query" name:"SourceEndpointRegion"` + SourceEndpointArchitecture string `position:"Query" name:"SourceEndpointArchitecture"` + DestinationEndpointInstanceType string `position:"Query" name:"DestinationEndpointInstanceType"` + SourceEndpointInstanceID string `position:"Query" name:"SourceEndpointInstanceID"` + SourceEndpointUserName string `position:"Query" name:"SourceEndpointUserName"` + SourceEndpointDatabaseName string `position:"Query" name:"SourceEndpointDatabaseName"` + DestinationEndpointRegion string `position:"Query" name:"DestinationEndpointRegion"` + SourceEndpointIP string `position:"Query" name:"SourceEndpointIP"` + DestinationEndpointUserName string `position:"Query" name:"DestinationEndpointUserName"` + DestinationEndpointArchitecture string `position:"Query" name:"DestinationEndpointArchitecture"` + DestinationEndpointOracleSID string `position:"Query" name:"DestinationEndpointOracleSID"` + DestinationEndpointEngineName string `position:"Query" name:"DestinationEndpointEngineName"` + DestinationEndpointInstanceID string `position:"Query" name:"DestinationEndpointInstanceID"` + DestinationEndpointPort string `position:"Query" name:"DestinationEndpointPort"` + SourceEndpointPassword string `position:"Query" name:"SourceEndpointPassword"` + SourceEndpointPort string `position:"Query" name:"SourceEndpointPort"` + DestinationEndpointIP string `position:"Query" name:"DestinationEndpointIP"` + SourceEndpointInstanceType string `position:"Query" name:"SourceEndpointInstanceType"` + SourceEndpointOracleSID string `position:"Query" name:"SourceEndpointOracleSID"` + DestinationEndpointDatabaseName string `position:"Query" name:"DestinationEndpointDatabaseName"` + DestinationEndpointPassword string `position:"Query" name:"DestinationEndpointPassword"` + SourceEndpointEngineName string `position:"Query" name:"SourceEndpointEngineName"` +} + +// DescribeConnectionStatusResponse is the response struct for api DescribeConnectionStatus +type DescribeConnectionStatusResponse struct { + *responses.BaseResponse + SourceConnectionStatus map[string]interface{} `json:"SourceConnectionStatus" xml:"SourceConnectionStatus"` + DestinationConnectionStatus map[string]interface{} `json:"DestinationConnectionStatus" xml:"DestinationConnectionStatus"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateDescribeConnectionStatusRequest creates a request to invoke DescribeConnectionStatus API +func CreateDescribeConnectionStatusRequest() (request *DescribeConnectionStatusRequest) { + request = &DescribeConnectionStatusRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeConnectionStatus", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeConnectionStatusResponse creates a response to parse from DescribeConnectionStatus response +func CreateDescribeConnectionStatusResponse() (response *DescribeConnectionStatusResponse) { + response = &DescribeConnectionStatusResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_consumer_channel.go b/services/dts/describe_consumer_channel.go new file mode 100644 index 0000000000..03f9b0c864 --- /dev/null +++ b/services/dts/describe_consumer_channel.go @@ -0,0 +1,111 @@ +package dts + +//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" +) + +// DescribeConsumerChannel invokes the dts.DescribeConsumerChannel API synchronously +func (client *Client) DescribeConsumerChannel(request *DescribeConsumerChannelRequest) (response *DescribeConsumerChannelResponse, err error) { + response = CreateDescribeConsumerChannelResponse() + err = client.DoAction(request, response) + return +} + +// DescribeConsumerChannelWithChan invokes the dts.DescribeConsumerChannel API asynchronously +func (client *Client) DescribeConsumerChannelWithChan(request *DescribeConsumerChannelRequest) (<-chan *DescribeConsumerChannelResponse, <-chan error) { + responseChan := make(chan *DescribeConsumerChannelResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeConsumerChannel(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeConsumerChannelWithCallback invokes the dts.DescribeConsumerChannel API asynchronously +func (client *Client) DescribeConsumerChannelWithCallback(request *DescribeConsumerChannelRequest, callback func(response *DescribeConsumerChannelResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeConsumerChannelResponse + var err error + defer close(result) + response, err = client.DescribeConsumerChannel(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeConsumerChannelRequest is the request struct for api DescribeConsumerChannel +type DescribeConsumerChannelRequest struct { + *requests.RpcRequest + PageNumber requests.Integer `position:"Query" name:"PageNumber"` + ParentChannelId string `position:"Query" name:"ParentChannelId"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + DtsJobId string `position:"Query" name:"DtsJobId"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` +} + +// DescribeConsumerChannelResponse is the response struct for api DescribeConsumerChannel +type DescribeConsumerChannelResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + PageRecordCount int `json:"PageRecordCount" xml:"PageRecordCount"` + Success string `json:"Success" xml:"Success"` + TotalRecordCount int64 `json:"TotalRecordCount" xml:"TotalRecordCount"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + ConsumerChannels []ConsumerChannel `json:"ConsumerChannels" xml:"ConsumerChannels"` +} + +// CreateDescribeConsumerChannelRequest creates a request to invoke DescribeConsumerChannel API +func CreateDescribeConsumerChannelRequest() (request *DescribeConsumerChannelRequest) { + request = &DescribeConsumerChannelRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeConsumerChannel", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeConsumerChannelResponse creates a response to parse from DescribeConsumerChannel response +func CreateDescribeConsumerChannelResponse() (response *DescribeConsumerChannelResponse) { + response = &DescribeConsumerChannelResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_consumer_group.go b/services/dts/describe_consumer_group.go new file mode 100644 index 0000000000..8bbc73cd97 --- /dev/null +++ b/services/dts/describe_consumer_group.go @@ -0,0 +1,110 @@ +package dts + +//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" +) + +// DescribeConsumerGroup invokes the dts.DescribeConsumerGroup API synchronously +func (client *Client) DescribeConsumerGroup(request *DescribeConsumerGroupRequest) (response *DescribeConsumerGroupResponse, err error) { + response = CreateDescribeConsumerGroupResponse() + err = client.DoAction(request, response) + return +} + +// DescribeConsumerGroupWithChan invokes the dts.DescribeConsumerGroup API asynchronously +func (client *Client) DescribeConsumerGroupWithChan(request *DescribeConsumerGroupRequest) (<-chan *DescribeConsumerGroupResponse, <-chan error) { + responseChan := make(chan *DescribeConsumerGroupResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeConsumerGroup(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeConsumerGroupWithCallback invokes the dts.DescribeConsumerGroup API asynchronously +func (client *Client) DescribeConsumerGroupWithCallback(request *DescribeConsumerGroupRequest, callback func(response *DescribeConsumerGroupResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeConsumerGroupResponse + var err error + defer close(result) + response, err = client.DescribeConsumerGroup(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeConsumerGroupRequest is the request struct for api DescribeConsumerGroup +type DescribeConsumerGroupRequest struct { + *requests.RpcRequest + SubscriptionInstanceId string `position:"Query" name:"SubscriptionInstanceId"` + PageNum requests.Integer `position:"Query" name:"PageNum"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` + PageSize requests.Integer `position:"Query" name:"PageSize"` +} + +// DescribeConsumerGroupResponse is the response struct for api DescribeConsumerGroup +type DescribeConsumerGroupResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + PageRecordCount int `json:"PageRecordCount" xml:"PageRecordCount"` + TotalRecordCount int `json:"TotalRecordCount" xml:"TotalRecordCount"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + ConsumerChannels ConsumerChannelsInDescribeConsumerGroup `json:"ConsumerChannels" xml:"ConsumerChannels"` +} + +// CreateDescribeConsumerGroupRequest creates a request to invoke DescribeConsumerGroup API +func CreateDescribeConsumerGroupRequest() (request *DescribeConsumerGroupRequest) { + request = &DescribeConsumerGroupRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeConsumerGroup", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeConsumerGroupResponse creates a response to parse from DescribeConsumerGroup response +func CreateDescribeConsumerGroupResponse() (response *DescribeConsumerGroupResponse) { + response = &DescribeConsumerGroupResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_data_check_report_url.go b/services/dts/describe_data_check_report_url.go new file mode 100644 index 0000000000..d50f7f0977 --- /dev/null +++ b/services/dts/describe_data_check_report_url.go @@ -0,0 +1,107 @@ +package dts + +//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" +) + +// DescribeDataCheckReportUrl invokes the dts.DescribeDataCheckReportUrl API synchronously +func (client *Client) DescribeDataCheckReportUrl(request *DescribeDataCheckReportUrlRequest) (response *DescribeDataCheckReportUrlResponse, err error) { + response = CreateDescribeDataCheckReportUrlResponse() + err = client.DoAction(request, response) + return +} + +// DescribeDataCheckReportUrlWithChan invokes the dts.DescribeDataCheckReportUrl API asynchronously +func (client *Client) DescribeDataCheckReportUrlWithChan(request *DescribeDataCheckReportUrlRequest) (<-chan *DescribeDataCheckReportUrlResponse, <-chan error) { + responseChan := make(chan *DescribeDataCheckReportUrlResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeDataCheckReportUrl(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeDataCheckReportUrlWithCallback invokes the dts.DescribeDataCheckReportUrl API asynchronously +func (client *Client) DescribeDataCheckReportUrlWithCallback(request *DescribeDataCheckReportUrlRequest, callback func(response *DescribeDataCheckReportUrlResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeDataCheckReportUrlResponse + var err error + defer close(result) + response, err = client.DescribeDataCheckReportUrl(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeDataCheckReportUrlRequest is the request struct for api DescribeDataCheckReportUrl +type DescribeDataCheckReportUrlRequest struct { + *requests.RpcRequest + CheckType requests.Integer `position:"Query" name:"CheckType"` + TbName string `position:"Query" name:"TbName"` + DbName string `position:"Query" name:"DbName"` + DtsJobId string `position:"Query" name:"DtsJobId"` +} + +// DescribeDataCheckReportUrlResponse is the response struct for api DescribeDataCheckReportUrl +type DescribeDataCheckReportUrlResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` +} + +// CreateDescribeDataCheckReportUrlRequest creates a request to invoke DescribeDataCheckReportUrl API +func CreateDescribeDataCheckReportUrlRequest() (request *DescribeDataCheckReportUrlRequest) { + request = &DescribeDataCheckReportUrlRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeDataCheckReportUrl", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeDataCheckReportUrlResponse creates a response to parse from DescribeDataCheckReportUrl response +func CreateDescribeDataCheckReportUrlResponse() (response *DescribeDataCheckReportUrlResponse) { + response = &DescribeDataCheckReportUrlResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_data_check_table_details.go b/services/dts/describe_data_check_table_details.go new file mode 100644 index 0000000000..0fc99f7516 --- /dev/null +++ b/services/dts/describe_data_check_table_details.go @@ -0,0 +1,115 @@ +package dts + +//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" +) + +// DescribeDataCheckTableDetails invokes the dts.DescribeDataCheckTableDetails API synchronously +func (client *Client) DescribeDataCheckTableDetails(request *DescribeDataCheckTableDetailsRequest) (response *DescribeDataCheckTableDetailsResponse, err error) { + response = CreateDescribeDataCheckTableDetailsResponse() + err = client.DoAction(request, response) + return +} + +// DescribeDataCheckTableDetailsWithChan invokes the dts.DescribeDataCheckTableDetails API asynchronously +func (client *Client) DescribeDataCheckTableDetailsWithChan(request *DescribeDataCheckTableDetailsRequest) (<-chan *DescribeDataCheckTableDetailsResponse, <-chan error) { + responseChan := make(chan *DescribeDataCheckTableDetailsResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeDataCheckTableDetails(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeDataCheckTableDetailsWithCallback invokes the dts.DescribeDataCheckTableDetails API asynchronously +func (client *Client) DescribeDataCheckTableDetailsWithCallback(request *DescribeDataCheckTableDetailsRequest, callback func(response *DescribeDataCheckTableDetailsResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeDataCheckTableDetailsResponse + var err error + defer close(result) + response, err = client.DescribeDataCheckTableDetails(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeDataCheckTableDetailsRequest is the request struct for api DescribeDataCheckTableDetails +type DescribeDataCheckTableDetailsRequest struct { + *requests.RpcRequest + PageNumber requests.Integer `position:"Query" name:"PageNumber"` + CheckType requests.Integer `position:"Query" name:"CheckType"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + DtsJobId string `position:"Query" name:"DtsJobId"` + TableName string `position:"Query" name:"TableName"` + Status string `position:"Query" name:"Status"` +} + +// DescribeDataCheckTableDetailsResponse is the response struct for api DescribeDataCheckTableDetails +type DescribeDataCheckTableDetailsResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` + TotalCount int64 `json:"TotalCount" xml:"TotalCount"` + FinishedCount int64 `json:"FinishedCount" xml:"FinishedCount"` + DiffTableCount int64 `json:"DiffTableCount" xml:"DiffTableCount"` + TableDetails []TableDetailsItem `json:"TableDetails" xml:"TableDetails"` +} + +// CreateDescribeDataCheckTableDetailsRequest creates a request to invoke DescribeDataCheckTableDetails API +func CreateDescribeDataCheckTableDetailsRequest() (request *DescribeDataCheckTableDetailsRequest) { + request = &DescribeDataCheckTableDetailsRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeDataCheckTableDetails", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeDataCheckTableDetailsResponse creates a response to parse from DescribeDataCheckTableDetails response +func CreateDescribeDataCheckTableDetailsResponse() (response *DescribeDataCheckTableDetailsResponse) { + response = &DescribeDataCheckTableDetailsResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_data_check_table_diff_details.go b/services/dts/describe_data_check_table_diff_details.go new file mode 100644 index 0000000000..5c2dbb1fa6 --- /dev/null +++ b/services/dts/describe_data_check_table_diff_details.go @@ -0,0 +1,114 @@ +package dts + +//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" +) + +// DescribeDataCheckTableDiffDetails invokes the dts.DescribeDataCheckTableDiffDetails API synchronously +func (client *Client) DescribeDataCheckTableDiffDetails(request *DescribeDataCheckTableDiffDetailsRequest) (response *DescribeDataCheckTableDiffDetailsResponse, err error) { + response = CreateDescribeDataCheckTableDiffDetailsResponse() + err = client.DoAction(request, response) + return +} + +// DescribeDataCheckTableDiffDetailsWithChan invokes the dts.DescribeDataCheckTableDiffDetails API asynchronously +func (client *Client) DescribeDataCheckTableDiffDetailsWithChan(request *DescribeDataCheckTableDiffDetailsRequest) (<-chan *DescribeDataCheckTableDiffDetailsResponse, <-chan error) { + responseChan := make(chan *DescribeDataCheckTableDiffDetailsResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeDataCheckTableDiffDetails(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeDataCheckTableDiffDetailsWithCallback invokes the dts.DescribeDataCheckTableDiffDetails API asynchronously +func (client *Client) DescribeDataCheckTableDiffDetailsWithCallback(request *DescribeDataCheckTableDiffDetailsRequest, callback func(response *DescribeDataCheckTableDiffDetailsResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeDataCheckTableDiffDetailsResponse + var err error + defer close(result) + response, err = client.DescribeDataCheckTableDiffDetails(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeDataCheckTableDiffDetailsRequest is the request struct for api DescribeDataCheckTableDiffDetails +type DescribeDataCheckTableDiffDetailsRequest struct { + *requests.RpcRequest + PageNumber requests.Integer `position:"Query" name:"PageNumber"` + CheckType requests.Integer `position:"Query" name:"CheckType"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + DtsJobId string `position:"Query" name:"DtsJobId"` + TbName string `position:"Query" name:"TbName"` + DbName string `position:"Query" name:"DbName"` +} + +// DescribeDataCheckTableDiffDetailsResponse is the response struct for api DescribeDataCheckTableDiffDetails +type DescribeDataCheckTableDiffDetailsResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + TbName string `json:"TbName" xml:"TbName"` + DbName string `json:"DbName" xml:"DbName"` + DiffCount int64 `json:"DiffCount" xml:"DiffCount"` + InstanceId string `json:"InstanceId" xml:"InstanceId"` + DiffDetails []DiffDetailsItem `json:"DiffDetails" xml:"DiffDetails"` +} + +// CreateDescribeDataCheckTableDiffDetailsRequest creates a request to invoke DescribeDataCheckTableDiffDetails API +func CreateDescribeDataCheckTableDiffDetailsRequest() (request *DescribeDataCheckTableDiffDetailsRequest) { + request = &DescribeDataCheckTableDiffDetailsRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeDataCheckTableDiffDetails", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeDataCheckTableDiffDetailsResponse creates a response to parse from DescribeDataCheckTableDiffDetails response +func CreateDescribeDataCheckTableDiffDetailsResponse() (response *DescribeDataCheckTableDiffDetailsResponse) { + response = &DescribeDataCheckTableDiffDetailsResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_dedicated_cluster.go b/services/dts/describe_dedicated_cluster.go new file mode 100644 index 0000000000..54c8387a7c --- /dev/null +++ b/services/dts/describe_dedicated_cluster.go @@ -0,0 +1,125 @@ +package dts + +//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" +) + +// DescribeDedicatedCluster invokes the dts.DescribeDedicatedCluster API synchronously +func (client *Client) DescribeDedicatedCluster(request *DescribeDedicatedClusterRequest) (response *DescribeDedicatedClusterResponse, err error) { + response = CreateDescribeDedicatedClusterResponse() + err = client.DoAction(request, response) + return +} + +// DescribeDedicatedClusterWithChan invokes the dts.DescribeDedicatedCluster API asynchronously +func (client *Client) DescribeDedicatedClusterWithChan(request *DescribeDedicatedClusterRequest) (<-chan *DescribeDedicatedClusterResponse, <-chan error) { + responseChan := make(chan *DescribeDedicatedClusterResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeDedicatedCluster(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeDedicatedClusterWithCallback invokes the dts.DescribeDedicatedCluster API asynchronously +func (client *Client) DescribeDedicatedClusterWithCallback(request *DescribeDedicatedClusterRequest, callback func(response *DescribeDedicatedClusterResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeDedicatedClusterResponse + var err error + defer close(result) + response, err = client.DescribeDedicatedCluster(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeDedicatedClusterRequest is the request struct for api DescribeDedicatedCluster +type DescribeDedicatedClusterRequest struct { + *requests.RpcRequest + DedicatedClusterId string `position:"Query" name:"DedicatedClusterId"` + OwnerId string `position:"Query" name:"OwnerId"` +} + +// DescribeDedicatedClusterResponse is the response struct for api DescribeDedicatedCluster +type DescribeDedicatedClusterResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DedicatedClusterId string `json:"DedicatedClusterId" xml:"DedicatedClusterId"` + DedicatedClusterName string `json:"DedicatedClusterName" xml:"DedicatedClusterName"` + Du int64 `json:"Du" xml:"Du"` + OversoldDu int64 `json:"OversoldDu" xml:"OversoldDu"` + UsedDu int64 `json:"UsedDu" xml:"UsedDu"` + State string `json:"State" xml:"State"` + RegionId string `json:"RegionId" xml:"RegionId"` + NodeCount int64 `json:"NodeCount" xml:"NodeCount"` + DuUtilization int64 `json:"DuUtilization" xml:"DuUtilization"` + CpuUtilization int64 `json:"CpuUtilization" xml:"CpuUtilization"` + TotalCpuCore int64 `json:"TotalCpuCore" xml:"TotalCpuCore"` + UsedCpuCore int64 `json:"UsedCpuCore" xml:"UsedCpuCore"` + MemUtilization int64 `json:"MemUtilization" xml:"MemUtilization"` + TotalMemGBSize int64 `json:"TotalMemGBSize" xml:"TotalMemGBSize"` + UsedMemGBSize int64 `json:"UsedMemGBSize" xml:"UsedMemGBSize"` + DiskUtilization int64 `json:"DiskUtilization" xml:"DiskUtilization"` + TotalDiskGBSize int64 `json:"TotalDiskGBSize" xml:"TotalDiskGBSize"` + UsedDiskGBSize int64 `json:"UsedDiskGBSize" xml:"UsedDiskGBSize"` + GmtCreated int64 `json:"GmtCreated" xml:"GmtCreated"` + GmtFinished int64 `json:"GmtFinished" xml:"GmtFinished"` + DtsInstanceID string `json:"DtsInstanceID" xml:"DtsInstanceID"` +} + +// CreateDescribeDedicatedClusterRequest creates a request to invoke DescribeDedicatedCluster API +func CreateDescribeDedicatedClusterRequest() (request *DescribeDedicatedClusterRequest) { + request = &DescribeDedicatedClusterRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeDedicatedCluster", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeDedicatedClusterResponse creates a response to parse from DescribeDedicatedCluster response +func CreateDescribeDedicatedClusterResponse() (response *DescribeDedicatedClusterResponse) { + response = &DescribeDedicatedClusterResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_dedicated_cluster_monitor_rule.go b/services/dts/describe_dedicated_cluster_monitor_rule.go new file mode 100644 index 0000000000..f84c599b81 --- /dev/null +++ b/services/dts/describe_dedicated_cluster_monitor_rule.go @@ -0,0 +1,111 @@ +package dts + +//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" +) + +// DescribeDedicatedClusterMonitorRule invokes the dts.DescribeDedicatedClusterMonitorRule API synchronously +func (client *Client) DescribeDedicatedClusterMonitorRule(request *DescribeDedicatedClusterMonitorRuleRequest) (response *DescribeDedicatedClusterMonitorRuleResponse, err error) { + response = CreateDescribeDedicatedClusterMonitorRuleResponse() + err = client.DoAction(request, response) + return +} + +// DescribeDedicatedClusterMonitorRuleWithChan invokes the dts.DescribeDedicatedClusterMonitorRule API asynchronously +func (client *Client) DescribeDedicatedClusterMonitorRuleWithChan(request *DescribeDedicatedClusterMonitorRuleRequest) (<-chan *DescribeDedicatedClusterMonitorRuleResponse, <-chan error) { + responseChan := make(chan *DescribeDedicatedClusterMonitorRuleResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeDedicatedClusterMonitorRule(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeDedicatedClusterMonitorRuleWithCallback invokes the dts.DescribeDedicatedClusterMonitorRule API asynchronously +func (client *Client) DescribeDedicatedClusterMonitorRuleWithCallback(request *DescribeDedicatedClusterMonitorRuleRequest, callback func(response *DescribeDedicatedClusterMonitorRuleResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeDedicatedClusterMonitorRuleResponse + var err error + defer close(result) + response, err = client.DescribeDedicatedClusterMonitorRule(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeDedicatedClusterMonitorRuleRequest is the request struct for api DescribeDedicatedClusterMonitorRule +type DescribeDedicatedClusterMonitorRuleRequest struct { + *requests.RpcRequest + DedicatedClusterId string `position:"Query" name:"DedicatedClusterId"` + OwnerId string `position:"Query" name:"OwnerId"` +} + +// DescribeDedicatedClusterMonitorRuleResponse is the response struct for api DescribeDedicatedClusterMonitorRule +type DescribeDedicatedClusterMonitorRuleResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DedicatedClusterId string `json:"DedicatedClusterId" xml:"DedicatedClusterId"` + NoticeSwitch string `json:"NoticeSwitch" xml:"NoticeSwitch"` + DuAlarmThreshold string `json:"DuAlarmThreshold" xml:"DuAlarmThreshold"` + CpuAlarmThreshold string `json:"CpuAlarmThreshold" xml:"CpuAlarmThreshold"` + MemAlarmThreshold string `json:"MemAlarmThreshold" xml:"MemAlarmThreshold"` + DiskAlarmThreshold string `json:"DiskAlarmThreshold" xml:"DiskAlarmThreshold"` + Phones string `json:"Phones" xml:"Phones"` +} + +// CreateDescribeDedicatedClusterMonitorRuleRequest creates a request to invoke DescribeDedicatedClusterMonitorRule API +func CreateDescribeDedicatedClusterMonitorRuleRequest() (request *DescribeDedicatedClusterMonitorRuleRequest) { + request = &DescribeDedicatedClusterMonitorRuleRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeDedicatedClusterMonitorRule", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeDedicatedClusterMonitorRuleResponse creates a response to parse from DescribeDedicatedClusterMonitorRule response +func CreateDescribeDedicatedClusterMonitorRuleResponse() (response *DescribeDedicatedClusterMonitorRuleResponse) { + response = &DescribeDedicatedClusterMonitorRuleResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_dts_etl_job_version_info.go b/services/dts/describe_dts_etl_job_version_info.go new file mode 100644 index 0000000000..64a6cd733c --- /dev/null +++ b/services/dts/describe_dts_etl_job_version_info.go @@ -0,0 +1,112 @@ +package dts + +//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" +) + +// DescribeDtsEtlJobVersionInfo invokes the dts.DescribeDtsEtlJobVersionInfo API synchronously +func (client *Client) DescribeDtsEtlJobVersionInfo(request *DescribeDtsEtlJobVersionInfoRequest) (response *DescribeDtsEtlJobVersionInfoResponse, err error) { + response = CreateDescribeDtsEtlJobVersionInfoResponse() + err = client.DoAction(request, response) + return +} + +// DescribeDtsEtlJobVersionInfoWithChan invokes the dts.DescribeDtsEtlJobVersionInfo API asynchronously +func (client *Client) DescribeDtsEtlJobVersionInfoWithChan(request *DescribeDtsEtlJobVersionInfoRequest) (<-chan *DescribeDtsEtlJobVersionInfoResponse, <-chan error) { + responseChan := make(chan *DescribeDtsEtlJobVersionInfoResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeDtsEtlJobVersionInfo(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeDtsEtlJobVersionInfoWithCallback invokes the dts.DescribeDtsEtlJobVersionInfo API asynchronously +func (client *Client) DescribeDtsEtlJobVersionInfoWithCallback(request *DescribeDtsEtlJobVersionInfoRequest, callback func(response *DescribeDtsEtlJobVersionInfoResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeDtsEtlJobVersionInfoResponse + var err error + defer close(result) + response, err = client.DescribeDtsEtlJobVersionInfo(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeDtsEtlJobVersionInfoRequest is the request struct for api DescribeDtsEtlJobVersionInfo +type DescribeDtsEtlJobVersionInfoRequest struct { + *requests.RpcRequest + PageNumber requests.Integer `position:"Query" name:"PageNumber"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + DtsJobId string `position:"Query" name:"DtsJobId"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` +} + +// DescribeDtsEtlJobVersionInfoResponse is the response struct for api DescribeDtsEtlJobVersionInfo +type DescribeDtsEtlJobVersionInfoResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + Success bool `json:"Success" xml:"Success"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + PageRecordCount int `json:"PageRecordCount" xml:"PageRecordCount"` + TotalRecordCount int `json:"TotalRecordCount" xml:"TotalRecordCount"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DtsEtlJobVersionInfos []DtsEtlJobVersionInfo `json:"DtsEtlJobVersionInfos" xml:"DtsEtlJobVersionInfos"` +} + +// CreateDescribeDtsEtlJobVersionInfoRequest creates a request to invoke DescribeDtsEtlJobVersionInfo API +func CreateDescribeDtsEtlJobVersionInfoRequest() (request *DescribeDtsEtlJobVersionInfoRequest) { + request = &DescribeDtsEtlJobVersionInfoRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeDtsEtlJobVersionInfo", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeDtsEtlJobVersionInfoResponse creates a response to parse from DescribeDtsEtlJobVersionInfo response +func CreateDescribeDtsEtlJobVersionInfoResponse() (response *DescribeDtsEtlJobVersionInfoResponse) { + response = &DescribeDtsEtlJobVersionInfoResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_dts_job_detail.go b/services/dts/describe_dts_job_detail.go new file mode 100644 index 0000000000..af812fd2ca --- /dev/null +++ b/services/dts/describe_dts_job_detail.go @@ -0,0 +1,156 @@ +package dts + +//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" +) + +// DescribeDtsJobDetail invokes the dts.DescribeDtsJobDetail API synchronously +func (client *Client) DescribeDtsJobDetail(request *DescribeDtsJobDetailRequest) (response *DescribeDtsJobDetailResponse, err error) { + response = CreateDescribeDtsJobDetailResponse() + err = client.DoAction(request, response) + return +} + +// DescribeDtsJobDetailWithChan invokes the dts.DescribeDtsJobDetail API asynchronously +func (client *Client) DescribeDtsJobDetailWithChan(request *DescribeDtsJobDetailRequest) (<-chan *DescribeDtsJobDetailResponse, <-chan error) { + responseChan := make(chan *DescribeDtsJobDetailResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeDtsJobDetail(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeDtsJobDetailWithCallback invokes the dts.DescribeDtsJobDetail API asynchronously +func (client *Client) DescribeDtsJobDetailWithCallback(request *DescribeDtsJobDetailRequest, callback func(response *DescribeDtsJobDetailResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeDtsJobDetailResponse + var err error + defer close(result) + response, err = client.DescribeDtsJobDetail(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeDtsJobDetailRequest is the request struct for api DescribeDtsJobDetail +type DescribeDtsJobDetailRequest struct { + *requests.RpcRequest + SyncSubJobHistory requests.Boolean `position:"Query" name:"SyncSubJobHistory"` + DtsJobId string `position:"Query" name:"DtsJobId"` + DtsInstanceID string `position:"Query" name:"DtsInstanceID"` + SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` +} + +// DescribeDtsJobDetailResponse is the response struct for api DescribeDtsJobDetail +type DescribeDtsJobDetailResponse struct { + *responses.BaseResponse + Status string `json:"Status" xml:"Status"` + DtsJobName string `json:"DtsJobName" xml:"DtsJobName"` + FinishTime string `json:"FinishTime" xml:"FinishTime"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + CreateTime string `json:"CreateTime" xml:"CreateTime"` + PayType string `json:"PayType" xml:"PayType"` + Reserved string `json:"Reserved" xml:"Reserved"` + DatabaseCount int `json:"DatabaseCount" xml:"DatabaseCount"` + DtsJobClass string `json:"DtsJobClass" xml:"DtsJobClass"` + EndTimestamp string `json:"EndTimestamp" xml:"EndTimestamp"` + AppName string `json:"AppName" xml:"AppName"` + DestNetType string `json:"DestNetType" xml:"DestNetType"` + SubscribeTopic string `json:"SubscribeTopic" xml:"SubscribeTopic"` + DtsInstanceID string `json:"DtsInstanceID" xml:"DtsInstanceID"` + RequestId string `json:"RequestId" xml:"RequestId"` + Code int `json:"Code" xml:"Code"` + Checkpoint int64 `json:"Checkpoint" xml:"Checkpoint"` + Delay int64 `json:"Delay" xml:"Delay"` + ExpireTime string `json:"ExpireTime" xml:"ExpireTime"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + ConsumptionClient string `json:"ConsumptionClient" xml:"ConsumptionClient"` + DbObject string `json:"DbObject" xml:"DbObject"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + ConsumptionCheckpoint string `json:"ConsumptionCheckpoint" xml:"ConsumptionCheckpoint"` + EtlCalculator string `json:"EtlCalculator" xml:"EtlCalculator"` + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + BeginTimestamp string `json:"BeginTimestamp" xml:"BeginTimestamp"` + GroupId string `json:"GroupId" xml:"GroupId"` + SynchronizationDirection string `json:"SynchronizationDirection" xml:"SynchronizationDirection"` + DtsJobDirection string `json:"DtsJobDirection" xml:"DtsJobDirection"` + DemoJob bool `json:"DemoJob" xml:"DemoJob"` + JobType string `json:"JobType" xml:"JobType"` + TaskType string `json:"TaskType" xml:"TaskType"` + DedicatedClusterId string `json:"DedicatedClusterId" xml:"DedicatedClusterId"` + BootTime string `json:"BootTime" xml:"BootTime"` + Binlog string `json:"Binlog" xml:"Binlog"` + BinlogSite string `json:"BinlogSite" xml:"BinlogSite"` + BinlogTime string `json:"BinlogTime" xml:"BinlogTime"` + LastUpdateTime string `json:"LastUpdateTime" xml:"LastUpdateTime"` + ResourceGroupId string `json:"ResourceGroupId" xml:"ResourceGroupId"` + ResourceGroupDisplayName string `json:"ResourceGroupDisplayName" xml:"ResourceGroupDisplayName"` + DtsBisLabel string `json:"DtsBisLabel" xml:"DtsBisLabel"` + SourceEndpoint SourceEndpoint `json:"SourceEndpoint" xml:"SourceEndpoint"` + DestinationEndpoint DestinationEndpoint `json:"DestinationEndpoint" xml:"DestinationEndpoint"` + MigrationMode MigrationMode `json:"MigrationMode" xml:"MigrationMode"` + SubscriptionHost SubscriptionHost `json:"SubscriptionHost" xml:"SubscriptionHost"` + SubscriptionDataType SubscriptionDataType `json:"SubscriptionDataType" xml:"SubscriptionDataType"` + DataSynchronizationStatus DataSynchronizationStatus `json:"DataSynchronizationStatus" xml:"DataSynchronizationStatus"` + RetryState RetryState `json:"RetryState" xml:"RetryState"` + DataDeliveryChannelInfo DataDeliveryChannelInfo `json:"DataDeliveryChannelInfo" xml:"DataDeliveryChannelInfo"` + SubDistributedJob []SubDistributedJobItem `json:"SubDistributedJob" xml:"SubDistributedJob"` + SubSyncJob []SubSyncJobItem `json:"SubSyncJob" xml:"SubSyncJob"` +} + +// CreateDescribeDtsJobDetailRequest creates a request to invoke DescribeDtsJobDetail API +func CreateDescribeDtsJobDetailRequest() (request *DescribeDtsJobDetailRequest) { + request = &DescribeDtsJobDetailRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeDtsJobDetail", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeDtsJobDetailResponse creates a response to parse from DescribeDtsJobDetail response +func CreateDescribeDtsJobDetailResponse() (response *DescribeDtsJobDetailResponse) { + response = &DescribeDtsJobDetailResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_dts_jobs.go b/services/dts/describe_dts_jobs.go new file mode 100644 index 0000000000..eb67155281 --- /dev/null +++ b/services/dts/describe_dts_jobs.go @@ -0,0 +1,128 @@ +package dts + +//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" +) + +// DescribeDtsJobs invokes the dts.DescribeDtsJobs API synchronously +func (client *Client) DescribeDtsJobs(request *DescribeDtsJobsRequest) (response *DescribeDtsJobsResponse, err error) { + response = CreateDescribeDtsJobsResponse() + err = client.DoAction(request, response) + return +} + +// DescribeDtsJobsWithChan invokes the dts.DescribeDtsJobs API asynchronously +func (client *Client) DescribeDtsJobsWithChan(request *DescribeDtsJobsRequest) (<-chan *DescribeDtsJobsResponse, <-chan error) { + responseChan := make(chan *DescribeDtsJobsResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeDtsJobs(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeDtsJobsWithCallback invokes the dts.DescribeDtsJobs API asynchronously +func (client *Client) DescribeDtsJobsWithCallback(request *DescribeDtsJobsRequest, callback func(response *DescribeDtsJobsResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeDtsJobsResponse + var err error + defer close(result) + response, err = client.DescribeDtsJobs(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeDtsJobsRequest is the request struct for api DescribeDtsJobs +type DescribeDtsJobsRequest struct { + *requests.RpcRequest + WithoutDbList requests.Boolean `position:"Query" name:"WithoutDbList"` + OrderDirection string `position:"Query" name:"OrderDirection"` + DedicatedClusterId string `position:"Query" name:"DedicatedClusterId"` + Type string `position:"Query" name:"Type"` + PageNumber requests.Integer `position:"Query" name:"PageNumber"` + OrderColumn string `position:"Query" name:"OrderColumn"` + ResourceGroupId string `position:"Query" name:"ResourceGroupId"` + DtsBisLabel string `position:"Query" name:"DtsBisLabel"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + DtsJobId string `position:"Query" name:"DtsJobId"` + OriginType string `position:"Query" name:"OriginType"` + GroupId string `position:"Query" name:"GroupId"` + Params string `position:"Query" name:"Params"` + OwnerId string `position:"Query" name:"OwnerId"` + JobType string `position:"Query" name:"JobType"` + Tags string `position:"Query" name:"Tags"` + Region string `position:"Query" name:"Region"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` + Status string `position:"Query" name:"Status"` +} + +// DescribeDtsJobsResponse is the response struct for api DescribeDtsJobs +type DescribeDtsJobsResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + PageRecordCount int `json:"PageRecordCount" xml:"PageRecordCount"` + TotalRecordCount int `json:"TotalRecordCount" xml:"TotalRecordCount"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` + DtsJobList []DtsJobStatus `json:"DtsJobList" xml:"DtsJobList"` + EtlDemoList []DtsJobStatus `json:"EtlDemoList" xml:"EtlDemoList"` +} + +// CreateDescribeDtsJobsRequest creates a request to invoke DescribeDtsJobs API +func CreateDescribeDtsJobsRequest() (request *DescribeDtsJobsRequest) { + request = &DescribeDtsJobsRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeDtsJobs", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeDtsJobsResponse creates a response to parse from DescribeDtsJobs response +func CreateDescribeDtsJobsResponse() (response *DescribeDtsJobsResponse) { + response = &DescribeDtsJobsResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_dts_service_log.go b/services/dts/describe_dts_service_log.go new file mode 100644 index 0000000000..cf25f8bd29 --- /dev/null +++ b/services/dts/describe_dts_service_log.go @@ -0,0 +1,116 @@ +package dts + +//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" +) + +// DescribeDtsServiceLog invokes the dts.DescribeDtsServiceLog API synchronously +func (client *Client) DescribeDtsServiceLog(request *DescribeDtsServiceLogRequest) (response *DescribeDtsServiceLogResponse, err error) { + response = CreateDescribeDtsServiceLogResponse() + err = client.DoAction(request, response) + return +} + +// DescribeDtsServiceLogWithChan invokes the dts.DescribeDtsServiceLog API asynchronously +func (client *Client) DescribeDtsServiceLogWithChan(request *DescribeDtsServiceLogRequest) (<-chan *DescribeDtsServiceLogResponse, <-chan error) { + responseChan := make(chan *DescribeDtsServiceLogResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeDtsServiceLog(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeDtsServiceLogWithCallback invokes the dts.DescribeDtsServiceLog API asynchronously +func (client *Client) DescribeDtsServiceLogWithCallback(request *DescribeDtsServiceLogRequest, callback func(response *DescribeDtsServiceLogResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeDtsServiceLogResponse + var err error + defer close(result) + response, err = client.DescribeDtsServiceLog(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeDtsServiceLogRequest is the request struct for api DescribeDtsServiceLog +type DescribeDtsServiceLogRequest struct { + *requests.RpcRequest + StartTime requests.Integer `position:"Query" name:"StartTime"` + PageNumber requests.Integer `position:"Query" name:"PageNumber"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + DtsJobId string `position:"Query" name:"DtsJobId"` + Keyword string `position:"Query" name:"Keyword"` + SubJobType string `position:"Query" name:"SubJobType"` + EndTime requests.Integer `position:"Query" name:"EndTime"` + Status string `position:"Query" name:"Status"` +} + +// DescribeDtsServiceLogResponse is the response struct for api DescribeDtsServiceLog +type DescribeDtsServiceLogResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + PageRecordCount int `json:"PageRecordCount" xml:"PageRecordCount"` + TotalRecordCount int64 `json:"TotalRecordCount" xml:"TotalRecordCount"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` + ServiceLogContexts []ServiceLogContext `json:"ServiceLogContexts" xml:"ServiceLogContexts"` +} + +// CreateDescribeDtsServiceLogRequest creates a request to invoke DescribeDtsServiceLog API +func CreateDescribeDtsServiceLogRequest() (request *DescribeDtsServiceLogRequest) { + request = &DescribeDtsServiceLogRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeDtsServiceLog", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeDtsServiceLogResponse creates a response to parse from DescribeDtsServiceLog response +func CreateDescribeDtsServiceLogResponse() (response *DescribeDtsServiceLogResponse) { + response = &DescribeDtsServiceLogResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_dtsip.go b/services/dts/describe_dtsip.go new file mode 100644 index 0000000000..a4a82e7e79 --- /dev/null +++ b/services/dts/describe_dtsip.go @@ -0,0 +1,105 @@ +package dts + +//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" +) + +// DescribeDTSIP invokes the dts.DescribeDTSIP API synchronously +func (client *Client) DescribeDTSIP(request *DescribeDTSIPRequest) (response *DescribeDTSIPResponse, err error) { + response = CreateDescribeDTSIPResponse() + err = client.DoAction(request, response) + return +} + +// DescribeDTSIPWithChan invokes the dts.DescribeDTSIP API asynchronously +func (client *Client) DescribeDTSIPWithChan(request *DescribeDTSIPRequest) (<-chan *DescribeDTSIPResponse, <-chan error) { + responseChan := make(chan *DescribeDTSIPResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeDTSIP(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeDTSIPWithCallback invokes the dts.DescribeDTSIP API asynchronously +func (client *Client) DescribeDTSIPWithCallback(request *DescribeDTSIPRequest, callback func(response *DescribeDTSIPResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeDTSIPResponse + var err error + defer close(result) + response, err = client.DescribeDTSIP(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeDTSIPRequest is the request struct for api DescribeDTSIP +type DescribeDTSIPRequest struct { + *requests.RpcRequest + SourceEndpointRegion string `position:"Query" name:"SourceEndpointRegion"` + DestinationEndpointRegion string `position:"Query" name:"DestinationEndpointRegion"` +} + +// DescribeDTSIPResponse is the response struct for api DescribeDTSIP +type DescribeDTSIPResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` +} + +// CreateDescribeDTSIPRequest creates a request to invoke DescribeDTSIP API +func CreateDescribeDTSIPRequest() (request *DescribeDTSIPRequest) { + request = &DescribeDTSIPRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeDTSIP", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeDTSIPResponse creates a response to parse from DescribeDTSIP response +func CreateDescribeDTSIPResponse() (response *DescribeDTSIPResponse) { + response = &DescribeDTSIPResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_endpoint_switch_status.go b/services/dts/describe_endpoint_switch_status.go index 4f2ec599f8..329ebea21c 100644 --- a/services/dts/describe_endpoint_switch_status.go +++ b/services/dts/describe_endpoint_switch_status.go @@ -73,6 +73,7 @@ type DescribeEndpointSwitchStatusRequest struct { *requests.RpcRequest ClientToken string `position:"Query" name:"ClientToken"` OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` TaskId string `position:"Query" name:"TaskId"` } @@ -80,8 +81,11 @@ type DescribeEndpointSwitchStatusRequest struct { type DescribeEndpointSwitchStatusResponse struct { *responses.BaseResponse Status string `json:"Status" xml:"Status"` - RequestId string `json:"RequestId" xml:"RequestId"` ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` } // CreateDescribeEndpointSwitchStatusRequest creates a request to invoke DescribeEndpointSwitchStatus API @@ -89,7 +93,7 @@ func CreateDescribeEndpointSwitchStatusRequest() (request *DescribeEndpointSwitc request = &DescribeEndpointSwitchStatusRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "DescribeEndpointSwitchStatus", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeEndpointSwitchStatus", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/describe_etl_job_logs.go b/services/dts/describe_etl_job_logs.go new file mode 100644 index 0000000000..15a5c8e0a5 --- /dev/null +++ b/services/dts/describe_etl_job_logs.go @@ -0,0 +1,106 @@ +package dts + +//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" +) + +// DescribeEtlJobLogs invokes the dts.DescribeEtlJobLogs API synchronously +func (client *Client) DescribeEtlJobLogs(request *DescribeEtlJobLogsRequest) (response *DescribeEtlJobLogsResponse, err error) { + response = CreateDescribeEtlJobLogsResponse() + err = client.DoAction(request, response) + return +} + +// DescribeEtlJobLogsWithChan invokes the dts.DescribeEtlJobLogs API asynchronously +func (client *Client) DescribeEtlJobLogsWithChan(request *DescribeEtlJobLogsRequest) (<-chan *DescribeEtlJobLogsResponse, <-chan error) { + responseChan := make(chan *DescribeEtlJobLogsResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeEtlJobLogs(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeEtlJobLogsWithCallback invokes the dts.DescribeEtlJobLogs API asynchronously +func (client *Client) DescribeEtlJobLogsWithCallback(request *DescribeEtlJobLogsRequest, callback func(response *DescribeEtlJobLogsResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeEtlJobLogsResponse + var err error + defer close(result) + response, err = client.DescribeEtlJobLogs(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeEtlJobLogsRequest is the request struct for api DescribeEtlJobLogs +type DescribeEtlJobLogsRequest struct { + *requests.RpcRequest + DtsJobId string `position:"Query" name:"DtsJobId"` +} + +// DescribeEtlJobLogsResponse is the response struct for api DescribeEtlJobLogs +type DescribeEtlJobLogsResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` + EtlRunningLogs []EtlRunningLog `json:"EtlRunningLogs" xml:"EtlRunningLogs"` +} + +// CreateDescribeEtlJobLogsRequest creates a request to invoke DescribeEtlJobLogs API +func CreateDescribeEtlJobLogsRequest() (request *DescribeEtlJobLogsRequest) { + request = &DescribeEtlJobLogsRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeEtlJobLogs", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeEtlJobLogsResponse creates a response to parse from DescribeEtlJobLogs response +func CreateDescribeEtlJobLogsResponse() (response *DescribeEtlJobLogsResponse) { + response = &DescribeEtlJobLogsResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_initialization_status.go b/services/dts/describe_initialization_status.go new file mode 100644 index 0000000000..9bb2e75d5e --- /dev/null +++ b/services/dts/describe_initialization_status.go @@ -0,0 +1,109 @@ +package dts + +//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" +) + +// DescribeInitializationStatus invokes the dts.DescribeInitializationStatus API synchronously +func (client *Client) DescribeInitializationStatus(request *DescribeInitializationStatusRequest) (response *DescribeInitializationStatusResponse, err error) { + response = CreateDescribeInitializationStatusResponse() + err = client.DoAction(request, response) + return +} + +// DescribeInitializationStatusWithChan invokes the dts.DescribeInitializationStatus API asynchronously +func (client *Client) DescribeInitializationStatusWithChan(request *DescribeInitializationStatusRequest) (<-chan *DescribeInitializationStatusResponse, <-chan error) { + responseChan := make(chan *DescribeInitializationStatusResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeInitializationStatus(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeInitializationStatusWithCallback invokes the dts.DescribeInitializationStatus API asynchronously +func (client *Client) DescribeInitializationStatusWithCallback(request *DescribeInitializationStatusRequest, callback func(response *DescribeInitializationStatusResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeInitializationStatusResponse + var err error + defer close(result) + response, err = client.DescribeInitializationStatus(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeInitializationStatusRequest is the request struct for api DescribeInitializationStatus +type DescribeInitializationStatusRequest struct { + *requests.RpcRequest + PageNum requests.Integer `position:"Query" name:"PageNum"` + OwnerId string `position:"Query" name:"OwnerId"` + SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` + AccountId string `position:"Query" name:"AccountId"` + PageSize requests.Integer `position:"Query" name:"PageSize"` +} + +// DescribeInitializationStatusResponse is the response struct for api DescribeInitializationStatus +type DescribeInitializationStatusResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DataInitializationDetails []DataInitializationDetail `json:"DataInitializationDetails" xml:"DataInitializationDetails"` + DataSynchronizationDetails []DataSynchronizationDetail `json:"DataSynchronizationDetails" xml:"DataSynchronizationDetails"` + StructureInitializationDetails []StructureInitializationDetail `json:"StructureInitializationDetails" xml:"StructureInitializationDetails"` +} + +// CreateDescribeInitializationStatusRequest creates a request to invoke DescribeInitializationStatus API +func CreateDescribeInitializationStatusRequest() (request *DescribeInitializationStatusRequest) { + request = &DescribeInitializationStatusRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeInitializationStatus", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeInitializationStatusResponse creates a response to parse from DescribeInitializationStatus response +func CreateDescribeInitializationStatusResponse() (response *DescribeInitializationStatusResponse) { + response = &DescribeInitializationStatusResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_job_monitor_rule.go b/services/dts/describe_job_monitor_rule.go new file mode 100644 index 0000000000..301e903c56 --- /dev/null +++ b/services/dts/describe_job_monitor_rule.go @@ -0,0 +1,108 @@ +package dts + +//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" +) + +// DescribeJobMonitorRule invokes the dts.DescribeJobMonitorRule API synchronously +func (client *Client) DescribeJobMonitorRule(request *DescribeJobMonitorRuleRequest) (response *DescribeJobMonitorRuleResponse, err error) { + response = CreateDescribeJobMonitorRuleResponse() + err = client.DoAction(request, response) + return +} + +// DescribeJobMonitorRuleWithChan invokes the dts.DescribeJobMonitorRule API asynchronously +func (client *Client) DescribeJobMonitorRuleWithChan(request *DescribeJobMonitorRuleRequest) (<-chan *DescribeJobMonitorRuleResponse, <-chan error) { + responseChan := make(chan *DescribeJobMonitorRuleResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeJobMonitorRule(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeJobMonitorRuleWithCallback invokes the dts.DescribeJobMonitorRule API asynchronously +func (client *Client) DescribeJobMonitorRuleWithCallback(request *DescribeJobMonitorRuleRequest, callback func(response *DescribeJobMonitorRuleResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeJobMonitorRuleResponse + var err error + defer close(result) + response, err = client.DescribeJobMonitorRule(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeJobMonitorRuleRequest is the request struct for api DescribeJobMonitorRule +type DescribeJobMonitorRuleRequest struct { + *requests.RpcRequest + DtsJobId string `position:"Query" name:"DtsJobId"` +} + +// DescribeJobMonitorRuleResponse is the response struct for api DescribeJobMonitorRule +type DescribeJobMonitorRuleResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + Code string `json:"Code" xml:"Code"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + Topics []string `json:"Topics" xml:"Topics"` + MonitorRules []MonitorRule `json:"MonitorRules" xml:"MonitorRules"` +} + +// CreateDescribeJobMonitorRuleRequest creates a request to invoke DescribeJobMonitorRule API +func CreateDescribeJobMonitorRuleRequest() (request *DescribeJobMonitorRuleRequest) { + request = &DescribeJobMonitorRuleRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeJobMonitorRule", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeJobMonitorRuleResponse creates a response to parse from DescribeJobMonitorRule response +func CreateDescribeJobMonitorRuleResponse() (response *DescribeJobMonitorRuleResponse) { + response = &DescribeJobMonitorRuleResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_metric_list.go b/services/dts/describe_metric_list.go new file mode 100644 index 0000000000..95d5dc7996 --- /dev/null +++ b/services/dts/describe_metric_list.go @@ -0,0 +1,120 @@ +package dts + +//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" +) + +// DescribeMetricList invokes the dts.DescribeMetricList API synchronously +func (client *Client) DescribeMetricList(request *DescribeMetricListRequest) (response *DescribeMetricListResponse, err error) { + response = CreateDescribeMetricListResponse() + err = client.DoAction(request, response) + return +} + +// DescribeMetricListWithChan invokes the dts.DescribeMetricList API asynchronously +func (client *Client) DescribeMetricListWithChan(request *DescribeMetricListRequest) (<-chan *DescribeMetricListResponse, <-chan error) { + responseChan := make(chan *DescribeMetricListResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeMetricList(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeMetricListWithCallback invokes the dts.DescribeMetricList API asynchronously +func (client *Client) DescribeMetricListWithCallback(request *DescribeMetricListRequest, callback func(response *DescribeMetricListResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeMetricListResponse + var err error + defer close(result) + response, err = client.DescribeMetricList(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeMetricListRequest is the request struct for api DescribeMetricList +type DescribeMetricListRequest struct { + *requests.RpcRequest + MetricType string `position:"Body" name:"MetricType"` + ClientToken string `position:"Body" name:"ClientToken"` + StartTime requests.Integer `position:"Body" name:"StartTime"` + AccountId string `position:"Body" name:"AccountId"` + Param string `position:"Body" name:"Param"` + DtsJobId string `position:"Body" name:"DtsJobId"` + MetricName string `position:"Body" name:"MetricName"` + Period requests.Integer `position:"Body" name:"Period"` + EndTime requests.Integer `position:"Body" name:"EndTime"` + Env string `position:"Body" name:"Env"` + OwnerID string `position:"Body" name:"OwnerID"` +} + +// DescribeMetricListResponse is the response struct for api DescribeMetricList +type DescribeMetricListResponse struct { + *responses.BaseResponse + MetricType string `json:"MetricType" xml:"MetricType"` + Param string `json:"Param" xml:"Param"` + MetricName string `json:"MetricName" xml:"MetricName"` + Period int64 `json:"Period" xml:"Period"` + Success bool `json:"Success" xml:"Success"` + Code string `json:"Code" xml:"Code"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + DataPoints []DataPoint `json:"DataPoints" xml:"DataPoints"` +} + +// CreateDescribeMetricListRequest creates a request to invoke DescribeMetricList API +func CreateDescribeMetricListRequest() (request *DescribeMetricListRequest) { + request = &DescribeMetricListRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeMetricList", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeMetricListResponse creates a response to parse from DescribeMetricList response +func CreateDescribeMetricListResponse() (response *DescribeMetricListResponse) { + response = &DescribeMetricListResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_migration_job_alert.go b/services/dts/describe_migration_job_alert.go new file mode 100644 index 0000000000..693bddd1a8 --- /dev/null +++ b/services/dts/describe_migration_job_alert.go @@ -0,0 +1,112 @@ +package dts + +//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" +) + +// DescribeMigrationJobAlert invokes the dts.DescribeMigrationJobAlert API synchronously +func (client *Client) DescribeMigrationJobAlert(request *DescribeMigrationJobAlertRequest) (response *DescribeMigrationJobAlertResponse, err error) { + response = CreateDescribeMigrationJobAlertResponse() + err = client.DoAction(request, response) + return +} + +// DescribeMigrationJobAlertWithChan invokes the dts.DescribeMigrationJobAlert API asynchronously +func (client *Client) DescribeMigrationJobAlertWithChan(request *DescribeMigrationJobAlertRequest) (<-chan *DescribeMigrationJobAlertResponse, <-chan error) { + responseChan := make(chan *DescribeMigrationJobAlertResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeMigrationJobAlert(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeMigrationJobAlertWithCallback invokes the dts.DescribeMigrationJobAlert API asynchronously +func (client *Client) DescribeMigrationJobAlertWithCallback(request *DescribeMigrationJobAlertRequest, callback func(response *DescribeMigrationJobAlertResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeMigrationJobAlertResponse + var err error + defer close(result) + response, err = client.DescribeMigrationJobAlert(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeMigrationJobAlertRequest is the request struct for api DescribeMigrationJobAlert +type DescribeMigrationJobAlertRequest struct { + *requests.RpcRequest + ClientToken string `position:"Query" name:"ClientToken"` + MigrationJobId string `position:"Query" name:"MigrationJobId"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` +} + +// DescribeMigrationJobAlertResponse is the response struct for api DescribeMigrationJobAlert +type DescribeMigrationJobAlertResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + MigrationJobName string `json:"MigrationJobName" xml:"MigrationJobName"` + ErrorAlertStatus string `json:"ErrorAlertStatus" xml:"ErrorAlertStatus"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrorAlertPhone string `json:"ErrorAlertPhone" xml:"ErrorAlertPhone"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DelayAlertStatus string `json:"DelayAlertStatus" xml:"DelayAlertStatus"` + DelayAlertPhone string `json:"DelayAlertPhone" xml:"DelayAlertPhone"` + MigrationJobId string `json:"MigrationJobId" xml:"MigrationJobId"` + DelayOverSeconds string `json:"DelayOverSeconds" xml:"DelayOverSeconds"` +} + +// CreateDescribeMigrationJobAlertRequest creates a request to invoke DescribeMigrationJobAlert API +func CreateDescribeMigrationJobAlertRequest() (request *DescribeMigrationJobAlertRequest) { + request = &DescribeMigrationJobAlertRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeMigrationJobAlert", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeMigrationJobAlertResponse creates a response to parse from DescribeMigrationJobAlert response +func CreateDescribeMigrationJobAlertResponse() (response *DescribeMigrationJobAlertResponse) { + response = &DescribeMigrationJobAlertResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_migration_job_detail.go b/services/dts/describe_migration_job_detail.go new file mode 100644 index 0000000000..d06ee638c4 --- /dev/null +++ b/services/dts/describe_migration_job_detail.go @@ -0,0 +1,116 @@ +package dts + +//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" +) + +// DescribeMigrationJobDetail invokes the dts.DescribeMigrationJobDetail API synchronously +func (client *Client) DescribeMigrationJobDetail(request *DescribeMigrationJobDetailRequest) (response *DescribeMigrationJobDetailResponse, err error) { + response = CreateDescribeMigrationJobDetailResponse() + err = client.DoAction(request, response) + return +} + +// DescribeMigrationJobDetailWithChan invokes the dts.DescribeMigrationJobDetail API asynchronously +func (client *Client) DescribeMigrationJobDetailWithChan(request *DescribeMigrationJobDetailRequest) (<-chan *DescribeMigrationJobDetailResponse, <-chan error) { + responseChan := make(chan *DescribeMigrationJobDetailResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeMigrationJobDetail(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeMigrationJobDetailWithCallback invokes the dts.DescribeMigrationJobDetail API asynchronously +func (client *Client) DescribeMigrationJobDetailWithCallback(request *DescribeMigrationJobDetailRequest, callback func(response *DescribeMigrationJobDetailResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeMigrationJobDetailResponse + var err error + defer close(result) + response, err = client.DescribeMigrationJobDetail(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeMigrationJobDetailRequest is the request struct for api DescribeMigrationJobDetail +type DescribeMigrationJobDetailRequest struct { + *requests.RpcRequest + ClientToken string `position:"Query" name:"ClientToken"` + MigrationModeDataInitialization requests.Boolean `position:"Query" name:"MigrationMode.DataInitialization"` + MigrationJobId string `position:"Query" name:"MigrationJobId"` + PageNum requests.Integer `position:"Query" name:"PageNum"` + AccountId string `position:"Query" name:"AccountId"` + MigrationModeDataSynchronization requests.Boolean `position:"Query" name:"MigrationMode.DataSynchronization"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + OwnerId string `position:"Query" name:"OwnerId"` + MigrationModeStructureInitialization requests.Boolean `position:"Query" name:"MigrationMode.StructureInitialization"` +} + +// DescribeMigrationJobDetailResponse is the response struct for api DescribeMigrationJobDetail +type DescribeMigrationJobDetailResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + PageRecordCount int `json:"PageRecordCount" xml:"PageRecordCount"` + Success string `json:"Success" xml:"Success"` + TotalRecordCount int64 `json:"TotalRecordCount" xml:"TotalRecordCount"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + DataInitializationDetailList DataInitializationDetailList `json:"DataInitializationDetailList" xml:"DataInitializationDetailList"` + DataSynchronizationDetailList DataSynchronizationDetailList `json:"DataSynchronizationDetailList" xml:"DataSynchronizationDetailList"` + StructureInitializationDetailList StructureInitializationDetailList `json:"StructureInitializationDetailList" xml:"StructureInitializationDetailList"` +} + +// CreateDescribeMigrationJobDetailRequest creates a request to invoke DescribeMigrationJobDetail API +func CreateDescribeMigrationJobDetailRequest() (request *DescribeMigrationJobDetailRequest) { + request = &DescribeMigrationJobDetailRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeMigrationJobDetail", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeMigrationJobDetailResponse creates a response to parse from DescribeMigrationJobDetail response +func CreateDescribeMigrationJobDetailResponse() (response *DescribeMigrationJobDetailResponse) { + response = &DescribeMigrationJobDetailResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_migration_job_status.go b/services/dts/describe_migration_job_status.go new file mode 100644 index 0000000000..6f0f190e55 --- /dev/null +++ b/services/dts/describe_migration_job_status.go @@ -0,0 +1,119 @@ +package dts + +//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" +) + +// DescribeMigrationJobStatus invokes the dts.DescribeMigrationJobStatus API synchronously +func (client *Client) DescribeMigrationJobStatus(request *DescribeMigrationJobStatusRequest) (response *DescribeMigrationJobStatusResponse, err error) { + response = CreateDescribeMigrationJobStatusResponse() + err = client.DoAction(request, response) + return +} + +// DescribeMigrationJobStatusWithChan invokes the dts.DescribeMigrationJobStatus API asynchronously +func (client *Client) DescribeMigrationJobStatusWithChan(request *DescribeMigrationJobStatusRequest) (<-chan *DescribeMigrationJobStatusResponse, <-chan error) { + responseChan := make(chan *DescribeMigrationJobStatusResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeMigrationJobStatus(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeMigrationJobStatusWithCallback invokes the dts.DescribeMigrationJobStatus API asynchronously +func (client *Client) DescribeMigrationJobStatusWithCallback(request *DescribeMigrationJobStatusRequest, callback func(response *DescribeMigrationJobStatusResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeMigrationJobStatusResponse + var err error + defer close(result) + response, err = client.DescribeMigrationJobStatus(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeMigrationJobStatusRequest is the request struct for api DescribeMigrationJobStatus +type DescribeMigrationJobStatusRequest struct { + *requests.RpcRequest + ClientToken string `position:"Query" name:"ClientToken"` + MigrationJobId string `position:"Query" name:"MigrationJobId"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` +} + +// DescribeMigrationJobStatusResponse is the response struct for api DescribeMigrationJobStatus +type DescribeMigrationJobStatusResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + MigrationJobName string `json:"MigrationJobName" xml:"MigrationJobName"` + MigrationJobStatus string `json:"MigrationJobStatus" xml:"MigrationJobStatus"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + PayType string `json:"PayType" xml:"PayType"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + MigrationObject string `json:"MigrationObject" xml:"MigrationObject"` + MigrationJobId string `json:"MigrationJobId" xml:"MigrationJobId"` + TaskId string `json:"TaskId" xml:"TaskId"` + MigrationJobClass string `json:"MigrationJobClass" xml:"MigrationJobClass"` + DataInitializationStatus DataInitializationStatus `json:"DataInitializationStatus" xml:"DataInitializationStatus"` + DataSynchronizationStatus DataSynchronizationStatus `json:"DataSynchronizationStatus" xml:"DataSynchronizationStatus"` + DestinationEndpoint DestinationEndpoint `json:"DestinationEndpoint" xml:"DestinationEndpoint"` + MigrationMode MigrationMode `json:"MigrationMode" xml:"MigrationMode"` + PrecheckStatus PrecheckStatusInDescribeMigrationJobStatus `json:"PrecheckStatus" xml:"PrecheckStatus"` + SourceEndpoint SourceEndpoint `json:"SourceEndpoint" xml:"SourceEndpoint"` + StructureInitializationStatus StructureInitializationStatus `json:"StructureInitializationStatus" xml:"StructureInitializationStatus"` +} + +// CreateDescribeMigrationJobStatusRequest creates a request to invoke DescribeMigrationJobStatus API +func CreateDescribeMigrationJobStatusRequest() (request *DescribeMigrationJobStatusRequest) { + request = &DescribeMigrationJobStatusRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeMigrationJobStatus", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeMigrationJobStatusResponse creates a response to parse from DescribeMigrationJobStatus response +func CreateDescribeMigrationJobStatusResponse() (response *DescribeMigrationJobStatusResponse) { + response = &DescribeMigrationJobStatusResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_migration_jobs.go b/services/dts/describe_migration_jobs.go new file mode 100644 index 0000000000..ec2f0c9f7c --- /dev/null +++ b/services/dts/describe_migration_jobs.go @@ -0,0 +1,118 @@ +package dts + +//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" +) + +// DescribeMigrationJobs invokes the dts.DescribeMigrationJobs API synchronously +func (client *Client) DescribeMigrationJobs(request *DescribeMigrationJobsRequest) (response *DescribeMigrationJobsResponse, err error) { + response = CreateDescribeMigrationJobsResponse() + err = client.DoAction(request, response) + return +} + +// DescribeMigrationJobsWithChan invokes the dts.DescribeMigrationJobs API asynchronously +func (client *Client) DescribeMigrationJobsWithChan(request *DescribeMigrationJobsRequest) (<-chan *DescribeMigrationJobsResponse, <-chan error) { + responseChan := make(chan *DescribeMigrationJobsResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeMigrationJobs(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeMigrationJobsWithCallback invokes the dts.DescribeMigrationJobs API asynchronously +func (client *Client) DescribeMigrationJobsWithCallback(request *DescribeMigrationJobsRequest, callback func(response *DescribeMigrationJobsResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeMigrationJobsResponse + var err error + defer close(result) + response, err = client.DescribeMigrationJobs(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeMigrationJobsRequest is the request struct for api DescribeMigrationJobs +type DescribeMigrationJobsRequest struct { + *requests.RpcRequest + InstFilterRegion string `position:"Query" name:"InstFilterRegion"` + PageNum requests.Integer `position:"Query" name:"PageNum"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + MigrationJobName string `position:"Query" name:"MigrationJobName"` + Tag *[]DescribeMigrationJobsTag `position:"Query" name:"Tag" type:"Repeated"` +} + +// DescribeMigrationJobsTag is a repeated param struct in DescribeMigrationJobsRequest +type DescribeMigrationJobsTag struct { + Value string `name:"Value"` + Key string `name:"Key"` +} + +// DescribeMigrationJobsResponse is the response struct for api DescribeMigrationJobs +type DescribeMigrationJobsResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + PageRecordCount int `json:"PageRecordCount" xml:"PageRecordCount"` + Success string `json:"Success" xml:"Success"` + TotalRecordCount int64 `json:"TotalRecordCount" xml:"TotalRecordCount"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + MigrationJobs MigrationJobs `json:"MigrationJobs" xml:"MigrationJobs"` +} + +// CreateDescribeMigrationJobsRequest creates a request to invoke DescribeMigrationJobs API +func CreateDescribeMigrationJobsRequest() (request *DescribeMigrationJobsRequest) { + request = &DescribeMigrationJobsRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeMigrationJobs", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeMigrationJobsResponse creates a response to parse from DescribeMigrationJobs response +func CreateDescribeMigrationJobsResponse() (response *DescribeMigrationJobsResponse) { + response = &DescribeMigrationJobsResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_pre_check_status.go b/services/dts/describe_pre_check_status.go new file mode 100644 index 0000000000..a74a189e34 --- /dev/null +++ b/services/dts/describe_pre_check_status.go @@ -0,0 +1,121 @@ +package dts + +//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" +) + +// DescribePreCheckStatus invokes the dts.DescribePreCheckStatus API synchronously +func (client *Client) DescribePreCheckStatus(request *DescribePreCheckStatusRequest) (response *DescribePreCheckStatusResponse, err error) { + response = CreateDescribePreCheckStatusResponse() + err = client.DoAction(request, response) + return +} + +// DescribePreCheckStatusWithChan invokes the dts.DescribePreCheckStatus API asynchronously +func (client *Client) DescribePreCheckStatusWithChan(request *DescribePreCheckStatusRequest) (<-chan *DescribePreCheckStatusResponse, <-chan error) { + responseChan := make(chan *DescribePreCheckStatusResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribePreCheckStatus(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribePreCheckStatusWithCallback invokes the dts.DescribePreCheckStatus API asynchronously +func (client *Client) DescribePreCheckStatusWithCallback(request *DescribePreCheckStatusRequest, callback func(response *DescribePreCheckStatusResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribePreCheckStatusResponse + var err error + defer close(result) + response, err = client.DescribePreCheckStatus(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribePreCheckStatusRequest is the request struct for api DescribePreCheckStatus +type DescribePreCheckStatusRequest struct { + *requests.RpcRequest + StructType string `position:"Query" name:"StructType"` + PageSize string `position:"Query" name:"PageSize"` + DtsJobId string `position:"Query" name:"DtsJobId"` + PageNo string `position:"Query" name:"PageNo"` + JobCode string `position:"Query" name:"JobCode"` + Name string `position:"Query" name:"Name"` + StructPhase string `position:"Query" name:"StructPhase"` +} + +// DescribePreCheckStatusResponse is the response struct for api DescribePreCheckStatus +type DescribePreCheckStatusResponse struct { + *responses.BaseResponse + State string `json:"State" xml:"State"` + Success bool `json:"Success" xml:"Success"` + PageRecordCount int64 `json:"PageRecordCount" xml:"PageRecordCount"` + Total int `json:"Total" xml:"Total"` + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + JobName string `json:"JobName" xml:"JobName"` + JobId string `json:"JobId" xml:"JobId"` + ErrorItem int `json:"ErrorItem" xml:"ErrorItem"` + ErrorAnalysisItem int `json:"ErrorAnalysisItem" xml:"ErrorAnalysisItem"` + TotalRecordCount int64 `json:"TotalRecordCount" xml:"TotalRecordCount"` + Code string `json:"Code" xml:"Code"` + PageNumber int64 `json:"PageNumber" xml:"PageNumber"` + JobProgress []ProgressInfo `json:"JobProgress" xml:"JobProgress"` + AnalysisJobProgress []AnalysisProgressInfo `json:"AnalysisJobProgress" xml:"AnalysisJobProgress"` + SubDistributedJobStatus []SubDistributedJobStatusItem `json:"SubDistributedJobStatus" xml:"SubDistributedJobStatus"` + FullNetCheckJobStatus []FullNetCheckJobStatusItem `json:"FullNetCheckJobStatus" xml:"FullNetCheckJobStatus"` +} + +// CreateDescribePreCheckStatusRequest creates a request to invoke DescribePreCheckStatus API +func CreateDescribePreCheckStatusRequest() (request *DescribePreCheckStatusRequest) { + request = &DescribePreCheckStatusRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribePreCheckStatus", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribePreCheckStatusResponse creates a response to parse from DescribePreCheckStatus response +func CreateDescribePreCheckStatusResponse() (response *DescribePreCheckStatusResponse) { + response = &DescribePreCheckStatusResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_subscription_instance_alert.go b/services/dts/describe_subscription_instance_alert.go new file mode 100644 index 0000000000..ac3625c0f6 --- /dev/null +++ b/services/dts/describe_subscription_instance_alert.go @@ -0,0 +1,112 @@ +package dts + +//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" +) + +// DescribeSubscriptionInstanceAlert invokes the dts.DescribeSubscriptionInstanceAlert API synchronously +func (client *Client) DescribeSubscriptionInstanceAlert(request *DescribeSubscriptionInstanceAlertRequest) (response *DescribeSubscriptionInstanceAlertResponse, err error) { + response = CreateDescribeSubscriptionInstanceAlertResponse() + err = client.DoAction(request, response) + return +} + +// DescribeSubscriptionInstanceAlertWithChan invokes the dts.DescribeSubscriptionInstanceAlert API asynchronously +func (client *Client) DescribeSubscriptionInstanceAlertWithChan(request *DescribeSubscriptionInstanceAlertRequest) (<-chan *DescribeSubscriptionInstanceAlertResponse, <-chan error) { + responseChan := make(chan *DescribeSubscriptionInstanceAlertResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeSubscriptionInstanceAlert(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeSubscriptionInstanceAlertWithCallback invokes the dts.DescribeSubscriptionInstanceAlert API asynchronously +func (client *Client) DescribeSubscriptionInstanceAlertWithCallback(request *DescribeSubscriptionInstanceAlertRequest, callback func(response *DescribeSubscriptionInstanceAlertResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeSubscriptionInstanceAlertResponse + var err error + defer close(result) + response, err = client.DescribeSubscriptionInstanceAlert(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeSubscriptionInstanceAlertRequest is the request struct for api DescribeSubscriptionInstanceAlert +type DescribeSubscriptionInstanceAlertRequest struct { + *requests.RpcRequest + ClientToken string `position:"Query" name:"ClientToken"` + SubscriptionInstanceId string `position:"Query" name:"SubscriptionInstanceId"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` +} + +// DescribeSubscriptionInstanceAlertResponse is the response struct for api DescribeSubscriptionInstanceAlert +type DescribeSubscriptionInstanceAlertResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrorAlertStatus string `json:"ErrorAlertStatus" xml:"ErrorAlertStatus"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrorAlertPhone string `json:"ErrorAlertPhone" xml:"ErrorAlertPhone"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DelayAlertStatus string `json:"DelayAlertStatus" xml:"DelayAlertStatus"` + SubscriptionInstanceName string `json:"SubscriptionInstanceName" xml:"SubscriptionInstanceName"` + DelayAlertPhone string `json:"DelayAlertPhone" xml:"DelayAlertPhone"` + SubscriptionInstanceID string `json:"SubscriptionInstanceID" xml:"SubscriptionInstanceID"` + DelayOverSeconds string `json:"DelayOverSeconds" xml:"DelayOverSeconds"` +} + +// CreateDescribeSubscriptionInstanceAlertRequest creates a request to invoke DescribeSubscriptionInstanceAlert API +func CreateDescribeSubscriptionInstanceAlertRequest() (request *DescribeSubscriptionInstanceAlertRequest) { + request = &DescribeSubscriptionInstanceAlertRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeSubscriptionInstanceAlert", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeSubscriptionInstanceAlertResponse creates a response to parse from DescribeSubscriptionInstanceAlert response +func CreateDescribeSubscriptionInstanceAlertResponse() (response *DescribeSubscriptionInstanceAlertResponse) { + response = &DescribeSubscriptionInstanceAlertResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_subscription_instance_status.go b/services/dts/describe_subscription_instance_status.go new file mode 100644 index 0000000000..3dcfc63771 --- /dev/null +++ b/services/dts/describe_subscription_instance_status.go @@ -0,0 +1,119 @@ +package dts + +//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" +) + +// DescribeSubscriptionInstanceStatus invokes the dts.DescribeSubscriptionInstanceStatus API synchronously +func (client *Client) DescribeSubscriptionInstanceStatus(request *DescribeSubscriptionInstanceStatusRequest) (response *DescribeSubscriptionInstanceStatusResponse, err error) { + response = CreateDescribeSubscriptionInstanceStatusResponse() + err = client.DoAction(request, response) + return +} + +// DescribeSubscriptionInstanceStatusWithChan invokes the dts.DescribeSubscriptionInstanceStatus API asynchronously +func (client *Client) DescribeSubscriptionInstanceStatusWithChan(request *DescribeSubscriptionInstanceStatusRequest) (<-chan *DescribeSubscriptionInstanceStatusResponse, <-chan error) { + responseChan := make(chan *DescribeSubscriptionInstanceStatusResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeSubscriptionInstanceStatus(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeSubscriptionInstanceStatusWithCallback invokes the dts.DescribeSubscriptionInstanceStatus API asynchronously +func (client *Client) DescribeSubscriptionInstanceStatusWithCallback(request *DescribeSubscriptionInstanceStatusRequest, callback func(response *DescribeSubscriptionInstanceStatusResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeSubscriptionInstanceStatusResponse + var err error + defer close(result) + response, err = client.DescribeSubscriptionInstanceStatus(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeSubscriptionInstanceStatusRequest is the request struct for api DescribeSubscriptionInstanceStatus +type DescribeSubscriptionInstanceStatusRequest struct { + *requests.RpcRequest + SubscriptionInstanceId string `position:"Query" name:"SubscriptionInstanceId"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` +} + +// DescribeSubscriptionInstanceStatusResponse is the response struct for api DescribeSubscriptionInstanceStatus +type DescribeSubscriptionInstanceStatusResponse struct { + *responses.BaseResponse + Status string `json:"Status" xml:"Status"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + PayType string `json:"PayType" xml:"PayType"` + ConsumptionClient string `json:"ConsumptionClient" xml:"ConsumptionClient"` + ConsumptionCheckpoint string `json:"ConsumptionCheckpoint" xml:"ConsumptionCheckpoint"` + EndTimestamp string `json:"EndTimestamp" xml:"EndTimestamp"` + BeginTimestamp string `json:"BeginTimestamp" xml:"BeginTimestamp"` + RequestId string `json:"RequestId" xml:"RequestId"` + SubscribeTopic string `json:"SubscribeTopic" xml:"SubscribeTopic"` + SubscriptionInstanceName string `json:"SubscriptionInstanceName" xml:"SubscriptionInstanceName"` + SubscriptionInstanceID string `json:"SubscriptionInstanceID" xml:"SubscriptionInstanceID"` + TaskId string `json:"TaskId" xml:"TaskId"` + SourceEndpoint SourceEndpoint `json:"SourceEndpoint" xml:"SourceEndpoint"` + SubscriptionDataType SubscriptionDataType `json:"SubscriptionDataType" xml:"SubscriptionDataType"` + SubscriptionHost SubscriptionHost `json:"SubscriptionHost" xml:"SubscriptionHost"` + SubscriptionObject SubscriptionObjectInDescribeSubscriptionInstanceStatus `json:"SubscriptionObject" xml:"SubscriptionObject"` +} + +// CreateDescribeSubscriptionInstanceStatusRequest creates a request to invoke DescribeSubscriptionInstanceStatus API +func CreateDescribeSubscriptionInstanceStatusRequest() (request *DescribeSubscriptionInstanceStatusRequest) { + request = &DescribeSubscriptionInstanceStatusRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeSubscriptionInstanceStatus", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeSubscriptionInstanceStatusResponse creates a response to parse from DescribeSubscriptionInstanceStatus response +func CreateDescribeSubscriptionInstanceStatusResponse() (response *DescribeSubscriptionInstanceStatusResponse) { + response = &DescribeSubscriptionInstanceStatusResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_subscription_instances.go b/services/dts/describe_subscription_instances.go new file mode 100644 index 0000000000..bd1eeb37fb --- /dev/null +++ b/services/dts/describe_subscription_instances.go @@ -0,0 +1,119 @@ +package dts + +//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" +) + +// DescribeSubscriptionInstances invokes the dts.DescribeSubscriptionInstances API synchronously +func (client *Client) DescribeSubscriptionInstances(request *DescribeSubscriptionInstancesRequest) (response *DescribeSubscriptionInstancesResponse, err error) { + response = CreateDescribeSubscriptionInstancesResponse() + err = client.DoAction(request, response) + return +} + +// DescribeSubscriptionInstancesWithChan invokes the dts.DescribeSubscriptionInstances API asynchronously +func (client *Client) DescribeSubscriptionInstancesWithChan(request *DescribeSubscriptionInstancesRequest) (<-chan *DescribeSubscriptionInstancesResponse, <-chan error) { + responseChan := make(chan *DescribeSubscriptionInstancesResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeSubscriptionInstances(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeSubscriptionInstancesWithCallback invokes the dts.DescribeSubscriptionInstances API asynchronously +func (client *Client) DescribeSubscriptionInstancesWithCallback(request *DescribeSubscriptionInstancesRequest, callback func(response *DescribeSubscriptionInstancesResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeSubscriptionInstancesResponse + var err error + defer close(result) + response, err = client.DescribeSubscriptionInstances(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeSubscriptionInstancesRequest is the request struct for api DescribeSubscriptionInstances +type DescribeSubscriptionInstancesRequest struct { + *requests.RpcRequest + ClientToken string `position:"Query" name:"ClientToken"` + PageNum requests.Integer `position:"Query" name:"PageNum"` + AccountId string `position:"Query" name:"AccountId"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + Tag *[]DescribeSubscriptionInstancesTag `position:"Query" name:"Tag" type:"Repeated"` + InstFilterRegion string `position:"Query" name:"InstFilterRegion"` + OwnerId string `position:"Query" name:"OwnerId"` + SubscriptionInstanceName string `position:"Query" name:"SubscriptionInstanceName"` +} + +// DescribeSubscriptionInstancesTag is a repeated param struct in DescribeSubscriptionInstancesRequest +type DescribeSubscriptionInstancesTag struct { + Value string `name:"Value"` + Key string `name:"Key"` +} + +// DescribeSubscriptionInstancesResponse is the response struct for api DescribeSubscriptionInstances +type DescribeSubscriptionInstancesResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + PageRecordCount int `json:"PageRecordCount" xml:"PageRecordCount"` + Success string `json:"Success" xml:"Success"` + TotalRecordCount int64 `json:"TotalRecordCount" xml:"TotalRecordCount"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + SubscriptionInstances SubscriptionInstances `json:"SubscriptionInstances" xml:"SubscriptionInstances"` +} + +// CreateDescribeSubscriptionInstancesRequest creates a request to invoke DescribeSubscriptionInstances API +func CreateDescribeSubscriptionInstancesRequest() (request *DescribeSubscriptionInstancesRequest) { + request = &DescribeSubscriptionInstancesRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeSubscriptionInstances", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeSubscriptionInstancesResponse creates a response to parse from DescribeSubscriptionInstances response +func CreateDescribeSubscriptionInstancesResponse() (response *DescribeSubscriptionInstancesResponse) { + response = &DescribeSubscriptionInstancesResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_subscription_meta.go b/services/dts/describe_subscription_meta.go new file mode 100644 index 0000000000..2158dd28b4 --- /dev/null +++ b/services/dts/describe_subscription_meta.go @@ -0,0 +1,107 @@ +package dts + +//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" +) + +// DescribeSubscriptionMeta invokes the dts.DescribeSubscriptionMeta API synchronously +func (client *Client) DescribeSubscriptionMeta(request *DescribeSubscriptionMetaRequest) (response *DescribeSubscriptionMetaResponse, err error) { + response = CreateDescribeSubscriptionMetaResponse() + err = client.DoAction(request, response) + return +} + +// DescribeSubscriptionMetaWithChan invokes the dts.DescribeSubscriptionMeta API asynchronously +func (client *Client) DescribeSubscriptionMetaWithChan(request *DescribeSubscriptionMetaRequest) (<-chan *DescribeSubscriptionMetaResponse, <-chan error) { + responseChan := make(chan *DescribeSubscriptionMetaResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeSubscriptionMeta(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeSubscriptionMetaWithCallback invokes the dts.DescribeSubscriptionMeta API asynchronously +func (client *Client) DescribeSubscriptionMetaWithCallback(request *DescribeSubscriptionMetaRequest, callback func(response *DescribeSubscriptionMetaResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeSubscriptionMetaResponse + var err error + defer close(result) + response, err = client.DescribeSubscriptionMeta(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeSubscriptionMetaRequest is the request struct for api DescribeSubscriptionMeta +type DescribeSubscriptionMetaRequest struct { + *requests.RpcRequest + Sid string `position:"Query" name:"Sid"` + SubMigrationJobIds string `position:"Query" name:"SubMigrationJobIds"` + Topics string `position:"Query" name:"Topics"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` +} + +// DescribeSubscriptionMetaResponse is the response struct for api DescribeSubscriptionMeta +type DescribeSubscriptionMetaResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + SubscriptionMetaList []SubscriptionMetaListItem `json:"SubscriptionMetaList" xml:"SubscriptionMetaList"` +} + +// CreateDescribeSubscriptionMetaRequest creates a request to invoke DescribeSubscriptionMeta API +func CreateDescribeSubscriptionMetaRequest() (request *DescribeSubscriptionMetaRequest) { + request = &DescribeSubscriptionMetaRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeSubscriptionMeta", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeSubscriptionMetaResponse creates a response to parse from DescribeSubscriptionMeta response +func CreateDescribeSubscriptionMetaResponse() (response *DescribeSubscriptionMetaResponse) { + response = &DescribeSubscriptionMetaResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_synchronization_job_alert.go b/services/dts/describe_synchronization_job_alert.go index 8ce9a7cfb9..540e1dd9a9 100644 --- a/services/dts/describe_synchronization_job_alert.go +++ b/services/dts/describe_synchronization_job_alert.go @@ -74,6 +74,7 @@ type DescribeSynchronizationJobAlertRequest struct { ClientToken string `position:"Query" name:"ClientToken"` OwnerId string `position:"Query" name:"OwnerId"` SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` + AccountId string `position:"Query" name:"AccountId"` SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` } @@ -99,7 +100,7 @@ func CreateDescribeSynchronizationJobAlertRequest() (request *DescribeSynchroniz request = &DescribeSynchronizationJobAlertRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "DescribeSynchronizationJobAlert", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeSynchronizationJobAlert", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/describe_synchronization_job_replicator_compare.go b/services/dts/describe_synchronization_job_replicator_compare.go new file mode 100644 index 0000000000..d6a0c8de33 --- /dev/null +++ b/services/dts/describe_synchronization_job_replicator_compare.go @@ -0,0 +1,107 @@ +package dts + +//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" +) + +// DescribeSynchronizationJobReplicatorCompare invokes the dts.DescribeSynchronizationJobReplicatorCompare API synchronously +func (client *Client) DescribeSynchronizationJobReplicatorCompare(request *DescribeSynchronizationJobReplicatorCompareRequest) (response *DescribeSynchronizationJobReplicatorCompareResponse, err error) { + response = CreateDescribeSynchronizationJobReplicatorCompareResponse() + err = client.DoAction(request, response) + return +} + +// DescribeSynchronizationJobReplicatorCompareWithChan invokes the dts.DescribeSynchronizationJobReplicatorCompare API asynchronously +func (client *Client) DescribeSynchronizationJobReplicatorCompareWithChan(request *DescribeSynchronizationJobReplicatorCompareRequest) (<-chan *DescribeSynchronizationJobReplicatorCompareResponse, <-chan error) { + responseChan := make(chan *DescribeSynchronizationJobReplicatorCompareResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeSynchronizationJobReplicatorCompare(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeSynchronizationJobReplicatorCompareWithCallback invokes the dts.DescribeSynchronizationJobReplicatorCompare API asynchronously +func (client *Client) DescribeSynchronizationJobReplicatorCompareWithCallback(request *DescribeSynchronizationJobReplicatorCompareRequest, callback func(response *DescribeSynchronizationJobReplicatorCompareResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeSynchronizationJobReplicatorCompareResponse + var err error + defer close(result) + response, err = client.DescribeSynchronizationJobReplicatorCompare(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeSynchronizationJobReplicatorCompareRequest is the request struct for api DescribeSynchronizationJobReplicatorCompare +type DescribeSynchronizationJobReplicatorCompareRequest struct { + *requests.RpcRequest + ClientToken string `position:"Query" name:"ClientToken"` + OwnerId string `position:"Query" name:"OwnerId"` + SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` + AccountId string `position:"Query" name:"AccountId"` + SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` +} + +// DescribeSynchronizationJobReplicatorCompareResponse is the response struct for api DescribeSynchronizationJobReplicatorCompare +type DescribeSynchronizationJobReplicatorCompareResponse struct { + *responses.BaseResponse + SynchronizationReplicatorCompareEnable bool `json:"SynchronizationReplicatorCompareEnable" xml:"SynchronizationReplicatorCompareEnable"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateDescribeSynchronizationJobReplicatorCompareRequest creates a request to invoke DescribeSynchronizationJobReplicatorCompare API +func CreateDescribeSynchronizationJobReplicatorCompareRequest() (request *DescribeSynchronizationJobReplicatorCompareRequest) { + request = &DescribeSynchronizationJobReplicatorCompareRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeSynchronizationJobReplicatorCompare", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeSynchronizationJobReplicatorCompareResponse creates a response to parse from DescribeSynchronizationJobReplicatorCompare response +func CreateDescribeSynchronizationJobReplicatorCompareResponse() (response *DescribeSynchronizationJobReplicatorCompareResponse) { + response = &DescribeSynchronizationJobReplicatorCompareResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_synchronization_job_status.go b/services/dts/describe_synchronization_job_status.go index 97cb23caf1..bdeab13512 100644 --- a/services/dts/describe_synchronization_job_status.go +++ b/services/dts/describe_synchronization_job_status.go @@ -72,35 +72,41 @@ func (client *Client) DescribeSynchronizationJobStatusWithCallback(request *Desc type DescribeSynchronizationJobStatusRequest struct { *requests.RpcRequest ClientToken string `position:"Query" name:"ClientToken"` - OwnerId string `position:"Query" name:"OwnerId"` SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` + AccountId string `position:"Query" name:"AccountId"` + OwnerId string `position:"Query" name:"OwnerId"` SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` } // DescribeSynchronizationJobStatusResponse is the response struct for api DescribeSynchronizationJobStatus type DescribeSynchronizationJobStatusResponse struct { *responses.BaseResponse - SynchronizationJobName string `json:"SynchronizationJobName" xml:"SynchronizationJobName"` - DataInitialization string `json:"DataInitialization" xml:"DataInitialization"` - Status string `json:"Status" xml:"Status"` - Delay string `json:"Delay" xml:"Delay"` - ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` - ExpireTime string `json:"ExpireTime" xml:"ExpireTime"` - PayType string `json:"PayType" xml:"PayType"` - StructureInitialization string `json:"StructureInitialization" xml:"StructureInitialization"` - SynchronizationJobClass string `json:"SynchronizationJobClass" xml:"SynchronizationJobClass"` - RequestId string `json:"RequestId" xml:"RequestId"` - SynchronizationJobId string `json:"SynchronizationJobId" xml:"SynchronizationJobId"` - SynchronizationDirection string `json:"SynchronizationDirection" xml:"SynchronizationDirection"` - Checkpoint string `json:"Checkpoint" xml:"Checkpoint"` - SourceEndpoint SourceEndpoint `json:"SourceEndpoint" xml:"SourceEndpoint"` - DestinationEndpoint DestinationEndpoint `json:"DestinationEndpoint" xml:"DestinationEndpoint"` - PrecheckStatus PrecheckStatus `json:"PrecheckStatus" xml:"PrecheckStatus"` - StructureInitializationStatus StructureInitializationStatus `json:"StructureInitializationStatus" xml:"StructureInitializationStatus"` - DataInitializationStatus DataInitializationStatus `json:"DataInitializationStatus" xml:"DataInitializationStatus"` - DataSynchronizationStatus DataSynchronizationStatus `json:"DataSynchronizationStatus" xml:"DataSynchronizationStatus"` - Performance Performance `json:"Performance" xml:"Performance"` - SynchronizationObjects []SynchronizationObject `json:"SynchronizationObjects" xml:"SynchronizationObjects"` + SynchronizationJobName string `json:"SynchronizationJobName" xml:"SynchronizationJobName"` + Status string `json:"Status" xml:"Status"` + DataInitialization string `json:"DataInitialization" xml:"DataInitialization"` + Delay string `json:"Delay" xml:"Delay"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + ExpireTime string `json:"ExpireTime" xml:"ExpireTime"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + StructureInitialization string `json:"StructureInitialization" xml:"StructureInitialization"` + PayType string `json:"PayType" xml:"PayType"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + SynchronizationJobClass string `json:"SynchronizationJobClass" xml:"SynchronizationJobClass"` + RequestId string `json:"RequestId" xml:"RequestId"` + SynchronizationJobId string `json:"SynchronizationJobId" xml:"SynchronizationJobId"` + DelayMillis int64 `json:"DelayMillis" xml:"DelayMillis"` + SynchronizationDirection string `json:"SynchronizationDirection" xml:"SynchronizationDirection"` + TaskId string `json:"TaskId" xml:"TaskId"` + Checkpoint string `json:"Checkpoint" xml:"Checkpoint"` + DataInitializationStatus DataInitializationStatus `json:"DataInitializationStatus" xml:"DataInitializationStatus"` + DataSynchronizationStatus DataSynchronizationStatus `json:"DataSynchronizationStatus" xml:"DataSynchronizationStatus"` + DestinationEndpoint DestinationEndpoint `json:"DestinationEndpoint" xml:"DestinationEndpoint"` + Performance Performance `json:"Performance" xml:"Performance"` + PrecheckStatus PrecheckStatusInDescribeSynchronizationJobStatus `json:"PrecheckStatus" xml:"PrecheckStatus"` + SourceEndpoint SourceEndpoint `json:"SourceEndpoint" xml:"SourceEndpoint"` + StructureInitializationStatus StructureInitializationStatus `json:"StructureInitializationStatus" xml:"StructureInitializationStatus"` + SynchronizationObjects []SynchronizationObject `json:"SynchronizationObjects" xml:"SynchronizationObjects"` } // CreateDescribeSynchronizationJobStatusRequest creates a request to invoke DescribeSynchronizationJobStatus API @@ -108,7 +114,7 @@ func CreateDescribeSynchronizationJobStatusRequest() (request *DescribeSynchroni request = &DescribeSynchronizationJobStatusRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "DescribeSynchronizationJobStatus", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeSynchronizationJobStatus", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/describe_synchronization_job_status_list.go b/services/dts/describe_synchronization_job_status_list.go new file mode 100644 index 0000000000..a4cc69ae98 --- /dev/null +++ b/services/dts/describe_synchronization_job_status_list.go @@ -0,0 +1,109 @@ +package dts + +//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" +) + +// DescribeSynchronizationJobStatusList invokes the dts.DescribeSynchronizationJobStatusList API synchronously +func (client *Client) DescribeSynchronizationJobStatusList(request *DescribeSynchronizationJobStatusListRequest) (response *DescribeSynchronizationJobStatusListResponse, err error) { + response = CreateDescribeSynchronizationJobStatusListResponse() + err = client.DoAction(request, response) + return +} + +// DescribeSynchronizationJobStatusListWithChan invokes the dts.DescribeSynchronizationJobStatusList API asynchronously +func (client *Client) DescribeSynchronizationJobStatusListWithChan(request *DescribeSynchronizationJobStatusListRequest) (<-chan *DescribeSynchronizationJobStatusListResponse, <-chan error) { + responseChan := make(chan *DescribeSynchronizationJobStatusListResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeSynchronizationJobStatusList(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeSynchronizationJobStatusListWithCallback invokes the dts.DescribeSynchronizationJobStatusList API asynchronously +func (client *Client) DescribeSynchronizationJobStatusListWithCallback(request *DescribeSynchronizationJobStatusListRequest, callback func(response *DescribeSynchronizationJobStatusListResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeSynchronizationJobStatusListResponse + var err error + defer close(result) + response, err = client.DescribeSynchronizationJobStatusList(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeSynchronizationJobStatusListRequest is the request struct for api DescribeSynchronizationJobStatusList +type DescribeSynchronizationJobStatusListRequest struct { + *requests.RpcRequest + ClientToken string `position:"Query" name:"ClientToken"` + OwnerId string `position:"Query" name:"OwnerId"` + SynchronizationJobIdListJsonStr string `position:"Query" name:"SynchronizationJobIdListJsonStr"` + AccountId string `position:"Query" name:"AccountId"` +} + +// DescribeSynchronizationJobStatusListResponse is the response struct for api DescribeSynchronizationJobStatusList +type DescribeSynchronizationJobStatusListResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + PageRecordCount int `json:"PageRecordCount" xml:"PageRecordCount"` + Success string `json:"Success" xml:"Success"` + TotalRecordCount int64 `json:"TotalRecordCount" xml:"TotalRecordCount"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + SynchronizationJobListStatusList []SynchronizationJobStatusInfo `json:"SynchronizationJobListStatusList" xml:"SynchronizationJobListStatusList"` +} + +// CreateDescribeSynchronizationJobStatusListRequest creates a request to invoke DescribeSynchronizationJobStatusList API +func CreateDescribeSynchronizationJobStatusListRequest() (request *DescribeSynchronizationJobStatusListRequest) { + request = &DescribeSynchronizationJobStatusListRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeSynchronizationJobStatusList", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeSynchronizationJobStatusListResponse creates a response to parse from DescribeSynchronizationJobStatusList response +func CreateDescribeSynchronizationJobStatusListResponse() (response *DescribeSynchronizationJobStatusListResponse) { + response = &DescribeSynchronizationJobStatusListResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_synchronization_jobs.go b/services/dts/describe_synchronization_jobs.go index 04bd5b33f6..4b88e8f517 100644 --- a/services/dts/describe_synchronization_jobs.go +++ b/services/dts/describe_synchronization_jobs.go @@ -71,18 +71,27 @@ func (client *Client) DescribeSynchronizationJobsWithCallback(request *DescribeS // DescribeSynchronizationJobsRequest is the request struct for api DescribeSynchronizationJobs type DescribeSynchronizationJobsRequest struct { *requests.RpcRequest - ClientToken string `position:"Query" name:"ClientToken"` - PageNum requests.Integer `position:"Query" name:"PageNum"` - OwnerId string `position:"Query" name:"OwnerId"` - SynchronizationJobName string `position:"Query" name:"SynchronizationJobName"` - PageSize requests.Integer `position:"Query" name:"PageSize"` + ClientToken string `position:"Query" name:"ClientToken"` + PageNum requests.Integer `position:"Query" name:"PageNum"` + SynchronizationJobName string `position:"Query" name:"SynchronizationJobName"` + AccountId string `position:"Query" name:"AccountId"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + Tag *[]DescribeSynchronizationJobsTag `position:"Query" name:"Tag" type:"Repeated"` + InstFilterRegion string `position:"Query" name:"InstFilterRegion"` + OwnerId string `position:"Query" name:"OwnerId"` +} + +// DescribeSynchronizationJobsTag is a repeated param struct in DescribeSynchronizationJobsRequest +type DescribeSynchronizationJobsTag struct { + Value string `name:"Value"` + Key string `name:"Key"` } // DescribeSynchronizationJobsResponse is the response struct for api DescribeSynchronizationJobs type DescribeSynchronizationJobsResponse struct { *responses.BaseResponse - RequestId string `json:"RequestId" xml:"RequestId"` PageNumber int `json:"PageNumber" xml:"PageNumber"` + RequestId string `json:"RequestId" xml:"RequestId"` PageRecordCount int `json:"PageRecordCount" xml:"PageRecordCount"` TotalRecordCount int64 `json:"TotalRecordCount" xml:"TotalRecordCount"` SynchronizationInstances []SynchronizationInstance `json:"SynchronizationInstances" xml:"SynchronizationInstances"` @@ -93,7 +102,7 @@ func CreateDescribeSynchronizationJobsRequest() (request *DescribeSynchronizatio request = &DescribeSynchronizationJobsRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "DescribeSynchronizationJobs", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeSynchronizationJobs", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/describe_synchronization_object_modify_status.go b/services/dts/describe_synchronization_object_modify_status.go index e87f9cc5ca..70ab49df07 100644 --- a/services/dts/describe_synchronization_object_modify_status.go +++ b/services/dts/describe_synchronization_object_modify_status.go @@ -73,19 +73,23 @@ type DescribeSynchronizationObjectModifyStatusRequest struct { *requests.RpcRequest ClientToken string `position:"Query" name:"ClientToken"` OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` TaskId string `position:"Query" name:"TaskId"` } // DescribeSynchronizationObjectModifyStatusResponse is the response struct for api DescribeSynchronizationObjectModifyStatus type DescribeSynchronizationObjectModifyStatusResponse struct { *responses.BaseResponse - Status string `json:"Status" xml:"Status"` - RequestId string `json:"RequestId" xml:"RequestId"` - ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` - PrecheckStatus PrecheckStatus `json:"PrecheckStatus" xml:"PrecheckStatus"` - StructureInitializationStatus StructureInitializationStatus `json:"StructureInitializationStatus" xml:"StructureInitializationStatus"` - DataInitializationStatus DataInitializationStatus `json:"DataInitializationStatus" xml:"DataInitializationStatus"` - DataSynchronizationStatus DataSynchronizationStatus `json:"DataSynchronizationStatus" xml:"DataSynchronizationStatus"` + Status string `json:"Status" xml:"Status"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DataInitializationStatus DataInitializationStatus `json:"DataInitializationStatus" xml:"DataInitializationStatus"` + DataSynchronizationStatus DataSynchronizationStatus `json:"DataSynchronizationStatus" xml:"DataSynchronizationStatus"` + PrecheckStatus PrecheckStatusInDescribeSynchronizationObjectModifyStatus `json:"PrecheckStatus" xml:"PrecheckStatus"` + StructureInitializationStatus StructureInitializationStatus `json:"StructureInitializationStatus" xml:"StructureInitializationStatus"` } // CreateDescribeSynchronizationObjectModifyStatusRequest creates a request to invoke DescribeSynchronizationObjectModifyStatus API @@ -93,7 +97,7 @@ func CreateDescribeSynchronizationObjectModifyStatusRequest() (request *Describe request = &DescribeSynchronizationObjectModifyStatusRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "DescribeSynchronizationObjectModifyStatus", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeSynchronizationObjectModifyStatus", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/describe_tag_keys.go b/services/dts/describe_tag_keys.go new file mode 100644 index 0000000000..4018011c31 --- /dev/null +++ b/services/dts/describe_tag_keys.go @@ -0,0 +1,108 @@ +package dts + +//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" +) + +// DescribeTagKeys invokes the dts.DescribeTagKeys API synchronously +func (client *Client) DescribeTagKeys(request *DescribeTagKeysRequest) (response *DescribeTagKeysResponse, err error) { + response = CreateDescribeTagKeysResponse() + err = client.DoAction(request, response) + return +} + +// DescribeTagKeysWithChan invokes the dts.DescribeTagKeys API asynchronously +func (client *Client) DescribeTagKeysWithChan(request *DescribeTagKeysRequest) (<-chan *DescribeTagKeysResponse, <-chan error) { + responseChan := make(chan *DescribeTagKeysResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeTagKeys(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeTagKeysWithCallback invokes the dts.DescribeTagKeys API asynchronously +func (client *Client) DescribeTagKeysWithCallback(request *DescribeTagKeysRequest, callback func(response *DescribeTagKeysResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeTagKeysResponse + var err error + defer close(result) + response, err = client.DescribeTagKeys(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeTagKeysRequest is the request struct for api DescribeTagKeys +type DescribeTagKeysRequest struct { + *requests.RpcRequest + PageNumber requests.Integer `position:"Query" name:"PageNumber"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + ResourceId string `position:"Query" name:"ResourceId"` + ResourceType string `position:"Query" name:"ResourceType"` + Category string `position:"Query" name:"Category"` +} + +// DescribeTagKeysResponse is the response struct for api DescribeTagKeys +type DescribeTagKeysResponse struct { + *responses.BaseResponse + Category string `json:"Category" xml:"Category"` + RequestId string `json:"RequestId" xml:"RequestId"` + PageSize int `json:"PageSize" xml:"PageSize"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + TotalCount int `json:"TotalCount" xml:"TotalCount"` + TagKeys []string `json:"TagKeys" xml:"TagKeys"` +} + +// CreateDescribeTagKeysRequest creates a request to invoke DescribeTagKeys API +func CreateDescribeTagKeysRequest() (request *DescribeTagKeysRequest) { + request = &DescribeTagKeysRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeTagKeys", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeTagKeysResponse creates a response to parse from DescribeTagKeys response +func CreateDescribeTagKeysResponse() (response *DescribeTagKeysResponse) { + response = &DescribeTagKeysResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/describe_tag_values.go b/services/dts/describe_tag_values.go new file mode 100644 index 0000000000..ffff019fd8 --- /dev/null +++ b/services/dts/describe_tag_values.go @@ -0,0 +1,109 @@ +package dts + +//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" +) + +// DescribeTagValues invokes the dts.DescribeTagValues API synchronously +func (client *Client) DescribeTagValues(request *DescribeTagValuesRequest) (response *DescribeTagValuesResponse, err error) { + response = CreateDescribeTagValuesResponse() + err = client.DoAction(request, response) + return +} + +// DescribeTagValuesWithChan invokes the dts.DescribeTagValues API asynchronously +func (client *Client) DescribeTagValuesWithChan(request *DescribeTagValuesRequest) (<-chan *DescribeTagValuesResponse, <-chan error) { + responseChan := make(chan *DescribeTagValuesResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DescribeTagValues(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DescribeTagValuesWithCallback invokes the dts.DescribeTagValues API asynchronously +func (client *Client) DescribeTagValuesWithCallback(request *DescribeTagValuesRequest, callback func(response *DescribeTagValuesResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DescribeTagValuesResponse + var err error + defer close(result) + response, err = client.DescribeTagValues(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DescribeTagValuesRequest is the request struct for api DescribeTagValues +type DescribeTagValuesRequest struct { + *requests.RpcRequest + PageNumber requests.Integer `position:"Query" name:"PageNumber"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + Key string `position:"Query" name:"Key"` + ResourceId string `position:"Query" name:"ResourceId"` + ResourceType string `position:"Query" name:"ResourceType"` + Category string `position:"Query" name:"Category"` +} + +// DescribeTagValuesResponse is the response struct for api DescribeTagValues +type DescribeTagValuesResponse struct { + *responses.BaseResponse + Category string `json:"Category" xml:"Category"` + RequestId string `json:"RequestId" xml:"RequestId"` + PageSize int `json:"PageSize" xml:"PageSize"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + TotalCount int `json:"TotalCount" xml:"TotalCount"` + TagValues []string `json:"TagValues" xml:"TagValues"` +} + +// CreateDescribeTagValuesRequest creates a request to invoke DescribeTagValues API +func CreateDescribeTagValuesRequest() (request *DescribeTagValuesRequest) { + request = &DescribeTagValuesRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "DescribeTagValues", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateDescribeTagValuesResponse creates a response to parse from DescribeTagValues response +func CreateDescribeTagValuesResponse() (response *DescribeTagValuesResponse) { + response = &DescribeTagValuesResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/init_dts_rds_instance.go b/services/dts/init_dts_rds_instance.go new file mode 100644 index 0000000000..4ec0791b51 --- /dev/null +++ b/services/dts/init_dts_rds_instance.go @@ -0,0 +1,109 @@ +package dts + +//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" +) + +// InitDtsRdsInstance invokes the dts.InitDtsRdsInstance API synchronously +func (client *Client) InitDtsRdsInstance(request *InitDtsRdsInstanceRequest) (response *InitDtsRdsInstanceResponse, err error) { + response = CreateInitDtsRdsInstanceResponse() + err = client.DoAction(request, response) + return +} + +// InitDtsRdsInstanceWithChan invokes the dts.InitDtsRdsInstance API asynchronously +func (client *Client) InitDtsRdsInstanceWithChan(request *InitDtsRdsInstanceRequest) (<-chan *InitDtsRdsInstanceResponse, <-chan error) { + responseChan := make(chan *InitDtsRdsInstanceResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.InitDtsRdsInstance(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// InitDtsRdsInstanceWithCallback invokes the dts.InitDtsRdsInstance API asynchronously +func (client *Client) InitDtsRdsInstanceWithCallback(request *InitDtsRdsInstanceRequest, callback func(response *InitDtsRdsInstanceResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *InitDtsRdsInstanceResponse + var err error + defer close(result) + response, err = client.InitDtsRdsInstance(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// InitDtsRdsInstanceRequest is the request struct for api InitDtsRdsInstance +type InitDtsRdsInstanceRequest struct { + *requests.RpcRequest + EndpointInstanceId string `position:"Query" name:"EndpointInstanceId"` + EndpointRegion string `position:"Query" name:"EndpointRegion"` + EndpointCenId string `position:"Query" name:"EndpointCenId"` + EndpointInstanceType string `position:"Query" name:"EndpointInstanceType"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` +} + +// InitDtsRdsInstanceResponse is the response struct for api InitDtsRdsInstance +type InitDtsRdsInstanceResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + AdminAccount string `json:"AdminAccount" xml:"AdminAccount"` + AdminPassword string `json:"AdminPassword" xml:"AdminPassword"` +} + +// CreateInitDtsRdsInstanceRequest creates a request to invoke InitDtsRdsInstance API +func CreateInitDtsRdsInstanceRequest() (request *InitDtsRdsInstanceRequest) { + request = &InitDtsRdsInstanceRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "InitDtsRdsInstance", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateInitDtsRdsInstanceResponse creates a response to parse from InitDtsRdsInstance response +func CreateInitDtsRdsInstanceResponse() (response *InitDtsRdsInstanceResponse) { + response = &InitDtsRdsInstanceResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/list_dedicated_cluster.go b/services/dts/list_dedicated_cluster.go new file mode 100644 index 0000000000..4a2b5961b5 --- /dev/null +++ b/services/dts/list_dedicated_cluster.go @@ -0,0 +1,114 @@ +package dts + +//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" +) + +// ListDedicatedCluster invokes the dts.ListDedicatedCluster API synchronously +func (client *Client) ListDedicatedCluster(request *ListDedicatedClusterRequest) (response *ListDedicatedClusterResponse, err error) { + response = CreateListDedicatedClusterResponse() + err = client.DoAction(request, response) + return +} + +// ListDedicatedClusterWithChan invokes the dts.ListDedicatedCluster API asynchronously +func (client *Client) ListDedicatedClusterWithChan(request *ListDedicatedClusterRequest) (<-chan *ListDedicatedClusterResponse, <-chan error) { + responseChan := make(chan *ListDedicatedClusterResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ListDedicatedCluster(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ListDedicatedClusterWithCallback invokes the dts.ListDedicatedCluster API asynchronously +func (client *Client) ListDedicatedClusterWithCallback(request *ListDedicatedClusterRequest, callback func(response *ListDedicatedClusterResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ListDedicatedClusterResponse + var err error + defer close(result) + response, err = client.ListDedicatedCluster(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ListDedicatedClusterRequest is the request struct for api ListDedicatedCluster +type ListDedicatedClusterRequest struct { + *requests.RpcRequest + OrderDirection string `position:"Query" name:"OrderDirection"` + Type string `position:"Query" name:"Type"` + PageNumber requests.Integer `position:"Query" name:"PageNumber"` + OrderColumn string `position:"Query" name:"OrderColumn"` + PageSize requests.Integer `position:"Query" name:"PageSize"` + State string `position:"Query" name:"State"` + OwnerId string `position:"Query" name:"OwnerId"` + Params string `position:"Query" name:"Params"` +} + +// ListDedicatedClusterResponse is the response struct for api ListDedicatedCluster +type ListDedicatedClusterResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + PageRecordCount int `json:"PageRecordCount" xml:"PageRecordCount"` + TotalRecordCount int `json:"TotalRecordCount" xml:"TotalRecordCount"` + PageNumber int `json:"PageNumber" xml:"PageNumber"` + DedicatedClusterStatusList DedicatedClusterStatusList `json:"DedicatedClusterStatusList" xml:"DedicatedClusterStatusList"` +} + +// CreateListDedicatedClusterRequest creates a request to invoke ListDedicatedCluster API +func CreateListDedicatedClusterRequest() (request *ListDedicatedClusterRequest) { + request = &ListDedicatedClusterRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ListDedicatedCluster", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateListDedicatedClusterResponse creates a response to parse from ListDedicatedCluster response +func CreateListDedicatedClusterResponse() (response *ListDedicatedClusterResponse) { + response = &ListDedicatedClusterResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/list_tag_resources.go b/services/dts/list_tag_resources.go new file mode 100644 index 0000000000..37d536ef0b --- /dev/null +++ b/services/dts/list_tag_resources.go @@ -0,0 +1,113 @@ +package dts + +//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" +) + +// ListTagResources invokes the dts.ListTagResources API synchronously +func (client *Client) ListTagResources(request *ListTagResourcesRequest) (response *ListTagResourcesResponse, err error) { + response = CreateListTagResourcesResponse() + err = client.DoAction(request, response) + return +} + +// ListTagResourcesWithChan invokes the dts.ListTagResources API asynchronously +func (client *Client) ListTagResourcesWithChan(request *ListTagResourcesRequest) (<-chan *ListTagResourcesResponse, <-chan error) { + responseChan := make(chan *ListTagResourcesResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ListTagResources(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ListTagResourcesWithCallback invokes the dts.ListTagResources API asynchronously +func (client *Client) ListTagResourcesWithCallback(request *ListTagResourcesRequest, callback func(response *ListTagResourcesResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ListTagResourcesResponse + var err error + defer close(result) + response, err = client.ListTagResources(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ListTagResourcesRequest is the request struct for api ListTagResources +type ListTagResourcesRequest struct { + *requests.RpcRequest + NextToken string `position:"Query" name:"NextToken"` + Tag *[]ListTagResourcesTag `position:"Query" name:"Tag" type:"Repeated"` + ResourceId *[]string `position:"Query" name:"ResourceId" type:"Repeated"` + ResourceType string `position:"Query" name:"ResourceType"` +} + +// ListTagResourcesTag is a repeated param struct in ListTagResourcesRequest +type ListTagResourcesTag struct { + Value string `name:"Value"` + Key string `name:"Key"` +} + +// ListTagResourcesResponse is the response struct for api ListTagResources +type ListTagResourcesResponse struct { + *responses.BaseResponse + NextToken string `json:"NextToken" xml:"NextToken"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + TagResources TagResources `json:"TagResources" xml:"TagResources"` +} + +// CreateListTagResourcesRequest creates a request to invoke ListTagResources API +func CreateListTagResourcesRequest() (request *ListTagResourcesRequest) { + request = &ListTagResourcesRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ListTagResources", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateListTagResourcesResponse creates a response to parse from ListTagResources response +func CreateListTagResourcesResponse() (response *ListTagResourcesResponse) { + response = &ListTagResourcesResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/modify_consumer_channel.go b/services/dts/modify_consumer_channel.go new file mode 100644 index 0000000000..87e805a34f --- /dev/null +++ b/services/dts/modify_consumer_channel.go @@ -0,0 +1,108 @@ +package dts + +//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" +) + +// ModifyConsumerChannel invokes the dts.ModifyConsumerChannel API synchronously +func (client *Client) ModifyConsumerChannel(request *ModifyConsumerChannelRequest) (response *ModifyConsumerChannelResponse, err error) { + response = CreateModifyConsumerChannelResponse() + err = client.DoAction(request, response) + return +} + +// ModifyConsumerChannelWithChan invokes the dts.ModifyConsumerChannel API asynchronously +func (client *Client) ModifyConsumerChannelWithChan(request *ModifyConsumerChannelRequest) (<-chan *ModifyConsumerChannelResponse, <-chan error) { + responseChan := make(chan *ModifyConsumerChannelResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifyConsumerChannel(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifyConsumerChannelWithCallback invokes the dts.ModifyConsumerChannel API asynchronously +func (client *Client) ModifyConsumerChannelWithCallback(request *ModifyConsumerChannelRequest, callback func(response *ModifyConsumerChannelResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifyConsumerChannelResponse + var err error + defer close(result) + response, err = client.ModifyConsumerChannel(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifyConsumerChannelRequest is the request struct for api ModifyConsumerChannel +type ModifyConsumerChannelRequest struct { + *requests.RpcRequest + ConsumerGroupId string `position:"Query" name:"ConsumerGroupId"` + ConsumerGroupPassword string `position:"Query" name:"ConsumerGroupPassword"` + ConsumerGroupUserName string `position:"Query" name:"ConsumerGroupUserName"` + DtsJobId string `position:"Query" name:"DtsJobId"` + ConsumerGroupName string `position:"Query" name:"ConsumerGroupName"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` +} + +// ModifyConsumerChannelResponse is the response struct for api ModifyConsumerChannel +type ModifyConsumerChannelResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateModifyConsumerChannelRequest creates a request to invoke ModifyConsumerChannel API +func CreateModifyConsumerChannelRequest() (request *ModifyConsumerChannelRequest) { + request = &ModifyConsumerChannelRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ModifyConsumerChannel", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateModifyConsumerChannelResponse creates a response to parse from ModifyConsumerChannel response +func CreateModifyConsumerChannelResponse() (response *ModifyConsumerChannelResponse) { + response = &ModifyConsumerChannelResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/modify_consumer_group_password.go b/services/dts/modify_consumer_group_password.go new file mode 100644 index 0000000000..e6ac238f98 --- /dev/null +++ b/services/dts/modify_consumer_group_password.go @@ -0,0 +1,109 @@ +package dts + +//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" +) + +// ModifyConsumerGroupPassword invokes the dts.ModifyConsumerGroupPassword API synchronously +func (client *Client) ModifyConsumerGroupPassword(request *ModifyConsumerGroupPasswordRequest) (response *ModifyConsumerGroupPasswordResponse, err error) { + response = CreateModifyConsumerGroupPasswordResponse() + err = client.DoAction(request, response) + return +} + +// ModifyConsumerGroupPasswordWithChan invokes the dts.ModifyConsumerGroupPassword API asynchronously +func (client *Client) ModifyConsumerGroupPasswordWithChan(request *ModifyConsumerGroupPasswordRequest) (<-chan *ModifyConsumerGroupPasswordResponse, <-chan error) { + responseChan := make(chan *ModifyConsumerGroupPasswordResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifyConsumerGroupPassword(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifyConsumerGroupPasswordWithCallback invokes the dts.ModifyConsumerGroupPassword API asynchronously +func (client *Client) ModifyConsumerGroupPasswordWithCallback(request *ModifyConsumerGroupPasswordRequest, callback func(response *ModifyConsumerGroupPasswordResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifyConsumerGroupPasswordResponse + var err error + defer close(result) + response, err = client.ModifyConsumerGroupPassword(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifyConsumerGroupPasswordRequest is the request struct for api ModifyConsumerGroupPassword +type ModifyConsumerGroupPasswordRequest struct { + *requests.RpcRequest + ConsumerGroupID string `position:"Query" name:"ConsumerGroupID"` + ConsumerGroupPassword string `position:"Query" name:"ConsumerGroupPassword"` + AccountId string `position:"Query" name:"AccountId"` + ConsumerGroupUserName string `position:"Query" name:"ConsumerGroupUserName"` + ConsumerGroupName string `position:"Query" name:"ConsumerGroupName"` + SubscriptionInstanceId string `position:"Query" name:"SubscriptionInstanceId"` + OwnerId string `position:"Query" name:"OwnerId"` + ConsumerGroupNewPassword string `position:"Query" name:"consumerGroupNewPassword"` +} + +// ModifyConsumerGroupPasswordResponse is the response struct for api ModifyConsumerGroupPassword +type ModifyConsumerGroupPasswordResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateModifyConsumerGroupPasswordRequest creates a request to invoke ModifyConsumerGroupPassword API +func CreateModifyConsumerGroupPasswordRequest() (request *ModifyConsumerGroupPasswordRequest) { + request = &ModifyConsumerGroupPasswordRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ModifyConsumerGroupPassword", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateModifyConsumerGroupPasswordResponse creates a response to parse from ModifyConsumerGroupPassword response +func CreateModifyConsumerGroupPasswordResponse() (response *ModifyConsumerGroupPasswordResponse) { + response = &ModifyConsumerGroupPasswordResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/modify_consumption_timestamp.go b/services/dts/modify_consumption_timestamp.go new file mode 100644 index 0000000000..28de0e29b5 --- /dev/null +++ b/services/dts/modify_consumption_timestamp.go @@ -0,0 +1,105 @@ +package dts + +//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" +) + +// ModifyConsumptionTimestamp invokes the dts.ModifyConsumptionTimestamp API synchronously +func (client *Client) ModifyConsumptionTimestamp(request *ModifyConsumptionTimestampRequest) (response *ModifyConsumptionTimestampResponse, err error) { + response = CreateModifyConsumptionTimestampResponse() + err = client.DoAction(request, response) + return +} + +// ModifyConsumptionTimestampWithChan invokes the dts.ModifyConsumptionTimestamp API asynchronously +func (client *Client) ModifyConsumptionTimestampWithChan(request *ModifyConsumptionTimestampRequest) (<-chan *ModifyConsumptionTimestampResponse, <-chan error) { + responseChan := make(chan *ModifyConsumptionTimestampResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifyConsumptionTimestamp(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifyConsumptionTimestampWithCallback invokes the dts.ModifyConsumptionTimestamp API asynchronously +func (client *Client) ModifyConsumptionTimestampWithCallback(request *ModifyConsumptionTimestampRequest, callback func(response *ModifyConsumptionTimestampResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifyConsumptionTimestampResponse + var err error + defer close(result) + response, err = client.ModifyConsumptionTimestamp(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifyConsumptionTimestampRequest is the request struct for api ModifyConsumptionTimestamp +type ModifyConsumptionTimestampRequest struct { + *requests.RpcRequest + SubscriptionInstanceId string `position:"Query" name:"SubscriptionInstanceId"` + ConsumptionTimestamp string `position:"Query" name:"ConsumptionTimestamp"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` +} + +// ModifyConsumptionTimestampResponse is the response struct for api ModifyConsumptionTimestamp +type ModifyConsumptionTimestampResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateModifyConsumptionTimestampRequest creates a request to invoke ModifyConsumptionTimestamp API +func CreateModifyConsumptionTimestampRequest() (request *ModifyConsumptionTimestampRequest) { + request = &ModifyConsumptionTimestampRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ModifyConsumptionTimestamp", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateModifyConsumptionTimestampResponse creates a response to parse from ModifyConsumptionTimestamp response +func CreateModifyConsumptionTimestampResponse() (response *ModifyConsumptionTimestampResponse) { + response = &ModifyConsumptionTimestampResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/modify_dedicated_cluster.go b/services/dts/modify_dedicated_cluster.go new file mode 100644 index 0000000000..1696d168ad --- /dev/null +++ b/services/dts/modify_dedicated_cluster.go @@ -0,0 +1,108 @@ +package dts + +//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" +) + +// ModifyDedicatedCluster invokes the dts.ModifyDedicatedCluster API synchronously +func (client *Client) ModifyDedicatedCluster(request *ModifyDedicatedClusterRequest) (response *ModifyDedicatedClusterResponse, err error) { + response = CreateModifyDedicatedClusterResponse() + err = client.DoAction(request, response) + return +} + +// ModifyDedicatedClusterWithChan invokes the dts.ModifyDedicatedCluster API asynchronously +func (client *Client) ModifyDedicatedClusterWithChan(request *ModifyDedicatedClusterRequest) (<-chan *ModifyDedicatedClusterResponse, <-chan error) { + responseChan := make(chan *ModifyDedicatedClusterResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifyDedicatedCluster(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifyDedicatedClusterWithCallback invokes the dts.ModifyDedicatedCluster API asynchronously +func (client *Client) ModifyDedicatedClusterWithCallback(request *ModifyDedicatedClusterRequest, callback func(response *ModifyDedicatedClusterResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifyDedicatedClusterResponse + var err error + defer close(result) + response, err = client.ModifyDedicatedCluster(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifyDedicatedClusterRequest is the request struct for api ModifyDedicatedCluster +type ModifyDedicatedClusterRequest struct { + *requests.RpcRequest + DedicatedClusterId string `position:"Query" name:"DedicatedClusterId"` + OwnerId string `position:"Query" name:"OwnerId"` + DedicatedClusterName string `position:"Query" name:"DedicatedClusterName"` + InstanceId string `position:"Query" name:"InstanceId"` + OversoldRatio requests.Integer `position:"Query" name:"OversoldRatio"` +} + +// ModifyDedicatedClusterResponse is the response struct for api ModifyDedicatedCluster +type ModifyDedicatedClusterResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DedicatedClusterId string `json:"DedicatedClusterId" xml:"DedicatedClusterId"` +} + +// CreateModifyDedicatedClusterRequest creates a request to invoke ModifyDedicatedCluster API +func CreateModifyDedicatedClusterRequest() (request *ModifyDedicatedClusterRequest) { + request = &ModifyDedicatedClusterRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ModifyDedicatedCluster", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateModifyDedicatedClusterResponse creates a response to parse from ModifyDedicatedCluster response +func CreateModifyDedicatedClusterResponse() (response *ModifyDedicatedClusterResponse) { + response = &ModifyDedicatedClusterResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/modify_dts_job.go b/services/dts/modify_dts_job.go new file mode 100644 index 0000000000..bb4e104dd0 --- /dev/null +++ b/services/dts/modify_dts_job.go @@ -0,0 +1,116 @@ +package dts + +//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" +) + +// ModifyDtsJob invokes the dts.ModifyDtsJob API synchronously +func (client *Client) ModifyDtsJob(request *ModifyDtsJobRequest) (response *ModifyDtsJobResponse, err error) { + response = CreateModifyDtsJobResponse() + err = client.DoAction(request, response) + return +} + +// ModifyDtsJobWithChan invokes the dts.ModifyDtsJob API asynchronously +func (client *Client) ModifyDtsJobWithChan(request *ModifyDtsJobRequest) (<-chan *ModifyDtsJobResponse, <-chan error) { + responseChan := make(chan *ModifyDtsJobResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifyDtsJob(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifyDtsJobWithCallback invokes the dts.ModifyDtsJob API asynchronously +func (client *Client) ModifyDtsJobWithCallback(request *ModifyDtsJobRequest, callback func(response *ModifyDtsJobResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifyDtsJobResponse + var err error + defer close(result) + response, err = client.ModifyDtsJob(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifyDtsJobRequest is the request struct for api ModifyDtsJob +type ModifyDtsJobRequest struct { + *requests.RpcRequest + DataInitialization requests.Boolean `position:"Query" name:"DataInitialization"` + ClientToken string `position:"Query" name:"ClientToken"` + StructureInitialization requests.Boolean `position:"Query" name:"StructureInitialization"` + EtlOperatorColumnReference string `position:"Body" name:"EtlOperatorColumnReference"` + DataSynchronization requests.Boolean `position:"Query" name:"DataSynchronization"` + DbList string `position:"Body" name:"DbList"` + FileOssUrl string `position:"Query" name:"FileOssUrl"` + OwnerId string `position:"Query" name:"OwnerId"` + ModifyTypeEnum string `position:"Body" name:"ModifyTypeEnum"` + Reserved string `position:"Body" name:"Reserved"` + FilterTableName string `position:"Body" name:"FilterTableName"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` + SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` +} + +// ModifyDtsJobResponse is the response struct for api ModifyDtsJob +type ModifyDtsJobResponse struct { + *responses.BaseResponse + Status string `json:"Status" xml:"Status"` + RequestId string `json:"RequestId" xml:"RequestId"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage bool `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateModifyDtsJobRequest creates a request to invoke ModifyDtsJob API +func CreateModifyDtsJobRequest() (request *ModifyDtsJobRequest) { + request = &ModifyDtsJobRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ModifyDtsJob", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateModifyDtsJobResponse creates a response to parse from ModifyDtsJob response +func CreateModifyDtsJobResponse() (response *ModifyDtsJobResponse) { + response = &ModifyDtsJobResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/modify_dts_job_dedicated_cluster.go b/services/dts/modify_dts_job_dedicated_cluster.go new file mode 100644 index 0000000000..fc80630ad2 --- /dev/null +++ b/services/dts/modify_dts_job_dedicated_cluster.go @@ -0,0 +1,107 @@ +package dts + +//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" +) + +// ModifyDtsJobDedicatedCluster invokes the dts.ModifyDtsJobDedicatedCluster API synchronously +func (client *Client) ModifyDtsJobDedicatedCluster(request *ModifyDtsJobDedicatedClusterRequest) (response *ModifyDtsJobDedicatedClusterResponse, err error) { + response = CreateModifyDtsJobDedicatedClusterResponse() + err = client.DoAction(request, response) + return +} + +// ModifyDtsJobDedicatedClusterWithChan invokes the dts.ModifyDtsJobDedicatedCluster API asynchronously +func (client *Client) ModifyDtsJobDedicatedClusterWithChan(request *ModifyDtsJobDedicatedClusterRequest) (<-chan *ModifyDtsJobDedicatedClusterResponse, <-chan error) { + responseChan := make(chan *ModifyDtsJobDedicatedClusterResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifyDtsJobDedicatedCluster(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifyDtsJobDedicatedClusterWithCallback invokes the dts.ModifyDtsJobDedicatedCluster API asynchronously +func (client *Client) ModifyDtsJobDedicatedClusterWithCallback(request *ModifyDtsJobDedicatedClusterRequest, callback func(response *ModifyDtsJobDedicatedClusterResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifyDtsJobDedicatedClusterResponse + var err error + defer close(result) + response, err = client.ModifyDtsJobDedicatedCluster(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifyDtsJobDedicatedClusterRequest is the request struct for api ModifyDtsJobDedicatedCluster +type ModifyDtsJobDedicatedClusterRequest struct { + *requests.RpcRequest + DtsJobIds string `position:"Query" name:"DtsJobIds"` + DedicatedClusterId string `position:"Query" name:"DedicatedClusterId"` + OwnerId string `position:"Query" name:"OwnerId"` +} + +// ModifyDtsJobDedicatedClusterResponse is the response struct for api ModifyDtsJobDedicatedCluster +type ModifyDtsJobDedicatedClusterResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + HttpStatusCode int64 `json:"HttpStatusCode" xml:"HttpStatusCode"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + Code string `json:"Code" xml:"Code"` + Success bool `json:"Success" xml:"Success"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` +} + +// CreateModifyDtsJobDedicatedClusterRequest creates a request to invoke ModifyDtsJobDedicatedCluster API +func CreateModifyDtsJobDedicatedClusterRequest() (request *ModifyDtsJobDedicatedClusterRequest) { + request = &ModifyDtsJobDedicatedClusterRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ModifyDtsJobDedicatedCluster", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateModifyDtsJobDedicatedClusterResponse creates a response to parse from ModifyDtsJobDedicatedCluster response +func CreateModifyDtsJobDedicatedClusterResponse() (response *ModifyDtsJobDedicatedClusterResponse) { + response = &ModifyDtsJobDedicatedClusterResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/modify_dts_job_du_limit.go b/services/dts/modify_dts_job_du_limit.go new file mode 100644 index 0000000000..2486b43174 --- /dev/null +++ b/services/dts/modify_dts_job_du_limit.go @@ -0,0 +1,107 @@ +package dts + +//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" +) + +// ModifyDtsJobDuLimit invokes the dts.ModifyDtsJobDuLimit API synchronously +func (client *Client) ModifyDtsJobDuLimit(request *ModifyDtsJobDuLimitRequest) (response *ModifyDtsJobDuLimitResponse, err error) { + response = CreateModifyDtsJobDuLimitResponse() + err = client.DoAction(request, response) + return +} + +// ModifyDtsJobDuLimitWithChan invokes the dts.ModifyDtsJobDuLimit API asynchronously +func (client *Client) ModifyDtsJobDuLimitWithChan(request *ModifyDtsJobDuLimitRequest) (<-chan *ModifyDtsJobDuLimitResponse, <-chan error) { + responseChan := make(chan *ModifyDtsJobDuLimitResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifyDtsJobDuLimit(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifyDtsJobDuLimitWithCallback invokes the dts.ModifyDtsJobDuLimit API asynchronously +func (client *Client) ModifyDtsJobDuLimitWithCallback(request *ModifyDtsJobDuLimitRequest, callback func(response *ModifyDtsJobDuLimitResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifyDtsJobDuLimitResponse + var err error + defer close(result) + response, err = client.ModifyDtsJobDuLimit(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifyDtsJobDuLimitRequest is the request struct for api ModifyDtsJobDuLimit +type ModifyDtsJobDuLimitRequest struct { + *requests.RpcRequest + OwnerId string `position:"Query" name:"OwnerId"` + DuLimit requests.Integer `position:"Query" name:"DuLimit"` + DtsJobId string `position:"Query" name:"DtsJobId"` +} + +// ModifyDtsJobDuLimitResponse is the response struct for api ModifyDtsJobDuLimit +type ModifyDtsJobDuLimitResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + HttpStatusCode int64 `json:"HttpStatusCode" xml:"HttpStatusCode"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + Code string `json:"Code" xml:"Code"` + Success bool `json:"Success" xml:"Success"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` +} + +// CreateModifyDtsJobDuLimitRequest creates a request to invoke ModifyDtsJobDuLimit API +func CreateModifyDtsJobDuLimitRequest() (request *ModifyDtsJobDuLimitRequest) { + request = &ModifyDtsJobDuLimitRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ModifyDtsJobDuLimit", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateModifyDtsJobDuLimitResponse creates a response to parse from ModifyDtsJobDuLimit response +func CreateModifyDtsJobDuLimitResponse() (response *ModifyDtsJobDuLimitResponse) { + response = &ModifyDtsJobDuLimitResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/modify_dts_job_name.go b/services/dts/modify_dts_job_name.go new file mode 100644 index 0000000000..1dd19f50ba --- /dev/null +++ b/services/dts/modify_dts_job_name.go @@ -0,0 +1,106 @@ +package dts + +//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" +) + +// ModifyDtsJobName invokes the dts.ModifyDtsJobName API synchronously +func (client *Client) ModifyDtsJobName(request *ModifyDtsJobNameRequest) (response *ModifyDtsJobNameResponse, err error) { + response = CreateModifyDtsJobNameResponse() + err = client.DoAction(request, response) + return +} + +// ModifyDtsJobNameWithChan invokes the dts.ModifyDtsJobName API asynchronously +func (client *Client) ModifyDtsJobNameWithChan(request *ModifyDtsJobNameRequest) (<-chan *ModifyDtsJobNameResponse, <-chan error) { + responseChan := make(chan *ModifyDtsJobNameResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifyDtsJobName(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifyDtsJobNameWithCallback invokes the dts.ModifyDtsJobName API asynchronously +func (client *Client) ModifyDtsJobNameWithCallback(request *ModifyDtsJobNameRequest, callback func(response *ModifyDtsJobNameResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifyDtsJobNameResponse + var err error + defer close(result) + response, err = client.ModifyDtsJobName(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifyDtsJobNameRequest is the request struct for api ModifyDtsJobName +type ModifyDtsJobNameRequest struct { + *requests.RpcRequest + DtsJobName string `position:"Query" name:"DtsJobName"` + DtsJobId string `position:"Query" name:"DtsJobId"` +} + +// ModifyDtsJobNameResponse is the response struct for api ModifyDtsJobName +type ModifyDtsJobNameResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + Code string `json:"Code" xml:"Code"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` +} + +// CreateModifyDtsJobNameRequest creates a request to invoke ModifyDtsJobName API +func CreateModifyDtsJobNameRequest() (request *ModifyDtsJobNameRequest) { + request = &ModifyDtsJobNameRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ModifyDtsJobName", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateModifyDtsJobNameResponse creates a response to parse from ModifyDtsJobName response +func CreateModifyDtsJobNameResponse() (response *ModifyDtsJobNameResponse) { + response = &ModifyDtsJobNameResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/modify_dts_job_password.go b/services/dts/modify_dts_job_password.go new file mode 100644 index 0000000000..bbe2a7501b --- /dev/null +++ b/services/dts/modify_dts_job_password.go @@ -0,0 +1,108 @@ +package dts + +//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" +) + +// ModifyDtsJobPassword invokes the dts.ModifyDtsJobPassword API synchronously +func (client *Client) ModifyDtsJobPassword(request *ModifyDtsJobPasswordRequest) (response *ModifyDtsJobPasswordResponse, err error) { + response = CreateModifyDtsJobPasswordResponse() + err = client.DoAction(request, response) + return +} + +// ModifyDtsJobPasswordWithChan invokes the dts.ModifyDtsJobPassword API asynchronously +func (client *Client) ModifyDtsJobPasswordWithChan(request *ModifyDtsJobPasswordRequest) (<-chan *ModifyDtsJobPasswordResponse, <-chan error) { + responseChan := make(chan *ModifyDtsJobPasswordResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifyDtsJobPassword(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifyDtsJobPasswordWithCallback invokes the dts.ModifyDtsJobPassword API asynchronously +func (client *Client) ModifyDtsJobPasswordWithCallback(request *ModifyDtsJobPasswordRequest, callback func(response *ModifyDtsJobPasswordResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifyDtsJobPasswordResponse + var err error + defer close(result) + response, err = client.ModifyDtsJobPassword(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifyDtsJobPasswordRequest is the request struct for api ModifyDtsJobPassword +type ModifyDtsJobPasswordRequest struct { + *requests.RpcRequest + Password string `position:"Query" name:"Password"` + Endpoint string `position:"Query" name:"Endpoint"` + DtsJobId string `position:"Query" name:"DtsJobId"` + UserName string `position:"Query" name:"UserName"` +} + +// ModifyDtsJobPasswordResponse is the response struct for api ModifyDtsJobPassword +type ModifyDtsJobPasswordResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + Code string `json:"Code" xml:"Code"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` +} + +// CreateModifyDtsJobPasswordRequest creates a request to invoke ModifyDtsJobPassword API +func CreateModifyDtsJobPasswordRequest() (request *ModifyDtsJobPasswordRequest) { + request = &ModifyDtsJobPasswordRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ModifyDtsJobPassword", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateModifyDtsJobPasswordResponse creates a response to parse from ModifyDtsJobPassword response +func CreateModifyDtsJobPasswordResponse() (response *ModifyDtsJobPasswordResponse) { + response = &ModifyDtsJobPasswordResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/modify_subscription.go b/services/dts/modify_subscription.go new file mode 100644 index 0000000000..43ff0014ba --- /dev/null +++ b/services/dts/modify_subscription.go @@ -0,0 +1,107 @@ +package dts + +//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" +) + +// ModifySubscription invokes the dts.ModifySubscription API synchronously +func (client *Client) ModifySubscription(request *ModifySubscriptionRequest) (response *ModifySubscriptionResponse, err error) { + response = CreateModifySubscriptionResponse() + err = client.DoAction(request, response) + return +} + +// ModifySubscriptionWithChan invokes the dts.ModifySubscription API asynchronously +func (client *Client) ModifySubscriptionWithChan(request *ModifySubscriptionRequest) (<-chan *ModifySubscriptionResponse, <-chan error) { + responseChan := make(chan *ModifySubscriptionResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifySubscription(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifySubscriptionWithCallback invokes the dts.ModifySubscription API asynchronously +func (client *Client) ModifySubscriptionWithCallback(request *ModifySubscriptionRequest, callback func(response *ModifySubscriptionResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifySubscriptionResponse + var err error + defer close(result) + response, err = client.ModifySubscription(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifySubscriptionRequest is the request struct for api ModifySubscription +type ModifySubscriptionRequest struct { + *requests.RpcRequest + DbList string `position:"Query" name:"DbList"` + SubscriptionDataTypeDDL requests.Boolean `position:"Query" name:"SubscriptionDataTypeDDL"` + SubscriptionDataTypeDML requests.Boolean `position:"Query" name:"SubscriptionDataTypeDML"` + DtsJobId string `position:"Query" name:"DtsJobId"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` +} + +// ModifySubscriptionResponse is the response struct for api ModifySubscription +type ModifySubscriptionResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateModifySubscriptionRequest creates a request to invoke ModifySubscription API +func CreateModifySubscriptionRequest() (request *ModifySubscriptionRequest) { + request = &ModifySubscriptionRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ModifySubscription", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateModifySubscriptionResponse creates a response to parse from ModifySubscription response +func CreateModifySubscriptionResponse() (response *ModifySubscriptionResponse) { + response = &ModifySubscriptionResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/modify_subscription_object.go b/services/dts/modify_subscription_object.go new file mode 100644 index 0000000000..f7ad00ce30 --- /dev/null +++ b/services/dts/modify_subscription_object.go @@ -0,0 +1,105 @@ +package dts + +//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" +) + +// ModifySubscriptionObject invokes the dts.ModifySubscriptionObject API synchronously +func (client *Client) ModifySubscriptionObject(request *ModifySubscriptionObjectRequest) (response *ModifySubscriptionObjectResponse, err error) { + response = CreateModifySubscriptionObjectResponse() + err = client.DoAction(request, response) + return +} + +// ModifySubscriptionObjectWithChan invokes the dts.ModifySubscriptionObject API asynchronously +func (client *Client) ModifySubscriptionObjectWithChan(request *ModifySubscriptionObjectRequest) (<-chan *ModifySubscriptionObjectResponse, <-chan error) { + responseChan := make(chan *ModifySubscriptionObjectResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ModifySubscriptionObject(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ModifySubscriptionObjectWithCallback invokes the dts.ModifySubscriptionObject API asynchronously +func (client *Client) ModifySubscriptionObjectWithCallback(request *ModifySubscriptionObjectRequest, callback func(response *ModifySubscriptionObjectResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ModifySubscriptionObjectResponse + var err error + defer close(result) + response, err = client.ModifySubscriptionObject(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ModifySubscriptionObjectRequest is the request struct for api ModifySubscriptionObject +type ModifySubscriptionObjectRequest struct { + *requests.RpcRequest + SubscriptionInstanceId string `position:"Query" name:"SubscriptionInstanceId"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` + SubscriptionObject string `position:"Query" name:"SubscriptionObject"` +} + +// ModifySubscriptionObjectResponse is the response struct for api ModifySubscriptionObject +type ModifySubscriptionObjectResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateModifySubscriptionObjectRequest creates a request to invoke ModifySubscriptionObject API +func CreateModifySubscriptionObjectRequest() (request *ModifySubscriptionObjectRequest) { + request = &ModifySubscriptionObjectRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ModifySubscriptionObject", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateModifySubscriptionObjectResponse creates a response to parse from ModifySubscriptionObject response +func CreateModifySubscriptionObjectResponse() (response *ModifySubscriptionObjectResponse) { + response = &ModifySubscriptionObjectResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/modify_synchronization_object.go b/services/dts/modify_synchronization_object.go index f8413dc06e..0ae27962e6 100644 --- a/services/dts/modify_synchronization_object.go +++ b/services/dts/modify_synchronization_object.go @@ -71,9 +71,10 @@ func (client *Client) ModifySynchronizationObjectWithCallback(request *ModifySyn // ModifySynchronizationObjectRequest is the request struct for api ModifySynchronizationObject type ModifySynchronizationObjectRequest struct { *requests.RpcRequest - SynchronizationObjects string `position:"Query" name:"SynchronizationObjects"` + SynchronizationObjects string `position:"Body" name:"SynchronizationObjects"` OwnerId string `position:"Query" name:"OwnerId"` SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` + AccountId string `position:"Query" name:"AccountId"` SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` } @@ -92,7 +93,7 @@ func CreateModifySynchronizationObjectRequest() (request *ModifySynchronizationO request = &ModifySynchronizationObjectRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "ModifySynchronizationObject", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "ModifySynchronizationObject", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/renew_instance.go b/services/dts/renew_instance.go new file mode 100644 index 0000000000..ec5858e8aa --- /dev/null +++ b/services/dts/renew_instance.go @@ -0,0 +1,112 @@ +package dts + +//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" +) + +// RenewInstance invokes the dts.RenewInstance API synchronously +func (client *Client) RenewInstance(request *RenewInstanceRequest) (response *RenewInstanceResponse, err error) { + response = CreateRenewInstanceResponse() + err = client.DoAction(request, response) + return +} + +// RenewInstanceWithChan invokes the dts.RenewInstance API asynchronously +func (client *Client) RenewInstanceWithChan(request *RenewInstanceRequest) (<-chan *RenewInstanceResponse, <-chan error) { + responseChan := make(chan *RenewInstanceResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.RenewInstance(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// RenewInstanceWithCallback invokes the dts.RenewInstance API asynchronously +func (client *Client) RenewInstanceWithCallback(request *RenewInstanceRequest, callback func(response *RenewInstanceResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *RenewInstanceResponse + var err error + defer close(result) + response, err = client.RenewInstance(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// RenewInstanceRequest is the request struct for api RenewInstance +type RenewInstanceRequest struct { + *requests.RpcRequest + Period string `position:"Query" name:"Period"` + BuyCount string `position:"Query" name:"BuyCount"` + DtsJobId string `position:"Query" name:"DtsJobId"` + ChargeType string `position:"Query" name:"ChargeType"` +} + +// RenewInstanceResponse is the response struct for api RenewInstance +type RenewInstanceResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + EndTime string `json:"EndTime" xml:"EndTime"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + ChargeType string `json:"ChargeType" xml:"ChargeType"` + Code string `json:"Code" xml:"Code"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + InstanceId string `json:"InstanceId" xml:"InstanceId"` +} + +// CreateRenewInstanceRequest creates a request to invoke RenewInstance API +func CreateRenewInstanceRequest() (request *RenewInstanceRequest) { + request = &RenewInstanceRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "RenewInstance", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateRenewInstanceResponse creates a response to parse from RenewInstance response +func CreateRenewInstanceResponse() (response *RenewInstanceResponse) { + response = &RenewInstanceResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/reset_dts_job.go b/services/dts/reset_dts_job.go new file mode 100644 index 0000000000..594bcf23fa --- /dev/null +++ b/services/dts/reset_dts_job.go @@ -0,0 +1,107 @@ +package dts + +//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" +) + +// ResetDtsJob invokes the dts.ResetDtsJob API synchronously +func (client *Client) ResetDtsJob(request *ResetDtsJobRequest) (response *ResetDtsJobResponse, err error) { + response = CreateResetDtsJobResponse() + err = client.DoAction(request, response) + return +} + +// ResetDtsJobWithChan invokes the dts.ResetDtsJob API asynchronously +func (client *Client) ResetDtsJobWithChan(request *ResetDtsJobRequest) (<-chan *ResetDtsJobResponse, <-chan error) { + responseChan := make(chan *ResetDtsJobResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ResetDtsJob(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ResetDtsJobWithCallback invokes the dts.ResetDtsJob API asynchronously +func (client *Client) ResetDtsJobWithCallback(request *ResetDtsJobRequest, callback func(response *ResetDtsJobResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ResetDtsJobResponse + var err error + defer close(result) + response, err = client.ResetDtsJob(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ResetDtsJobRequest is the request struct for api ResetDtsJob +type ResetDtsJobRequest struct { + *requests.RpcRequest + DtsJobId string `position:"Query" name:"DtsJobId"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` + SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` +} + +// ResetDtsJobResponse is the response struct for api ResetDtsJob +type ResetDtsJobResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` +} + +// CreateResetDtsJobRequest creates a request to invoke ResetDtsJob API +func CreateResetDtsJobRequest() (request *ResetDtsJobRequest) { + request = &ResetDtsJobRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ResetDtsJob", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateResetDtsJobResponse creates a response to parse from ResetDtsJob response +func CreateResetDtsJobResponse() (response *ResetDtsJobResponse) { + response = &ResetDtsJobResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/reset_synchronization_job.go b/services/dts/reset_synchronization_job.go index 72acf8aaea..981ce3445c 100644 --- a/services/dts/reset_synchronization_job.go +++ b/services/dts/reset_synchronization_job.go @@ -73,6 +73,7 @@ type ResetSynchronizationJobRequest struct { *requests.RpcRequest OwnerId string `position:"Query" name:"OwnerId"` SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` + AccountId string `position:"Query" name:"AccountId"` SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` } @@ -90,7 +91,7 @@ func CreateResetSynchronizationJobRequest() (request *ResetSynchronizationJobReq request = &ResetSynchronizationJobRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "ResetSynchronizationJob", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "ResetSynchronizationJob", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/reverse_two_way_direction.go b/services/dts/reverse_two_way_direction.go new file mode 100644 index 0000000000..35ba79a2a2 --- /dev/null +++ b/services/dts/reverse_two_way_direction.go @@ -0,0 +1,106 @@ +package dts + +//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" +) + +// ReverseTwoWayDirection invokes the dts.ReverseTwoWayDirection API synchronously +func (client *Client) ReverseTwoWayDirection(request *ReverseTwoWayDirectionRequest) (response *ReverseTwoWayDirectionResponse, err error) { + response = CreateReverseTwoWayDirectionResponse() + err = client.DoAction(request, response) + return +} + +// ReverseTwoWayDirectionWithChan invokes the dts.ReverseTwoWayDirection API asynchronously +func (client *Client) ReverseTwoWayDirectionWithChan(request *ReverseTwoWayDirectionRequest) (<-chan *ReverseTwoWayDirectionResponse, <-chan error) { + responseChan := make(chan *ReverseTwoWayDirectionResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ReverseTwoWayDirection(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ReverseTwoWayDirectionWithCallback invokes the dts.ReverseTwoWayDirection API asynchronously +func (client *Client) ReverseTwoWayDirectionWithCallback(request *ReverseTwoWayDirectionRequest, callback func(response *ReverseTwoWayDirectionResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ReverseTwoWayDirectionResponse + var err error + defer close(result) + response, err = client.ReverseTwoWayDirection(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ReverseTwoWayDirectionRequest is the request struct for api ReverseTwoWayDirection +type ReverseTwoWayDirectionRequest struct { + *requests.RpcRequest + IgnoreErrorSubJob requests.Boolean `position:"Query" name:"IgnoreErrorSubJob"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` +} + +// ReverseTwoWayDirectionResponse is the response struct for api ReverseTwoWayDirection +type ReverseTwoWayDirectionResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + Code string `json:"Code" xml:"Code"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` +} + +// CreateReverseTwoWayDirectionRequest creates a request to invoke ReverseTwoWayDirection API +func CreateReverseTwoWayDirectionRequest() (request *ReverseTwoWayDirectionRequest) { + request = &ReverseTwoWayDirectionRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ReverseTwoWayDirection", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateReverseTwoWayDirectionResponse creates a response to parse from ReverseTwoWayDirection response +func CreateReverseTwoWayDirectionResponse() (response *ReverseTwoWayDirectionResponse) { + response = &ReverseTwoWayDirectionResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/shield_precheck.go b/services/dts/shield_precheck.go new file mode 100644 index 0000000000..6074cdf37f --- /dev/null +++ b/services/dts/shield_precheck.go @@ -0,0 +1,103 @@ +package dts + +//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" +) + +// ShieldPrecheck invokes the dts.ShieldPrecheck API synchronously +func (client *Client) ShieldPrecheck(request *ShieldPrecheckRequest) (response *ShieldPrecheckResponse, err error) { + response = CreateShieldPrecheckResponse() + err = client.DoAction(request, response) + return +} + +// ShieldPrecheckWithChan invokes the dts.ShieldPrecheck API asynchronously +func (client *Client) ShieldPrecheckWithChan(request *ShieldPrecheckRequest) (<-chan *ShieldPrecheckResponse, <-chan error) { + responseChan := make(chan *ShieldPrecheckResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.ShieldPrecheck(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// ShieldPrecheckWithCallback invokes the dts.ShieldPrecheck API asynchronously +func (client *Client) ShieldPrecheckWithCallback(request *ShieldPrecheckRequest, callback func(response *ShieldPrecheckResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *ShieldPrecheckResponse + var err error + defer close(result) + response, err = client.ShieldPrecheck(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// ShieldPrecheckRequest is the request struct for api ShieldPrecheck +type ShieldPrecheckRequest struct { + *requests.RpcRequest + PrecheckItems string `position:"Query" name:"PrecheckItems"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` +} + +// ShieldPrecheckResponse is the response struct for api ShieldPrecheck +type ShieldPrecheckResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateShieldPrecheckRequest creates a request to invoke ShieldPrecheck API +func CreateShieldPrecheckRequest() (request *ShieldPrecheckRequest) { + request = &ShieldPrecheckRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "ShieldPrecheck", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateShieldPrecheckResponse creates a response to parse from ShieldPrecheck response +func CreateShieldPrecheckResponse() (response *ShieldPrecheckResponse) { + response = &ShieldPrecheckResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/skip_pre_check.go b/services/dts/skip_pre_check.go new file mode 100644 index 0000000000..5d9f85fd19 --- /dev/null +++ b/services/dts/skip_pre_check.go @@ -0,0 +1,113 @@ +package dts + +//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" +) + +// SkipPreCheck invokes the dts.SkipPreCheck API synchronously +func (client *Client) SkipPreCheck(request *SkipPreCheckRequest) (response *SkipPreCheckResponse, err error) { + response = CreateSkipPreCheckResponse() + err = client.DoAction(request, response) + return +} + +// SkipPreCheckWithChan invokes the dts.SkipPreCheck API asynchronously +func (client *Client) SkipPreCheckWithChan(request *SkipPreCheckRequest) (<-chan *SkipPreCheckResponse, <-chan error) { + responseChan := make(chan *SkipPreCheckResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.SkipPreCheck(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// SkipPreCheckWithCallback invokes the dts.SkipPreCheck API asynchronously +func (client *Client) SkipPreCheckWithCallback(request *SkipPreCheckRequest, callback func(response *SkipPreCheckResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *SkipPreCheckResponse + var err error + defer close(result) + response, err = client.SkipPreCheck(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// SkipPreCheckRequest is the request struct for api SkipPreCheck +type SkipPreCheckRequest struct { + *requests.RpcRequest + Skip requests.Boolean `position:"Query" name:"Skip"` + JobId string `position:"Query" name:"JobId"` + SkipPreCheckNames string `position:"Query" name:"SkipPreCheckNames"` + DtsJobId string `position:"Query" name:"DtsJobId"` + SkipPreCheckItems string `position:"Query" name:"SkipPreCheckItems"` +} + +// SkipPreCheckResponse is the response struct for api SkipPreCheck +type SkipPreCheckResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + SkipNames string `json:"SkipNames" xml:"SkipNames"` + Code string `json:"Code" xml:"Code"` + ScheduleJobId string `json:"ScheduleJobId" xml:"ScheduleJobId"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + MigrationJobId string `json:"MigrationJobId" xml:"MigrationJobId"` + SkipItems string `json:"SkipItems" xml:"SkipItems"` +} + +// CreateSkipPreCheckRequest creates a request to invoke SkipPreCheck API +func CreateSkipPreCheckRequest() (request *SkipPreCheckRequest) { + request = &SkipPreCheckRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "SkipPreCheck", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateSkipPreCheckResponse creates a response to parse from SkipPreCheck response +func CreateSkipPreCheckResponse() (response *SkipPreCheckResponse) { + response = &SkipPreCheckResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/start_dts_job.go b/services/dts/start_dts_job.go new file mode 100644 index 0000000000..26e9919108 --- /dev/null +++ b/services/dts/start_dts_job.go @@ -0,0 +1,109 @@ +package dts + +//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" +) + +// StartDtsJob invokes the dts.StartDtsJob API synchronously +func (client *Client) StartDtsJob(request *StartDtsJobRequest) (response *StartDtsJobResponse, err error) { + response = CreateStartDtsJobResponse() + err = client.DoAction(request, response) + return +} + +// StartDtsJobWithChan invokes the dts.StartDtsJob API asynchronously +func (client *Client) StartDtsJobWithChan(request *StartDtsJobRequest) (<-chan *StartDtsJobResponse, <-chan error) { + responseChan := make(chan *StartDtsJobResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.StartDtsJob(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// StartDtsJobWithCallback invokes the dts.StartDtsJob API asynchronously +func (client *Client) StartDtsJobWithCallback(request *StartDtsJobRequest, callback func(response *StartDtsJobResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *StartDtsJobResponse + var err error + defer close(result) + response, err = client.StartDtsJob(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// StartDtsJobRequest is the request struct for api StartDtsJob +type StartDtsJobRequest struct { + *requests.RpcRequest + ResetCheckpoint string `position:"Query" name:"ResetCheckpoint"` + ResumeHoldJob string `position:"Query" name:"ResumeHoldJob"` + DtsJobId string `position:"Query" name:"DtsJobId"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` + SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` +} + +// StartDtsJobResponse is the response struct for api StartDtsJob +type StartDtsJobResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` +} + +// CreateStartDtsJobRequest creates a request to invoke StartDtsJob API +func CreateStartDtsJobRequest() (request *StartDtsJobRequest) { + request = &StartDtsJobRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "StartDtsJob", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateStartDtsJobResponse creates a response to parse from StartDtsJob response +func CreateStartDtsJobResponse() (response *StartDtsJobResponse) { + response = &StartDtsJobResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/start_dts_jobs.go b/services/dts/start_dts_jobs.go new file mode 100644 index 0000000000..5df3429c26 --- /dev/null +++ b/services/dts/start_dts_jobs.go @@ -0,0 +1,105 @@ +package dts + +//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" +) + +// StartDtsJobs invokes the dts.StartDtsJobs API synchronously +func (client *Client) StartDtsJobs(request *StartDtsJobsRequest) (response *StartDtsJobsResponse, err error) { + response = CreateStartDtsJobsResponse() + err = client.DoAction(request, response) + return +} + +// StartDtsJobsWithChan invokes the dts.StartDtsJobs API asynchronously +func (client *Client) StartDtsJobsWithChan(request *StartDtsJobsRequest) (<-chan *StartDtsJobsResponse, <-chan error) { + responseChan := make(chan *StartDtsJobsResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.StartDtsJobs(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// StartDtsJobsWithCallback invokes the dts.StartDtsJobs API asynchronously +func (client *Client) StartDtsJobsWithCallback(request *StartDtsJobsRequest, callback func(response *StartDtsJobsResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *StartDtsJobsResponse + var err error + defer close(result) + response, err = client.StartDtsJobs(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// StartDtsJobsRequest is the request struct for api StartDtsJobs +type StartDtsJobsRequest struct { + *requests.RpcRequest + DtsJobIds string `position:"Query" name:"DtsJobIds"` +} + +// StartDtsJobsResponse is the response struct for api StartDtsJobs +type StartDtsJobsResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` +} + +// CreateStartDtsJobsRequest creates a request to invoke StartDtsJobs API +func CreateStartDtsJobsRequest() (request *StartDtsJobsRequest) { + request = &StartDtsJobsRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "StartDtsJobs", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateStartDtsJobsResponse creates a response to parse from StartDtsJobs response +func CreateStartDtsJobsResponse() (response *StartDtsJobsResponse) { + response = &StartDtsJobsResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/start_migration_job.go b/services/dts/start_migration_job.go new file mode 100644 index 0000000000..2574af993d --- /dev/null +++ b/services/dts/start_migration_job.go @@ -0,0 +1,104 @@ +package dts + +//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" +) + +// StartMigrationJob invokes the dts.StartMigrationJob API synchronously +func (client *Client) StartMigrationJob(request *StartMigrationJobRequest) (response *StartMigrationJobResponse, err error) { + response = CreateStartMigrationJobResponse() + err = client.DoAction(request, response) + return +} + +// StartMigrationJobWithChan invokes the dts.StartMigrationJob API asynchronously +func (client *Client) StartMigrationJobWithChan(request *StartMigrationJobRequest) (<-chan *StartMigrationJobResponse, <-chan error) { + responseChan := make(chan *StartMigrationJobResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.StartMigrationJob(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// StartMigrationJobWithCallback invokes the dts.StartMigrationJob API asynchronously +func (client *Client) StartMigrationJobWithCallback(request *StartMigrationJobRequest, callback func(response *StartMigrationJobResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *StartMigrationJobResponse + var err error + defer close(result) + response, err = client.StartMigrationJob(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// StartMigrationJobRequest is the request struct for api StartMigrationJob +type StartMigrationJobRequest struct { + *requests.RpcRequest + MigrationJobId string `position:"Query" name:"MigrationJobId"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` +} + +// StartMigrationJobResponse is the response struct for api StartMigrationJob +type StartMigrationJobResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateStartMigrationJobRequest creates a request to invoke StartMigrationJob API +func CreateStartMigrationJobRequest() (request *StartMigrationJobRequest) { + request = &StartMigrationJobRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "StartMigrationJob", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateStartMigrationJobResponse creates a response to parse from StartMigrationJob response +func CreateStartMigrationJobResponse() (response *StartMigrationJobResponse) { + response = &StartMigrationJobResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/start_subscription_instance.go b/services/dts/start_subscription_instance.go new file mode 100644 index 0000000000..c9c9c6cfc3 --- /dev/null +++ b/services/dts/start_subscription_instance.go @@ -0,0 +1,105 @@ +package dts + +//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" +) + +// StartSubscriptionInstance invokes the dts.StartSubscriptionInstance API synchronously +func (client *Client) StartSubscriptionInstance(request *StartSubscriptionInstanceRequest) (response *StartSubscriptionInstanceResponse, err error) { + response = CreateStartSubscriptionInstanceResponse() + err = client.DoAction(request, response) + return +} + +// StartSubscriptionInstanceWithChan invokes the dts.StartSubscriptionInstance API asynchronously +func (client *Client) StartSubscriptionInstanceWithChan(request *StartSubscriptionInstanceRequest) (<-chan *StartSubscriptionInstanceResponse, <-chan error) { + responseChan := make(chan *StartSubscriptionInstanceResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.StartSubscriptionInstance(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// StartSubscriptionInstanceWithCallback invokes the dts.StartSubscriptionInstance API asynchronously +func (client *Client) StartSubscriptionInstanceWithCallback(request *StartSubscriptionInstanceRequest, callback func(response *StartSubscriptionInstanceResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *StartSubscriptionInstanceResponse + var err error + defer close(result) + response, err = client.StartSubscriptionInstance(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// StartSubscriptionInstanceRequest is the request struct for api StartSubscriptionInstance +type StartSubscriptionInstanceRequest struct { + *requests.RpcRequest + SubscriptionInstanceId string `position:"Query" name:"SubscriptionInstanceId"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` +} + +// StartSubscriptionInstanceResponse is the response struct for api StartSubscriptionInstance +type StartSubscriptionInstanceResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + TaskId string `json:"TaskId" xml:"TaskId"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateStartSubscriptionInstanceRequest creates a request to invoke StartSubscriptionInstance API +func CreateStartSubscriptionInstanceRequest() (request *StartSubscriptionInstanceRequest) { + request = &StartSubscriptionInstanceRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "StartSubscriptionInstance", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateStartSubscriptionInstanceResponse creates a response to parse from StartSubscriptionInstance response +func CreateStartSubscriptionInstanceResponse() (response *StartSubscriptionInstanceResponse) { + response = &StartSubscriptionInstanceResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/start_synchronization_job.go b/services/dts/start_synchronization_job.go index 6003fa6c88..e42cc891b5 100644 --- a/services/dts/start_synchronization_job.go +++ b/services/dts/start_synchronization_job.go @@ -73,6 +73,7 @@ type StartSynchronizationJobRequest struct { *requests.RpcRequest OwnerId string `position:"Query" name:"OwnerId"` SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` + AccountId string `position:"Query" name:"AccountId"` SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` } @@ -90,7 +91,7 @@ func CreateStartSynchronizationJobRequest() (request *StartSynchronizationJobReq request = &StartSynchronizationJobRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "StartSynchronizationJob", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "StartSynchronizationJob", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/stop_dedicated_cluster.go b/services/dts/stop_dedicated_cluster.go new file mode 100644 index 0000000000..771e023d82 --- /dev/null +++ b/services/dts/stop_dedicated_cluster.go @@ -0,0 +1,106 @@ +package dts + +//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" +) + +// StopDedicatedCluster invokes the dts.StopDedicatedCluster API synchronously +func (client *Client) StopDedicatedCluster(request *StopDedicatedClusterRequest) (response *StopDedicatedClusterResponse, err error) { + response = CreateStopDedicatedClusterResponse() + err = client.DoAction(request, response) + return +} + +// StopDedicatedClusterWithChan invokes the dts.StopDedicatedCluster API asynchronously +func (client *Client) StopDedicatedClusterWithChan(request *StopDedicatedClusterRequest) (<-chan *StopDedicatedClusterResponse, <-chan error) { + responseChan := make(chan *StopDedicatedClusterResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.StopDedicatedCluster(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// StopDedicatedClusterWithCallback invokes the dts.StopDedicatedCluster API asynchronously +func (client *Client) StopDedicatedClusterWithCallback(request *StopDedicatedClusterRequest, callback func(response *StopDedicatedClusterResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *StopDedicatedClusterResponse + var err error + defer close(result) + response, err = client.StopDedicatedCluster(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// StopDedicatedClusterRequest is the request struct for api StopDedicatedCluster +type StopDedicatedClusterRequest struct { + *requests.RpcRequest + DedicatedClusterId string `position:"Query" name:"DedicatedClusterId"` + OwnerId string `position:"Query" name:"OwnerId"` + DedicatedClusterName string `position:"Query" name:"DedicatedClusterName"` + InstanceId string `position:"Query" name:"InstanceId"` +} + +// StopDedicatedClusterResponse is the response struct for api StopDedicatedCluster +type StopDedicatedClusterResponse struct { + *responses.BaseResponse + HttpStatusCode string `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateStopDedicatedClusterRequest creates a request to invoke StopDedicatedCluster API +func CreateStopDedicatedClusterRequest() (request *StopDedicatedClusterRequest) { + request = &StopDedicatedClusterRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "StopDedicatedCluster", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateStopDedicatedClusterResponse creates a response to parse from StopDedicatedCluster response +func CreateStopDedicatedClusterResponse() (response *StopDedicatedClusterResponse) { + response = &StopDedicatedClusterResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/stop_dts_job.go b/services/dts/stop_dts_job.go new file mode 100644 index 0000000000..2a79ea06d4 --- /dev/null +++ b/services/dts/stop_dts_job.go @@ -0,0 +1,107 @@ +package dts + +//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" +) + +// StopDtsJob invokes the dts.StopDtsJob API synchronously +func (client *Client) StopDtsJob(request *StopDtsJobRequest) (response *StopDtsJobResponse, err error) { + response = CreateStopDtsJobResponse() + err = client.DoAction(request, response) + return +} + +// StopDtsJobWithChan invokes the dts.StopDtsJob API asynchronously +func (client *Client) StopDtsJobWithChan(request *StopDtsJobRequest) (<-chan *StopDtsJobResponse, <-chan error) { + responseChan := make(chan *StopDtsJobResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.StopDtsJob(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// StopDtsJobWithCallback invokes the dts.StopDtsJob API asynchronously +func (client *Client) StopDtsJobWithCallback(request *StopDtsJobRequest, callback func(response *StopDtsJobResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *StopDtsJobResponse + var err error + defer close(result) + response, err = client.StopDtsJob(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// StopDtsJobRequest is the request struct for api StopDtsJob +type StopDtsJobRequest struct { + *requests.RpcRequest + DtsJobId string `position:"Query" name:"DtsJobId"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` + SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` +} + +// StopDtsJobResponse is the response struct for api StopDtsJob +type StopDtsJobResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` +} + +// CreateStopDtsJobRequest creates a request to invoke StopDtsJob API +func CreateStopDtsJobRequest() (request *StopDtsJobRequest) { + request = &StopDtsJobRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "StopDtsJob", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateStopDtsJobResponse creates a response to parse from StopDtsJob response +func CreateStopDtsJobResponse() (response *StopDtsJobResponse) { + response = &StopDtsJobResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/stop_dts_jobs.go b/services/dts/stop_dts_jobs.go new file mode 100644 index 0000000000..fd32287a8d --- /dev/null +++ b/services/dts/stop_dts_jobs.go @@ -0,0 +1,105 @@ +package dts + +//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" +) + +// StopDtsJobs invokes the dts.StopDtsJobs API synchronously +func (client *Client) StopDtsJobs(request *StopDtsJobsRequest) (response *StopDtsJobsResponse, err error) { + response = CreateStopDtsJobsResponse() + err = client.DoAction(request, response) + return +} + +// StopDtsJobsWithChan invokes the dts.StopDtsJobs API asynchronously +func (client *Client) StopDtsJobsWithChan(request *StopDtsJobsRequest) (<-chan *StopDtsJobsResponse, <-chan error) { + responseChan := make(chan *StopDtsJobsResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.StopDtsJobs(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// StopDtsJobsWithCallback invokes the dts.StopDtsJobs API asynchronously +func (client *Client) StopDtsJobsWithCallback(request *StopDtsJobsRequest, callback func(response *StopDtsJobsResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *StopDtsJobsResponse + var err error + defer close(result) + response, err = client.StopDtsJobs(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// StopDtsJobsRequest is the request struct for api StopDtsJobs +type StopDtsJobsRequest struct { + *requests.RpcRequest + DtsJobIds string `position:"Query" name:"DtsJobIds"` +} + +// StopDtsJobsResponse is the response struct for api StopDtsJobs +type StopDtsJobsResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` +} + +// CreateStopDtsJobsRequest creates a request to invoke StopDtsJobs API +func CreateStopDtsJobsRequest() (request *StopDtsJobsRequest) { + request = &StopDtsJobsRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "StopDtsJobs", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateStopDtsJobsResponse creates a response to parse from StopDtsJobs response +func CreateStopDtsJobsResponse() (response *StopDtsJobsResponse) { + response = &StopDtsJobsResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/stop_migration_job.go b/services/dts/stop_migration_job.go new file mode 100644 index 0000000000..6a142f8b57 --- /dev/null +++ b/services/dts/stop_migration_job.go @@ -0,0 +1,105 @@ +package dts + +//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" +) + +// StopMigrationJob invokes the dts.StopMigrationJob API synchronously +func (client *Client) StopMigrationJob(request *StopMigrationJobRequest) (response *StopMigrationJobResponse, err error) { + response = CreateStopMigrationJobResponse() + err = client.DoAction(request, response) + return +} + +// StopMigrationJobWithChan invokes the dts.StopMigrationJob API asynchronously +func (client *Client) StopMigrationJobWithChan(request *StopMigrationJobRequest) (<-chan *StopMigrationJobResponse, <-chan error) { + responseChan := make(chan *StopMigrationJobResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.StopMigrationJob(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// StopMigrationJobWithCallback invokes the dts.StopMigrationJob API asynchronously +func (client *Client) StopMigrationJobWithCallback(request *StopMigrationJobRequest, callback func(response *StopMigrationJobResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *StopMigrationJobResponse + var err error + defer close(result) + response, err = client.StopMigrationJob(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// StopMigrationJobRequest is the request struct for api StopMigrationJob +type StopMigrationJobRequest struct { + *requests.RpcRequest + ClientToken string `position:"Query" name:"ClientToken"` + MigrationJobId string `position:"Query" name:"MigrationJobId"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` +} + +// StopMigrationJobResponse is the response struct for api StopMigrationJob +type StopMigrationJobResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateStopMigrationJobRequest creates a request to invoke StopMigrationJob API +func CreateStopMigrationJobRequest() (request *StopMigrationJobRequest) { + request = &StopMigrationJobRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "StopMigrationJob", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateStopMigrationJobResponse creates a response to parse from StopMigrationJob response +func CreateStopMigrationJobResponse() (response *StopMigrationJobResponse) { + response = &StopMigrationJobResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/struct_analysis_job_progress.go b/services/dts/struct_analysis_job_progress.go new file mode 100644 index 0000000000..c752d75549 --- /dev/null +++ b/services/dts/struct_analysis_job_progress.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// AnalysisJobProgress is a nested struct in dts response +type AnalysisJobProgress struct { + AnalysisProgressInfo []AnalysisProgressInfo `json:"AnalysisProgressInfo" xml:"AnalysisProgressInfo"` +} diff --git a/services/dts/struct_analysis_progress_info.go b/services/dts/struct_analysis_progress_info.go new file mode 100644 index 0000000000..d71dc4af35 --- /dev/null +++ b/services/dts/struct_analysis_progress_info.go @@ -0,0 +1,45 @@ +package dts + +//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. + +// AnalysisProgressInfo is a nested struct in dts response +type AnalysisProgressInfo struct { + Skip bool `json:"Skip" xml:"Skip"` + FinishTime string `json:"FinishTime" xml:"FinishTime"` + IgnoreFlag string `json:"IgnoreFlag" xml:"IgnoreFlag"` + DelaySeconds int `json:"DelaySeconds" xml:"DelaySeconds"` + DdlSql string `json:"DdlSql" xml:"DdlSql"` + State string `json:"State" xml:"State"` + BootTime string `json:"BootTime" xml:"BootTime"` + Item string `json:"Item" xml:"Item"` + Sub string `json:"Sub" xml:"Sub"` + Total int `json:"Total" xml:"Total"` + TargetNames string `json:"TargetNames" xml:"TargetNames"` + CanSkip bool `json:"CanSkip" xml:"CanSkip"` + Names string `json:"Names" xml:"Names"` + ErrDetail string `json:"ErrDetail" xml:"ErrDetail"` + DiffRow int64 `json:"DiffRow" xml:"DiffRow"` + JobId string `json:"JobId" xml:"JobId"` + SourceSchema string `json:"SourceSchema" xml:"SourceSchema"` + DestSchema string `json:"DestSchema" xml:"DestSchema"` + ParentObj string `json:"ParentObj" xml:"ParentObj"` + ErrMsg string `json:"ErrMsg" xml:"ErrMsg"` + OrderNum int `json:"OrderNum" xml:"OrderNum"` + RepairMethod string `json:"RepairMethod" xml:"RepairMethod"` + Id string `json:"Id" xml:"Id"` + Current string `json:"Current" xml:"Current"` + Logs []JobLog `json:"Logs" xml:"Logs"` +} diff --git a/services/dts/struct_check_jobs.go b/services/dts/struct_check_jobs.go new file mode 100644 index 0000000000..527d8cd0b4 --- /dev/null +++ b/services/dts/struct_check_jobs.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// CheckJobs is a nested struct in dts response +type CheckJobs struct { + CheckJobsItem []CheckJobsItem `json:"checkJobs" xml:"checkJobs"` +} diff --git a/services/dts/struct_check_jobs_item.go b/services/dts/struct_check_jobs_item.go new file mode 100644 index 0000000000..fd7ddbce8e --- /dev/null +++ b/services/dts/struct_check_jobs_item.go @@ -0,0 +1,36 @@ +package dts + +//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. + +// CheckJobsItem is a nested struct in dts response +type CheckJobsItem struct { + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + JobStepId string `json:"JobStepId" xml:"JobStepId"` + JobName string `json:"JobName" xml:"JobName"` + Status int `json:"Status" xml:"Status"` + CheckType int `json:"CheckType" xml:"CheckType"` + InstanceClass string `json:"InstanceClass" xml:"InstanceClass"` + CheckPoint int64 `json:"CheckPoint" xml:"CheckPoint"` + TotalCount int64 `json:"TotalCount" xml:"TotalCount"` + DiffCount int64 `json:"DiffCount" xml:"DiffCount"` + DiffSum int64 `json:"DiffSum" xml:"DiffSum"` + FinishCount int64 `json:"FinishCount" xml:"FinishCount"` + GroupId string `json:"GroupId" xml:"GroupId"` + DtsInstanceID string `json:"DtsInstanceID" xml:"DtsInstanceID"` + ChargeType string `json:"ChargeType" xml:"ChargeType"` + ParentJobType string `json:"ParentJobType" xml:"ParentJobType"` + RegionId string `json:"RegionId" xml:"RegionId"` +} diff --git a/services/dts/struct_constraint_list.go b/services/dts/struct_constraint_list.go new file mode 100644 index 0000000000..ec10c8c277 --- /dev/null +++ b/services/dts/struct_constraint_list.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// ConstraintList is a nested struct in dts response +type ConstraintList struct { + StructureInitializationDetail []StructureInitializationDetail `json:"StructureInitializationDetail" xml:"StructureInitializationDetail"` +} diff --git a/services/dts/struct_constraints.go b/services/dts/struct_constraints.go new file mode 100644 index 0000000000..64d06bd7b1 --- /dev/null +++ b/services/dts/struct_constraints.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// Constraints is a nested struct in dts response +type Constraints struct { + StructureInitializationDetail []StructureInitializationDetail `json:"StructureInitializationDetail" xml:"StructureInitializationDetail"` +} diff --git a/services/dts/struct_consumer_channel.go b/services/dts/struct_consumer_channel.go new file mode 100644 index 0000000000..5aefed6818 --- /dev/null +++ b/services/dts/struct_consumer_channel.go @@ -0,0 +1,26 @@ +package dts + +//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. + +// ConsumerChannel is a nested struct in dts response +type ConsumerChannel struct { + ConsumerGroupUserName string `json:"ConsumerGroupUserName" xml:"ConsumerGroupUserName"` + ConsumerGroupId string `json:"ConsumerGroupId" xml:"ConsumerGroupId"` + MessageDelay int64 `json:"MessageDelay" xml:"MessageDelay"` + ConsumerGroupName string `json:"ConsumerGroupName" xml:"ConsumerGroupName"` + ConsumptionCheckpoint string `json:"ConsumptionCheckpoint" xml:"ConsumptionCheckpoint"` + UnconsumedData int64 `json:"UnconsumedData" xml:"UnconsumedData"` +} diff --git a/services/dts/struct_consumer_channels_in_describe_consumer_channel.go b/services/dts/struct_consumer_channels_in_describe_consumer_channel.go new file mode 100644 index 0000000000..c7569c6fe5 --- /dev/null +++ b/services/dts/struct_consumer_channels_in_describe_consumer_channel.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// ConsumerChannelsInDescribeConsumerChannel is a nested struct in dts response +type ConsumerChannelsInDescribeConsumerChannel struct { + ConsumerChannel []ConsumerChannel `json:"ConsumerChannel" xml:"ConsumerChannel"` +} diff --git a/services/dts/struct_consumer_channels_in_describe_consumer_group.go b/services/dts/struct_consumer_channels_in_describe_consumer_group.go new file mode 100644 index 0000000000..cd1eedef36 --- /dev/null +++ b/services/dts/struct_consumer_channels_in_describe_consumer_group.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// ConsumerChannelsInDescribeConsumerGroup is a nested struct in dts response +type ConsumerChannelsInDescribeConsumerGroup struct { + DescribeConsumerChannel []DescribeConsumerChannel `json:"DescribeConsumerChannel" xml:"DescribeConsumerChannel"` +} diff --git a/services/dts/struct_data_cloud_status.go b/services/dts/struct_data_cloud_status.go new file mode 100644 index 0000000000..9fbb46138a --- /dev/null +++ b/services/dts/struct_data_cloud_status.go @@ -0,0 +1,25 @@ +package dts + +//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. + +// DataCloudStatus is a nested struct in dts response +type DataCloudStatus struct { + Status string `json:"Status" xml:"Status"` + NeedUpgrade bool `json:"NeedUpgrade" xml:"NeedUpgrade"` + Percent string `json:"Percent" xml:"Percent"` + Progress string `json:"Progress" xml:"Progress"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` +} diff --git a/services/dts/struct_data_delivery_channel_info.go b/services/dts/struct_data_delivery_channel_info.go new file mode 100644 index 0000000000..82f55ca30f --- /dev/null +++ b/services/dts/struct_data_delivery_channel_info.go @@ -0,0 +1,25 @@ +package dts + +//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. + +// DataDeliveryChannelInfo is a nested struct in dts response +type DataDeliveryChannelInfo struct { + PublicDproxyUrl string `json:"PublicDproxyUrl" xml:"PublicDproxyUrl"` + VpcDproxyUrl string `json:"VpcDproxyUrl" xml:"VpcDproxyUrl"` + Topic string `json:"Topic" xml:"Topic"` + Region string `json:"Region" xml:"Region"` + PartitionNum int `json:"PartitionNum" xml:"PartitionNum"` +} diff --git a/services/dts/struct_data_etl_status.go b/services/dts/struct_data_etl_status.go new file mode 100644 index 0000000000..1e1f72d5b6 --- /dev/null +++ b/services/dts/struct_data_etl_status.go @@ -0,0 +1,25 @@ +package dts + +//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. + +// DataEtlStatus is a nested struct in dts response +type DataEtlStatus struct { + Progress string `json:"Progress" xml:"Progress"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + Status string `json:"Status" xml:"Status"` + Percent string `json:"Percent" xml:"Percent"` + NeedUpgrade bool `json:"NeedUpgrade" xml:"NeedUpgrade"` +} diff --git a/services/dts/struct_data_initialization.go b/services/dts/struct_data_initialization.go new file mode 100644 index 0000000000..dfd992971f --- /dev/null +++ b/services/dts/struct_data_initialization.go @@ -0,0 +1,24 @@ +package dts + +//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. + +// DataInitialization is a nested struct in dts response +type DataInitialization struct { + Percent string `json:"Percent" xml:"Percent"` + Status string `json:"status" xml:"status"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + Progress string `json:"Progress" xml:"Progress"` +} diff --git a/services/dts/struct_data_initialization_detail.go b/services/dts/struct_data_initialization_detail.go new file mode 100644 index 0000000000..a96a7903e0 --- /dev/null +++ b/services/dts/struct_data_initialization_detail.go @@ -0,0 +1,29 @@ +package dts + +//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. + +// DataInitializationDetail is a nested struct in dts response +type DataInitializationDetail struct { + SourceOwnerDBName string `json:"SourceOwnerDBName" xml:"SourceOwnerDBName"` + FinishRowNum string `json:"FinishRowNum" xml:"FinishRowNum"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + TotalRowNum string `json:"TotalRowNum" xml:"TotalRowNum"` + MigrationTime string `json:"MigrationTime" xml:"MigrationTime"` + DestinationOwnerDBName string `json:"DestinationOwnerDBName" xml:"DestinationOwnerDBName"` + Status string `json:"Status" xml:"Status"` + UsedTime string `json:"UsedTime" xml:"UsedTime"` + TableName string `json:"TableName" xml:"TableName"` +} diff --git a/services/dts/struct_data_initialization_detail_list.go b/services/dts/struct_data_initialization_detail_list.go new file mode 100644 index 0000000000..f1da5c4f5d --- /dev/null +++ b/services/dts/struct_data_initialization_detail_list.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// DataInitializationDetailList is a nested struct in dts response +type DataInitializationDetailList struct { + DataInitializationDetail []DataInitializationDetail `json:"DataInitializationDetail" xml:"DataInitializationDetail"` +} diff --git a/services/dts/struct_data_initialization_details.go b/services/dts/struct_data_initialization_details.go new file mode 100644 index 0000000000..92c46fa459 --- /dev/null +++ b/services/dts/struct_data_initialization_details.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// DataInitializationDetails is a nested struct in dts response +type DataInitializationDetails struct { + DataInitializationDetail []DataInitializationDetail `json:"DataInitializationDetail" xml:"DataInitializationDetail"` +} diff --git a/services/dts/struct_data_initialization_status.go b/services/dts/struct_data_initialization_status.go index 3fd0f5dcc0..a388fba5c7 100644 --- a/services/dts/struct_data_initialization_status.go +++ b/services/dts/struct_data_initialization_status.go @@ -21,4 +21,5 @@ type DataInitializationStatus struct { ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` Status string `json:"Status" xml:"Status"` Percent string `json:"Percent" xml:"Percent"` + NeedUpgrade bool `json:"NeedUpgrade" xml:"NeedUpgrade"` } diff --git a/services/dts/struct_data_point.go b/services/dts/struct_data_point.go new file mode 100644 index 0000000000..6144d149a8 --- /dev/null +++ b/services/dts/struct_data_point.go @@ -0,0 +1,30 @@ +package dts + +//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. + +// DataPoint is a nested struct in dts response +type DataPoint struct { + NewValue string `json:"NewValue" xml:"NewValue"` + LogDatetime int64 `json:"LogDatetime" xml:"LogDatetime"` + Statistics float64 `json:"Statistics" xml:"Statistics"` + Content string `json:"Content" xml:"Content"` + Timestamp int64 `json:"Timestamp" xml:"Timestamp"` + OldValue string `json:"OldValue" xml:"OldValue"` + Success int `json:"Success" xml:"Success"` + Id string `json:"Id" xml:"Id"` + OperationUser string `json:"OperationUser" xml:"OperationUser"` + OperationName string `json:"OperationName" xml:"OperationName"` +} diff --git a/services/dts/struct_data_points_in_describe_cluster_operate_logs.go b/services/dts/struct_data_points_in_describe_cluster_operate_logs.go new file mode 100644 index 0000000000..2b44539f3a --- /dev/null +++ b/services/dts/struct_data_points_in_describe_cluster_operate_logs.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// DataPointsInDescribeClusterOperateLogs is a nested struct in dts response +type DataPointsInDescribeClusterOperateLogs struct { + DataPoint []DataPoint `json:"DataPoint" xml:"DataPoint"` +} diff --git a/services/dts/struct_data_points_in_describe_metric_list.go b/services/dts/struct_data_points_in_describe_metric_list.go new file mode 100644 index 0000000000..4fc0409560 --- /dev/null +++ b/services/dts/struct_data_points_in_describe_metric_list.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// DataPointsInDescribeMetricList is a nested struct in dts response +type DataPointsInDescribeMetricList struct { + DataPoint []DataPoint `json:"DataPoint" xml:"DataPoint"` +} diff --git a/services/dts/struct_data_synchronization.go b/services/dts/struct_data_synchronization.go new file mode 100644 index 0000000000..c55e43eaaa --- /dev/null +++ b/services/dts/struct_data_synchronization.go @@ -0,0 +1,24 @@ +package dts + +//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. + +// DataSynchronization is a nested struct in dts response +type DataSynchronization struct { + Delay string `json:"Delay" xml:"Delay"` + Percent string `json:"Percent" xml:"Percent"` + Status string `json:"status" xml:"status"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` +} diff --git a/services/dts/struct_data_synchronization_detail.go b/services/dts/struct_data_synchronization_detail.go new file mode 100644 index 0000000000..add93ea4d2 --- /dev/null +++ b/services/dts/struct_data_synchronization_detail.go @@ -0,0 +1,25 @@ +package dts + +//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. + +// DataSynchronizationDetail is a nested struct in dts response +type DataSynchronizationDetail struct { + SourceOwnerDBName string `json:"SourceOwnerDBName" xml:"SourceOwnerDBName"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + DestinationOwnerDBName string `json:"DestinationOwnerDBName" xml:"DestinationOwnerDBName"` + Status string `json:"Status" xml:"Status"` + TableName string `json:"TableName" xml:"TableName"` +} diff --git a/services/dts/struct_data_synchronization_detail_list.go b/services/dts/struct_data_synchronization_detail_list.go new file mode 100644 index 0000000000..c2542f4813 --- /dev/null +++ b/services/dts/struct_data_synchronization_detail_list.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// DataSynchronizationDetailList is a nested struct in dts response +type DataSynchronizationDetailList struct { + DataSynchronizationDetail []DataSynchronizationDetail `json:"DataSynchronizationDetail" xml:"DataSynchronizationDetail"` +} diff --git a/services/dts/struct_data_synchronization_details.go b/services/dts/struct_data_synchronization_details.go new file mode 100644 index 0000000000..e8a2dfe3fd --- /dev/null +++ b/services/dts/struct_data_synchronization_details.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// DataSynchronizationDetails is a nested struct in dts response +type DataSynchronizationDetails struct { + DataSynchronizationDetail []DataSynchronizationDetail `json:"DataSynchronizationDetail" xml:"DataSynchronizationDetail"` +} diff --git a/services/dts/struct_data_synchronization_status.go b/services/dts/struct_data_synchronization_status.go index 7dc9ebfbd9..e2d8e5d5a9 100644 --- a/services/dts/struct_data_synchronization_status.go +++ b/services/dts/struct_data_synchronization_status.go @@ -17,9 +17,12 @@ package dts // DataSynchronizationStatus is a nested struct in dts response type DataSynchronizationStatus struct { + Progress string `json:"Progress" xml:"Progress"` Delay string `json:"Delay" xml:"Delay"` Checkpoint string `json:"Checkpoint" xml:"Checkpoint"` ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` Status string `json:"Status" xml:"Status"` Percent string `json:"Percent" xml:"Percent"` + NeedUpgrade bool `json:"NeedUpgrade" xml:"NeedUpgrade"` + DelayMillis int64 `json:"DelayMillis" xml:"DelayMillis"` } diff --git a/services/dts/struct_dedicated_cluster_status.go b/services/dts/struct_dedicated_cluster_status.go new file mode 100644 index 0000000000..d3e4e4a3d0 --- /dev/null +++ b/services/dts/struct_dedicated_cluster_status.go @@ -0,0 +1,40 @@ +package dts + +//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. + +// DedicatedClusterStatus is a nested struct in dts response +type DedicatedClusterStatus struct { + DtsInstanceID string `json:"DtsInstanceID" xml:"DtsInstanceID"` + DedicatedClusterId string `json:"DedicatedClusterId" xml:"DedicatedClusterId"` + DedicatedClusterName string `json:"DedicatedClusterName" xml:"DedicatedClusterName"` + Du int64 `json:"Du" xml:"Du"` + OversoldDu int64 `json:"OversoldDu" xml:"OversoldDu"` + UsedDu int64 `json:"UsedDu" xml:"UsedDu"` + State string `json:"State" xml:"State"` + RegionId string `json:"RegionId" xml:"RegionId"` + GmtCreated int64 `json:"GmtCreated" xml:"GmtCreated"` + NodeCount int64 `json:"NodeCount" xml:"NodeCount"` + DuUtilization int64 `json:"DuUtilization" xml:"DuUtilization"` + CpuUtilization int64 `json:"CpuUtilization" xml:"CpuUtilization"` + TotalCpuCore int64 `json:"TotalCpuCore" xml:"TotalCpuCore"` + UsedCpuCore int64 `json:"UsedCpuCore" xml:"UsedCpuCore"` + MemUtilization int64 `json:"MemUtilization" xml:"MemUtilization"` + TotalMemGBSize int64 `json:"TotalMemGBSize" xml:"TotalMemGBSize"` + UsedMemGBSize int64 `json:"UsedMemGBSize" xml:"UsedMemGBSize"` + DiskUtilization int64 `json:"DiskUtilization" xml:"DiskUtilization"` + TotalDiskGBSize int64 `json:"TotalDiskGBSize" xml:"TotalDiskGBSize"` + UsedDiskGBSize int64 `json:"UsedDiskGBSize" xml:"UsedDiskGBSize"` +} diff --git a/services/dts/struct_dedicated_cluster_status_list.go b/services/dts/struct_dedicated_cluster_status_list.go new file mode 100644 index 0000000000..7ed1314606 --- /dev/null +++ b/services/dts/struct_dedicated_cluster_status_list.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// DedicatedClusterStatusList is a nested struct in dts response +type DedicatedClusterStatusList struct { + DedicatedClusterStatus []DedicatedClusterStatus `json:"DedicatedClusterStatus" xml:"DedicatedClusterStatus"` +} diff --git a/services/dts/struct_describe_consumer_channel.go b/services/dts/struct_describe_consumer_channel.go new file mode 100644 index 0000000000..0d5724a0e5 --- /dev/null +++ b/services/dts/struct_describe_consumer_channel.go @@ -0,0 +1,26 @@ +package dts + +//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. + +// DescribeConsumerChannel is a nested struct in dts response +type DescribeConsumerChannel struct { + ConsumerGroupUserName string `json:"ConsumerGroupUserName" xml:"ConsumerGroupUserName"` + ConsumerGroupID string `json:"ConsumerGroupID" xml:"ConsumerGroupID"` + MessageDelay int64 `json:"MessageDelay" xml:"MessageDelay"` + ConsumerGroupName string `json:"ConsumerGroupName" xml:"ConsumerGroupName"` + ConsumptionCheckpoint string `json:"ConsumptionCheckpoint" xml:"ConsumptionCheckpoint"` + UnconsumedData int64 `json:"UnconsumedData" xml:"UnconsumedData"` +} diff --git a/services/dts/struct_destination_endpoint.go b/services/dts/struct_destination_endpoint.go index 54befe78af..0a9a09209b 100644 --- a/services/dts/struct_destination_endpoint.go +++ b/services/dts/struct_destination_endpoint.go @@ -17,10 +17,19 @@ package dts // DestinationEndpoint is a nested struct in dts response type DestinationEndpoint struct { - EngineName string `json:"EngineName" xml:"EngineName"` - Port string `json:"Port" xml:"Port"` - InstanceId string `json:"InstanceId" xml:"InstanceId"` - IP string `json:"IP" xml:"IP"` - UserName string `json:"UserName" xml:"UserName"` - InstanceType string `json:"InstanceType" xml:"InstanceType"` + Region string `json:"Region" xml:"Region"` + SslSolutionEnum string `json:"SslSolutionEnum" xml:"SslSolutionEnum"` + Port string `json:"Port" xml:"Port"` + Ip string `json:"Ip" xml:"Ip"` + CanModifyPassword bool `json:"CanModifyPassword" xml:"CanModifyPassword"` + IP string `json:"IP" xml:"IP"` + OracleSID string `json:"OracleSID" xml:"OracleSID"` + InstanceType string `json:"InstanceType" xml:"InstanceType"` + RoleName string `json:"RoleName" xml:"RoleName"` + EngineName string `json:"EngineName" xml:"EngineName"` + InstanceID string `json:"InstanceID" xml:"InstanceID"` + InstanceId string `json:"InstanceId" xml:"InstanceId"` + AliyunUid string `json:"AliyunUid" xml:"AliyunUid"` + UserName string `json:"UserName" xml:"UserName"` + DatabaseName string `json:"DatabaseName" xml:"DatabaseName"` } diff --git a/services/dts/struct_detail_in_describe_dts_job_detail.go b/services/dts/struct_detail_in_describe_dts_job_detail.go new file mode 100644 index 0000000000..57ae0a67bb --- /dev/null +++ b/services/dts/struct_detail_in_describe_dts_job_detail.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// DetailInDescribeDtsJobDetail is a nested struct in dts response +type DetailInDescribeDtsJobDetail struct { + DetailItem []DetailItem `json:"Detail" xml:"Detail"` +} diff --git a/services/dts/struct_detail_in_describe_dts_jobs.go b/services/dts/struct_detail_in_describe_dts_jobs.go new file mode 100644 index 0000000000..f38fdee01a --- /dev/null +++ b/services/dts/struct_detail_in_describe_dts_jobs.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// DetailInDescribeDtsJobs is a nested struct in dts response +type DetailInDescribeDtsJobs struct { + PrecheckDetail []PrecheckDetail `json:"PrecheckDetail" xml:"PrecheckDetail"` +} diff --git a/services/dts/struct_detail_in_describe_migration_job_status.go b/services/dts/struct_detail_in_describe_migration_job_status.go new file mode 100644 index 0000000000..3fbf3e0455 --- /dev/null +++ b/services/dts/struct_detail_in_describe_migration_job_status.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// DetailInDescribeMigrationJobStatus is a nested struct in dts response +type DetailInDescribeMigrationJobStatus struct { + CheckItem []CheckItem `json:"CheckItem" xml:"CheckItem"` +} diff --git a/services/dts/struct_detail_item.go b/services/dts/struct_detail_item.go new file mode 100644 index 0000000000..c054df0f4d --- /dev/null +++ b/services/dts/struct_detail_item.go @@ -0,0 +1,25 @@ +package dts + +//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. + +// DetailItem is a nested struct in dts response +type DetailItem struct { + RepairMethod string `json:"RepairMethod" xml:"RepairMethod"` + CheckResult string `json:"CheckResult" xml:"CheckResult"` + FailedReason string `json:"FailedReason" xml:"FailedReason"` + CheckItem string `json:"CheckItem" xml:"CheckItem"` + CheckItemDescription string `json:"CheckItemDescription" xml:"CheckItemDescription"` +} diff --git a/services/dts/struct_diff_details.go b/services/dts/struct_diff_details.go new file mode 100644 index 0000000000..65a143c107 --- /dev/null +++ b/services/dts/struct_diff_details.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// DiffDetails is a nested struct in dts response +type DiffDetails struct { + DiffDetailsItem []DiffDetailsItem `json:"DiffDetails" xml:"DiffDetails"` +} diff --git a/services/dts/struct_diff_details_item.go b/services/dts/struct_diff_details_item.go new file mode 100644 index 0000000000..bed425e38a --- /dev/null +++ b/services/dts/struct_diff_details_item.go @@ -0,0 +1,23 @@ +package dts + +//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. + +// DiffDetailsItem is a nested struct in dts response +type DiffDetailsItem struct { + Id int64 `json:"Id" xml:"Id"` + GmtCreated string `json:"GmtCreated" xml:"GmtCreated"` + Diff string `json:"Diff" xml:"Diff"` +} diff --git a/services/dts/struct_dts_etl_job_version_info.go b/services/dts/struct_dts_etl_job_version_info.go new file mode 100644 index 0000000000..5601b55039 --- /dev/null +++ b/services/dts/struct_dts_etl_job_version_info.go @@ -0,0 +1,30 @@ +package dts + +//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. + +// DtsEtlJobVersionInfo is a nested struct in dts response +type DtsEtlJobVersionInfo struct { + Status string `json:"Status" xml:"Status"` + DtsJobName string `json:"DtsJobName" xml:"DtsJobName"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + Version int `json:"Version" xml:"Version"` + DtsInstanceId string `json:"DtsInstanceId" xml:"DtsInstanceId"` + CreateTime string `json:"CreateTime" xml:"CreateTime"` + SafeCheckpoint string `json:"SafeCheckpoint" xml:"SafeCheckpoint"` + Creator string `json:"Creator" xml:"Creator"` + ModifyTime string `json:"ModifyTime" xml:"ModifyTime"` + CreatorName string `json:"CreatorName" xml:"CreatorName"` +} diff --git a/services/dts/struct_dts_etl_job_version_infos.go b/services/dts/struct_dts_etl_job_version_infos.go new file mode 100644 index 0000000000..46f5dd7dc7 --- /dev/null +++ b/services/dts/struct_dts_etl_job_version_infos.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// DtsEtlJobVersionInfos is a nested struct in dts response +type DtsEtlJobVersionInfos struct { + DtsEtlJobVersionInfo []DtsEtlJobVersionInfo `json:"DtsEtlJobVersionInfo" xml:"DtsEtlJobVersionInfo"` +} diff --git a/services/dts/struct_dts_job_list.go b/services/dts/struct_dts_job_list.go new file mode 100644 index 0000000000..f295a9aa5b --- /dev/null +++ b/services/dts/struct_dts_job_list.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// DtsJobList is a nested struct in dts response +type DtsJobList struct { + DtsJobStatus []DtsJobStatus `json:"DtsJobStatus" xml:"DtsJobStatus"` +} diff --git a/services/dts/struct_dts_job_status.go b/services/dts/struct_dts_job_status.go new file mode 100644 index 0000000000..1c018e8b6e --- /dev/null +++ b/services/dts/struct_dts_job_status.go @@ -0,0 +1,71 @@ +package dts + +//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. + +// DtsJobStatus is a nested struct in dts response +type DtsJobStatus struct { + DedicatedClusterId string `json:"DedicatedClusterId" xml:"DedicatedClusterId"` + OriginType string `json:"OriginType" xml:"OriginType"` + MigrationErrMsg string `json:"MigrationErrMsg" xml:"MigrationErrMsg"` + BeginTimestamp string `json:"BeginTimestamp" xml:"BeginTimestamp"` + MigrationErrType string `json:"MigrationErrType" xml:"MigrationErrType"` + Reserved string `json:"Reserved" xml:"Reserved"` + MigrationErrCode string `json:"MigrationErrCode" xml:"MigrationErrCode"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + DtsBisLabel string `json:"DtsBisLabel" xml:"DtsBisLabel"` + JobType string `json:"JobType" xml:"JobType"` + Checkpoint string `json:"Checkpoint" xml:"Checkpoint"` + PayType string `json:"PayType" xml:"PayType"` + DtsJobClass string `json:"DtsJobClass" xml:"DtsJobClass"` + CpuUsage string `json:"CpuUsage" xml:"CpuUsage"` + ResourceGroupDisplayName string `json:"ResourceGroupDisplayName" xml:"ResourceGroupDisplayName"` + Status string `json:"Status" xml:"Status"` + ConsumptionCheckpoint string `json:"ConsumptionCheckpoint" xml:"ConsumptionCheckpoint"` + DtsJobDirection string `json:"DtsJobDirection" xml:"DtsJobDirection"` + MemUsage string `json:"MemUsage" xml:"MemUsage"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + CreateTime string `json:"CreateTime" xml:"CreateTime"` + MigrationErrHelpDocKey string `json:"MigrationErrHelpDocKey" xml:"MigrationErrHelpDocKey"` + EndTimestamp string `json:"EndTimestamp" xml:"EndTimestamp"` + ConsumptionClient string `json:"ConsumptionClient" xml:"ConsumptionClient"` + DbObject string `json:"DbObject" xml:"DbObject"` + ResourceGroupId string `json:"ResourceGroupId" xml:"ResourceGroupId"` + Delay int64 `json:"Delay" xml:"Delay"` + MigrationErrHelpDocId string `json:"MigrationErrHelpDocId" xml:"MigrationErrHelpDocId"` + ExpireTime string `json:"ExpireTime" xml:"ExpireTime"` + DtsJobName string `json:"DtsJobName" xml:"DtsJobName"` + DuUsage int64 `json:"DuUsage" xml:"DuUsage"` + EtlSafeCheckpoint string `json:"EtlSafeCheckpoint" xml:"EtlSafeCheckpoint"` + AppName string `json:"AppName" xml:"AppName"` + MigrationErrWorkaround string `json:"MigrationErrWorkaround" xml:"MigrationErrWorkaround"` + DtsInstanceID string `json:"DtsInstanceID" xml:"DtsInstanceID"` + RetryState RetryState `json:"RetryState" xml:"RetryState"` + DataEtlStatus DataEtlStatus `json:"DataEtlStatus" xml:"DataEtlStatus"` + MigrationMode MigrationMode `json:"MigrationMode" xml:"MigrationMode"` + ReverseJob ReverseJob `json:"ReverseJob" xml:"ReverseJob"` + DataSynchronizationStatus DataSynchronizationStatus `json:"DataSynchronizationStatus" xml:"DataSynchronizationStatus"` + SourceEndpoint SourceEndpoint `json:"SourceEndpoint" xml:"SourceEndpoint"` + DataInitializationStatus DataInitializationStatus `json:"DataInitializationStatus" xml:"DataInitializationStatus"` + DataCloudStatus DataCloudStatus `json:"DataCloudStatus" xml:"DataCloudStatus"` + DestinationEndpoint DestinationEndpoint `json:"DestinationEndpoint" xml:"DestinationEndpoint"` + StructureInitializationStatus StructureInitializationStatus `json:"StructureInitializationStatus" xml:"StructureInitializationStatus"` + IncDataCheckStatus IncDataCheckStatus `json:"IncDataCheckStatus" xml:"IncDataCheckStatus"` + PrecheckStatus PrecheckStatusInDescribeDtsJobs `json:"PrecheckStatus" xml:"PrecheckStatus"` + Performance Performance `json:"Performance" xml:"Performance"` + FullDataCheckStatus FullDataCheckStatus `json:"FullDataCheckStatus" xml:"FullDataCheckStatus"` + TagList []DtsTag `json:"TagList" xml:"TagList"` + ErrorDetails []ErrorDetail `json:"ErrorDetails" xml:"ErrorDetails"` +} diff --git a/services/dts/struct_dts_tag.go b/services/dts/struct_dts_tag.go new file mode 100644 index 0000000000..49e25684ff --- /dev/null +++ b/services/dts/struct_dts_tag.go @@ -0,0 +1,22 @@ +package dts + +//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. + +// DtsTag is a nested struct in dts response +type DtsTag struct { + TagValue string `json:"TagValue" xml:"TagValue"` + TagKey string `json:"TagKey" xml:"TagKey"` +} diff --git a/services/dts/struct_error_detail.go b/services/dts/struct_error_detail.go new file mode 100644 index 0000000000..a3a2c3043e --- /dev/null +++ b/services/dts/struct_error_detail.go @@ -0,0 +1,22 @@ +package dts + +//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. + +// ErrorDetail is a nested struct in dts response +type ErrorDetail struct { + HelpUrl string `json:"HelpUrl" xml:"HelpUrl"` + ErrorCode string `json:"ErrorCode" xml:"ErrorCode"` +} diff --git a/services/dts/struct_error_details_in_describe_dts_jobs.go b/services/dts/struct_error_details_in_describe_dts_jobs.go new file mode 100644 index 0000000000..5a60f56d3d --- /dev/null +++ b/services/dts/struct_error_details_in_describe_dts_jobs.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// ErrorDetailsInDescribeDtsJobs is a nested struct in dts response +type ErrorDetailsInDescribeDtsJobs struct { + ErrorDetail []ErrorDetail `json:"ErrorDetail" xml:"ErrorDetail"` +} diff --git a/services/dts/struct_etl_demo_list.go b/services/dts/struct_etl_demo_list.go new file mode 100644 index 0000000000..29e5a730e2 --- /dev/null +++ b/services/dts/struct_etl_demo_list.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// EtlDemoList is a nested struct in dts response +type EtlDemoList struct { + DtsJobStatus []DtsJobStatus `json:"DtsJobStatus" xml:"DtsJobStatus"` +} diff --git a/services/dts/struct_etl_running_log.go b/services/dts/struct_etl_running_log.go new file mode 100644 index 0000000000..594d06399a --- /dev/null +++ b/services/dts/struct_etl_running_log.go @@ -0,0 +1,26 @@ +package dts + +//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. + +// EtlRunningLog is a nested struct in dts response +type EtlRunningLog struct { + EtlId string `json:"EtlId" xml:"EtlId"` + UserId string `json:"UserId" xml:"UserId"` + ContentKey string `json:"ContentKey" xml:"ContentKey"` + Content string `json:"Content" xml:"Content"` + Status string `json:"Status" xml:"Status"` + LogDatetime string `json:"LogDatetime" xml:"LogDatetime"` +} diff --git a/services/dts/struct_etl_running_logs.go b/services/dts/struct_etl_running_logs.go new file mode 100644 index 0000000000..b5d2d2b009 --- /dev/null +++ b/services/dts/struct_etl_running_logs.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// EtlRunningLogs is a nested struct in dts response +type EtlRunningLogs struct { + EtlRunningLog []EtlRunningLog `json:"EtlRunningLog" xml:"EtlRunningLog"` +} diff --git a/services/dts/struct_full_data_check_status.go b/services/dts/struct_full_data_check_status.go new file mode 100644 index 0000000000..51fa458372 --- /dev/null +++ b/services/dts/struct_full_data_check_status.go @@ -0,0 +1,24 @@ +package dts + +//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. + +// FullDataCheckStatus is a nested struct in dts response +type FullDataCheckStatus struct { + Status string `json:"Status" xml:"Status"` + Percent string `json:"Percent" xml:"Percent"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + Progress string `json:"Progress" xml:"Progress"` +} diff --git a/services/dts/struct_full_net_check_job_status.go b/services/dts/struct_full_net_check_job_status.go new file mode 100644 index 0000000000..4e40f7ca6f --- /dev/null +++ b/services/dts/struct_full_net_check_job_status.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// FullNetCheckJobStatus is a nested struct in dts response +type FullNetCheckJobStatus struct { + FullNetCheckJobStatusItem []FullNetCheckJobStatusItem `json:"FullNetCheckJobStatus" xml:"FullNetCheckJobStatus"` +} diff --git a/services/dts/struct_full_net_check_job_status_item.go b/services/dts/struct_full_net_check_job_status_item.go new file mode 100644 index 0000000000..8aa42fbfdd --- /dev/null +++ b/services/dts/struct_full_net_check_job_status_item.go @@ -0,0 +1,34 @@ +package dts + +//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. + +// FullNetCheckJobStatusItem is a nested struct in dts response +type FullNetCheckJobStatusItem struct { + JobName string `json:"JobName" xml:"JobName"` + State string `json:"State" xml:"State"` + JobId string `json:"JobId" xml:"JobId"` + ErrorItem int `json:"ErrorItem" xml:"ErrorItem"` + Code string `json:"Code" xml:"Code"` + Total int `json:"Total" xml:"Total"` + HostRegion string `json:"HostRegion" xml:"HostRegion"` + SrcRegion string `json:"SrcRegion" xml:"SrcRegion"` + DestRegion string `json:"DestRegion" xml:"DestRegion"` + SrcRegionCidr string `json:"SrcRegionCidr" xml:"SrcRegionCidr"` + DestRegionCidr string `json:"DestRegionCidr" xml:"DestRegionCidr"` + SourceEndpointType string `json:"SourceEndpointType" xml:"SourceEndpointType"` + DestinationEndpointType string `json:"DestinationEndpointType" xml:"DestinationEndpointType"` + JobProgress []ProgressInfo `json:"JobProgress" xml:"JobProgress"` +} diff --git a/services/dts/struct_inc_data_check_status.go b/services/dts/struct_inc_data_check_status.go new file mode 100644 index 0000000000..4316a63516 --- /dev/null +++ b/services/dts/struct_inc_data_check_status.go @@ -0,0 +1,24 @@ +package dts + +//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. + +// IncDataCheckStatus is a nested struct in dts response +type IncDataCheckStatus struct { + Status string `json:"Status" xml:"Status"` + Percent string `json:"Percent" xml:"Percent"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + Progress string `json:"Progress" xml:"Progress"` +} diff --git a/services/dts/struct_job_log.go b/services/dts/struct_job_log.go new file mode 100644 index 0000000000..b86e304841 --- /dev/null +++ b/services/dts/struct_job_log.go @@ -0,0 +1,24 @@ +package dts + +//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. + +// JobLog is a nested struct in dts response +type JobLog struct { + ErrMsg string `json:"ErrMsg" xml:"ErrMsg"` + ErrData string `json:"ErrData" xml:"ErrData"` + LogLevel string `json:"LogLevel" xml:"LogLevel"` + ErrType string `json:"ErrType" xml:"ErrType"` +} diff --git a/services/dts/struct_job_progress_in_describe_pre_check_status.go b/services/dts/struct_job_progress_in_describe_pre_check_status.go new file mode 100644 index 0000000000..71993a6a00 --- /dev/null +++ b/services/dts/struct_job_progress_in_describe_pre_check_status.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// JobProgressInDescribePreCheckStatus is a nested struct in dts response +type JobProgressInDescribePreCheckStatus struct { + ProgressInfo []ProgressInfo `json:"ProgressInfo" xml:"ProgressInfo"` +} diff --git a/services/dts/struct_logs_in_describe_pre_check_status.go b/services/dts/struct_logs_in_describe_pre_check_status.go new file mode 100644 index 0000000000..2fe45ccf60 --- /dev/null +++ b/services/dts/struct_logs_in_describe_pre_check_status.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// LogsInDescribePreCheckStatus is a nested struct in dts response +type LogsInDescribePreCheckStatus struct { + JobLog []JobLog `json:"JobLog" xml:"JobLog"` +} diff --git a/services/dts/struct_migration_job.go b/services/dts/struct_migration_job.go new file mode 100644 index 0000000000..be5cc0e7a2 --- /dev/null +++ b/services/dts/struct_migration_job.go @@ -0,0 +1,36 @@ +package dts + +//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. + +// MigrationJob is a nested struct in dts response +type MigrationJob struct { + MigrationJobName string `json:"MigrationJobName" xml:"MigrationJobName"` + MigrationJobStatus string `json:"MigrationJobStatus" xml:"MigrationJobStatus"` + PayType string `json:"PayType" xml:"PayType"` + MigrationJobClass string `json:"MigrationJobClass" xml:"MigrationJobClass"` + InstanceCreateTime string `json:"InstanceCreateTime" xml:"InstanceCreateTime"` + MigrationJobID string `json:"MigrationJobID" xml:"MigrationJobID"` + JobCreateTime string `json:"JobCreateTime" xml:"JobCreateTime"` + DataInitialization DataInitialization `json:"DataInitialization" xml:"DataInitialization"` + DataSynchronization DataSynchronization `json:"DataSynchronization" xml:"DataSynchronization"` + DestinationEndpoint DestinationEndpoint `json:"DestinationEndpoint" xml:"DestinationEndpoint"` + MigrationMode MigrationMode `json:"MigrationMode" xml:"MigrationMode"` + Precheck Precheck `json:"Precheck" xml:"Precheck"` + SourceEndpoint SourceEndpoint `json:"SourceEndpoint" xml:"SourceEndpoint"` + StructureInitialization StructureInitialization `json:"StructureInitialization" xml:"StructureInitialization"` + MigrationObject MigrationObject `json:"MigrationObject" xml:"MigrationObject"` + Tags TagsInDescribeMigrationJobs `json:"Tags" xml:"Tags"` +} diff --git a/services/dts/struct_migration_jobs.go b/services/dts/struct_migration_jobs.go new file mode 100644 index 0000000000..10941b3769 --- /dev/null +++ b/services/dts/struct_migration_jobs.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// MigrationJobs is a nested struct in dts response +type MigrationJobs struct { + MigrationJob []MigrationJob `json:"MigrationJob" xml:"MigrationJob"` +} diff --git a/services/dts/struct_migration_mode.go b/services/dts/struct_migration_mode.go new file mode 100644 index 0000000000..5f12d3fe68 --- /dev/null +++ b/services/dts/struct_migration_mode.go @@ -0,0 +1,26 @@ +package dts + +//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. + +// MigrationMode is a nested struct in dts response +type MigrationMode struct { + DataInitialization bool `json:"dataInitialization" xml:"dataInitialization"` + FullDataCheck bool `json:"FullDataCheck" xml:"FullDataCheck"` + DataExtractTransformLoad bool `json:"DataExtractTransformLoad" xml:"DataExtractTransformLoad"` + StructureInitialization bool `json:"StructureInitialization" xml:"StructureInitialization"` + IncDataCheck bool `json:"IncDataCheck" xml:"IncDataCheck"` + DataSynchronization bool `json:"dataSynchronization" xml:"dataSynchronization"` +} diff --git a/services/dts/struct_migration_object.go b/services/dts/struct_migration_object.go new file mode 100644 index 0000000000..92964d7e3a --- /dev/null +++ b/services/dts/struct_migration_object.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// MigrationObject is a nested struct in dts response +type MigrationObject struct { + SynchronousObject []SynchronousObject `json:"SynchronousObject" xml:"SynchronousObject"` +} diff --git a/services/dts/struct_monitor_rule.go b/services/dts/struct_monitor_rule.go new file mode 100644 index 0000000000..3846c4458e --- /dev/null +++ b/services/dts/struct_monitor_rule.go @@ -0,0 +1,29 @@ +package dts + +//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. + +// MonitorRule is a nested struct in dts response +type MonitorRule struct { + Type string `json:"Type" xml:"Type"` + DelayRuleTime int64 `json:"DelayRuleTime" xml:"DelayRuleTime"` + State string `json:"State" xml:"State"` + Phone string `json:"Phone" xml:"Phone"` + JobType string `json:"JobType" xml:"JobType"` + Period int `json:"Period" xml:"Period"` + Times int `json:"Times" xml:"Times"` + NoticeValue int `json:"NoticeValue" xml:"NoticeValue"` + JobId string `json:"JobId" xml:"JobId"` +} diff --git a/services/dts/struct_monitor_rules.go b/services/dts/struct_monitor_rules.go new file mode 100644 index 0000000000..1d6fe889f5 --- /dev/null +++ b/services/dts/struct_monitor_rules.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// MonitorRules is a nested struct in dts response +type MonitorRules struct { + MonitorRule []MonitorRule `json:"MonitorRule" xml:"MonitorRule"` +} diff --git a/services/dts/struct_performance.go b/services/dts/struct_performance.go index ccf5cf41fe..9c592e039f 100644 --- a/services/dts/struct_performance.go +++ b/services/dts/struct_performance.go @@ -17,6 +17,8 @@ package dts // Performance is a nested struct in dts response type Performance struct { + Flow string `json:"Flow" xml:"Flow"` + Rps string `json:"Rps" xml:"Rps"` RPS string `json:"RPS" xml:"RPS"` FLOW string `json:"FLOW" xml:"FLOW"` } diff --git a/services/dts/struct_precheck.go b/services/dts/struct_precheck.go new file mode 100644 index 0000000000..b7514a21c0 --- /dev/null +++ b/services/dts/struct_precheck.go @@ -0,0 +1,22 @@ +package dts + +//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. + +// Precheck is a nested struct in dts response +type Precheck struct { + Status string `json:"Status" xml:"Status"` + Percent string `json:"Percent" xml:"Percent"` +} diff --git a/services/dts/struct_precheck_detail.go b/services/dts/struct_precheck_detail.go new file mode 100644 index 0000000000..3cb0b829f4 --- /dev/null +++ b/services/dts/struct_precheck_detail.go @@ -0,0 +1,25 @@ +package dts + +//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. + +// PrecheckDetail is a nested struct in dts response +type PrecheckDetail struct { + RepairMethod string `json:"RepairMethod" xml:"RepairMethod"` + CheckResult string `json:"CheckResult" xml:"CheckResult"` + FailedReason string `json:"FailedReason" xml:"FailedReason"` + CheckItem string `json:"CheckItem" xml:"CheckItem"` + CheckItemDescription string `json:"CheckItemDescription" xml:"CheckItemDescription"` +} diff --git a/services/dts/struct_precheck_status.go b/services/dts/struct_precheck_status.go index 49acb6a560..e4aa360dfa 100644 --- a/services/dts/struct_precheck_status.go +++ b/services/dts/struct_precheck_status.go @@ -17,7 +17,8 @@ package dts // PrecheckStatus is a nested struct in dts response type PrecheckStatus struct { - Status string `json:"Status" xml:"Status"` - Percent string `json:"Percent" xml:"Percent"` - Detail []CheckItem `json:"Detail" xml:"Detail"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + Status string `json:"Status" xml:"Status"` + Percent string `json:"Percent" xml:"Percent"` + Detail []DetailItem `json:"Detail" xml:"Detail"` } diff --git a/services/dts/struct_precheck_status_in_describe_dts_jobs.go b/services/dts/struct_precheck_status_in_describe_dts_jobs.go new file mode 100644 index 0000000000..e57b51dc28 --- /dev/null +++ b/services/dts/struct_precheck_status_in_describe_dts_jobs.go @@ -0,0 +1,24 @@ +package dts + +//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. + +// PrecheckStatusInDescribeDtsJobs is a nested struct in dts response +type PrecheckStatusInDescribeDtsJobs struct { + Status string `json:"Status" xml:"Status"` + Percent string `json:"Percent" xml:"Percent"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + Detail []PrecheckDetail `json:"Detail" xml:"Detail"` +} diff --git a/services/dts/struct_precheck_status_in_describe_migration_job_status.go b/services/dts/struct_precheck_status_in_describe_migration_job_status.go new file mode 100644 index 0000000000..30d13d13c7 --- /dev/null +++ b/services/dts/struct_precheck_status_in_describe_migration_job_status.go @@ -0,0 +1,23 @@ +package dts + +//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. + +// PrecheckStatusInDescribeMigrationJobStatus is a nested struct in dts response +type PrecheckStatusInDescribeMigrationJobStatus struct { + Status string `json:"Status" xml:"Status"` + Percent string `json:"Percent" xml:"Percent"` + Detail DetailInDescribeMigrationJobStatus `json:"Detail" xml:"Detail"` +} diff --git a/services/dts/struct_precheck_status_in_describe_synchronization_job_status.go b/services/dts/struct_precheck_status_in_describe_synchronization_job_status.go new file mode 100644 index 0000000000..b6631d1dc9 --- /dev/null +++ b/services/dts/struct_precheck_status_in_describe_synchronization_job_status.go @@ -0,0 +1,23 @@ +package dts + +//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. + +// PrecheckStatusInDescribeSynchronizationJobStatus is a nested struct in dts response +type PrecheckStatusInDescribeSynchronizationJobStatus struct { + Status string `json:"Status" xml:"Status"` + Percent string `json:"Percent" xml:"Percent"` + Detail []CheckItem `json:"Detail" xml:"Detail"` +} diff --git a/services/dts/struct_precheck_status_in_describe_synchronization_jobs.go b/services/dts/struct_precheck_status_in_describe_synchronization_jobs.go new file mode 100644 index 0000000000..19658e8b47 --- /dev/null +++ b/services/dts/struct_precheck_status_in_describe_synchronization_jobs.go @@ -0,0 +1,23 @@ +package dts + +//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. + +// PrecheckStatusInDescribeSynchronizationJobs is a nested struct in dts response +type PrecheckStatusInDescribeSynchronizationJobs struct { + Status string `json:"Status" xml:"Status"` + Percent string `json:"Percent" xml:"Percent"` + Detail []CheckItem `json:"Detail" xml:"Detail"` +} diff --git a/services/dts/struct_precheck_status_in_describe_synchronization_object_modify_status.go b/services/dts/struct_precheck_status_in_describe_synchronization_object_modify_status.go new file mode 100644 index 0000000000..1895d30f48 --- /dev/null +++ b/services/dts/struct_precheck_status_in_describe_synchronization_object_modify_status.go @@ -0,0 +1,23 @@ +package dts + +//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. + +// PrecheckStatusInDescribeSynchronizationObjectModifyStatus is a nested struct in dts response +type PrecheckStatusInDescribeSynchronizationObjectModifyStatus struct { + Status string `json:"Status" xml:"Status"` + Percent string `json:"Percent" xml:"Percent"` + Detail []CheckItem `json:"Detail" xml:"Detail"` +} diff --git a/services/dts/struct_progress_info.go b/services/dts/struct_progress_info.go new file mode 100644 index 0000000000..77285cefbd --- /dev/null +++ b/services/dts/struct_progress_info.go @@ -0,0 +1,45 @@ +package dts + +//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. + +// ProgressInfo is a nested struct in dts response +type ProgressInfo struct { + DdlSql string `json:"DdlSql" xml:"DdlSql"` + DestSchema string `json:"DestSchema" xml:"DestSchema"` + Current string `json:"Current" xml:"Current"` + ErrDetail string `json:"ErrDetail" xml:"ErrDetail"` + DiffRow int64 `json:"DiffRow" xml:"DiffRow"` + OrderNum int `json:"OrderNum" xml:"OrderNum"` + DelaySeconds int `json:"DelaySeconds" xml:"DelaySeconds"` + ErrMsg string `json:"ErrMsg" xml:"ErrMsg"` + Sub string `json:"Sub" xml:"Sub"` + Names string `json:"Names" xml:"Names"` + Id string `json:"Id" xml:"Id"` + RepairMethod string `json:"RepairMethod" xml:"RepairMethod"` + JobId string `json:"JobId" xml:"JobId"` + Skip bool `json:"Skip" xml:"Skip"` + SourceSchema string `json:"SourceSchema" xml:"SourceSchema"` + FinishTime string `json:"FinishTime" xml:"FinishTime"` + BootTime string `json:"BootTime" xml:"BootTime"` + TargetNames string `json:"TargetNames" xml:"TargetNames"` + State string `json:"State" xml:"State"` + ParentObj string `json:"ParentObj" xml:"ParentObj"` + Total int `json:"Total" xml:"Total"` + IgnoreFlag string `json:"IgnoreFlag" xml:"IgnoreFlag"` + CanSkip bool `json:"CanSkip" xml:"CanSkip"` + Item string `json:"Item" xml:"Item"` + Logs []JobLog `json:"Logs" xml:"Logs"` +} diff --git a/services/dts/struct_progress_summary_detail.go b/services/dts/struct_progress_summary_detail.go new file mode 100644 index 0000000000..c1abc85b02 --- /dev/null +++ b/services/dts/struct_progress_summary_detail.go @@ -0,0 +1,23 @@ +package dts + +//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. + +// ProgressSummaryDetail is a nested struct in dts response +type ProgressSummaryDetail struct { + Key string `json:"Key" xml:"Key"` + TotalCount int64 `json:"TotalCount" xml:"TotalCount"` + State int `json:"State" xml:"State"` +} diff --git a/services/dts/struct_progress_summary_details.go b/services/dts/struct_progress_summary_details.go new file mode 100644 index 0000000000..db79df764c --- /dev/null +++ b/services/dts/struct_progress_summary_details.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// ProgressSummaryDetails is a nested struct in dts response +type ProgressSummaryDetails struct { + ProgressSummaryDetail []ProgressSummaryDetail `json:"ProgressSummaryDetail" xml:"ProgressSummaryDetail"` +} diff --git a/services/dts/struct_retry_state.go b/services/dts/struct_retry_state.go new file mode 100644 index 0000000000..94e6210a3b --- /dev/null +++ b/services/dts/struct_retry_state.go @@ -0,0 +1,35 @@ +package dts + +//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. + +// RetryState is a nested struct in dts response +type RetryState struct { + JobId string `json:"JobId" xml:"JobId"` + Retrying bool `json:"Retrying" xml:"Retrying"` + Module string `json:"Module" xml:"Module"` + RetryCount int `json:"RetryCount" xml:"RetryCount"` + MigrationErrMsg string `json:"MigrationErrMsg" xml:"MigrationErrMsg"` + MigrationErrHelpDocKey string `json:"MigrationErrHelpDocKey" xml:"MigrationErrHelpDocKey"` + RetryTarget string `json:"RetryTarget" xml:"RetryTarget"` + ErrMsg string `json:"ErrMsg" xml:"ErrMsg"` + MigrationErrType string `json:"MigrationErrType" xml:"MigrationErrType"` + MigrationErrCode string `json:"MigrationErrCode" xml:"MigrationErrCode"` + RetryTime int `json:"RetryTime" xml:"RetryTime"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + MigrationErrHelpDocId string `json:"MigrationErrHelpDocId" xml:"MigrationErrHelpDocId"` + MaxRetryTime int `json:"MaxRetryTime" xml:"MaxRetryTime"` + MigrationErrWorkaround string `json:"MigrationErrWorkaround" xml:"MigrationErrWorkaround"` +} diff --git a/services/dts/struct_reverse_job.go b/services/dts/struct_reverse_job.go new file mode 100644 index 0000000000..07d249ff6b --- /dev/null +++ b/services/dts/struct_reverse_job.go @@ -0,0 +1,70 @@ +package dts + +//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. + +// ReverseJob is a nested struct in dts response +type ReverseJob struct { + DedicatedClusterId string `json:"DedicatedClusterId" xml:"DedicatedClusterId"` + OriginType string `json:"OriginType" xml:"OriginType"` + IsDemoJob bool `json:"IsDemoJob" xml:"IsDemoJob"` + BeginTimestamp string `json:"BeginTimestamp" xml:"BeginTimestamp"` + Reserved string `json:"Reserved" xml:"Reserved"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + GroupId string `json:"GroupId" xml:"GroupId"` + JobType string `json:"JobType" xml:"JobType"` + Checkpoint string `json:"Checkpoint" xml:"Checkpoint"` + PayType string `json:"PayType" xml:"PayType"` + DtsJobClass string `json:"DtsJobClass" xml:"DtsJobClass"` + FinishTime string `json:"FinishTime" xml:"FinishTime"` + CpuUsage string `json:"CpuUsage" xml:"CpuUsage"` + Status string `json:"Status" xml:"Status"` + ConsumptionCheckpoint string `json:"ConsumptionCheckpoint" xml:"ConsumptionCheckpoint"` + TaskType string `json:"TaskType" xml:"TaskType"` + DtsJobDirection string `json:"DtsJobDirection" xml:"DtsJobDirection"` + MemUsage string `json:"MemUsage" xml:"MemUsage"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + CreateTime string `json:"CreateTime" xml:"CreateTime"` + EndTimestamp string `json:"EndTimestamp" xml:"EndTimestamp"` + DatabaseCount int `json:"DatabaseCount" xml:"DatabaseCount"` + ConsumptionClient string `json:"ConsumptionClient" xml:"ConsumptionClient"` + DbObject string `json:"DbObject" xml:"DbObject"` + SynchronizationDirection string `json:"SynchronizationDirection" xml:"SynchronizationDirection"` + Delay int64 `json:"Delay" xml:"Delay"` + ExpireTime string `json:"ExpireTime" xml:"ExpireTime"` + DtsJobName string `json:"DtsJobName" xml:"DtsJobName"` + DuUsage int64 `json:"DuUsage" xml:"DuUsage"` + EtlCalculator string `json:"EtlCalculator" xml:"EtlCalculator"` + ReverseJob string `json:"ReverseJob" xml:"ReverseJob"` + EtlSafeCheckpoint string `json:"EtlSafeCheckpoint" xml:"EtlSafeCheckpoint"` + DestNetType string `json:"DestNetType" xml:"DestNetType"` + AppName string `json:"AppName" xml:"AppName"` + DtsInstanceID string `json:"DtsInstanceID" xml:"DtsInstanceID"` + SubscribeTopic string `json:"SubscribeTopic" xml:"SubscribeTopic"` + MigrationMode MigrationMode `json:"MigrationMode" xml:"MigrationMode"` + DataSynchronizationStatus DataSynchronizationStatus `json:"DataSynchronizationStatus" xml:"DataSynchronizationStatus"` + SourceEndpoint SourceEndpoint `json:"SourceEndpoint" xml:"SourceEndpoint"` + DataInitializationStatus DataInitializationStatus `json:"DataInitializationStatus" xml:"DataInitializationStatus"` + DestinationEndpoint DestinationEndpoint `json:"DestinationEndpoint" xml:"DestinationEndpoint"` + RetryState RetryState `json:"RetryState" xml:"RetryState"` + DataEtlStatus DataEtlStatus `json:"DataEtlStatus" xml:"DataEtlStatus"` + SubscriptionHost SubscriptionHost `json:"SubscriptionHost" xml:"SubscriptionHost"` + StructureInitializationStatus StructureInitializationStatus `json:"StructureInitializationStatus" xml:"StructureInitializationStatus"` + PrecheckStatus PrecheckStatusInDescribeDtsJobs `json:"PrecheckStatus" xml:"PrecheckStatus"` + Performance Performance `json:"Performance" xml:"Performance"` + SubscriptionDataType SubscriptionDataType `json:"SubscriptionDataType" xml:"SubscriptionDataType"` + TagList []TagListItem `json:"TagList" xml:"TagList"` + ErrorDetails []ErrorDetail `json:"ErrorDetails" xml:"ErrorDetails"` +} diff --git a/services/dts/struct_service_log_context.go b/services/dts/struct_service_log_context.go new file mode 100644 index 0000000000..6a5383ff58 --- /dev/null +++ b/services/dts/struct_service_log_context.go @@ -0,0 +1,23 @@ +package dts + +//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. + +// ServiceLogContext is a nested struct in dts response +type ServiceLogContext struct { + Context string `json:"Context" xml:"Context"` + Time string `json:"Time" xml:"Time"` + State string `json:"State" xml:"State"` +} diff --git a/services/dts/struct_service_log_contexts.go b/services/dts/struct_service_log_contexts.go new file mode 100644 index 0000000000..2a920b39dd --- /dev/null +++ b/services/dts/struct_service_log_contexts.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// ServiceLogContexts is a nested struct in dts response +type ServiceLogContexts struct { + ServiceLogContext []ServiceLogContext `json:"ServiceLogContext" xml:"ServiceLogContext"` +} diff --git a/services/dts/struct_source_endpoint.go b/services/dts/struct_source_endpoint.go index 0a51b9f423..c52e5313a8 100644 --- a/services/dts/struct_source_endpoint.go +++ b/services/dts/struct_source_endpoint.go @@ -17,10 +17,19 @@ package dts // SourceEndpoint is a nested struct in dts response type SourceEndpoint struct { - EngineName string `json:"EngineName" xml:"EngineName"` - Port string `json:"Port" xml:"Port"` - InstanceId string `json:"InstanceId" xml:"InstanceId"` - IP string `json:"IP" xml:"IP"` - UserName string `json:"UserName" xml:"UserName"` - InstanceType string `json:"InstanceType" xml:"InstanceType"` + Region string `json:"Region" xml:"Region"` + SslSolutionEnum string `json:"SslSolutionEnum" xml:"SslSolutionEnum"` + Port string `json:"Port" xml:"Port"` + Ip string `json:"Ip" xml:"Ip"` + CanModifyPassword bool `json:"CanModifyPassword" xml:"CanModifyPassword"` + IP string `json:"IP" xml:"IP"` + OracleSID string `json:"OracleSID" xml:"OracleSID"` + InstanceType string `json:"InstanceType" xml:"InstanceType"` + RoleName string `json:"RoleName" xml:"RoleName"` + EngineName string `json:"EngineName" xml:"EngineName"` + InstanceID string `json:"InstanceID" xml:"InstanceID"` + InstanceId string `json:"InstanceId" xml:"InstanceId"` + AliyunUid string `json:"AliyunUid" xml:"AliyunUid"` + UserName string `json:"UserName" xml:"UserName"` + DatabaseName string `json:"DatabaseName" xml:"DatabaseName"` } diff --git a/services/dts/struct_structure_initialization.go b/services/dts/struct_structure_initialization.go new file mode 100644 index 0000000000..8c7f9d36e1 --- /dev/null +++ b/services/dts/struct_structure_initialization.go @@ -0,0 +1,24 @@ +package dts + +//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. + +// StructureInitialization is a nested struct in dts response +type StructureInitialization struct { + Percent string `json:"Percent" xml:"Percent"` + Status string `json:"status" xml:"status"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + Progress string `json:"Progress" xml:"Progress"` +} diff --git a/services/dts/struct_structure_initialization_detail.go b/services/dts/struct_structure_initialization_detail.go new file mode 100644 index 0000000000..cb48326442 --- /dev/null +++ b/services/dts/struct_structure_initialization_detail.go @@ -0,0 +1,29 @@ +package dts + +//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. + +// StructureInitializationDetail is a nested struct in dts response +type StructureInitializationDetail struct { + SourceOwnerDBName string `json:"SourceOwnerDBName" xml:"SourceOwnerDBName"` + ObjectName string `json:"ObjectName" xml:"ObjectName"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + ObjectType string `json:"ObjectType" xml:"ObjectType"` + DestinationOwnerDBName string `json:"DestinationOwnerDBName" xml:"DestinationOwnerDBName"` + Status string `json:"Status" xml:"Status"` + ObjectDefinition string `json:"ObjectDefinition" xml:"ObjectDefinition"` + Constraints []StructureInitializationDetail `json:"Constraints" xml:"Constraints"` + ConstraintList ConstraintList `json:"ConstraintList" xml:"ConstraintList"` +} diff --git a/services/dts/struct_structure_initialization_detail_in_describe_migration_job_detail.go b/services/dts/struct_structure_initialization_detail_in_describe_migration_job_detail.go new file mode 100644 index 0000000000..b4ed32abc0 --- /dev/null +++ b/services/dts/struct_structure_initialization_detail_in_describe_migration_job_detail.go @@ -0,0 +1,28 @@ +package dts + +//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. + +// StructureInitializationDetailInDescribeMigrationJobDetail is a nested struct in dts response +type StructureInitializationDetailInDescribeMigrationJobDetail struct { + Status string `json:"Status" xml:"Status"` + SourceOwnerDBName string `json:"SourceOwnerDBName" xml:"SourceOwnerDBName"` + ObjectDefinition string `json:"ObjectDefinition" xml:"ObjectDefinition"` + ObjectType string `json:"ObjectType" xml:"ObjectType"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + DestinationOwnerDBName string `json:"DestinationOwnerDBName" xml:"DestinationOwnerDBName"` + ObjectName string `json:"ObjectName" xml:"ObjectName"` + ConstraintList ConstraintList `json:"ConstraintList" xml:"ConstraintList"` +} diff --git a/services/dts/struct_structure_initialization_detail_list.go b/services/dts/struct_structure_initialization_detail_list.go new file mode 100644 index 0000000000..fdb163861d --- /dev/null +++ b/services/dts/struct_structure_initialization_detail_list.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// StructureInitializationDetailList is a nested struct in dts response +type StructureInitializationDetailList struct { + StructureInitializationDetail []StructureInitializationDetailInDescribeMigrationJobDetail `json:"StructureInitializationDetail" xml:"StructureInitializationDetail"` +} diff --git a/services/dts/struct_structure_initialization_details.go b/services/dts/struct_structure_initialization_details.go new file mode 100644 index 0000000000..8fd58a89fc --- /dev/null +++ b/services/dts/struct_structure_initialization_details.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// StructureInitializationDetails is a nested struct in dts response +type StructureInitializationDetails struct { + StructureInitializationDetail []StructureInitializationDetail `json:"StructureInitializationDetail" xml:"StructureInitializationDetail"` +} diff --git a/services/dts/struct_structure_initialization_status.go b/services/dts/struct_structure_initialization_status.go index a041240eda..d1a947ed75 100644 --- a/services/dts/struct_structure_initialization_status.go +++ b/services/dts/struct_structure_initialization_status.go @@ -21,4 +21,5 @@ type StructureInitializationStatus struct { ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` Status string `json:"Status" xml:"Status"` Percent string `json:"Percent" xml:"Percent"` + NeedUpgrade bool `json:"NeedUpgrade" xml:"NeedUpgrade"` } diff --git a/services/dts/struct_sub_distributed_job.go b/services/dts/struct_sub_distributed_job.go new file mode 100644 index 0000000000..d40de883e1 --- /dev/null +++ b/services/dts/struct_sub_distributed_job.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// SubDistributedJob is a nested struct in dts response +type SubDistributedJob struct { + SubDistributedJobItem []SubDistributedJobItem `json:"SubDistributedJob" xml:"SubDistributedJob"` +} diff --git a/services/dts/struct_sub_distributed_job_item.go b/services/dts/struct_sub_distributed_job_item.go new file mode 100644 index 0000000000..bd7e5ab017 --- /dev/null +++ b/services/dts/struct_sub_distributed_job_item.go @@ -0,0 +1,65 @@ +package dts + +//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. + +// SubDistributedJobItem is a nested struct in dts response +type SubDistributedJobItem struct { + DtsInstanceID string `json:"DtsInstanceID" xml:"DtsInstanceID"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + DtsJobName string `json:"DtsJobName" xml:"DtsJobName"` + GroupId string `json:"GroupId" xml:"GroupId"` + DatabaseCount int `json:"DatabaseCount" xml:"DatabaseCount"` + DtsJobClass string `json:"DtsJobClass" xml:"DtsJobClass"` + DtsJobDirection string `json:"DtsJobDirection" xml:"DtsJobDirection"` + SynchronizationDirection string `json:"SynchronizationDirection" xml:"SynchronizationDirection"` + PayType string `json:"PayType" xml:"PayType"` + ExpireTime string `json:"ExpireTime" xml:"ExpireTime"` + CreateTime string `json:"CreateTime" xml:"CreateTime"` + FinishTime string `json:"FinishTime" xml:"FinishTime"` + DbObject string `json:"DbObject" xml:"DbObject"` + Status string `json:"Status" xml:"Status"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + Delay int64 `json:"Delay" xml:"Delay"` + Checkpoint string `json:"Checkpoint" xml:"Checkpoint"` + Reserved string `json:"Reserved" xml:"Reserved"` + SubscribeTopic string `json:"SubscribeTopic" xml:"SubscribeTopic"` + ConsumptionCheckpoint string `json:"ConsumptionCheckpoint" xml:"ConsumptionCheckpoint"` + BeginTimestamp string `json:"BeginTimestamp" xml:"BeginTimestamp"` + EndTimestamp string `json:"EndTimestamp" xml:"EndTimestamp"` + ConsumptionClient string `json:"ConsumptionClient" xml:"ConsumptionClient"` + DestNetType string `json:"DestNetType" xml:"DestNetType"` + AppName string `json:"AppName" xml:"AppName"` + EtlCalculator string `json:"EtlCalculator" xml:"EtlCalculator"` + OriginType string `json:"OriginType" xml:"OriginType"` + JobType string `json:"JobType" xml:"JobType"` + IsDemoJob bool `json:"IsDemoJob" xml:"IsDemoJob"` + TaskType string `json:"TaskType" xml:"TaskType"` + SubSyncJob []string `json:"SubSyncJob" xml:"SubSyncJob"` + SourceEndpoint SourceEndpoint `json:"SourceEndpoint" xml:"SourceEndpoint"` + DestinationEndpoint DestinationEndpoint `json:"DestinationEndpoint" xml:"DestinationEndpoint"` + MigrationMode MigrationMode `json:"MigrationMode" xml:"MigrationMode"` + PrecheckStatus PrecheckStatus `json:"PrecheckStatus" xml:"PrecheckStatus"` + StructureInitializationStatus StructureInitializationStatus `json:"StructureInitializationStatus" xml:"StructureInitializationStatus"` + DataInitializationStatus DataInitializationStatus `json:"DataInitializationStatus" xml:"DataInitializationStatus"` + DataSynchronizationStatus DataSynchronizationStatus `json:"DataSynchronizationStatus" xml:"DataSynchronizationStatus"` + DataEtlStatus DataEtlStatus `json:"DataEtlStatus" xml:"DataEtlStatus"` + Performance Performance `json:"Performance" xml:"Performance"` + ReverseJob ReverseJob `json:"ReverseJob" xml:"ReverseJob"` + SubscriptionHost SubscriptionHost `json:"SubscriptionHost" xml:"SubscriptionHost"` + SubscriptionDataType SubscriptionDataType `json:"SubscriptionDataType" xml:"SubscriptionDataType"` + RetryState RetryState `json:"RetryState" xml:"RetryState"` + TagList []TagListItem `json:"TagList" xml:"TagList"` +} diff --git a/services/dts/struct_sub_distributed_job_status.go b/services/dts/struct_sub_distributed_job_status.go new file mode 100644 index 0000000000..afc375788d --- /dev/null +++ b/services/dts/struct_sub_distributed_job_status.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// SubDistributedJobStatus is a nested struct in dts response +type SubDistributedJobStatus struct { + SubDistributedJobStatusItem []SubDistributedJobStatusItem `json:"SubDistributedJobStatus" xml:"SubDistributedJobStatus"` +} diff --git a/services/dts/struct_sub_distributed_job_status_item.go b/services/dts/struct_sub_distributed_job_status_item.go new file mode 100644 index 0000000000..8c9c645d0e --- /dev/null +++ b/services/dts/struct_sub_distributed_job_status_item.go @@ -0,0 +1,27 @@ +package dts + +//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. + +// SubDistributedJobStatusItem is a nested struct in dts response +type SubDistributedJobStatusItem struct { + JobName string `json:"JobName" xml:"JobName"` + State string `json:"State" xml:"State"` + JobId string `json:"JobId" xml:"JobId"` + ErrorItem int `json:"ErrorItem" xml:"ErrorItem"` + Code string `json:"Code" xml:"Code"` + Total int `json:"Total" xml:"Total"` + JobProgress []ProgressInfo `json:"JobProgress" xml:"JobProgress"` +} diff --git a/services/dts/struct_sub_sync_job_in_describe_dts_job_detail.go b/services/dts/struct_sub_sync_job_in_describe_dts_job_detail.go new file mode 100644 index 0000000000..30df59a3ef --- /dev/null +++ b/services/dts/struct_sub_sync_job_in_describe_dts_job_detail.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// SubSyncJobInDescribeDtsJobDetail is a nested struct in dts response +type SubSyncJobInDescribeDtsJobDetail struct { + SubSyncJob []string `json:"SubSyncJob" xml:"SubSyncJob"` +} diff --git a/services/dts/struct_sub_sync_job_item.go b/services/dts/struct_sub_sync_job_item.go new file mode 100644 index 0000000000..bdd9d7bd37 --- /dev/null +++ b/services/dts/struct_sub_sync_job_item.go @@ -0,0 +1,65 @@ +package dts + +//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. + +// SubSyncJobItem is a nested struct in dts response +type SubSyncJobItem struct { + DtsInstanceID string `json:"DtsInstanceID" xml:"DtsInstanceID"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + DtsJobName string `json:"DtsJobName" xml:"DtsJobName"` + GroupId string `json:"GroupId" xml:"GroupId"` + DatabaseCount int `json:"DatabaseCount" xml:"DatabaseCount"` + DtsJobClass string `json:"DtsJobClass" xml:"DtsJobClass"` + DtsJobDirection string `json:"DtsJobDirection" xml:"DtsJobDirection"` + SynchronizationDirection string `json:"SynchronizationDirection" xml:"SynchronizationDirection"` + PayType string `json:"PayType" xml:"PayType"` + ExpireTime string `json:"ExpireTime" xml:"ExpireTime"` + CreateTime string `json:"CreateTime" xml:"CreateTime"` + FinishTime string `json:"FinishTime" xml:"FinishTime"` + DbObject string `json:"DbObject" xml:"DbObject"` + Status string `json:"Status" xml:"Status"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + Delay int64 `json:"Delay" xml:"Delay"` + Checkpoint string `json:"Checkpoint" xml:"Checkpoint"` + Reserved string `json:"Reserved" xml:"Reserved"` + SubscribeTopic string `json:"SubscribeTopic" xml:"SubscribeTopic"` + ConsumptionCheckpoint string `json:"ConsumptionCheckpoint" xml:"ConsumptionCheckpoint"` + BeginTimestamp string `json:"BeginTimestamp" xml:"BeginTimestamp"` + EndTimestamp string `json:"EndTimestamp" xml:"EndTimestamp"` + ConsumptionClient string `json:"ConsumptionClient" xml:"ConsumptionClient"` + DestNetType string `json:"DestNetType" xml:"DestNetType"` + AppName string `json:"AppName" xml:"AppName"` + EtlCalculator string `json:"EtlCalculator" xml:"EtlCalculator"` + OriginType string `json:"OriginType" xml:"OriginType"` + JobType string `json:"JobType" xml:"JobType"` + IsDemoJob bool `json:"IsDemoJob" xml:"IsDemoJob"` + TaskType string `json:"TaskType" xml:"TaskType"` + SubSyncJob []string `json:"SubSyncJob" xml:"SubSyncJob"` + SourceEndpoint SourceEndpoint `json:"SourceEndpoint" xml:"SourceEndpoint"` + DestinationEndpoint DestinationEndpoint `json:"DestinationEndpoint" xml:"DestinationEndpoint"` + MigrationMode MigrationMode `json:"MigrationMode" xml:"MigrationMode"` + PrecheckStatus PrecheckStatus `json:"PrecheckStatus" xml:"PrecheckStatus"` + StructureInitializationStatus StructureInitializationStatus `json:"StructureInitializationStatus" xml:"StructureInitializationStatus"` + DataInitializationStatus DataInitializationStatus `json:"DataInitializationStatus" xml:"DataInitializationStatus"` + DataSynchronizationStatus DataSynchronizationStatus `json:"DataSynchronizationStatus" xml:"DataSynchronizationStatus"` + DataEtlStatus DataEtlStatus `json:"DataEtlStatus" xml:"DataEtlStatus"` + Performance Performance `json:"Performance" xml:"Performance"` + ReverseJob ReverseJob `json:"ReverseJob" xml:"ReverseJob"` + SubscriptionHost SubscriptionHost `json:"SubscriptionHost" xml:"SubscriptionHost"` + SubscriptionDataType SubscriptionDataType `json:"SubscriptionDataType" xml:"SubscriptionDataType"` + RetryState RetryState `json:"RetryState" xml:"RetryState"` + TagList []TagListItem `json:"TagList" xml:"TagList"` +} diff --git a/services/dts/struct_subscription_data_type.go b/services/dts/struct_subscription_data_type.go new file mode 100644 index 0000000000..0a68e14ef1 --- /dev/null +++ b/services/dts/struct_subscription_data_type.go @@ -0,0 +1,24 @@ +package dts + +//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. + +// SubscriptionDataType is a nested struct in dts response +type SubscriptionDataType struct { + Ddl bool `json:"Ddl" xml:"Ddl"` + DDL bool `json:"DDL" xml:"DDL"` + DML bool `json:"DML" xml:"DML"` + Dml bool `json:"Dml" xml:"Dml"` +} diff --git a/services/dts/struct_subscription_host.go b/services/dts/struct_subscription_host.go new file mode 100644 index 0000000000..76619682c7 --- /dev/null +++ b/services/dts/struct_subscription_host.go @@ -0,0 +1,24 @@ +package dts + +//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. + +// SubscriptionHost is a nested struct in dts response +type SubscriptionHost struct { + VpcHost string `json:"VpcHost" xml:"VpcHost"` + VPCHost string `json:"VPCHost" xml:"VPCHost"` + PublicHost string `json:"PublicHost" xml:"PublicHost"` + PrivateHost string `json:"PrivateHost" xml:"PrivateHost"` +} diff --git a/services/dts/struct_subscription_instance.go b/services/dts/struct_subscription_instance.go new file mode 100644 index 0000000000..77add5cdf7 --- /dev/null +++ b/services/dts/struct_subscription_instance.go @@ -0,0 +1,37 @@ +package dts + +//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. + +// SubscriptionInstance is a nested struct in dts response +type SubscriptionInstance struct { + Status string `json:"Status" xml:"Status"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + PayType string `json:"PayType" xml:"PayType"` + ConsumptionClient string `json:"ConsumptionClient" xml:"ConsumptionClient"` + ConsumptionCheckpoint string `json:"ConsumptionCheckpoint" xml:"ConsumptionCheckpoint"` + EndTimestamp string `json:"EndTimestamp" xml:"EndTimestamp"` + InstanceCreateTime string `json:"InstanceCreateTime" xml:"InstanceCreateTime"` + BeginTimestamp string `json:"BeginTimestamp" xml:"BeginTimestamp"` + SubscribeTopic string `json:"SubscribeTopic" xml:"SubscribeTopic"` + SubscriptionInstanceName string `json:"SubscriptionInstanceName" xml:"SubscriptionInstanceName"` + SubscriptionInstanceID string `json:"SubscriptionInstanceID" xml:"SubscriptionInstanceID"` + JobCreateTime string `json:"JobCreateTime" xml:"JobCreateTime"` + SourceEndpoint SourceEndpoint `json:"SourceEndpoint" xml:"SourceEndpoint"` + SubscriptionDataType SubscriptionDataType `json:"SubscriptionDataType" xml:"SubscriptionDataType"` + SubscriptionHost SubscriptionHost `json:"SubscriptionHost" xml:"SubscriptionHost"` + SubscriptionObject SubscriptionObjectInDescribeSubscriptionInstances `json:"SubscriptionObject" xml:"SubscriptionObject"` + Tags TagsInDescribeSubscriptionInstances `json:"Tags" xml:"Tags"` +} diff --git a/services/dts/struct_subscription_instances.go b/services/dts/struct_subscription_instances.go new file mode 100644 index 0000000000..044c884212 --- /dev/null +++ b/services/dts/struct_subscription_instances.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// SubscriptionInstances is a nested struct in dts response +type SubscriptionInstances struct { + SubscriptionInstance []SubscriptionInstance `json:"SubscriptionInstance" xml:"SubscriptionInstance"` +} diff --git a/services/dts/struct_subscription_meta_list.go b/services/dts/struct_subscription_meta_list.go new file mode 100644 index 0000000000..af5828a7a3 --- /dev/null +++ b/services/dts/struct_subscription_meta_list.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// SubscriptionMetaList is a nested struct in dts response +type SubscriptionMetaList struct { + SubscriptionMetaListItem []SubscriptionMetaListItem `json:"SubscriptionMetaList" xml:"SubscriptionMetaList"` +} diff --git a/services/dts/struct_subscription_meta_list_item.go b/services/dts/struct_subscription_meta_list_item.go new file mode 100644 index 0000000000..8d322e93da --- /dev/null +++ b/services/dts/struct_subscription_meta_list_item.go @@ -0,0 +1,25 @@ +package dts + +//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. + +// SubscriptionMetaListItem is a nested struct in dts response +type SubscriptionMetaListItem struct { + Sid string `json:"Sid" xml:"Sid"` + Checkpoint int64 `json:"Checkpoint" xml:"Checkpoint"` + DProxyUrl string `json:"DProxyUrl" xml:"DProxyUrl"` + DBList string `json:"DBList" xml:"DBList"` + Topic string `json:"Topic" xml:"Topic"` +} diff --git a/services/dts/struct_subscription_object_in_describe_subscription_instance_status.go b/services/dts/struct_subscription_object_in_describe_subscription_instance_status.go new file mode 100644 index 0000000000..08088ee5af --- /dev/null +++ b/services/dts/struct_subscription_object_in_describe_subscription_instance_status.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// SubscriptionObjectInDescribeSubscriptionInstanceStatus is a nested struct in dts response +type SubscriptionObjectInDescribeSubscriptionInstanceStatus struct { + SynchronousObject []SynchronousObject `json:"SynchronousObject" xml:"SynchronousObject"` +} diff --git a/services/dts/struct_subscription_object_in_describe_subscription_instances.go b/services/dts/struct_subscription_object_in_describe_subscription_instances.go new file mode 100644 index 0000000000..ec16d0d9f7 --- /dev/null +++ b/services/dts/struct_subscription_object_in_describe_subscription_instances.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// SubscriptionObjectInDescribeSubscriptionInstances is a nested struct in dts response +type SubscriptionObjectInDescribeSubscriptionInstances struct { + SynchronousObject []SynchronousObject `json:"SynchronousObject" xml:"SynchronousObject"` +} diff --git a/services/dts/struct_synchronization_direction_info.go b/services/dts/struct_synchronization_direction_info.go new file mode 100644 index 0000000000..0bcafafc1d --- /dev/null +++ b/services/dts/struct_synchronization_direction_info.go @@ -0,0 +1,23 @@ +package dts + +//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. + +// SynchronizationDirectionInfo is a nested struct in dts response +type SynchronizationDirectionInfo struct { + Status string `json:"Status" xml:"Status"` + SynchronizationDirection string `json:"SynchronizationDirection" xml:"SynchronizationDirection"` + Checkpoint string `json:"Checkpoint" xml:"Checkpoint"` +} diff --git a/services/dts/struct_synchronization_direction_info_list.go b/services/dts/struct_synchronization_direction_info_list.go new file mode 100644 index 0000000000..e1a295518c --- /dev/null +++ b/services/dts/struct_synchronization_direction_info_list.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// SynchronizationDirectionInfoList is a nested struct in dts response +type SynchronizationDirectionInfoList struct { + SynchronizationDirectionInfo []SynchronizationDirectionInfo `json:"SynchronizationDirectionInfo" xml:"SynchronizationDirectionInfo"` +} diff --git a/services/dts/struct_synchronization_instance.go b/services/dts/struct_synchronization_instance.go index 22fdc9fc39..1cf11d3493 100644 --- a/services/dts/struct_synchronization_instance.go +++ b/services/dts/struct_synchronization_instance.go @@ -17,23 +17,27 @@ package dts // SynchronizationInstance is a nested struct in dts response type SynchronizationInstance struct { - Status string `json:"Status" xml:"Status"` - DataInitialization string `json:"DataInitialization" xml:"DataInitialization"` - SynchronizationJobName string `json:"SynchronizationJobName" xml:"SynchronizationJobName"` - Delay string `json:"Delay" xml:"Delay"` - ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` - ExpireTime string `json:"ExpireTime" xml:"ExpireTime"` - SynchronizationJobId string `json:"SynchronizationJobId" xml:"SynchronizationJobId"` - StructureInitialization string `json:"StructureInitialization" xml:"StructureInitialization"` - PayType string `json:"PayType" xml:"PayType"` - SynchronizationJobClass string `json:"SynchronizationJobClass" xml:"SynchronizationJobClass"` - SynchronizationDirection string `json:"SynchronizationDirection" xml:"SynchronizationDirection"` - SourceEndpoint SourceEndpoint `json:"SourceEndpoint" xml:"SourceEndpoint"` - DestinationEndpoint DestinationEndpoint `json:"DestinationEndpoint" xml:"DestinationEndpoint"` - PrecheckStatus PrecheckStatus `json:"PrecheckStatus" xml:"PrecheckStatus"` - StructureInitializationStatus StructureInitializationStatus `json:"StructureInitializationStatus" xml:"StructureInitializationStatus"` - DataInitializationStatus DataInitializationStatus `json:"DataInitializationStatus" xml:"DataInitializationStatus"` - DataSynchronizationStatus DataSynchronizationStatus `json:"DataSynchronizationStatus" xml:"DataSynchronizationStatus"` - Performance Performance `json:"Performance" xml:"Performance"` - SynchronizationObjects []SynchronizationObject `json:"SynchronizationObjects" xml:"SynchronizationObjects"` + DataInitialization string `json:"DataInitialization" xml:"DataInitialization"` + Status string `json:"Status" xml:"Status"` + SynchronizationJobName string `json:"SynchronizationJobName" xml:"SynchronizationJobName"` + Delay string `json:"Delay" xml:"Delay"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` + ExpireTime string `json:"ExpireTime" xml:"ExpireTime"` + CreateTime string `json:"CreateTime" xml:"CreateTime"` + PayType string `json:"PayType" xml:"PayType"` + StructureInitialization string `json:"StructureInitialization" xml:"StructureInitialization"` + SynchronizationJobClass string `json:"SynchronizationJobClass" xml:"SynchronizationJobClass"` + InstanceCreateTime string `json:"InstanceCreateTime" xml:"InstanceCreateTime"` + SynchronizationJobId string `json:"SynchronizationJobId" xml:"SynchronizationJobId"` + SynchronizationDirection string `json:"SynchronizationDirection" xml:"SynchronizationDirection"` + JobCreateTime string `json:"JobCreateTime" xml:"JobCreateTime"` + DataInitializationStatus DataInitializationStatus `json:"DataInitializationStatus" xml:"DataInitializationStatus"` + DataSynchronizationStatus DataSynchronizationStatus `json:"DataSynchronizationStatus" xml:"DataSynchronizationStatus"` + DestinationEndpoint DestinationEndpoint `json:"DestinationEndpoint" xml:"DestinationEndpoint"` + Performance Performance `json:"Performance" xml:"Performance"` + PrecheckStatus PrecheckStatusInDescribeSynchronizationJobs `json:"PrecheckStatus" xml:"PrecheckStatus"` + SourceEndpoint SourceEndpoint `json:"SourceEndpoint" xml:"SourceEndpoint"` + StructureInitializationStatus StructureInitializationStatus `json:"StructureInitializationStatus" xml:"StructureInitializationStatus"` + Tags []Tag `json:"Tags" xml:"Tags"` + SynchronizationObjects []SynchronizationObject `json:"SynchronizationObjects" xml:"SynchronizationObjects"` } diff --git a/services/dts/struct_synchronization_job_list_status_list.go b/services/dts/struct_synchronization_job_list_status_list.go new file mode 100644 index 0000000000..61548a9120 --- /dev/null +++ b/services/dts/struct_synchronization_job_list_status_list.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// SynchronizationJobListStatusList is a nested struct in dts response +type SynchronizationJobListStatusList struct { + SynchronizationJobStatusInfo []SynchronizationJobStatusInfo `json:"SynchronizationJobStatusInfo" xml:"SynchronizationJobStatusInfo"` +} diff --git a/services/dts/struct_synchronization_job_status_info.go b/services/dts/struct_synchronization_job_status_info.go new file mode 100644 index 0000000000..ae7773254c --- /dev/null +++ b/services/dts/struct_synchronization_job_status_info.go @@ -0,0 +1,22 @@ +package dts + +//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. + +// SynchronizationJobStatusInfo is a nested struct in dts response +type SynchronizationJobStatusInfo struct { + SynchronizationJobId string `json:"SynchronizationJobId" xml:"SynchronizationJobId"` + SynchronizationDirectionInfoList []SynchronizationDirectionInfo `json:"SynchronizationDirectionInfoList" xml:"SynchronizationDirectionInfoList"` +} diff --git a/services/dts/struct_synchronous_object.go b/services/dts/struct_synchronous_object.go new file mode 100644 index 0000000000..67cec54ca8 --- /dev/null +++ b/services/dts/struct_synchronous_object.go @@ -0,0 +1,23 @@ +package dts + +//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. + +// SynchronousObject is a nested struct in dts response +type SynchronousObject struct { + WholeDatabase string `json:"WholeDatabase" xml:"WholeDatabase"` + DatabaseName string `json:"DatabaseName" xml:"DatabaseName"` + TableList TableListInDescribeMigrationJobs `json:"TableList" xml:"TableList"` +} diff --git a/services/dts/struct_table_details.go b/services/dts/struct_table_details.go new file mode 100644 index 0000000000..5caa033196 --- /dev/null +++ b/services/dts/struct_table_details.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// TableDetails is a nested struct in dts response +type TableDetails struct { + TableDetailsItem []TableDetailsItem `json:"TableDetails" xml:"TableDetails"` +} diff --git a/services/dts/struct_table_details_item.go b/services/dts/struct_table_details_item.go new file mode 100644 index 0000000000..c717e01856 --- /dev/null +++ b/services/dts/struct_table_details_item.go @@ -0,0 +1,31 @@ +package dts + +//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. + +// TableDetailsItem is a nested struct in dts response +type TableDetailsItem struct { + Status string `json:"Status" xml:"Status"` + Id int64 `json:"Id" xml:"Id"` + SourceDbName string `json:"SourceDbName" xml:"SourceDbName"` + TargetDbName string `json:"TargetDbName" xml:"TargetDbName"` + SourceTbName string `json:"SourceTbName" xml:"SourceTbName"` + TargetTbName string `json:"TargetTbName" xml:"TargetTbName"` + TotalCount int64 `json:"TotalCount" xml:"TotalCount"` + FinishCount int64 `json:"FinishCount" xml:"FinishCount"` + DiffCount int64 `json:"DiffCount" xml:"DiffCount"` + BootTime string `json:"BootTime" xml:"BootTime"` + ErrorCode int `json:"ErrorCode" xml:"ErrorCode"` +} diff --git a/services/dts/struct_table_list_in_describe_migration_jobs.go b/services/dts/struct_table_list_in_describe_migration_jobs.go new file mode 100644 index 0000000000..b16d3c707f --- /dev/null +++ b/services/dts/struct_table_list_in_describe_migration_jobs.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// TableListInDescribeMigrationJobs is a nested struct in dts response +type TableListInDescribeMigrationJobs struct { + Table []string `json:"Table" xml:"Table"` +} diff --git a/services/dts/struct_table_list_in_describe_subscription_instance_status.go b/services/dts/struct_table_list_in_describe_subscription_instance_status.go new file mode 100644 index 0000000000..20215628da --- /dev/null +++ b/services/dts/struct_table_list_in_describe_subscription_instance_status.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// TableListInDescribeSubscriptionInstanceStatus is a nested struct in dts response +type TableListInDescribeSubscriptionInstanceStatus struct { + Table []string `json:"Table" xml:"Table"` +} diff --git a/services/dts/struct_table_list_in_describe_subscription_instances.go b/services/dts/struct_table_list_in_describe_subscription_instances.go new file mode 100644 index 0000000000..29eea1fb80 --- /dev/null +++ b/services/dts/struct_table_list_in_describe_subscription_instances.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// TableListInDescribeSubscriptionInstances is a nested struct in dts response +type TableListInDescribeSubscriptionInstances struct { + Table []string `json:"Table" xml:"Table"` +} diff --git a/services/dts/struct_tag.go b/services/dts/struct_tag.go new file mode 100644 index 0000000000..45c79dfed0 --- /dev/null +++ b/services/dts/struct_tag.go @@ -0,0 +1,22 @@ +package dts + +//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. + +// Tag is a nested struct in dts response +type Tag struct { + Key string `json:"Key" xml:"Key"` + Value string `json:"Value" xml:"Value"` +} diff --git a/services/dts/struct_tag_keys.go b/services/dts/struct_tag_keys.go new file mode 100644 index 0000000000..e5cb65bf51 --- /dev/null +++ b/services/dts/struct_tag_keys.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// TagKeys is a nested struct in dts response +type TagKeys struct { + TagKey []string `json:"TagKey" xml:"TagKey"` +} diff --git a/services/dts/struct_tag_list_in_describe_dts_job_detail.go b/services/dts/struct_tag_list_in_describe_dts_job_detail.go new file mode 100644 index 0000000000..3fa35add23 --- /dev/null +++ b/services/dts/struct_tag_list_in_describe_dts_job_detail.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// TagListInDescribeDtsJobDetail is a nested struct in dts response +type TagListInDescribeDtsJobDetail struct { + TagListItem []TagListItem `json:"TagList" xml:"TagList"` +} diff --git a/services/dts/struct_tag_list_in_describe_dts_jobs.go b/services/dts/struct_tag_list_in_describe_dts_jobs.go new file mode 100644 index 0000000000..36c190601a --- /dev/null +++ b/services/dts/struct_tag_list_in_describe_dts_jobs.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// TagListInDescribeDtsJobs is a nested struct in dts response +type TagListInDescribeDtsJobs struct { + DtsTag []DtsTag `json:"DtsTag" xml:"DtsTag"` +} diff --git a/services/dts/struct_tag_list_item.go b/services/dts/struct_tag_list_item.go new file mode 100644 index 0000000000..88fb022998 --- /dev/null +++ b/services/dts/struct_tag_list_item.go @@ -0,0 +1,33 @@ +package dts + +//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. + +// TagListItem is a nested struct in dts response +type TagListItem struct { + ResourceId string `json:"ResourceId" xml:"ResourceId"` + SrcRegion string `json:"SrcRegion" xml:"SrcRegion"` + GmtModified string `json:"GmtModified" xml:"GmtModified"` + TagCategory string `json:"TagCategory" xml:"TagCategory"` + Id int64 `json:"Id" xml:"Id"` + Creator int64 `json:"Creator" xml:"Creator"` + GmtCreate string `json:"GmtCreate" xml:"GmtCreate"` + ResourceType string `json:"ResourceType" xml:"ResourceType"` + RegionId string `json:"RegionId" xml:"RegionId"` + AliUid int64 `json:"AliUid" xml:"AliUid"` + TagValue string `json:"TagValue" xml:"TagValue"` + Scope string `json:"Scope" xml:"Scope"` + TagKey string `json:"TagKey" xml:"TagKey"` +} diff --git a/services/dts/struct_tag_resource.go b/services/dts/struct_tag_resource.go new file mode 100644 index 0000000000..d5af1fa08d --- /dev/null +++ b/services/dts/struct_tag_resource.go @@ -0,0 +1,24 @@ +package dts + +//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. + +// TagResource is a nested struct in dts response +type TagResource struct { + TagValue string `json:"TagValue" xml:"TagValue"` + ResourceType string `json:"ResourceType" xml:"ResourceType"` + ResourceId string `json:"ResourceId" xml:"ResourceId"` + TagKey string `json:"TagKey" xml:"TagKey"` +} diff --git a/services/dts/struct_tag_resources.go b/services/dts/struct_tag_resources.go new file mode 100644 index 0000000000..b6595a9e8b --- /dev/null +++ b/services/dts/struct_tag_resources.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// TagResources is a nested struct in dts response +type TagResources struct { + TagResource []TagResource `json:"TagResource" xml:"TagResource"` +} diff --git a/services/dts/struct_tag_values.go b/services/dts/struct_tag_values.go new file mode 100644 index 0000000000..7a427bbcab --- /dev/null +++ b/services/dts/struct_tag_values.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// TagValues is a nested struct in dts response +type TagValues struct { + TagValue []string `json:"TagValue" xml:"TagValue"` +} diff --git a/services/dts/struct_tags_in_describe_migration_jobs.go b/services/dts/struct_tags_in_describe_migration_jobs.go new file mode 100644 index 0000000000..18382d85b4 --- /dev/null +++ b/services/dts/struct_tags_in_describe_migration_jobs.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// TagsInDescribeMigrationJobs is a nested struct in dts response +type TagsInDescribeMigrationJobs struct { + Tag []Tag `json:"Tag" xml:"Tag"` +} diff --git a/services/dts/struct_tags_in_describe_subscription_instances.go b/services/dts/struct_tags_in_describe_subscription_instances.go new file mode 100644 index 0000000000..9a2e329415 --- /dev/null +++ b/services/dts/struct_tags_in_describe_subscription_instances.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// TagsInDescribeSubscriptionInstances is a nested struct in dts response +type TagsInDescribeSubscriptionInstances struct { + Tag []Tag `json:"Tag" xml:"Tag"` +} diff --git a/services/dts/struct_tags_in_describe_synchronization_jobs.go b/services/dts/struct_tags_in_describe_synchronization_jobs.go new file mode 100644 index 0000000000..945dae32e4 --- /dev/null +++ b/services/dts/struct_tags_in_describe_synchronization_jobs.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// TagsInDescribeSynchronizationJobs is a nested struct in dts response +type TagsInDescribeSynchronizationJobs struct { + Tag []Tag `json:"Tag" xml:"Tag"` +} diff --git a/services/dts/struct_topics.go b/services/dts/struct_topics.go new file mode 100644 index 0000000000..1d9a26f310 --- /dev/null +++ b/services/dts/struct_topics.go @@ -0,0 +1,21 @@ +package dts + +//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. + +// Topics is a nested struct in dts response +type Topics struct { + Topics []string `json:"Topics" xml:"Topics"` +} diff --git a/services/dts/summary_job_detail.go b/services/dts/summary_job_detail.go new file mode 100644 index 0000000000..fe12a76ace --- /dev/null +++ b/services/dts/summary_job_detail.go @@ -0,0 +1,108 @@ +package dts + +//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" +) + +// SummaryJobDetail invokes the dts.SummaryJobDetail API synchronously +func (client *Client) SummaryJobDetail(request *SummaryJobDetailRequest) (response *SummaryJobDetailResponse, err error) { + response = CreateSummaryJobDetailResponse() + err = client.DoAction(request, response) + return +} + +// SummaryJobDetailWithChan invokes the dts.SummaryJobDetail API asynchronously +func (client *Client) SummaryJobDetailWithChan(request *SummaryJobDetailRequest) (<-chan *SummaryJobDetailResponse, <-chan error) { + responseChan := make(chan *SummaryJobDetailResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.SummaryJobDetail(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// SummaryJobDetailWithCallback invokes the dts.SummaryJobDetail API asynchronously +func (client *Client) SummaryJobDetailWithCallback(request *SummaryJobDetailRequest, callback func(response *SummaryJobDetailResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *SummaryJobDetailResponse + var err error + defer close(result) + response, err = client.SummaryJobDetail(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// SummaryJobDetailRequest is the request struct for api SummaryJobDetail +type SummaryJobDetailRequest struct { + *requests.RpcRequest + StructType string `position:"Query" name:"StructType"` + DtsJobId string `position:"Query" name:"DtsJobId"` + JobCode string `position:"Query" name:"JobCode"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` + SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` +} + +// SummaryJobDetailResponse is the response struct for api SummaryJobDetail +type SummaryJobDetailResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + Code string `json:"Code" xml:"Code"` + RequestId string `json:"RequestId" xml:"RequestId"` + Success bool `json:"Success" xml:"Success"` + JobId string `json:"JobId" xml:"JobId"` + ProgressSummaryDetails []ProgressSummaryDetail `json:"ProgressSummaryDetails" xml:"ProgressSummaryDetails"` +} + +// CreateSummaryJobDetailRequest creates a request to invoke SummaryJobDetail API +func CreateSummaryJobDetailRequest() (request *SummaryJobDetailRequest) { + request = &SummaryJobDetailRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "SummaryJobDetail", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateSummaryJobDetailResponse creates a response to parse from SummaryJobDetail response +func CreateSummaryJobDetailResponse() (response *SummaryJobDetailResponse) { + response = &SummaryJobDetailResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/suspend_dts_job.go b/services/dts/suspend_dts_job.go new file mode 100644 index 0000000000..1bb084bba1 --- /dev/null +++ b/services/dts/suspend_dts_job.go @@ -0,0 +1,107 @@ +package dts + +//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" +) + +// SuspendDtsJob invokes the dts.SuspendDtsJob API synchronously +func (client *Client) SuspendDtsJob(request *SuspendDtsJobRequest) (response *SuspendDtsJobResponse, err error) { + response = CreateSuspendDtsJobResponse() + err = client.DoAction(request, response) + return +} + +// SuspendDtsJobWithChan invokes the dts.SuspendDtsJob API asynchronously +func (client *Client) SuspendDtsJobWithChan(request *SuspendDtsJobRequest) (<-chan *SuspendDtsJobResponse, <-chan error) { + responseChan := make(chan *SuspendDtsJobResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.SuspendDtsJob(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// SuspendDtsJobWithCallback invokes the dts.SuspendDtsJob API asynchronously +func (client *Client) SuspendDtsJobWithCallback(request *SuspendDtsJobRequest, callback func(response *SuspendDtsJobResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *SuspendDtsJobResponse + var err error + defer close(result) + response, err = client.SuspendDtsJob(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// SuspendDtsJobRequest is the request struct for api SuspendDtsJob +type SuspendDtsJobRequest struct { + *requests.RpcRequest + DtsJobId string `position:"Query" name:"DtsJobId"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` + SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` +} + +// SuspendDtsJobResponse is the response struct for api SuspendDtsJob +type SuspendDtsJobResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` +} + +// CreateSuspendDtsJobRequest creates a request to invoke SuspendDtsJob API +func CreateSuspendDtsJobRequest() (request *SuspendDtsJobRequest) { + request = &SuspendDtsJobRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "SuspendDtsJob", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateSuspendDtsJobResponse creates a response to parse from SuspendDtsJob response +func CreateSuspendDtsJobResponse() (response *SuspendDtsJobResponse) { + response = &SuspendDtsJobResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/suspend_dts_jobs.go b/services/dts/suspend_dts_jobs.go new file mode 100644 index 0000000000..3d0c796520 --- /dev/null +++ b/services/dts/suspend_dts_jobs.go @@ -0,0 +1,105 @@ +package dts + +//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" +) + +// SuspendDtsJobs invokes the dts.SuspendDtsJobs API synchronously +func (client *Client) SuspendDtsJobs(request *SuspendDtsJobsRequest) (response *SuspendDtsJobsResponse, err error) { + response = CreateSuspendDtsJobsResponse() + err = client.DoAction(request, response) + return +} + +// SuspendDtsJobsWithChan invokes the dts.SuspendDtsJobs API asynchronously +func (client *Client) SuspendDtsJobsWithChan(request *SuspendDtsJobsRequest) (<-chan *SuspendDtsJobsResponse, <-chan error) { + responseChan := make(chan *SuspendDtsJobsResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.SuspendDtsJobs(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// SuspendDtsJobsWithCallback invokes the dts.SuspendDtsJobs API asynchronously +func (client *Client) SuspendDtsJobsWithCallback(request *SuspendDtsJobsRequest, callback func(response *SuspendDtsJobsResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *SuspendDtsJobsResponse + var err error + defer close(result) + response, err = client.SuspendDtsJobs(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// SuspendDtsJobsRequest is the request struct for api SuspendDtsJobs +type SuspendDtsJobsRequest struct { + *requests.RpcRequest + DtsJobIds string `position:"Query" name:"DtsJobIds"` +} + +// SuspendDtsJobsResponse is the response struct for api SuspendDtsJobs +type SuspendDtsJobsResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` +} + +// CreateSuspendDtsJobsRequest creates a request to invoke SuspendDtsJobs API +func CreateSuspendDtsJobsRequest() (request *SuspendDtsJobsRequest) { + request = &SuspendDtsJobsRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "SuspendDtsJobs", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateSuspendDtsJobsResponse creates a response to parse from SuspendDtsJobs response +func CreateSuspendDtsJobsResponse() (response *SuspendDtsJobsResponse) { + response = &SuspendDtsJobsResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/suspend_migration_job.go b/services/dts/suspend_migration_job.go new file mode 100644 index 0000000000..7b7147ad9c --- /dev/null +++ b/services/dts/suspend_migration_job.go @@ -0,0 +1,105 @@ +package dts + +//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" +) + +// SuspendMigrationJob invokes the dts.SuspendMigrationJob API synchronously +func (client *Client) SuspendMigrationJob(request *SuspendMigrationJobRequest) (response *SuspendMigrationJobResponse, err error) { + response = CreateSuspendMigrationJobResponse() + err = client.DoAction(request, response) + return +} + +// SuspendMigrationJobWithChan invokes the dts.SuspendMigrationJob API asynchronously +func (client *Client) SuspendMigrationJobWithChan(request *SuspendMigrationJobRequest) (<-chan *SuspendMigrationJobResponse, <-chan error) { + responseChan := make(chan *SuspendMigrationJobResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.SuspendMigrationJob(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// SuspendMigrationJobWithCallback invokes the dts.SuspendMigrationJob API asynchronously +func (client *Client) SuspendMigrationJobWithCallback(request *SuspendMigrationJobRequest, callback func(response *SuspendMigrationJobResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *SuspendMigrationJobResponse + var err error + defer close(result) + response, err = client.SuspendMigrationJob(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// SuspendMigrationJobRequest is the request struct for api SuspendMigrationJob +type SuspendMigrationJobRequest struct { + *requests.RpcRequest + ClientToken string `position:"Query" name:"ClientToken"` + MigrationJobId string `position:"Query" name:"MigrationJobId"` + OwnerId string `position:"Query" name:"OwnerId"` + AccountId string `position:"Query" name:"AccountId"` +} + +// SuspendMigrationJobResponse is the response struct for api SuspendMigrationJob +type SuspendMigrationJobResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success string `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateSuspendMigrationJobRequest creates a request to invoke SuspendMigrationJob API +func CreateSuspendMigrationJobRequest() (request *SuspendMigrationJobRequest) { + request = &SuspendMigrationJobRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "SuspendMigrationJob", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateSuspendMigrationJobResponse creates a response to parse from SuspendMigrationJob response +func CreateSuspendMigrationJobResponse() (response *SuspendMigrationJobResponse) { + response = &SuspendMigrationJobResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/suspend_synchronization_job.go b/services/dts/suspend_synchronization_job.go index 0353ecd9c3..ad979b4a67 100644 --- a/services/dts/suspend_synchronization_job.go +++ b/services/dts/suspend_synchronization_job.go @@ -73,6 +73,7 @@ type SuspendSynchronizationJobRequest struct { *requests.RpcRequest OwnerId string `position:"Query" name:"OwnerId"` SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` + AccountId string `position:"Query" name:"AccountId"` SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` } @@ -90,7 +91,7 @@ func CreateSuspendSynchronizationJobRequest() (request *SuspendSynchronizationJo request = &SuspendSynchronizationJobRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "SuspendSynchronizationJob", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "SuspendSynchronizationJob", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/switch_physical_dts_job_to_cloud.go b/services/dts/switch_physical_dts_job_to_cloud.go new file mode 100644 index 0000000000..6fe1c935a7 --- /dev/null +++ b/services/dts/switch_physical_dts_job_to_cloud.go @@ -0,0 +1,109 @@ +package dts + +//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" +) + +// SwitchPhysicalDtsJobToCloud invokes the dts.SwitchPhysicalDtsJobToCloud API synchronously +func (client *Client) SwitchPhysicalDtsJobToCloud(request *SwitchPhysicalDtsJobToCloudRequest) (response *SwitchPhysicalDtsJobToCloudResponse, err error) { + response = CreateSwitchPhysicalDtsJobToCloudResponse() + err = client.DoAction(request, response) + return +} + +// SwitchPhysicalDtsJobToCloudWithChan invokes the dts.SwitchPhysicalDtsJobToCloud API asynchronously +func (client *Client) SwitchPhysicalDtsJobToCloudWithChan(request *SwitchPhysicalDtsJobToCloudRequest) (<-chan *SwitchPhysicalDtsJobToCloudResponse, <-chan error) { + responseChan := make(chan *SwitchPhysicalDtsJobToCloudResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.SwitchPhysicalDtsJobToCloud(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// SwitchPhysicalDtsJobToCloudWithCallback invokes the dts.SwitchPhysicalDtsJobToCloud API asynchronously +func (client *Client) SwitchPhysicalDtsJobToCloudWithCallback(request *SwitchPhysicalDtsJobToCloudRequest, callback func(response *SwitchPhysicalDtsJobToCloudResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *SwitchPhysicalDtsJobToCloudResponse + var err error + defer close(result) + response, err = client.SwitchPhysicalDtsJobToCloud(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// SwitchPhysicalDtsJobToCloudRequest is the request struct for api SwitchPhysicalDtsJobToCloud +type SwitchPhysicalDtsJobToCloudRequest struct { + *requests.RpcRequest + ResetCheckpoint string `position:"Query" name:"ResetCheckpoint"` + ResumeHoldJob string `position:"Query" name:"ResumeHoldJob"` + DtsJobId string `position:"Query" name:"DtsJobId"` + DtsInstanceId string `position:"Query" name:"DtsInstanceId"` + SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` +} + +// SwitchPhysicalDtsJobToCloudResponse is the response struct for api SwitchPhysicalDtsJobToCloud +type SwitchPhysicalDtsJobToCloudResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` +} + +// CreateSwitchPhysicalDtsJobToCloudRequest creates a request to invoke SwitchPhysicalDtsJobToCloud API +func CreateSwitchPhysicalDtsJobToCloudRequest() (request *SwitchPhysicalDtsJobToCloudRequest) { + request = &SwitchPhysicalDtsJobToCloudRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "SwitchPhysicalDtsJobToCloud", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateSwitchPhysicalDtsJobToCloudResponse creates a response to parse from SwitchPhysicalDtsJobToCloud response +func CreateSwitchPhysicalDtsJobToCloudResponse() (response *SwitchPhysicalDtsJobToCloudResponse) { + response = &SwitchPhysicalDtsJobToCloudResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/switch_synchronization_endpoint.go b/services/dts/switch_synchronization_endpoint.go index bb5577db90..2befd4de88 100644 --- a/services/dts/switch_synchronization_endpoint.go +++ b/services/dts/switch_synchronization_endpoint.go @@ -71,12 +71,15 @@ func (client *Client) SwitchSynchronizationEndpointWithCallback(request *SwitchS // SwitchSynchronizationEndpointRequest is the request struct for api SwitchSynchronizationEndpoint type SwitchSynchronizationEndpointRequest struct { *requests.RpcRequest - EndpointInstanceType string `position:"Query" name:"Endpoint.InstanceType"` - EndpointIP string `position:"Query" name:"Endpoint.IP"` - OwnerId string `position:"Query" name:"OwnerId"` SynchronizationJobId string `position:"Query" name:"SynchronizationJobId"` EndpointType string `position:"Query" name:"Endpoint.Type"` + AccountId string `position:"Query" name:"AccountId"` EndpointPort string `position:"Query" name:"Endpoint.Port"` + EndpointInstanceType string `position:"Query" name:"Endpoint.InstanceType"` + SourceEndpointOwnerID string `position:"Query" name:"SourceEndpoint.OwnerID"` + SourceEndpointRole string `position:"Query" name:"SourceEndpoint.Role"` + EndpointIP string `position:"Query" name:"Endpoint.IP"` + OwnerId string `position:"Query" name:"OwnerId"` EndpointInstanceId string `position:"Query" name:"Endpoint.InstanceId"` SynchronizationDirection string `position:"Query" name:"SynchronizationDirection"` } @@ -96,7 +99,7 @@ func CreateSwitchSynchronizationEndpointRequest() (request *SwitchSynchronizatio request = &SwitchSynchronizationEndpointRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Dts", "2019-09-01", "SwitchSynchronizationEndpoint", "", "") + request.InitWithApiInfo("Dts", "2020-01-01", "SwitchSynchronizationEndpoint", "dts", "openAPI") request.Method = requests.POST return } diff --git a/services/dts/tag_resources.go b/services/dts/tag_resources.go new file mode 100644 index 0000000000..fc816dcaa8 --- /dev/null +++ b/services/dts/tag_resources.go @@ -0,0 +1,110 @@ +package dts + +//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" +) + +// TagResources invokes the dts.TagResources API synchronously +func (client *Client) TagResources(request *TagResourcesRequest) (response *TagResourcesResponse, err error) { + response = CreateTagResourcesResponse() + err = client.DoAction(request, response) + return +} + +// TagResourcesWithChan invokes the dts.TagResources API asynchronously +func (client *Client) TagResourcesWithChan(request *TagResourcesRequest) (<-chan *TagResourcesResponse, <-chan error) { + responseChan := make(chan *TagResourcesResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.TagResources(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// TagResourcesWithCallback invokes the dts.TagResources API asynchronously +func (client *Client) TagResourcesWithCallback(request *TagResourcesRequest, callback func(response *TagResourcesResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *TagResourcesResponse + var err error + defer close(result) + response, err = client.TagResources(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// TagResourcesRequest is the request struct for api TagResources +type TagResourcesRequest struct { + *requests.RpcRequest + Tag *[]TagResourcesTag `position:"Query" name:"Tag" type:"Repeated"` + ResourceId *[]string `position:"Query" name:"ResourceId" type:"Repeated"` + ResourceType string `position:"Query" name:"ResourceType"` +} + +// TagResourcesTag is a repeated param struct in TagResourcesRequest +type TagResourcesTag struct { + Value string `name:"Value"` + Key string `name:"Key"` +} + +// TagResourcesResponse is the response struct for api TagResources +type TagResourcesResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateTagResourcesRequest creates a request to invoke TagResources API +func CreateTagResourcesRequest() (request *TagResourcesRequest) { + request = &TagResourcesRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "TagResources", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateTagResourcesResponse creates a response to parse from TagResources response +func CreateTagResourcesResponse() (response *TagResourcesResponse) { + response = &TagResourcesResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/transfer_instance_class.go b/services/dts/transfer_instance_class.go new file mode 100644 index 0000000000..6fdb90f018 --- /dev/null +++ b/services/dts/transfer_instance_class.go @@ -0,0 +1,111 @@ +package dts + +//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" +) + +// TransferInstanceClass invokes the dts.TransferInstanceClass API synchronously +func (client *Client) TransferInstanceClass(request *TransferInstanceClassRequest) (response *TransferInstanceClassResponse, err error) { + response = CreateTransferInstanceClassResponse() + err = client.DoAction(request, response) + return +} + +// TransferInstanceClassWithChan invokes the dts.TransferInstanceClass API asynchronously +func (client *Client) TransferInstanceClassWithChan(request *TransferInstanceClassRequest) (<-chan *TransferInstanceClassResponse, <-chan error) { + responseChan := make(chan *TransferInstanceClassResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.TransferInstanceClass(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// TransferInstanceClassWithCallback invokes the dts.TransferInstanceClass API asynchronously +func (client *Client) TransferInstanceClassWithCallback(request *TransferInstanceClassRequest, callback func(response *TransferInstanceClassResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *TransferInstanceClassResponse + var err error + defer close(result) + response, err = client.TransferInstanceClass(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// TransferInstanceClassRequest is the request struct for api TransferInstanceClass +type TransferInstanceClassRequest struct { + *requests.RpcRequest + InstanceClass string `position:"Query" name:"InstanceClass"` + DtsJobId string `position:"Query" name:"DtsJobId"` + OrderType string `position:"Query" name:"OrderType"` +} + +// TransferInstanceClassResponse is the response struct for api TransferInstanceClass +type TransferInstanceClassResponse struct { + *responses.BaseResponse + EndTime string `json:"EndTime" xml:"EndTime"` + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ChargeType string `json:"ChargeType" xml:"ChargeType"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + Code string `json:"Code" xml:"Code"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + InstanceId string `json:"InstanceId" xml:"InstanceId"` +} + +// CreateTransferInstanceClassRequest creates a request to invoke TransferInstanceClass API +func CreateTransferInstanceClassRequest() (request *TransferInstanceClassRequest) { + request = &TransferInstanceClassRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "TransferInstanceClass", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateTransferInstanceClassResponse creates a response to parse from TransferInstanceClass response +func CreateTransferInstanceClassResponse() (response *TransferInstanceClassResponse) { + response = &TransferInstanceClassResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/transfer_pay_type.go b/services/dts/transfer_pay_type.go new file mode 100644 index 0000000000..c64047ec64 --- /dev/null +++ b/services/dts/transfer_pay_type.go @@ -0,0 +1,112 @@ +package dts + +//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" +) + +// TransferPayType invokes the dts.TransferPayType API synchronously +func (client *Client) TransferPayType(request *TransferPayTypeRequest) (response *TransferPayTypeResponse, err error) { + response = CreateTransferPayTypeResponse() + err = client.DoAction(request, response) + return +} + +// TransferPayTypeWithChan invokes the dts.TransferPayType API asynchronously +func (client *Client) TransferPayTypeWithChan(request *TransferPayTypeRequest) (<-chan *TransferPayTypeResponse, <-chan error) { + responseChan := make(chan *TransferPayTypeResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.TransferPayType(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// TransferPayTypeWithCallback invokes the dts.TransferPayType API asynchronously +func (client *Client) TransferPayTypeWithCallback(request *TransferPayTypeRequest, callback func(response *TransferPayTypeResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *TransferPayTypeResponse + var err error + defer close(result) + response, err = client.TransferPayType(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// TransferPayTypeRequest is the request struct for api TransferPayType +type TransferPayTypeRequest struct { + *requests.RpcRequest + Period string `position:"Query" name:"Period"` + BuyCount string `position:"Query" name:"BuyCount"` + DtsJobId string `position:"Query" name:"DtsJobId"` + ChargeType string `position:"Query" name:"ChargeType"` +} + +// TransferPayTypeResponse is the response struct for api TransferPayType +type TransferPayTypeResponse struct { + *responses.BaseResponse + EndTime string `json:"EndTime" xml:"EndTime"` + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + DtsJobId string `json:"DtsJobId" xml:"DtsJobId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ChargeType string `json:"ChargeType" xml:"ChargeType"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + Code string `json:"Code" xml:"Code"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + InstanceId string `json:"InstanceId" xml:"InstanceId"` +} + +// CreateTransferPayTypeRequest creates a request to invoke TransferPayType API +func CreateTransferPayTypeRequest() (request *TransferPayTypeRequest) { + request = &TransferPayTypeRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "TransferPayType", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateTransferPayTypeResponse creates a response to parse from TransferPayType response +func CreateTransferPayTypeResponse() (response *TransferPayTypeResponse) { + response = &TransferPayTypeResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/untag_resources.go b/services/dts/untag_resources.go new file mode 100644 index 0000000000..7b7fdbe681 --- /dev/null +++ b/services/dts/untag_resources.go @@ -0,0 +1,105 @@ +package dts + +//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" +) + +// UntagResources invokes the dts.UntagResources API synchronously +func (client *Client) UntagResources(request *UntagResourcesRequest) (response *UntagResourcesResponse, err error) { + response = CreateUntagResourcesResponse() + err = client.DoAction(request, response) + return +} + +// UntagResourcesWithChan invokes the dts.UntagResources API asynchronously +func (client *Client) UntagResourcesWithChan(request *UntagResourcesRequest) (<-chan *UntagResourcesResponse, <-chan error) { + responseChan := make(chan *UntagResourcesResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.UntagResources(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// UntagResourcesWithCallback invokes the dts.UntagResources API asynchronously +func (client *Client) UntagResourcesWithCallback(request *UntagResourcesRequest, callback func(response *UntagResourcesResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *UntagResourcesResponse + var err error + defer close(result) + response, err = client.UntagResources(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// UntagResourcesRequest is the request struct for api UntagResources +type UntagResourcesRequest struct { + *requests.RpcRequest + All requests.Boolean `position:"Query" name:"All"` + ResourceId *[]string `position:"Query" name:"ResourceId" type:"Repeated"` + ResourceType string `position:"Query" name:"ResourceType"` + TagKey *[]string `position:"Query" name:"TagKey" type:"Repeated"` +} + +// UntagResourcesResponse is the response struct for api UntagResources +type UntagResourcesResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` +} + +// CreateUntagResourcesRequest creates a request to invoke UntagResources API +func CreateUntagResourcesRequest() (request *UntagResourcesRequest) { + request = &UntagResourcesRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "UntagResources", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateUntagResourcesResponse creates a response to parse from UntagResources response +func CreateUntagResourcesResponse() (response *UntagResourcesResponse) { + response = &UntagResourcesResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/upgrade_two_way.go b/services/dts/upgrade_two_way.go new file mode 100644 index 0000000000..ddd3f791cb --- /dev/null +++ b/services/dts/upgrade_two_way.go @@ -0,0 +1,106 @@ +package dts + +//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" +) + +// UpgradeTwoWay invokes the dts.UpgradeTwoWay API synchronously +func (client *Client) UpgradeTwoWay(request *UpgradeTwoWayRequest) (response *UpgradeTwoWayResponse, err error) { + response = CreateUpgradeTwoWayResponse() + err = client.DoAction(request, response) + return +} + +// UpgradeTwoWayWithChan invokes the dts.UpgradeTwoWay API asynchronously +func (client *Client) UpgradeTwoWayWithChan(request *UpgradeTwoWayRequest) (<-chan *UpgradeTwoWayResponse, <-chan error) { + responseChan := make(chan *UpgradeTwoWayResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.UpgradeTwoWay(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// UpgradeTwoWayWithCallback invokes the dts.UpgradeTwoWay API asynchronously +func (client *Client) UpgradeTwoWayWithCallback(request *UpgradeTwoWayRequest, callback func(response *UpgradeTwoWayResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *UpgradeTwoWayResponse + var err error + defer close(result) + response, err = client.UpgradeTwoWay(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// UpgradeTwoWayRequest is the request struct for api UpgradeTwoWay +type UpgradeTwoWayRequest struct { + *requests.RpcRequest + InstanceClass string `position:"Query" name:"InstanceClass"` + InstanceId string `position:"Query" name:"InstanceId"` +} + +// UpgradeTwoWayResponse is the response struct for api UpgradeTwoWay +type UpgradeTwoWayResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` +} + +// CreateUpgradeTwoWayRequest creates a request to invoke UpgradeTwoWay API +func CreateUpgradeTwoWayRequest() (request *UpgradeTwoWayRequest) { + request = &UpgradeTwoWayRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "UpgradeTwoWay", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateUpgradeTwoWayResponse creates a response to parse from UpgradeTwoWay response +func CreateUpgradeTwoWayResponse() (response *UpgradeTwoWayResponse) { + response = &UpgradeTwoWayResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/dts/white_ip_list.go b/services/dts/white_ip_list.go new file mode 100644 index 0000000000..5f06ef53b6 --- /dev/null +++ b/services/dts/white_ip_list.go @@ -0,0 +1,108 @@ +package dts + +//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" +) + +// WhiteIpList invokes the dts.WhiteIpList API synchronously +func (client *Client) WhiteIpList(request *WhiteIpListRequest) (response *WhiteIpListResponse, err error) { + response = CreateWhiteIpListResponse() + err = client.DoAction(request, response) + return +} + +// WhiteIpListWithChan invokes the dts.WhiteIpList API asynchronously +func (client *Client) WhiteIpListWithChan(request *WhiteIpListRequest) (<-chan *WhiteIpListResponse, <-chan error) { + responseChan := make(chan *WhiteIpListResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.WhiteIpList(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// WhiteIpListWithCallback invokes the dts.WhiteIpList API asynchronously +func (client *Client) WhiteIpListWithCallback(request *WhiteIpListRequest, callback func(response *WhiteIpListResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *WhiteIpListResponse + var err error + defer close(result) + response, err = client.WhiteIpList(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// WhiteIpListRequest is the request struct for api WhiteIpList +type WhiteIpListRequest struct { + *requests.RpcRequest + DestinationRegion string `position:"Query" name:"DestinationRegion"` + Type string `position:"Query" name:"Type"` + Region string `position:"Query" name:"Region"` +} + +// WhiteIpListResponse is the response struct for api WhiteIpList +type WhiteIpListResponse struct { + *responses.BaseResponse + HttpStatusCode int `json:"HttpStatusCode" xml:"HttpStatusCode"` + RequestId string `json:"RequestId" xml:"RequestId"` + ErrCode string `json:"ErrCode" xml:"ErrCode"` + Success bool `json:"Success" xml:"Success"` + ErrMessage string `json:"ErrMessage" xml:"ErrMessage"` + IpList string `json:"IpList" xml:"IpList"` + DynamicMessage string `json:"DynamicMessage" xml:"DynamicMessage"` + DynamicCode string `json:"DynamicCode" xml:"DynamicCode"` +} + +// CreateWhiteIpListRequest creates a request to invoke WhiteIpList API +func CreateWhiteIpListRequest() (request *WhiteIpListRequest) { + request = &WhiteIpListRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Dts", "2020-01-01", "WhiteIpList", "dts", "openAPI") + request.Method = requests.POST + return +} + +// CreateWhiteIpListResponse creates a response to parse from WhiteIpList response +func CreateWhiteIpListResponse() (response *WhiteIpListResponse) { + response = &WhiteIpListResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +}