Skip to content

Commit fa34cfb

Browse files
authored
[Automation] Generate Fluent Lite from azurearcdata#package-2021-08-01 (Azure#24307)
1 parent 86e6698 commit fa34cfb

File tree

46 files changed

+1347
-315
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+1347
-315
lines changed

sdk/azurearcdata/azure-resourcemanager-azurearcdata/CHANGELOG.md

Lines changed: 35 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,41 @@
11
# Release History
22

3-
## 1.0.0-beta.2 (Unreleased)
3+
## 1.0.0-beta.2 (2021-09-24)
44

5+
- Azure Resource Manager AzureArcData client library for Java. This package contains Microsoft Azure SDK for AzureArcData Management SDK. The AzureArcData management API provides a RESTful set of web APIs to manage Azure Data Services on Azure Arc Resources. Package tag package-2021-08-01. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
6+
7+
### Breaking Changes
8+
9+
* `models.ResourceIdentityType` was removed
10+
11+
#### `models.SqlManagedInstances` was modified
12+
13+
* `deleteWithResponse(java.lang.String,java.lang.String,com.azure.core.util.Context)` was removed
14+
* `com.azure.core.http.rest.Response deleteByIdWithResponse(java.lang.String,com.azure.core.util.Context)` -> `void deleteByIdWithResponse(java.lang.String,com.azure.core.util.Context)`
15+
16+
#### `models.SqlServerInstances` was modified
17+
18+
* `deleteWithResponse(java.lang.String,java.lang.String,com.azure.core.util.Context)` was removed
19+
* `com.azure.core.http.rest.Response deleteByIdWithResponse(java.lang.String,com.azure.core.util.Context)` -> `void deleteByIdWithResponse(java.lang.String,com.azure.core.util.Context)`
20+
21+
#### `models.DataControllers` was modified
22+
23+
* `com.azure.core.http.rest.Response deleteByIdWithResponse(java.lang.String,com.azure.core.util.Context)` -> `void deleteByIdWithResponse(java.lang.String,com.azure.core.util.Context)`
24+
* `deleteWithResponse(java.lang.String,java.lang.String,com.azure.core.util.Context)` was removed
25+
26+
### Features Added
27+
28+
#### `models.SqlManagedInstances` was modified
29+
30+
* `delete(java.lang.String,java.lang.String,com.azure.core.util.Context)` was added
31+
32+
#### `models.SqlServerInstances` was modified
33+
34+
* `delete(java.lang.String,java.lang.String,com.azure.core.util.Context)` was added
35+
36+
#### `models.DataControllers` was modified
37+
38+
* `delete(java.lang.String,java.lang.String,com.azure.core.util.Context)` was added
539

640
## 1.0.0-beta.1 (2021-07-21)
741

