From a3f41fbbd81013679b745522a64e97417f3e745c Mon Sep 17 00:00:00 2001 From: "openapi-bot[bot]" <37845953+openapi-bot[bot]@users.noreply.github.com> Date: Mon, 29 Jul 2019 06:43:18 +0000 Subject: [PATCH] Generated from 04df2c4ad1350ec47a500e1a1d1a609d43398aee (#4643) support dataset v2 split name --- .../datafactory/v2018_06_01/CopySource.java | 2 - .../v2018_06_01/Office365Source.java | 136 ------------------ .../datafactory/v2018_06_01/RestSource.java | 108 -------------- .../v2018_06_01/SapOpenHubSource.java | 57 -------- .../datafactory/v2018_06_01/TriggerRuns.java | 17 +-- .../DataFactoryManagementClientImpl.java | 26 ++-- .../implementation/DataFactoryManager.java | 24 ++-- .../implementation/DatasetInner.java | 3 - .../implementation/LinkedServiceInner.java | 1 - .../implementation/TriggerRunsImpl.java | 7 - .../implementation/TriggerRunsInner.java | 103 ------------- 11 files changed, 28 insertions(+), 456 deletions(-) diff --git a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/CopySource.java b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/CopySource.java index 6cd0cad90e2bb..91f4083bfac44 100644 --- a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/CopySource.java +++ b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/CopySource.java @@ -39,7 +39,6 @@ @JsonSubTypes.Type(name = "PhoenixSource", value = PhoenixSource.class), @JsonSubTypes.Type(name = "PaypalSource", value = PaypalSource.class), @JsonSubTypes.Type(name = "MarketoSource", value = MarketoSource.class), - @JsonSubTypes.Type(name = "AzureMariaDBSource", value = AzureMariaDBSource.class), @JsonSubTypes.Type(name = "MariaDBSource", value = MariaDBSource.class), @JsonSubTypes.Type(name = "MagentoSource", value = MagentoSource.class), @JsonSubTypes.Type(name = "JiraSource", value = JiraSource.class), @@ -84,7 +83,6 @@ @JsonSubTypes.Type(name = "SalesforceServiceCloudSource", value = SalesforceServiceCloudSource.class), @JsonSubTypes.Type(name = "SalesforceSource", value = SalesforceSource.class), @JsonSubTypes.Type(name = "ODataSource", value = ODataSource.class), - @JsonSubTypes.Type(name = "SapBwSource", value = SapBwSource.class), @JsonSubTypes.Type(name = "SybaseSource", value = SybaseSource.class), @JsonSubTypes.Type(name = "PostgreSqlSource", value = PostgreSqlSource.class), @JsonSubTypes.Type(name = "MySqlSource", value = MySqlSource.class), diff --git a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/Office365Source.java b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/Office365Source.java index 3f15d7fb5424b..7c1babfed200d 100644 --- a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/Office365Source.java +++ b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/Office365Source.java @@ -8,7 +8,6 @@ package com.microsoft.azure.management.datafactory.v2018_06_01; -import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -18,139 +17,4 @@ @JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "type") @JsonTypeName("Office365Source") public class Office365Source extends CopySource { - /** - * The groups containing all the users. Type: array of strings (or - * Expression with resultType array of strings). - */ - @JsonProperty(value = "allowedGroups") - private Object allowedGroups; - - /** - * The user scope uri. Type: string (or Expression with resultType string). - */ - @JsonProperty(value = "userScopeFilterUri") - private Object userScopeFilterUri; - - /** - * The Column to apply the <paramref name="StartTime"/> and - * <paramref name="EndTime"/>. Type: string (or Expression with - * resultType string). - */ - @JsonProperty(value = "dateFilterColumn") - private Object dateFilterColumn; - - /** - * Start time of the requested range for this dataset. Type: string (or - * Expression with resultType string). - */ - @JsonProperty(value = "startTime") - private Object startTime; - - /** - * End time of the requested range for thsi dataset. Type: string (or - * Expression with resultType string). - */ - @JsonProperty(value = "endTime") - private Object endTime; - - /** - * Get the groups containing all the users. Type: array of strings (or Expression with resultType array of strings). - * - * @return the allowedGroups value - */ - public Object allowedGroups() { - return this.allowedGroups; - } - - /** - * Set the groups containing all the users. Type: array of strings (or Expression with resultType array of strings). - * - * @param allowedGroups the allowedGroups value to set - * @return the Office365Source object itself. - */ - public Office365Source withAllowedGroups(Object allowedGroups) { - this.allowedGroups = allowedGroups; - return this; - } - - /** - * Get the user scope uri. Type: string (or Expression with resultType string). - * - * @return the userScopeFilterUri value - */ - public Object userScopeFilterUri() { - return this.userScopeFilterUri; - } - - /** - * Set the user scope uri. Type: string (or Expression with resultType string). - * - * @param userScopeFilterUri the userScopeFilterUri value to set - * @return the Office365Source object itself. - */ - public Office365Source withUserScopeFilterUri(Object userScopeFilterUri) { - this.userScopeFilterUri = userScopeFilterUri; - return this; - } - - /** - * Get the Column to apply the <paramref name="StartTime"/> and <paramref name="EndTime"/>. Type: string (or Expression with resultType string). - * - * @return the dateFilterColumn value - */ - public Object dateFilterColumn() { - return this.dateFilterColumn; - } - - /** - * Set the Column to apply the <paramref name="StartTime"/> and <paramref name="EndTime"/>. Type: string (or Expression with resultType string). - * - * @param dateFilterColumn the dateFilterColumn value to set - * @return the Office365Source object itself. - */ - public Office365Source withDateFilterColumn(Object dateFilterColumn) { - this.dateFilterColumn = dateFilterColumn; - return this; - } - - /** - * Get start time of the requested range for this dataset. Type: string (or Expression with resultType string). - * - * @return the startTime value - */ - public Object startTime() { - return this.startTime; - } - - /** - * Set start time of the requested range for this dataset. Type: string (or Expression with resultType string). - * - * @param startTime the startTime value to set - * @return the Office365Source object itself. - */ - public Office365Source withStartTime(Object startTime) { - this.startTime = startTime; - return this; - } - - /** - * Get end time of the requested range for thsi dataset. Type: string (or Expression with resultType string). - * - * @return the endTime value - */ - public Object endTime() { - return this.endTime; - } - - /** - * Set end time of the requested range for thsi dataset. Type: string (or Expression with resultType string). - * - * @param endTime the endTime value to set - * @return the Office365Source object itself. - */ - public Office365Source withEndTime(Object endTime) { - this.endTime = endTime; - return this; - } - } diff --git a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/RestSource.java b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/RestSource.java index 670ad210007ae..dd2d0cf303dca 100644 --- a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/RestSource.java +++ b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/RestSource.java @@ -18,34 +18,6 @@ @JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "type") @JsonTypeName("RestSource") public class RestSource extends CopySource { - /** - * The HTTP method used to call the RESTful API. The default is GET. Type: - * string (or Expression with resultType string). - */ - @JsonProperty(value = "requestMethod") - private Object requestMethod; - - /** - * The HTTP request body to the RESTful API if requestMethod is POST. Type: - * string (or Expression with resultType string). - */ - @JsonProperty(value = "requestBody") - private Object requestBody; - - /** - * The additional HTTP headers in the request to the RESTful API. Type: - * string (or Expression with resultType string). - */ - @JsonProperty(value = "additionalHeaders") - private Object additionalHeaders; - - /** - * The pagination rules to compose next page requests. Type: string (or - * Expression with resultType string). - */ - @JsonProperty(value = "paginationRules") - private Object paginationRules; - /** * The timeout (TimeSpan) to get an HTTP response. It is the timeout to get * a response, not the timeout to read response data. Default value: @@ -61,86 +33,6 @@ public class RestSource extends CopySource { @JsonProperty(value = "requestInterval") private Object requestInterval; - /** - * Get the HTTP method used to call the RESTful API. The default is GET. Type: string (or Expression with resultType string). - * - * @return the requestMethod value - */ - public Object requestMethod() { - return this.requestMethod; - } - - /** - * Set the HTTP method used to call the RESTful API. The default is GET. Type: string (or Expression with resultType string). - * - * @param requestMethod the requestMethod value to set - * @return the RestSource object itself. - */ - public RestSource withRequestMethod(Object requestMethod) { - this.requestMethod = requestMethod; - return this; - } - - /** - * Get the HTTP request body to the RESTful API if requestMethod is POST. Type: string (or Expression with resultType string). - * - * @return the requestBody value - */ - public Object requestBody() { - return this.requestBody; - } - - /** - * Set the HTTP request body to the RESTful API if requestMethod is POST. Type: string (or Expression with resultType string). - * - * @param requestBody the requestBody value to set - * @return the RestSource object itself. - */ - public RestSource withRequestBody(Object requestBody) { - this.requestBody = requestBody; - return this; - } - - /** - * Get the additional HTTP headers in the request to the RESTful API. Type: string (or Expression with resultType string). - * - * @return the additionalHeaders value - */ - public Object additionalHeaders() { - return this.additionalHeaders; - } - - /** - * Set the additional HTTP headers in the request to the RESTful API. Type: string (or Expression with resultType string). - * - * @param additionalHeaders the additionalHeaders value to set - * @return the RestSource object itself. - */ - public RestSource withAdditionalHeaders(Object additionalHeaders) { - this.additionalHeaders = additionalHeaders; - return this; - } - - /** - * Get the pagination rules to compose next page requests. Type: string (or Expression with resultType string). - * - * @return the paginationRules value - */ - public Object paginationRules() { - return this.paginationRules; - } - - /** - * Set the pagination rules to compose next page requests. Type: string (or Expression with resultType string). - * - * @param paginationRules the paginationRules value to set - * @return the RestSource object itself. - */ - public RestSource withPaginationRules(Object paginationRules) { - this.paginationRules = paginationRules; - return this; - } - /** * Get the timeout (TimeSpan) to get an HTTP response. It is the timeout to get a response, not the timeout to read response data. Default value: 00:01:40. Type: string (or Expression with resultType string), pattern: ((\d+)\.)?(\d\d):(60|([0-5][0-9])):(60|([0-5][0-9])). * diff --git a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/SapOpenHubSource.java b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/SapOpenHubSource.java index 853793f099f2c..2a925f1f4b02a 100644 --- a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/SapOpenHubSource.java +++ b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/SapOpenHubSource.java @@ -8,7 +8,6 @@ package com.microsoft.azure.management.datafactory.v2018_06_01; -import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -19,60 +18,4 @@ @JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "type") @JsonTypeName("SapOpenHubSource") public class SapOpenHubSource extends CopySource { - /** - * Whether to exclude the records of the last request. The default value is - * true. Type: boolean (or Expression with resultType boolean). - */ - @JsonProperty(value = "excludeLastRequest") - private Object excludeLastRequest; - - /** - * The ID of request for delta loading. Once it is set, only data with - * requestId larger than the value of this property will be retrieved. The - * default value is 0. Type: integer (or Expression with resultType integer - * ). - */ - @JsonProperty(value = "baseRequestId") - private Object baseRequestId; - - /** - * Get whether to exclude the records of the last request. The default value is true. Type: boolean (or Expression with resultType boolean). - * - * @return the excludeLastRequest value - */ - public Object excludeLastRequest() { - return this.excludeLastRequest; - } - - /** - * Set whether to exclude the records of the last request. The default value is true. Type: boolean (or Expression with resultType boolean). - * - * @param excludeLastRequest the excludeLastRequest value to set - * @return the SapOpenHubSource object itself. - */ - public SapOpenHubSource withExcludeLastRequest(Object excludeLastRequest) { - this.excludeLastRequest = excludeLastRequest; - return this; - } - - /** - * Get the ID of request for delta loading. Once it is set, only data with requestId larger than the value of this property will be retrieved. The default value is 0. Type: integer (or Expression with resultType integer ). - * - * @return the baseRequestId value - */ - public Object baseRequestId() { - return this.baseRequestId; - } - - /** - * Set the ID of request for delta loading. Once it is set, only data with requestId larger than the value of this property will be retrieved. The default value is 0. Type: integer (or Expression with resultType integer ). - * - * @param baseRequestId the baseRequestId value to set - * @return the SapOpenHubSource object itself. - */ - public SapOpenHubSource withBaseRequestId(Object baseRequestId) { - this.baseRequestId = baseRequestId; - return this; - } - } diff --git a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/TriggerRuns.java b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/TriggerRuns.java index bdce89dc5fefb..495f1ccde4d13 100644 --- a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/TriggerRuns.java +++ b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/TriggerRuns.java @@ -8,25 +8,14 @@ package com.microsoft.azure.management.datafactory.v2018_06_01; -import rx.Completable; import rx.Observable; +import com.microsoft.azure.management.datafactory.v2018_06_01.implementation.TriggerRunsInner; +import com.microsoft.azure.arm.model.HasInner; /** * Type representing TriggerRuns. */ -public interface TriggerRuns { - /** - * Rerun single trigger instance by runId. - * - * @param resourceGroupName The resource group name. - * @param factoryName The factory name. - * @param triggerName The trigger name. - * @param runId The pipeline run identifier. - * @throws IllegalArgumentException thrown if parameters fail the validation - * @return the observable for the request - */ - Completable rerunAsync(String resourceGroupName, String factoryName, String triggerName, String runId); - +public interface TriggerRuns extends HasInner { /** * Query trigger runs. * diff --git a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/implementation/DataFactoryManagementClientImpl.java b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/implementation/DataFactoryManagementClientImpl.java index 97f5e26e12319..2d8f762b9a0df 100644 --- a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/implementation/DataFactoryManagementClientImpl.java +++ b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/implementation/DataFactoryManagementClientImpl.java @@ -289,29 +289,29 @@ public TriggersInner triggers() { } /** - * The TriggerRunsInner object to access its operations. + * The RerunTriggersInner object to access its operations. */ - private TriggerRunsInner triggerRuns; + private RerunTriggersInner rerunTriggers; /** - * Gets the TriggerRunsInner object to access its operations. - * @return the TriggerRunsInner object. + * Gets the RerunTriggersInner object to access its operations. + * @return the RerunTriggersInner object. */ - public TriggerRunsInner triggerRuns() { - return this.triggerRuns; + public RerunTriggersInner rerunTriggers() { + return this.rerunTriggers; } /** - * The RerunTriggersInner object to access its operations. + * The TriggerRunsInner object to access its operations. */ - private RerunTriggersInner rerunTriggers; + private TriggerRunsInner triggerRuns; /** - * Gets the RerunTriggersInner object to access its operations. - * @return the RerunTriggersInner object. + * Gets the TriggerRunsInner object to access its operations. + * @return the TriggerRunsInner object. */ - public RerunTriggersInner rerunTriggers() { - return this.rerunTriggers; + public TriggerRunsInner triggerRuns() { + return this.triggerRuns; } /** @@ -361,8 +361,8 @@ protected void initialize() { this.pipelineRuns = new PipelineRunsInner(restClient().retrofit(), this); this.activityRuns = new ActivityRunsInner(restClient().retrofit(), this); this.triggers = new TriggersInner(restClient().retrofit(), this); - this.triggerRuns = new TriggerRunsInner(restClient().retrofit(), this); this.rerunTriggers = new RerunTriggersInner(restClient().retrofit(), this); + this.triggerRuns = new TriggerRunsInner(restClient().retrofit(), this); this.azureClient = new AzureClient(this); } diff --git a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/implementation/DataFactoryManager.java b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/implementation/DataFactoryManager.java index 66332e2048d5c..ac05e913b22dc 100644 --- a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/implementation/DataFactoryManager.java +++ b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/implementation/DataFactoryManager.java @@ -28,8 +28,8 @@ import com.microsoft.azure.management.datafactory.v2018_06_01.PipelineRuns; import com.microsoft.azure.management.datafactory.v2018_06_01.ActivityRuns; import com.microsoft.azure.management.datafactory.v2018_06_01.Triggers; -import com.microsoft.azure.management.datafactory.v2018_06_01.TriggerRuns; import com.microsoft.azure.management.datafactory.v2018_06_01.RerunTriggers; +import com.microsoft.azure.management.datafactory.v2018_06_01.TriggerRuns; import com.microsoft.azure.arm.resources.implementation.AzureConfigurableCoreImpl; import com.microsoft.azure.arm.resources.implementation.ManagerCore; @@ -49,8 +49,8 @@ public final class DataFactoryManager extends ManagerCore queryByFactoryAsync(String resourceGroupName, String factoryName, RunFilterParameters filterParameters) { TriggerRunsInner client = this.inner(); diff --git a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/implementation/TriggerRunsInner.java b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/implementation/TriggerRunsInner.java index 1ee31c0d96c82..11bd850a82a51 100644 --- a/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/implementation/TriggerRunsInner.java +++ b/datafactory/resource-manager/v2018_06_01/src/main/java/com/microsoft/azure/management/datafactory/v2018_06_01/implementation/TriggerRunsInner.java @@ -54,115 +54,12 @@ public TriggerRunsInner(Retrofit retrofit, DataFactoryManagementClientImpl clien * used by Retrofit to perform actually REST calls. */ interface TriggerRunsService { - @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.datafactory.v2018_06_01.TriggerRuns rerun" }) - @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/triggers/{triggerName}/triggerRuns/{runId}/rerun") - Observable> rerun(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("factoryName") String factoryName, @Path("triggerName") String triggerName, @Path("runId") String runId, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); - @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.datafactory.v2018_06_01.TriggerRuns queryByFactory" }) @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/queryTriggerRuns") Observable> queryByFactory(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("factoryName") String factoryName, @Query("api-version") String apiVersion, @Body RunFilterParameters filterParameters, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); } - /** - * Rerun single trigger instance by runId. - * - * @param resourceGroupName The resource group name. - * @param factoryName The factory name. - * @param triggerName The trigger name. - * @param runId The pipeline run identifier. - * @throws IllegalArgumentException thrown if parameters fail the validation - * @throws CloudException thrown if the request is rejected by server - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent - */ - public void rerun(String resourceGroupName, String factoryName, String triggerName, String runId) { - rerunWithServiceResponseAsync(resourceGroupName, factoryName, triggerName, runId).toBlocking().single().body(); - } - - /** - * Rerun single trigger instance by runId. - * - * @param resourceGroupName The resource group name. - * @param factoryName The factory name. - * @param triggerName The trigger name. - * @param runId The pipeline run identifier. - * @param serviceCallback the async ServiceCallback to handle successful and failed responses. - * @throws IllegalArgumentException thrown if parameters fail the validation - * @return the {@link ServiceFuture} object - */ - public ServiceFuture rerunAsync(String resourceGroupName, String factoryName, String triggerName, String runId, final ServiceCallback serviceCallback) { - return ServiceFuture.fromResponse(rerunWithServiceResponseAsync(resourceGroupName, factoryName, triggerName, runId), serviceCallback); - } - - /** - * Rerun single trigger instance by runId. - * - * @param resourceGroupName The resource group name. - * @param factoryName The factory name. - * @param triggerName The trigger name. - * @param runId The pipeline run identifier. - * @throws IllegalArgumentException thrown if parameters fail the validation - * @return the {@link ServiceResponse} object if successful. - */ - public Observable rerunAsync(String resourceGroupName, String factoryName, String triggerName, String runId) { - return rerunWithServiceResponseAsync(resourceGroupName, factoryName, triggerName, runId).map(new Func1, Void>() { - @Override - public Void call(ServiceResponse response) { - return response.body(); - } - }); - } - - /** - * Rerun single trigger instance by runId. - * - * @param resourceGroupName The resource group name. - * @param factoryName The factory name. - * @param triggerName The trigger name. - * @param runId The pipeline run identifier. - * @throws IllegalArgumentException thrown if parameters fail the validation - * @return the {@link ServiceResponse} object if successful. - */ - public Observable> rerunWithServiceResponseAsync(String resourceGroupName, String factoryName, String triggerName, String runId) { - if (this.client.subscriptionId() == null) { - throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); - } - if (resourceGroupName == null) { - throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); - } - if (factoryName == null) { - throw new IllegalArgumentException("Parameter factoryName is required and cannot be null."); - } - if (triggerName == null) { - throw new IllegalArgumentException("Parameter triggerName is required and cannot be null."); - } - if (runId == null) { - throw new IllegalArgumentException("Parameter runId is required and cannot be null."); - } - if (this.client.apiVersion() == null) { - throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); - } - return service.rerun(this.client.subscriptionId(), resourceGroupName, factoryName, triggerName, runId, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) - .flatMap(new Func1, Observable>>() { - @Override - public Observable> call(Response response) { - try { - ServiceResponse clientResponse = rerunDelegate(response); - return Observable.just(clientResponse); - } catch (Throwable t) { - return Observable.error(t); - } - } - }); - } - - private ServiceResponse rerunDelegate(Response response) throws CloudException, IOException, IllegalArgumentException { - return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) - .register(200, new TypeToken() { }.getType()) - .registerError(CloudException.class) - .build(response); - } - /** * Query trigger runs. *