sdk/azurearcdata/azure-resourcemanager-azurearcdata/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ Various documentation is available to help you get started
3232
<dependency>
3333
<groupId>com.azure.resourcemanager</groupId>
3434
<artifactId>azure-resourcemanager-azurearcdata</artifactId>
35-
<version>1.0.0-beta.1</version>
35+
<version>1.0.0-beta.2</version>
3636
</dependency>
3737
```
3838
[//]: # ({x-version-update-end})

sdk/azurearcdata/azure-resourcemanager-azurearcdata/SAMPLE.md

Lines changed: 675 additions & 23 deletions
Large diffs are not rendered by default.

sdk/azurearcdata/azure-resourcemanager-azurearcdata/src/main/java/com/azure/resourcemanager/azurearcdata/AzureArcDataManager.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ public AzureArcDataManager authenticate(TokenCredential credential, AzureProfile
185185
.append("-")
186186
.append("com.azure.resourcemanager.azurearcdata")
187187
.append("/")
188-
.append("1.0.0-beta.1");
188+
.append("1.0.0-beta.2");
189189
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
190190
userAgentBuilder
191191
.append(" (")

sdk/azurearcdata/azure-resourcemanager-azurearcdata/src/main/java/com/azure/resourcemanager/azurearcdata/fluent/DataControllersClient.java

Lines changed: 29 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,34 @@ DataControllerResourceInner putDataController(
131131
DataControllerResourceInner dataControllerResource,
132132
Context context);
133133

134+
/**
135+
* Deletes a dataController resource.
136+
*
137+
* @param resourceGroupName The name of the Azure resource group.
138+
* @param dataControllerName The dataControllerName parameter.
139+
* @throws IllegalArgumentException thrown if parameters fail the validation.
140+
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
141+
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
142+
* @return the completion.
143+
*/
144+
@ServiceMethod(returns = ReturnType.SINGLE)
145+
SyncPoller<PollResult<Void>, Void> beginDelete(String resourceGroupName, String dataControllerName);
146+
147+
/**
148+
* Deletes a dataController resource.
149+
*
150+
* @param resourceGroupName The name of the Azure resource group.
151+
* @param dataControllerName The dataControllerName parameter.
152+
* @param context The context to associate with this operation.
153+
* @throws IllegalArgumentException thrown if parameters fail the validation.
154+
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
155+
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
156+
* @return the completion.
157+
*/
158+
@ServiceMethod(returns = ReturnType.SINGLE)
159+
SyncPoller<PollResult<Void>, Void> beginDelete(
160+
String resourceGroupName, String dataControllerName, Context context);
161+
134162
/**
135163
* Deletes a dataController resource.
136164
*
@@ -152,10 +180,9 @@ DataControllerResourceInner putDataController(
152180
* @throws IllegalArgumentException thrown if parameters fail the validation.
153181
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
154182
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
155-
* @return the response.
156183
*/
157184
@ServiceMethod(returns = ReturnType.SINGLE)
158-
Response<Void> deleteWithResponse(String resourceGroupName, String dataControllerName, Context context);
185+
void delete(String resourceGroupName, String dataControllerName, Context context);
159186

160187
/**
161188
* Retrieves a dataController resource.

sdk/azurearcdata/azure-resourcemanager-azurearcdata/src/main/java/com/azure/resourcemanager/azurearcdata/fluent/SqlManagedInstancesClient.java

Lines changed: 29 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,34 @@ SqlManagedInstanceInner create(
159159
SqlManagedInstanceInner sqlManagedInstance,
160160
Context context);
161161

162+
/**
163+
* Deletes a SQL Managed Instance resource.
164+
*
165+
* @param resourceGroupName The name of the Azure resource group.
166+
* @param sqlManagedInstanceName The name of Sql Managed Instances.
167+
* @throws IllegalArgumentException thrown if parameters fail the validation.
168+
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
169+
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
170+
* @return the completion.
171+
*/
172+
@ServiceMethod(returns = ReturnType.SINGLE)
173+
SyncPoller<PollResult<Void>, Void> beginDelete(String resourceGroupName, String sqlManagedInstanceName);
174+
175+
/**
176+
* Deletes a SQL Managed Instance resource.
177+
*
178+
* @param resourceGroupName The name of the Azure resource group.
179+
* @param sqlManagedInstanceName The name of Sql Managed Instances.
180+
* @param context The context to associate with this operation.
181+
* @throws IllegalArgumentException thrown if parameters fail the validation.
182+
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
183+
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
184+
* @return the completion.
185+
*/
186+
@ServiceMethod(returns = ReturnType.SINGLE)
187+
SyncPoller<PollResult<Void>, Void> beginDelete(
188+
String resourceGroupName, String sqlManagedInstanceName, Context context);
189+
162190
/**
163191
* Deletes a SQL Managed Instance resource.
164192
*
@@ -180,10 +208,9 @@ SqlManagedInstanceInner create(
180208
* @throws IllegalArgumentException thrown if parameters fail the validation.
181209
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
182210
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
183-
* @return the response.
184211
*/
185212
@ServiceMethod(returns = ReturnType.SINGLE)
186-
Response<Void> deleteWithResponse(String resourceGroupName, String sqlManagedInstanceName, Context context);
213+
void delete(String resourceGroupName, String sqlManagedInstanceName, Context context);
187214

188215
/**
189216
* Updates a SQL Managed Instance resource.

sdk/azurearcdata/azure-resourcemanager-azurearcdata/src/main/java/com/azure/resourcemanager/azurearcdata/fluent/SqlServerInstancesClient.java

Lines changed: 29 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,34 @@ SqlServerInstanceInner create(
159159
SqlServerInstanceInner sqlServerInstance,
160160
Context context);
161161

162+
/**
163+
* Deletes a SQL Server Instance resource.
164+
*
165+
* @param resourceGroupName The name of the Azure resource group.
166+
* @param sqlServerInstanceName The name of SQL Server Instance.
167+
* @throws IllegalArgumentException thrown if parameters fail the validation.
168+
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
169+
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
170+
* @return the completion.
171+
*/
172+
@ServiceMethod(returns = ReturnType.SINGLE)
173+
SyncPoller<PollResult<Void>, Void> beginDelete(String resourceGroupName, String sqlServerInstanceName);
174+
175+
/**
176+
* Deletes a SQL Server Instance resource.
177+
*
178+
* @param resourceGroupName The name of the Azure resource group.
179+
* @param sqlServerInstanceName The name of SQL Server Instance.
180+
* @param context The context to associate with this operation.
181+
* @throws IllegalArgumentException thrown if parameters fail the validation.
182+
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
183+
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
184+
* @return the completion.
185+
*/
186+
@ServiceMethod(returns = ReturnType.SINGLE)
187+
SyncPoller<PollResult<Void>, Void> beginDelete(
188+
String resourceGroupName, String sqlServerInstanceName, Context context);
189+
162190
/**
163191
* Deletes a SQL Server Instance resource.
164192
*
@@ -180,10 +208,9 @@ SqlServerInstanceInner create(
180208
* @throws IllegalArgumentException thrown if parameters fail the validation.
181209
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
182210
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
183-
* @return the response.
184211
*/
185212
@ServiceMethod(returns = ReturnType.SINGLE)
186-
Response<Void> deleteWithResponse(String resourceGroupName, String sqlServerInstanceName, Context context);
213+
void delete(String resourceGroupName, String sqlServerInstanceName, Context context);
187214

188215
/**
189216
* Updates a SQL Server Instance resource.

sdk/azurearcdata/azure-resourcemanager-azurearcdata/src/main/java/com/azure/resourcemanager/azurearcdata/fluent/models/OperationInner.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
import com.azure.resourcemanager.azurearcdata.models.OperationDisplay;
1010
import com.azure.resourcemanager.azurearcdata.models.OperationOrigin;
1111
import com.fasterxml.jackson.annotation.JsonIgnore;
12+
import com.fasterxml.jackson.annotation.JsonInclude;
1213
import com.fasterxml.jackson.annotation.JsonProperty;
1314
import java.util.Map;
1415

@@ -46,6 +47,7 @@ public final class OperationInner {
4647
* Additional descriptions for the operation.
4748
*/
4849
@JsonProperty(value = "properties", access = JsonProperty.Access.WRITE_ONLY)
50+
@JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS)
4951
private Map<String, Object> properties;
5052

5153
/**

sdk/azurearcdata/azure-resourcemanager-azurearcdata/src/main/java/com/azure/resourcemanager/azurearcdata/implementation/DataControllersClientImpl.java

Lines changed: 99 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -114,9 +114,9 @@ Mono<Response<Flux<ByteBuffer>>> putDataController(
114114
@Delete(
115115
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AzureArcData"
116116
+ "/dataControllers/{dataControllerName}")
117-
@ExpectedResponses({200, 204})
117+
@ExpectedResponses({200, 202, 204})
118118
@UnexpectedResponseExceptionType(ManagementException.class)
119-
Mono<Response<Void>> delete(
119+
Mono<Response<Flux<ByteBuffer>>> delete(
120120
@HostParam("$host") String endpoint,
121121
@PathParam("subscriptionId") String subscriptionId,
122122
@PathParam("resourceGroupName") String resourceGroupName,
@@ -789,7 +789,8 @@ public DataControllerResourceInner putDataController(
789789
* @return the completion.
790790
*/
791791
@ServiceMethod(returns = ReturnType.SINGLE)
792-
private Mono<Response<Void>> deleteWithResponseAsync(String resourceGroupName, String dataControllerName) {
792+
private Mono<Response<Flux<ByteBuffer>>> deleteWithResponseAsync(
793+
String resourceGroupName, String dataControllerName) {
793794
if (this.client.getEndpoint() == null) {
794795
return Mono
795796
.error(
@@ -838,7 +839,7 @@ private Mono<Response<Void>> deleteWithResponseAsync(String resourceGroupName, S
838839
* @return the completion.
839840
*/
840841
@ServiceMethod(returns = ReturnType.SINGLE)
841-
private Mono<Response<Void>> deleteWithResponseAsync(
842+
private Mono<Response<Flux<ByteBuffer>>> deleteWithResponseAsync(
842843
String resourceGroupName, String dataControllerName, Context context) {
843844
if (this.client.getEndpoint() == null) {
844845
return Mono
@@ -873,6 +874,77 @@ private Mono<Response<Void>> deleteWithResponseAsync(
873874
context);
874875
}
875876

877+
/**
878+
* Deletes a dataController resource.
879+
*
880+
* @param resourceGroupName The name of the Azure resource group.
881+
* @param dataControllerName The dataControllerName parameter.
882+
* @throws IllegalArgumentException thrown if parameters fail the validation.
883+
* @throws ManagementException thrown if the request is rejected by server.
884+
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
885+
* @return the completion.
886+
*/
887+
@ServiceMethod(returns = ReturnType.SINGLE)
888+
private PollerFlux<PollResult<Void>, Void> beginDeleteAsync(String resourceGroupName, String dataControllerName) {
889+
Mono<Response<Flux<ByteBuffer>>> mono = deleteWithResponseAsync(resourceGroupName, dataControllerName);
890+
return this
891+
.client
892+
.<Void, Void>getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, Context.NONE);
893+
}
894+
895+
/**
896+
* Deletes a dataController resource.
897+
*
898+
* @param resourceGroupName The name of the Azure resource group.
899+
* @param dataControllerName The dataControllerName parameter.
900+
* @param context The context to associate with this operation.
901+
* @throws IllegalArgumentException thrown if parameters fail the validation.
902+
* @throws ManagementException thrown if the request is rejected by server.
903+
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
904+
* @return the completion.
905+
*/
906+
@ServiceMethod(returns = ReturnType.SINGLE)
907+
private PollerFlux<PollResult<Void>, Void> beginDeleteAsync(
908+
String resourceGroupName, String dataControllerName, Context context) {
909+
context = this.client.mergeContext(context);
910+
Mono<Response<Flux<ByteBuffer>>> mono = deleteWithResponseAsync(resourceGroupName, dataControllerName, context);
911+
return this
912+
.client
913+
.<Void, Void>getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, context);
914+
}
915+
916+
/**
917+
* Deletes a dataController resource.
918+
*
919+
* @param resourceGroupName The name of the Azure resource group.
920+
* @param dataControllerName The dataControllerName parameter.
921+
* @throws IllegalArgumentException thrown if parameters fail the validation.
922+
* @throws ManagementException thrown if the request is rejected by server.
923+
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
924+
* @return the completion.
925+
*/
926+
@ServiceMethod(returns = ReturnType.SINGLE)
927+
public SyncPoller<PollResult<Void>, Void> beginDelete(String resourceGroupName, String dataControllerName) {
928+
return beginDeleteAsync(resourceGroupName, dataControllerName).getSyncPoller();
929+
}
930+
931+
/**
932+
* Deletes a dataController resource.
933+
*
934+
* @param resourceGroupName The name of the Azure resource group.
935+
* @param dataControllerName The dataControllerName parameter.
936+
* @param context The context to associate with this operation.
937+
* @throws IllegalArgumentException thrown if parameters fail the validation.
938+
* @throws ManagementException thrown if the request is rejected by server.
939+
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
940+
* @return the completion.
941+
*/
942+
@ServiceMethod(returns = ReturnType.SINGLE)
943+
public SyncPoller<PollResult<Void>, Void> beginDelete(
944+
String resourceGroupName, String dataControllerName, Context context) {
945+
return beginDeleteAsync(resourceGroupName, dataControllerName, context).getSyncPoller();
946+
}
947+
876948
/**
877949
* Deletes a dataController resource.
878950
*
@@ -885,8 +957,27 @@ private Mono<Response<Void>> deleteWithResponseAsync(
885957
*/
886958
@ServiceMethod(returns = ReturnType.SINGLE)
887959
private Mono<Void> deleteAsync(String resourceGroupName, String dataControllerName) {
888-
return deleteWithResponseAsync(resourceGroupName, dataControllerName)
889-
.flatMap((Response<Void> res) -> Mono.empty());
960+
return beginDeleteAsync(resourceGroupName, dataControllerName)
961+
.last()
962+
.flatMap(this.client::getLroFinalResultOrError);
963+
}
964+
965+
/**
966+
* Deletes a dataController resource.
967+
*
968+
* @param resourceGroupName The name of the Azure resource group.
969+
* @param dataControllerName The dataControllerName parameter.
970+
* @param context The context to associate with this operation.
971+
* @throws IllegalArgumentException thrown if parameters fail the validation.
972+
* @throws ManagementException thrown if the request is rejected by server.
973+
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
974+
* @return the completion.
975+
*/
976+
@ServiceMethod(returns = ReturnType.SINGLE)
977+
private Mono<Void> deleteAsync(String resourceGroupName, String dataControllerName, Context context) {
978+
return beginDeleteAsync(resourceGroupName, dataControllerName, context)
979+
.last()
980+
.flatMap(this.client::getLroFinalResultOrError);
890981
}
891982

892983
/**
@@ -912,11 +1003,10 @@ public void delete(String resourceGroupName, String dataControllerName) {
9121003
* @throws IllegalArgumentException thrown if parameters fail the validation.
9131004
* @throws ManagementException thrown if the request is rejected by server.
9141005
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
915-
* @return the response.
9161006
*/
9171007
@ServiceMethod(returns = ReturnType.SINGLE)
918-
public Response<Void> deleteWithResponse(String resourceGroupName, String dataControllerName, Context context) {
919-
return deleteWithResponseAsync(resourceGroupName, dataControllerName, context).block();
1008+
public void delete(String resourceGroupName, String dataControllerName, Context context) {
1009+
deleteAsync(resourceGroupName, dataControllerName, context).block();
9201010
}
9211011

9221012
/**

0 commit comments

Comments
 (0)