diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/CHANGELOG.md b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/CHANGELOG.md index 6534b7b532585..579af662cfc5c 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/CHANGELOG.md +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/CHANGELOG.md @@ -1,14 +1,8 @@ # Release History -## 1.0.0-beta.6 (Unreleased) +## 1.0.0-beta.6 (2023-04-18) -### Features Added - -### Breaking Changes - -### Bugs Fixed - -### Other Changes +- Azure Resource Manager PostgreSql client library for Java. This package contains Microsoft Azure SDK for PostgreSql Management SDK. The Microsoft Azure management API provides create, read, update, and delete functionality for Azure PostgreSQL resources including servers, databases, firewall rules, VNET rules, security alert policies, log files and configurations with new business model. Package tag package-flexibleserver-2022-12-01. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt). ## 1.0.0-beta.5 (2023-01-11) diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/README.md b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/README.md index 15cf4f6c55a79..f78faf946b6d1 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/README.md +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/README.md @@ -32,7 +32,7 @@ Various documentation is available to help you get started com.azure.resourcemanager azure-resourcemanager-postgresqlflexibleserver - 1.0.0-beta.5 + 1.0.0-beta.6 ``` [//]: # ({x-version-update-end}) diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/SAMPLE.md b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/SAMPLE.md index 6d8ac826686e5..0456cfae25d9a 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/SAMPLE.md +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/SAMPLE.md @@ -757,7 +757,7 @@ public final class ServersCreateSamples { .withActiveDirectoryAuth(ActiveDirectoryAuthEnum.ENABLED) .withPasswordAuth(PasswordAuthEnum.ENABLED) .withTenantId("tttttt-tttt-tttt-tttt-tttttttttttt")) - .withDataEncryption(new DataEncryption().withType(ArmServerKeyType.fromString("SystemManaged"))) + .withDataEncryption(new DataEncryption().withType(ArmServerKeyType.SYSTEM_MANAGED)) .withBackup(new Backup().withBackupRetentionDays(7).withGeoRedundantBackup(GeoRedundantBackupEnum.DISABLED)) .withNetwork( new Network() diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/pom.xml b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/pom.xml index 06e368471b3c7..c07453b6eb471 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/pom.xml +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/pom.xml @@ -1,3 +1,8 @@ + 4.0.0 @@ -38,7 +43,8 @@ UTF-8 - true + 0 + 0 diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/PostgreSqlManager.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/PostgreSqlManager.java index be2a0dfb888ba..db3138bbea50d 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/PostgreSqlManager.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/PostgreSqlManager.java @@ -255,7 +255,7 @@ public PostgreSqlManager authenticate(TokenCredential credential, AzureProfile p .append("-") .append("com.azure.resourcemanager.postgresqlflexibleserver") .append("/") - .append("1.0.0-beta.5"); + .append("1.0.0-beta.6"); if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) { userAgentBuilder .append(" (") diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/AdministratorsClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/AdministratorsClient.java index e162e63a20655..83f6c69a1d597 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/AdministratorsClient.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/AdministratorsClient.java @@ -6,16 +6,54 @@ import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; +import com.azure.core.http.rest.PagedFlux; import com.azure.core.http.rest.PagedIterable; import com.azure.core.http.rest.Response; import com.azure.core.management.polling.PollResult; import com.azure.core.util.Context; +import com.azure.core.util.polling.PollerFlux; import com.azure.core.util.polling.SyncPoller; import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ActiveDirectoryAdministratorInner; import com.azure.resourcemanager.postgresqlflexibleserver.models.ActiveDirectoryAdministratorAdd; +import java.nio.ByteBuffer; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in AdministratorsClient. */ public interface AdministratorsClient { + /** + * Creates a new server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param objectId Guid of the objectId for the administrator. + * @param parameters The required parameters for adding an active directory administrator for a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents an Active Directory administrator along with {@link Response} on successful completion of + * {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> createWithResponseAsync( + String resourceGroupName, String serverName, String objectId, ActiveDirectoryAdministratorAdd parameters); + + /** + * Creates a new server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param objectId Guid of the objectId for the administrator. + * @param parameters The required parameters for adding an active directory administrator for a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of represents an Active Directory administrator. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, ActiveDirectoryAdministratorInner> beginCreateAsync( + String resourceGroupName, String serverName, String objectId, ActiveDirectoryAdministratorAdd parameters); + /** * Creates a new server. * @@ -53,6 +91,22 @@ SyncPoller, ActiveDirectoryAdminis ActiveDirectoryAdministratorAdd parameters, Context context); + /** + * Creates a new server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param objectId Guid of the objectId for the administrator. + * @param parameters The required parameters for adding an active directory administrator for a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents an Active Directory administrator on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono createAsync( + String resourceGroupName, String serverName, String objectId, ActiveDirectoryAdministratorAdd parameters); + /** * Creates a new server. * @@ -90,6 +144,35 @@ ActiveDirectoryAdministratorInner create( ActiveDirectoryAdministratorAdd parameters, Context context); + /** + * Deletes an Active Directory Administrator associated with the server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param objectId Guid of the objectId for the administrator. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> deleteWithResponseAsync( + String resourceGroupName, String serverName, String objectId); + + /** + * Deletes an Active Directory Administrator associated with the server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param objectId Guid of the objectId for the administrator. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, Void> beginDeleteAsync(String resourceGroupName, String serverName, String objectId); + /** * Deletes an Active Directory Administrator associated with the server. * @@ -120,6 +203,20 @@ ActiveDirectoryAdministratorInner create( SyncPoller, Void> beginDelete( String resourceGroupName, String serverName, String objectId, Context context); + /** + * Deletes an Active Directory Administrator associated with the server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param objectId Guid of the objectId for the administrator. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return A {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono deleteAsync(String resourceGroupName, String serverName, String objectId); + /** * Deletes an Active Directory Administrator associated with the server. * @@ -147,6 +244,35 @@ SyncPoller, Void> beginDelete( @ServiceMethod(returns = ReturnType.SINGLE) void delete(String resourceGroupName, String serverName, String objectId, Context context); + /** + * Gets information about a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param objectId Guid of the objectId for the administrator. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return information about a server along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono> getWithResponseAsync( + String resourceGroupName, String serverName, String objectId); + + /** + * Gets information about a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param objectId Guid of the objectId for the administrator. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return information about a server on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono getAsync(String resourceGroupName, String serverName, String objectId); + /** * Gets information about a server. * @@ -177,6 +303,19 @@ Response getWithResponse( @ServiceMethod(returns = ReturnType.SINGLE) ActiveDirectoryAdministratorInner get(String resourceGroupName, String serverName, String objectId); + /** + * List all the AAD administrators for a given server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return a list of active directory administrators as paginated response with {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedFlux listByServerAsync(String resourceGroupName, String serverName); + /** * List all the AAD administrators for a given server. * diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/BackupsClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/BackupsClient.java index f247b57df09d5..52b26e479ffad 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/BackupsClient.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/BackupsClient.java @@ -6,13 +6,44 @@ import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; +import com.azure.core.http.rest.PagedFlux; import com.azure.core.http.rest.PagedIterable; import com.azure.core.http.rest.Response; import com.azure.core.util.Context; import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ServerBackupInner; +import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in BackupsClient. */ public interface BackupsClient { + /** + * Get specific backup for a given server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param backupName The name of the backup. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return specific backup for a given server along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono> getWithResponseAsync( + String resourceGroupName, String serverName, String backupName); + + /** + * Get specific backup for a given server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param backupName The name of the backup. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return specific backup for a given server on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono getAsync(String resourceGroupName, String serverName, String backupName); + /** * Get specific backup for a given server. * @@ -43,6 +74,19 @@ Response getWithResponse( @ServiceMethod(returns = ReturnType.SINGLE) ServerBackupInner get(String resourceGroupName, String serverName, String backupName); + /** + * List all the backups for a given server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return a list of server backups as paginated response with {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedFlux listByServerAsync(String resourceGroupName, String serverName); + /** * List all the backups for a given server. * diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/CheckNameAvailabilitiesClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/CheckNameAvailabilitiesClient.java index 7239ac29f87f3..955c9b0b9d0e5 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/CheckNameAvailabilitiesClient.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/CheckNameAvailabilitiesClient.java @@ -10,9 +10,36 @@ import com.azure.core.util.Context; import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.NameAvailabilityInner; import com.azure.resourcemanager.postgresqlflexibleserver.models.CheckNameAvailabilityRequest; +import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in CheckNameAvailabilitiesClient. */ public interface CheckNameAvailabilitiesClient { + /** + * Check the availability of name for resource. + * + * @param nameAvailabilityRequest The required parameters for checking if resource name is available. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a resource name availability along with {@link Response} on successful completion of {@link + * Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono> executeWithResponseAsync( + CheckNameAvailabilityRequest nameAvailabilityRequest); + + /** + * Check the availability of name for resource. + * + * @param nameAvailabilityRequest The required parameters for checking if resource name is available. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a resource name availability on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono executeAsync(CheckNameAvailabilityRequest nameAvailabilityRequest); + /** * Check the availability of name for resource. * diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/CheckNameAvailabilityWithLocationsClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/CheckNameAvailabilityWithLocationsClient.java index b6dfdbde8d8ba..2d85b974e08f2 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/CheckNameAvailabilityWithLocationsClient.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/CheckNameAvailabilityWithLocationsClient.java @@ -10,11 +10,40 @@ import com.azure.core.util.Context; import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.NameAvailabilityInner; import com.azure.resourcemanager.postgresqlflexibleserver.models.CheckNameAvailabilityRequest; +import reactor.core.publisher.Mono; /** * An instance of this class provides access to all the operations defined in CheckNameAvailabilityWithLocationsClient. */ public interface CheckNameAvailabilityWithLocationsClient { + /** + * Check the availability of name for resource. + * + * @param locationName The name of the location. + * @param nameAvailabilityRequest The required parameters for checking if resource name is available. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a resource name availability along with {@link Response} on successful completion of {@link + * Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono> executeWithResponseAsync( + String locationName, CheckNameAvailabilityRequest nameAvailabilityRequest); + + /** + * Check the availability of name for resource. + * + * @param locationName The name of the location. + * @param nameAvailabilityRequest The required parameters for checking if resource name is available. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a resource name availability on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono executeAsync(String locationName, CheckNameAvailabilityRequest nameAvailabilityRequest); + /** * Check the availability of name for resource. * diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ConfigurationsClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ConfigurationsClient.java index fcd69f632c43c..395b26ad2836f 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ConfigurationsClient.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ConfigurationsClient.java @@ -6,16 +6,34 @@ import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; +import com.azure.core.http.rest.PagedFlux; import com.azure.core.http.rest.PagedIterable; import com.azure.core.http.rest.Response; import com.azure.core.management.polling.PollResult; import com.azure.core.util.Context; +import com.azure.core.util.polling.PollerFlux; import com.azure.core.util.polling.SyncPoller; import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ConfigurationInner; import com.azure.resourcemanager.postgresqlflexibleserver.models.ConfigurationForUpdate; +import java.nio.ByteBuffer; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in ConfigurationsClient. */ public interface ConfigurationsClient { + /** + * List all the configurations in a given server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return a list of server configurations as paginated response with {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedFlux listByServerAsync(String resourceGroupName, String serverName); + /** * List all the configurations in a given server. * @@ -43,6 +61,36 @@ public interface ConfigurationsClient { @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable listByServer(String resourceGroupName, String serverName, Context context); + /** + * Gets information about a configuration of server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param configurationName The name of the server configuration. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return information about a configuration of server along with {@link Response} on successful completion of + * {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono> getWithResponseAsync( + String resourceGroupName, String serverName, String configurationName); + + /** + * Gets information about a configuration of server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param configurationName The name of the server configuration. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return information about a configuration of server on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono getAsync(String resourceGroupName, String serverName, String configurationName); + /** * Gets information about a configuration of server. * @@ -73,6 +121,38 @@ Response getWithResponse( @ServiceMethod(returns = ReturnType.SINGLE) ConfigurationInner get(String resourceGroupName, String serverName, String configurationName); + /** + * Updates a configuration of a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param configurationName The name of the server configuration. + * @param parameters The required parameters for updating a server configuration. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a Configuration along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> updateWithResponseAsync( + String resourceGroupName, String serverName, String configurationName, ConfigurationForUpdate parameters); + + /** + * Updates a configuration of a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param configurationName The name of the server configuration. + * @param parameters The required parameters for updating a server configuration. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of represents a Configuration. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, ConfigurationInner> beginUpdateAsync( + String resourceGroupName, String serverName, String configurationName, ConfigurationForUpdate parameters); + /** * Updates a configuration of a server. * @@ -110,6 +190,22 @@ SyncPoller, ConfigurationInner> beginUpdate( ConfigurationForUpdate parameters, Context context); + /** + * Updates a configuration of a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param configurationName The name of the server configuration. + * @param parameters The required parameters for updating a server configuration. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a Configuration on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono updateAsync( + String resourceGroupName, String serverName, String configurationName, ConfigurationForUpdate parameters); + /** * Updates a configuration of a server. * @@ -147,6 +243,38 @@ ConfigurationInner update( ConfigurationForUpdate parameters, Context context); + /** + * Updates a configuration of a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param configurationName The name of the server configuration. + * @param parameters The required parameters for updating a server configuration. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a Configuration along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> putWithResponseAsync( + String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters); + + /** + * Updates a configuration of a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param configurationName The name of the server configuration. + * @param parameters The required parameters for updating a server configuration. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of represents a Configuration. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, ConfigurationInner> beginPutAsync( + String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters); + /** * Updates a configuration of a server. * @@ -184,6 +312,22 @@ SyncPoller, ConfigurationInner> beginPut( ConfigurationInner parameters, Context context); + /** + * Updates a configuration of a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param configurationName The name of the server configuration. + * @param parameters The required parameters for updating a server configuration. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a Configuration on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono putAsync( + String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters); + /** * Updates a configuration of a server. * diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/DatabasesClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/DatabasesClient.java index 3b006b56f25a0..b028dbf606e01 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/DatabasesClient.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/DatabasesClient.java @@ -6,15 +6,52 @@ import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; +import com.azure.core.http.rest.PagedFlux; import com.azure.core.http.rest.PagedIterable; import com.azure.core.http.rest.Response; import com.azure.core.management.polling.PollResult; import com.azure.core.util.Context; +import com.azure.core.util.polling.PollerFlux; import com.azure.core.util.polling.SyncPoller; import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.DatabaseInner; +import java.nio.ByteBuffer; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in DatabasesClient. */ public interface DatabasesClient { + /** + * Creates a new database or updates an existing database. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param databaseName The name of the database. + * @param parameters The required parameters for creating or updating a database. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a Database along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> createWithResponseAsync( + String resourceGroupName, String serverName, String databaseName, DatabaseInner parameters); + + /** + * Creates a new database or updates an existing database. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param databaseName The name of the database. + * @param parameters The required parameters for creating or updating a database. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of represents a Database. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, DatabaseInner> beginCreateAsync( + String resourceGroupName, String serverName, String databaseName, DatabaseInner parameters); + /** * Creates a new database or updates an existing database. * @@ -48,6 +85,22 @@ SyncPoller, DatabaseInner> beginCreate( SyncPoller, DatabaseInner> beginCreate( String resourceGroupName, String serverName, String databaseName, DatabaseInner parameters, Context context); + /** + * Creates a new database or updates an existing database. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param databaseName The name of the database. + * @param parameters The required parameters for creating or updating a database. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a Database on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono createAsync( + String resourceGroupName, String serverName, String databaseName, DatabaseInner parameters); + /** * Creates a new database or updates an existing database. * @@ -80,6 +133,36 @@ SyncPoller, DatabaseInner> beginCreate( DatabaseInner create( String resourceGroupName, String serverName, String databaseName, DatabaseInner parameters, Context context); + /** + * Deletes a database. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param databaseName The name of the database. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> deleteWithResponseAsync( + String resourceGroupName, String serverName, String databaseName); + + /** + * Deletes a database. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param databaseName The name of the database. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, Void> beginDeleteAsync( + String resourceGroupName, String serverName, String databaseName); + /** * Deletes a database. * @@ -110,6 +193,20 @@ DatabaseInner create( SyncPoller, Void> beginDelete( String resourceGroupName, String serverName, String databaseName, Context context); + /** + * Deletes a database. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param databaseName The name of the database. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return A {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono deleteAsync(String resourceGroupName, String serverName, String databaseName); + /** * Deletes a database. * @@ -137,6 +234,35 @@ SyncPoller, Void> beginDelete( @ServiceMethod(returns = ReturnType.SINGLE) void delete(String resourceGroupName, String serverName, String databaseName, Context context); + /** + * Gets information about a database. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param databaseName The name of the database. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return information about a database along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono> getWithResponseAsync( + String resourceGroupName, String serverName, String databaseName); + + /** + * Gets information about a database. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param databaseName The name of the database. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return information about a database on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono getAsync(String resourceGroupName, String serverName, String databaseName); + /** * Gets information about a database. * @@ -167,6 +293,19 @@ Response getWithResponse( @ServiceMethod(returns = ReturnType.SINGLE) DatabaseInner get(String resourceGroupName, String serverName, String databaseName); + /** + * List all the databases in a given server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return a List of databases as paginated response with {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedFlux listByServerAsync(String resourceGroupName, String serverName); + /** * List all the databases in a given server. * diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/FirewallRulesClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/FirewallRulesClient.java index 6e697a7bbe50c..03c1779b516b5 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/FirewallRulesClient.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/FirewallRulesClient.java @@ -6,15 +6,52 @@ import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; +import com.azure.core.http.rest.PagedFlux; import com.azure.core.http.rest.PagedIterable; import com.azure.core.http.rest.Response; import com.azure.core.management.polling.PollResult; import com.azure.core.util.Context; +import com.azure.core.util.polling.PollerFlux; import com.azure.core.util.polling.SyncPoller; import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.FirewallRuleInner; +import java.nio.ByteBuffer; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in FirewallRulesClient. */ public interface FirewallRulesClient { + /** + * Creates a new firewall rule or updates an existing firewall rule. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param firewallRuleName The name of the server firewall rule. + * @param parameters The required parameters for creating or updating a firewall rule. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a server firewall rule along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> createOrUpdateWithResponseAsync( + String resourceGroupName, String serverName, String firewallRuleName, FirewallRuleInner parameters); + + /** + * Creates a new firewall rule or updates an existing firewall rule. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param firewallRuleName The name of the server firewall rule. + * @param parameters The required parameters for creating or updating a firewall rule. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of represents a server firewall rule. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, FirewallRuleInner> beginCreateOrUpdateAsync( + String resourceGroupName, String serverName, String firewallRuleName, FirewallRuleInner parameters); + /** * Creates a new firewall rule or updates an existing firewall rule. * @@ -52,6 +89,22 @@ SyncPoller, FirewallRuleInner> beginCreateOrUpdate FirewallRuleInner parameters, Context context); + /** + * Creates a new firewall rule or updates an existing firewall rule. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param firewallRuleName The name of the server firewall rule. + * @param parameters The required parameters for creating or updating a firewall rule. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a server firewall rule on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono createOrUpdateAsync( + String resourceGroupName, String serverName, String firewallRuleName, FirewallRuleInner parameters); + /** * Creates a new firewall rule or updates an existing firewall rule. * @@ -89,6 +142,36 @@ FirewallRuleInner createOrUpdate( FirewallRuleInner parameters, Context context); + /** + * Deletes a PostgreSQL server firewall rule. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param firewallRuleName The name of the server firewall rule. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> deleteWithResponseAsync( + String resourceGroupName, String serverName, String firewallRuleName); + + /** + * Deletes a PostgreSQL server firewall rule. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param firewallRuleName The name of the server firewall rule. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, Void> beginDeleteAsync( + String resourceGroupName, String serverName, String firewallRuleName); + /** * Deletes a PostgreSQL server firewall rule. * @@ -120,6 +203,20 @@ SyncPoller, Void> beginDelete( SyncPoller, Void> beginDelete( String resourceGroupName, String serverName, String firewallRuleName, Context context); + /** + * Deletes a PostgreSQL server firewall rule. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param firewallRuleName The name of the server firewall rule. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return A {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono deleteAsync(String resourceGroupName, String serverName, String firewallRuleName); + /** * Deletes a PostgreSQL server firewall rule. * @@ -147,6 +244,35 @@ SyncPoller, Void> beginDelete( @ServiceMethod(returns = ReturnType.SINGLE) void delete(String resourceGroupName, String serverName, String firewallRuleName, Context context); + /** + * List all the firewall rules in a given server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param firewallRuleName The name of the server firewall rule. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a server firewall rule along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono> getWithResponseAsync( + String resourceGroupName, String serverName, String firewallRuleName); + + /** + * List all the firewall rules in a given server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param firewallRuleName The name of the server firewall rule. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a server firewall rule on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono getAsync(String resourceGroupName, String serverName, String firewallRuleName); + /** * List all the firewall rules in a given server. * @@ -177,6 +303,19 @@ Response getWithResponse( @ServiceMethod(returns = ReturnType.SINGLE) FirewallRuleInner get(String resourceGroupName, String serverName, String firewallRuleName); + /** + * List all the firewall rules in a given PostgreSQL server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return a list of firewall rules as paginated response with {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedFlux listByServerAsync(String resourceGroupName, String serverName); + /** * List all the firewall rules in a given PostgreSQL server. * diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/GetPrivateDnsZoneSuffixesClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/GetPrivateDnsZoneSuffixesClient.java index a1607d2650ff9..e59d2062500e0 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/GetPrivateDnsZoneSuffixesClient.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/GetPrivateDnsZoneSuffixesClient.java @@ -8,9 +8,31 @@ import com.azure.core.annotation.ServiceMethod; import com.azure.core.http.rest.Response; import com.azure.core.util.Context; +import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in GetPrivateDnsZoneSuffixesClient. */ public interface GetPrivateDnsZoneSuffixesClient { + /** + * Get private DNS zone suffix in the cloud. + * + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return private DNS zone suffix in the cloud along with {@link Response} on successful completion of {@link + * Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono> executeWithResponseAsync(); + + /** + * Get private DNS zone suffix in the cloud. + * + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return private DNS zone suffix in the cloud on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono executeAsync(); + /** * Get private DNS zone suffix in the cloud. * diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/LocationBasedCapabilitiesClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/LocationBasedCapabilitiesClient.java index 2599389d57d25..a9bd53c696001 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/LocationBasedCapabilitiesClient.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/LocationBasedCapabilitiesClient.java @@ -6,12 +6,25 @@ import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; +import com.azure.core.http.rest.PagedFlux; import com.azure.core.http.rest.PagedIterable; import com.azure.core.util.Context; import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.CapabilityPropertiesInner; /** An instance of this class provides access to all the operations defined in LocationBasedCapabilitiesClient. */ public interface LocationBasedCapabilitiesClient { + /** + * Get capabilities at specified location in a given subscription. + * + * @param locationName The name of the location. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return capabilities at specified location in a given subscription as paginated response with {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedFlux executeAsync(String locationName); + /** * Get capabilities at specified location in a given subscription. * diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/OperationsClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/OperationsClient.java index cbd6c8bfebd07..f6ad7e7f96e16 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/OperationsClient.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/OperationsClient.java @@ -9,9 +9,31 @@ import com.azure.core.http.rest.Response; import com.azure.core.util.Context; import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.OperationListResultInner; +import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in OperationsClient. */ public interface OperationsClient { + /** + * Lists all of the available REST API operations. + * + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return a list of resource provider operations along with {@link Response} on successful completion of {@link + * Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono> listWithResponseAsync(); + + /** + * Lists all of the available REST API operations. + * + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return a list of resource provider operations on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono listAsync(); + /** * Lists all of the available REST API operations. * diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ReplicasClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ReplicasClient.java index 68f1378bbd27c..025ec6e0371eb 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ReplicasClient.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ReplicasClient.java @@ -6,12 +6,26 @@ import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; +import com.azure.core.http.rest.PagedFlux; import com.azure.core.http.rest.PagedIterable; import com.azure.core.util.Context; import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ServerInner; /** An instance of this class provides access to all the operations defined in ReplicasClient. */ public interface ReplicasClient { + /** + * List all the replicas for a given server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return a list of servers as paginated response with {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedFlux listByServerAsync(String resourceGroupName, String serverName); + /** * List all the replicas for a given server. * diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServersClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServersClient.java index de27a1452cdeb..b766ac48cc243 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServersClient.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServersClient.java @@ -6,17 +6,52 @@ import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; +import com.azure.core.http.rest.PagedFlux; import com.azure.core.http.rest.PagedIterable; import com.azure.core.http.rest.Response; import com.azure.core.management.polling.PollResult; import com.azure.core.util.Context; +import com.azure.core.util.polling.PollerFlux; import com.azure.core.util.polling.SyncPoller; import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ServerInner; import com.azure.resourcemanager.postgresqlflexibleserver.models.RestartParameter; import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerForUpdate; +import java.nio.ByteBuffer; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in ServersClient. */ public interface ServersClient { + /** + * Creates a new server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param parameters The required parameters for creating or updating a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a server along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> createWithResponseAsync( + String resourceGroupName, String serverName, ServerInner parameters); + + /** + * Creates a new server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param parameters The required parameters for creating or updating a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of represents a server. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, ServerInner> beginCreateAsync( + String resourceGroupName, String serverName, ServerInner parameters); + /** * Creates a new server. * @@ -48,6 +83,20 @@ SyncPoller, ServerInner> beginCreate( SyncPoller, ServerInner> beginCreate( String resourceGroupName, String serverName, ServerInner parameters, Context context); + /** + * Creates a new server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param parameters The required parameters for creating or updating a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a server on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono createAsync(String resourceGroupName, String serverName, ServerInner parameters); + /** * Creates a new server. * @@ -77,6 +126,38 @@ SyncPoller, ServerInner> beginCreate( @ServiceMethod(returns = ReturnType.SINGLE) ServerInner create(String resourceGroupName, String serverName, ServerInner parameters, Context context); + /** + * Updates an existing server. The request body can contain one to many of the properties present in the normal + * server definition. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param parameters The required parameters for updating a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a server along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> updateWithResponseAsync( + String resourceGroupName, String serverName, ServerForUpdate parameters); + + /** + * Updates an existing server. The request body can contain one to many of the properties present in the normal + * server definition. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param parameters The required parameters for updating a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of represents a server. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, ServerInner> beginUpdateAsync( + String resourceGroupName, String serverName, ServerForUpdate parameters); + /** * Updates an existing server. The request body can contain one to many of the properties present in the normal * server definition. @@ -110,6 +191,21 @@ SyncPoller, ServerInner> beginUpdate( SyncPoller, ServerInner> beginUpdate( String resourceGroupName, String serverName, ServerForUpdate parameters, Context context); + /** + * Updates an existing server. The request body can contain one to many of the properties present in the normal + * server definition. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param parameters The required parameters for updating a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return represents a server on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono updateAsync(String resourceGroupName, String serverName, ServerForUpdate parameters); + /** * Updates an existing server. The request body can contain one to many of the properties present in the normal * server definition. @@ -141,6 +237,32 @@ SyncPoller, ServerInner> beginUpdate( @ServiceMethod(returns = ReturnType.SINGLE) ServerInner update(String resourceGroupName, String serverName, ServerForUpdate parameters, Context context); + /** + * Deletes a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> deleteWithResponseAsync(String resourceGroupName, String serverName); + + /** + * Deletes a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, Void> beginDeleteAsync(String resourceGroupName, String serverName); + /** * Deletes a server. * @@ -168,6 +290,19 @@ SyncPoller, ServerInner> beginUpdate( @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginDelete(String resourceGroupName, String serverName, Context context); + /** + * Deletes a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return A {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono deleteAsync(String resourceGroupName, String serverName); + /** * Deletes a server. * @@ -193,6 +328,32 @@ SyncPoller, ServerInner> beginUpdate( @ServiceMethod(returns = ReturnType.SINGLE) void delete(String resourceGroupName, String serverName, Context context); + /** + * Gets information about a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return information about a server along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono> getByResourceGroupWithResponseAsync(String resourceGroupName, String serverName); + + /** + * Gets information about a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return information about a server on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono getByResourceGroupAsync(String resourceGroupName, String serverName); + /** * Gets information about a server. * @@ -220,6 +381,18 @@ SyncPoller, ServerInner> beginUpdate( @ServiceMethod(returns = ReturnType.SINGLE) ServerInner getByResourceGroup(String resourceGroupName, String serverName); + /** + * List all the servers in a given resource group. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return a list of servers as paginated response with {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedFlux listByResourceGroupAsync(String resourceGroupName); + /** * List all the servers in a given resource group. * @@ -245,6 +418,16 @@ SyncPoller, ServerInner> beginUpdate( @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable listByResourceGroup(String resourceGroupName, Context context); + /** + * List all the servers in a given subscription. + * + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return a list of servers as paginated response with {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedFlux listAsync(); + /** * List all the servers in a given subscription. * @@ -267,6 +450,49 @@ SyncPoller, ServerInner> beginUpdate( @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(Context context); + /** + * Restarts a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param parameters The parameters for restarting a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> restartWithResponseAsync( + String resourceGroupName, String serverName, RestartParameter parameters); + + /** + * Restarts a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param parameters The parameters for restarting a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, Void> beginRestartAsync( + String resourceGroupName, String serverName, RestartParameter parameters); + + /** + * Restarts a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, Void> beginRestartAsync(String resourceGroupName, String serverName); + /** * Restarts a server. * @@ -296,6 +522,33 @@ SyncPoller, ServerInner> beginUpdate( SyncPoller, Void> beginRestart( String resourceGroupName, String serverName, RestartParameter parameters, Context context); + /** + * Restarts a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @param parameters The parameters for restarting a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return A {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono restartAsync(String resourceGroupName, String serverName, RestartParameter parameters); + + /** + * Restarts a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return A {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono restartAsync(String resourceGroupName, String serverName); + /** * Restarts a server. * @@ -322,6 +575,32 @@ SyncPoller, Void> beginRestart( @ServiceMethod(returns = ReturnType.SINGLE) void restart(String resourceGroupName, String serverName, RestartParameter parameters, Context context); + /** + * Starts a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> startWithResponseAsync(String resourceGroupName, String serverName); + + /** + * Starts a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, Void> beginStartAsync(String resourceGroupName, String serverName); + /** * Starts a server. * @@ -349,6 +628,19 @@ SyncPoller, Void> beginRestart( @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginStart(String resourceGroupName, String serverName, Context context); + /** + * Starts a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return A {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono startAsync(String resourceGroupName, String serverName); + /** * Starts a server. * @@ -374,6 +666,32 @@ SyncPoller, Void> beginRestart( @ServiceMethod(returns = ReturnType.SINGLE) void start(String resourceGroupName, String serverName, Context context); + /** + * Stops a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono>> stopWithResponseAsync(String resourceGroupName, String serverName); + + /** + * Stops a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + PollerFlux, Void> beginStopAsync(String resourceGroupName, String serverName); + /** * Stops a server. * @@ -401,6 +719,19 @@ SyncPoller, Void> beginRestart( @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginStop(String resourceGroupName, String serverName, Context context); + /** + * Stops a server. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param serverName The name of the server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return A {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono stopAsync(String resourceGroupName, String serverName); + /** * Stops a server. * diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/VirtualNetworkSubnetUsagesClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/VirtualNetworkSubnetUsagesClient.java index b830067d42266..571aa06a89319 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/VirtualNetworkSubnetUsagesClient.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/VirtualNetworkSubnetUsagesClient.java @@ -10,9 +10,39 @@ import com.azure.core.util.Context; import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.VirtualNetworkSubnetUsageResultInner; import com.azure.resourcemanager.postgresqlflexibleserver.models.VirtualNetworkSubnetUsageParameter; +import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in VirtualNetworkSubnetUsagesClient. */ public interface VirtualNetworkSubnetUsagesClient { + /** + * Get virtual network subnet usage for a given vNet resource id. + * + * @param locationName The name of the location. + * @param parameters The required parameters for creating or updating a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return virtual network subnet usage for a given vNet resource id along with {@link Response} on successful + * completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono> executeWithResponseAsync( + String locationName, VirtualNetworkSubnetUsageParameter parameters); + + /** + * Get virtual network subnet usage for a given vNet resource id. + * + * @param locationName The name of the location. + * @param parameters The required parameters for creating or updating a server. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return virtual network subnet usage for a given vNet resource id on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Mono executeAsync( + String locationName, VirtualNetworkSubnetUsageParameter parameters); + /** * Get virtual network subnet usage for a given vNet resource id. * diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/AdministratorsClientImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/AdministratorsClientImpl.java index 79695de9d1c0d..576a6f639986f 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/AdministratorsClientImpl.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/AdministratorsClientImpl.java @@ -67,8 +67,7 @@ public final class AdministratorsClientImpl implements AdministratorsClient { public interface AdministratorsService { @Headers({"Content-Type: application/json"}) @Put( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/administrators/{objectId}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/administrators/{objectId}") @ExpectedResponses({200, 201, 202}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> create( @@ -84,8 +83,7 @@ Mono>> create( @Headers({"Content-Type: application/json"}) @Delete( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/administrators/{objectId}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/administrators/{objectId}") @ExpectedResponses({200, 202, 204}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> delete( @@ -100,8 +98,7 @@ Mono>> delete( @Headers({"Content-Type: application/json"}) @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/administrators/{objectId}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/administrators/{objectId}") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> get( @@ -116,8 +113,7 @@ Mono> get( @Headers({"Content-Type: application/json"}) @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/administrators") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/administrators") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> listByServer( @@ -154,7 +150,7 @@ Mono> listByServerNext( * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> createWithResponseAsync( + public Mono>> createWithResponseAsync( String resourceGroupName, String serverName, String objectId, ActiveDirectoryAdministratorAdd parameters) { if (this.client.getEndpoint() == null) { return Mono @@ -277,7 +273,7 @@ private Mono>> createWithResponseAsync( * @return the {@link PollerFlux} for polling of represents an Active Directory administrator. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, ActiveDirectoryAdministratorInner> + public PollerFlux, ActiveDirectoryAdministratorInner> beginCreateAsync( String resourceGroupName, String serverName, String objectId, ActiveDirectoryAdministratorAdd parameters) { Mono>> mono = @@ -380,7 +376,7 @@ public SyncPoller, ActiveDirectory * @return represents an Active Directory administrator on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono createAsync( + public Mono createAsync( String resourceGroupName, String serverName, String objectId, ActiveDirectoryAdministratorAdd parameters) { return beginCreateAsync(resourceGroupName, serverName, objectId, parameters) .last() @@ -465,7 +461,7 @@ public ActiveDirectoryAdministratorInner create( * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> deleteWithResponseAsync( + public Mono>> deleteWithResponseAsync( String resourceGroupName, String serverName, String objectId) { if (this.client.getEndpoint() == null) { return Mono @@ -569,7 +565,7 @@ private Mono>> deleteWithResponseAsync( * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, Void> beginDeleteAsync( + public PollerFlux, Void> beginDeleteAsync( String resourceGroupName, String serverName, String objectId) { Mono>> mono = deleteWithResponseAsync(resourceGroupName, serverName, objectId); return this @@ -648,7 +644,7 @@ public SyncPoller, Void> beginDelete( * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono deleteAsync(String resourceGroupName, String serverName, String objectId) { + public Mono deleteAsync(String resourceGroupName, String serverName, String objectId) { return beginDeleteAsync(resourceGroupName, serverName, objectId) .last() .flatMap(this.client::getLroFinalResultOrError); @@ -716,7 +712,7 @@ public void delete(String resourceGroupName, String serverName, String objectId, * @return information about a server along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> getWithResponseAsync( + public Mono> getWithResponseAsync( String resourceGroupName, String serverName, String objectId) { if (this.client.getEndpoint() == null) { return Mono @@ -820,7 +816,7 @@ private Mono> getWithResponseAsync( * @return information about a server on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono getAsync( + public Mono getAsync( String resourceGroupName, String serverName, String objectId) { return getWithResponseAsync(resourceGroupName, serverName, objectId) .flatMap(res -> Mono.justOrEmpty(res.getValue())); @@ -985,8 +981,7 @@ private Mono> listByServerSingl * @return a list of active directory administrators as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listByServerAsync( - String resourceGroupName, String serverName) { + public PagedFlux listByServerAsync(String resourceGroupName, String serverName) { return new PagedFlux<>( () -> listByServerSinglePageAsync(resourceGroupName, serverName), nextLink -> listByServerNextSinglePageAsync(nextLink)); diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/BackupsClientImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/BackupsClientImpl.java index f736a6ae90200..17d85be3af1ca 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/BackupsClientImpl.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/BackupsClientImpl.java @@ -57,8 +57,7 @@ public final class BackupsClientImpl implements BackupsClient { public interface BackupsService { @Headers({"Content-Type: application/json"}) @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/backups/{backupName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/backups/{backupName}") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> get( @@ -73,8 +72,7 @@ Mono> get( @Headers({"Content-Type: application/json"}) @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/backups") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/backups") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> listByServer( @@ -109,7 +107,7 @@ Mono> listByServerNext( * @return specific backup for a given server along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> getWithResponseAsync( + public Mono> getWithResponseAsync( String resourceGroupName, String serverName, String backupName) { if (this.client.getEndpoint() == null) { return Mono @@ -213,7 +211,7 @@ private Mono> getWithResponseAsync( * @return specific backup for a given server on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono getAsync(String resourceGroupName, String serverName, String backupName) { + public Mono getAsync(String resourceGroupName, String serverName, String backupName) { return getWithResponseAsync(resourceGroupName, serverName, backupName) .flatMap(res -> Mono.justOrEmpty(res.getValue())); } @@ -375,7 +373,7 @@ private Mono> listByServerSinglePageAsync( * @return a list of server backups as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listByServerAsync(String resourceGroupName, String serverName) { + public PagedFlux listByServerAsync(String resourceGroupName, String serverName) { return new PagedFlux<>( () -> listByServerSinglePageAsync(resourceGroupName, serverName), nextLink -> listByServerNextSinglePageAsync(nextLink)); diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CheckNameAvailabilitiesClientImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CheckNameAvailabilitiesClientImpl.java index 70689af734f18..f2a868df4b425 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CheckNameAvailabilitiesClientImpl.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CheckNameAvailabilitiesClientImpl.java @@ -78,7 +78,7 @@ Mono> execute( * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> executeWithResponseAsync( + public Mono> executeWithResponseAsync( CheckNameAvailabilityRequest nameAvailabilityRequest) { if (this.client.getEndpoint() == null) { return Mono @@ -169,7 +169,7 @@ private Mono> executeWithResponseAsync( * @return represents a resource name availability on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono executeAsync(CheckNameAvailabilityRequest nameAvailabilityRequest) { + public Mono executeAsync(CheckNameAvailabilityRequest nameAvailabilityRequest) { return executeWithResponseAsync(nameAvailabilityRequest).flatMap(res -> Mono.justOrEmpty(res.getValue())); } diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CheckNameAvailabilityWithLocationsClientImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CheckNameAvailabilityWithLocationsClientImpl.java index 21985c99749b2..5c6e4aa872db0 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CheckNameAvailabilityWithLocationsClientImpl.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CheckNameAvailabilityWithLocationsClientImpl.java @@ -61,8 +61,7 @@ public final class CheckNameAvailabilityWithLocationsClientImpl implements Check public interface CheckNameAvailabilityWithLocationsService { @Headers({"Content-Type: application/json"}) @Post( - "/subscriptions/{subscriptionId}/providers/Microsoft.DBforPostgreSQL/locations/{locationName}" - + "/checkNameAvailability") + "/subscriptions/{subscriptionId}/providers/Microsoft.DBforPostgreSQL/locations/{locationName}/checkNameAvailability") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> execute( @@ -87,7 +86,7 @@ Mono> execute( * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> executeWithResponseAsync( + public Mono> executeWithResponseAsync( String locationName, CheckNameAvailabilityRequest nameAvailabilityRequest) { if (this.client.getEndpoint() == null) { return Mono @@ -188,7 +187,7 @@ private Mono> executeWithResponseAsync( * @return represents a resource name availability on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono executeAsync( + public Mono executeAsync( String locationName, CheckNameAvailabilityRequest nameAvailabilityRequest) { return executeWithResponseAsync(locationName, nameAvailabilityRequest) .flatMap(res -> Mono.justOrEmpty(res.getValue())); diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ConfigurationsClientImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ConfigurationsClientImpl.java index c21558f4524bb..cb91289ed36bf 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ConfigurationsClientImpl.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ConfigurationsClientImpl.java @@ -67,8 +67,7 @@ public final class ConfigurationsClientImpl implements ConfigurationsClient { public interface ConfigurationsService { @Headers({"Content-Type: application/json"}) @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/configurations") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/configurations") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> listByServer( @@ -82,8 +81,7 @@ Mono> listByServer( @Headers({"Content-Type: application/json"}) @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/configurations/{configurationName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/configurations/{configurationName}") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> get( @@ -98,8 +96,7 @@ Mono> get( @Headers({"Content-Type: application/json"}) @Patch( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/configurations/{configurationName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/configurations/{configurationName}") @ExpectedResponses({200, 201, 202}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> update( @@ -115,8 +112,7 @@ Mono>> update( @Headers({"Content-Type: application/json"}) @Put( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/configurations/{configurationName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/configurations/{configurationName}") @ExpectedResponses({200, 201, 202}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> put( @@ -266,7 +262,7 @@ private Mono> listByServerSinglePageAsync( * @return a list of server configurations as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listByServerAsync(String resourceGroupName, String serverName) { + public PagedFlux listByServerAsync(String resourceGroupName, String serverName) { return new PagedFlux<>( () -> listByServerSinglePageAsync(resourceGroupName, serverName), nextLink -> listByServerNextSinglePageAsync(nextLink)); @@ -336,7 +332,7 @@ public PagedIterable listByServer( * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> getWithResponseAsync( + public Mono> getWithResponseAsync( String resourceGroupName, String serverName, String configurationName) { if (this.client.getEndpoint() == null) { return Mono @@ -443,7 +439,7 @@ private Mono> getWithResponseAsync( * @return information about a configuration of server on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono getAsync(String resourceGroupName, String serverName, String configurationName) { + public Mono getAsync(String resourceGroupName, String serverName, String configurationName) { return getWithResponseAsync(resourceGroupName, serverName, configurationName) .flatMap(res -> Mono.justOrEmpty(res.getValue())); } @@ -495,7 +491,7 @@ public ConfigurationInner get(String resourceGroupName, String serverName, Strin * @return represents a Configuration along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> updateWithResponseAsync( + public Mono>> updateWithResponseAsync( String resourceGroupName, String serverName, String configurationName, ConfigurationForUpdate parameters) { if (this.client.getEndpoint() == null) { return Mono @@ -619,7 +615,7 @@ private Mono>> updateWithResponseAsync( * @return the {@link PollerFlux} for polling of represents a Configuration. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, ConfigurationInner> beginUpdateAsync( + public PollerFlux, ConfigurationInner> beginUpdateAsync( String resourceGroupName, String serverName, String configurationName, ConfigurationForUpdate parameters) { Mono>> mono = updateWithResponseAsync(resourceGroupName, serverName, configurationName, parameters); @@ -718,7 +714,7 @@ public SyncPoller, ConfigurationInner> beginUpdat * @return represents a Configuration on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono updateAsync( + public Mono updateAsync( String resourceGroupName, String serverName, String configurationName, ConfigurationForUpdate parameters) { return beginUpdateAsync(resourceGroupName, serverName, configurationName, parameters) .last() @@ -804,7 +800,7 @@ public ConfigurationInner update( * @return represents a Configuration along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> putWithResponseAsync( + public Mono>> putWithResponseAsync( String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters) { if (this.client.getEndpoint() == null) { return Mono @@ -928,7 +924,7 @@ private Mono>> putWithResponseAsync( * @return the {@link PollerFlux} for polling of represents a Configuration. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, ConfigurationInner> beginPutAsync( + public PollerFlux, ConfigurationInner> beginPutAsync( String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters) { Mono>> mono = putWithResponseAsync(resourceGroupName, serverName, configurationName, parameters); @@ -1027,7 +1023,7 @@ public SyncPoller, ConfigurationInner> beginPut( * @return represents a Configuration on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono putAsync( + public Mono putAsync( String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters) { return beginPutAsync(resourceGroupName, serverName, configurationName, parameters) .last() diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/DatabasesClientImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/DatabasesClientImpl.java index 6067524d95362..84482ce66e9db 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/DatabasesClientImpl.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/DatabasesClientImpl.java @@ -66,8 +66,7 @@ public final class DatabasesClientImpl implements DatabasesClient { public interface DatabasesService { @Headers({"Content-Type: application/json"}) @Put( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/databases/{databaseName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/databases/{databaseName}") @ExpectedResponses({200, 201, 202}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> create( @@ -83,8 +82,7 @@ Mono>> create( @Headers({"Content-Type: application/json"}) @Delete( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/databases/{databaseName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/databases/{databaseName}") @ExpectedResponses({200, 202, 204}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> delete( @@ -99,8 +97,7 @@ Mono>> delete( @Headers({"Content-Type: application/json"}) @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/databases/{databaseName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/databases/{databaseName}") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> get( @@ -115,8 +112,7 @@ Mono> get( @Headers({"Content-Type: application/json"}) @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/databases") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/databases") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> listByServer( @@ -152,7 +148,7 @@ Mono> listByServerNext( * @return represents a Database along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> createWithResponseAsync( + public Mono>> createWithResponseAsync( String resourceGroupName, String serverName, String databaseName, DatabaseInner parameters) { if (this.client.getEndpoint() == null) { return Mono @@ -270,7 +266,7 @@ private Mono>> createWithResponseAsync( * @return the {@link PollerFlux} for polling of represents a Database. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, DatabaseInner> beginCreateAsync( + public PollerFlux, DatabaseInner> beginCreateAsync( String resourceGroupName, String serverName, String databaseName, DatabaseInner parameters) { Mono>> mono = createWithResponseAsync(resourceGroupName, serverName, databaseName, parameters); @@ -359,7 +355,7 @@ public SyncPoller, DatabaseInner> beginCreate( * @return represents a Database on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono createAsync( + public Mono createAsync( String resourceGroupName, String serverName, String databaseName, DatabaseInner parameters) { return beginCreateAsync(resourceGroupName, serverName, databaseName, parameters) .last() @@ -436,7 +432,7 @@ public DatabaseInner create( * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> deleteWithResponseAsync( + public Mono>> deleteWithResponseAsync( String resourceGroupName, String serverName, String databaseName) { if (this.client.getEndpoint() == null) { return Mono @@ -540,7 +536,7 @@ private Mono>> deleteWithResponseAsync( * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, Void> beginDeleteAsync( + public PollerFlux, Void> beginDeleteAsync( String resourceGroupName, String serverName, String databaseName) { Mono>> mono = deleteWithResponseAsync(resourceGroupName, serverName, databaseName); return this @@ -619,7 +615,7 @@ public SyncPoller, Void> beginDelete( * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono deleteAsync(String resourceGroupName, String serverName, String databaseName) { + public Mono deleteAsync(String resourceGroupName, String serverName, String databaseName) { return beginDeleteAsync(resourceGroupName, serverName, databaseName) .last() .flatMap(this.client::getLroFinalResultOrError); @@ -687,7 +683,7 @@ public void delete(String resourceGroupName, String serverName, String databaseN * @return information about a database along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> getWithResponseAsync( + public Mono> getWithResponseAsync( String resourceGroupName, String serverName, String databaseName) { if (this.client.getEndpoint() == null) { return Mono @@ -791,7 +787,7 @@ private Mono> getWithResponseAsync( * @return information about a database on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono getAsync(String resourceGroupName, String serverName, String databaseName) { + public Mono getAsync(String resourceGroupName, String serverName, String databaseName) { return getWithResponseAsync(resourceGroupName, serverName, databaseName) .flatMap(res -> Mono.justOrEmpty(res.getValue())); } @@ -953,7 +949,7 @@ private Mono> listByServerSinglePageAsync( * @return a List of databases as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listByServerAsync(String resourceGroupName, String serverName) { + public PagedFlux listByServerAsync(String resourceGroupName, String serverName) { return new PagedFlux<>( () -> listByServerSinglePageAsync(resourceGroupName, serverName), nextLink -> listByServerNextSinglePageAsync(nextLink)); diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/FirewallRulesClientImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/FirewallRulesClientImpl.java index 3cda18ae98f43..0fc4d442dc63f 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/FirewallRulesClientImpl.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/FirewallRulesClientImpl.java @@ -66,8 +66,7 @@ public final class FirewallRulesClientImpl implements FirewallRulesClient { public interface FirewallRulesService { @Headers({"Content-Type: application/json"}) @Put( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/firewallRules/{firewallRuleName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/firewallRules/{firewallRuleName}") @ExpectedResponses({200, 201, 202}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> createOrUpdate( @@ -83,8 +82,7 @@ Mono>> createOrUpdate( @Headers({"Content-Type: application/json"}) @Delete( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/firewallRules/{firewallRuleName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/firewallRules/{firewallRuleName}") @ExpectedResponses({200, 202, 204}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> delete( @@ -99,8 +97,7 @@ Mono>> delete( @Headers({"Content-Type: application/json"}) @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/firewallRules/{firewallRuleName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/firewallRules/{firewallRuleName}") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> get( @@ -115,8 +112,7 @@ Mono> get( @Headers({"Content-Type: application/json"}) @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/firewallRules") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/firewallRules") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> listByServer( @@ -152,7 +148,7 @@ Mono> listByServerNext( * @return represents a server firewall rule along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> createOrUpdateWithResponseAsync( + public Mono>> createOrUpdateWithResponseAsync( String resourceGroupName, String serverName, String firewallRuleName, FirewallRuleInner parameters) { if (this.client.getEndpoint() == null) { return Mono @@ -276,7 +272,7 @@ private Mono>> createOrUpdateWithResponseAsync( * @return the {@link PollerFlux} for polling of represents a server firewall rule. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, FirewallRuleInner> beginCreateOrUpdateAsync( + public PollerFlux, FirewallRuleInner> beginCreateOrUpdateAsync( String resourceGroupName, String serverName, String firewallRuleName, FirewallRuleInner parameters) { Mono>> mono = createOrUpdateWithResponseAsync(resourceGroupName, serverName, firewallRuleName, parameters); @@ -377,7 +373,7 @@ public SyncPoller, FirewallRuleInner> beginCreateO * @return represents a server firewall rule on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono createOrUpdateAsync( + public Mono createOrUpdateAsync( String resourceGroupName, String serverName, String firewallRuleName, FirewallRuleInner parameters) { return beginCreateOrUpdateAsync(resourceGroupName, serverName, firewallRuleName, parameters) .last() @@ -462,7 +458,7 @@ public FirewallRuleInner createOrUpdate( * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> deleteWithResponseAsync( + public Mono>> deleteWithResponseAsync( String resourceGroupName, String serverName, String firewallRuleName) { if (this.client.getEndpoint() == null) { return Mono @@ -568,7 +564,7 @@ private Mono>> deleteWithResponseAsync( * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, Void> beginDeleteAsync( + public PollerFlux, Void> beginDeleteAsync( String resourceGroupName, String serverName, String firewallRuleName) { Mono>> mono = deleteWithResponseAsync(resourceGroupName, serverName, firewallRuleName); @@ -648,7 +644,7 @@ public SyncPoller, Void> beginDelete( * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono deleteAsync(String resourceGroupName, String serverName, String firewallRuleName) { + public Mono deleteAsync(String resourceGroupName, String serverName, String firewallRuleName) { return beginDeleteAsync(resourceGroupName, serverName, firewallRuleName) .last() .flatMap(this.client::getLroFinalResultOrError); @@ -717,7 +713,7 @@ public void delete(String resourceGroupName, String serverName, String firewallR * @return represents a server firewall rule along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> getWithResponseAsync( + public Mono> getWithResponseAsync( String resourceGroupName, String serverName, String firewallRuleName) { if (this.client.getEndpoint() == null) { return Mono @@ -823,7 +819,7 @@ private Mono> getWithResponseAsync( * @return represents a server firewall rule on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono getAsync(String resourceGroupName, String serverName, String firewallRuleName) { + public Mono getAsync(String resourceGroupName, String serverName, String firewallRuleName) { return getWithResponseAsync(resourceGroupName, serverName, firewallRuleName) .flatMap(res -> Mono.justOrEmpty(res.getValue())); } @@ -985,7 +981,7 @@ private Mono> listByServerSinglePageAsync( * @return a list of firewall rules as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listByServerAsync(String resourceGroupName, String serverName) { + public PagedFlux listByServerAsync(String resourceGroupName, String serverName) { return new PagedFlux<>( () -> listByServerSinglePageAsync(resourceGroupName, serverName), nextLink -> listByServerNextSinglePageAsync(nextLink)); diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/GetPrivateDnsZoneSuffixesClientImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/GetPrivateDnsZoneSuffixesClientImpl.java index 6e4aba88bfd90..99e7d83ef904d 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/GetPrivateDnsZoneSuffixesClientImpl.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/GetPrivateDnsZoneSuffixesClientImpl.java @@ -71,7 +71,7 @@ Mono> execute( * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> executeWithResponseAsync() { + public Mono> executeWithResponseAsync() { if (this.client.getEndpoint() == null) { return Mono .error( @@ -116,7 +116,7 @@ private Mono> executeWithResponseAsync(Context context) { * @return private DNS zone suffix in the cloud on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono executeAsync() { + public Mono executeAsync() { return executeWithResponseAsync().flatMap(res -> Mono.justOrEmpty(res.getValue())); } diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/LocationBasedCapabilitiesClientImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/LocationBasedCapabilitiesClientImpl.java index 91dd3f22fe0b8..1d3556eb07ea6 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/LocationBasedCapabilitiesClientImpl.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/LocationBasedCapabilitiesClientImpl.java @@ -193,7 +193,7 @@ private Mono> executeSinglePageAsync( * @return capabilities at specified location in a given subscription as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux executeAsync(String locationName) { + public PagedFlux executeAsync(String locationName) { return new PagedFlux<>( () -> executeSinglePageAsync(locationName), nextLink -> executeNextSinglePageAsync(nextLink)); } diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/OperationsClientImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/OperationsClientImpl.java index d4064d1254817..941dc59b1cbfa 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/OperationsClientImpl.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/OperationsClientImpl.java @@ -70,7 +70,7 @@ Mono> list( * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listWithResponseAsync() { + public Mono> listWithResponseAsync() { if (this.client.getEndpoint() == null) { return Mono .error( @@ -115,7 +115,7 @@ private Mono> listWithResponseAsync(Context c * @return a list of resource provider operations on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono listAsync() { + public Mono listAsync() { return listWithResponseAsync().flatMap(res -> Mono.justOrEmpty(res.getValue())); } diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ReplicasClientImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ReplicasClientImpl.java index 720dca7e657f3..ceede1e10a3c9 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ReplicasClientImpl.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ReplicasClientImpl.java @@ -57,8 +57,7 @@ public final class ReplicasClientImpl implements ReplicasClient { public interface ReplicasService { @Headers({"Content-Type: application/json"}) @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/replicas") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/replicas") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> listByServer( @@ -183,7 +182,7 @@ private Mono> listByServerSinglePageAsync( * @return a list of servers as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listByServerAsync(String resourceGroupName, String serverName) { + public PagedFlux listByServerAsync(String resourceGroupName, String serverName) { return new PagedFlux<>(() -> listByServerSinglePageAsync(resourceGroupName, serverName)); } diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ServersClientImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ServersClientImpl.java index ef632ea7ec8e7..d614d8d43507c 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ServersClientImpl.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ServersClientImpl.java @@ -69,8 +69,7 @@ public final class ServersClientImpl implements ServersClient { public interface ServersService { @Headers({"Content-Type: application/json"}) @Put( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}") @ExpectedResponses({200, 201, 202}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> create( @@ -85,8 +84,7 @@ Mono>> create( @Headers({"Content-Type: application/json"}) @Patch( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}") @ExpectedResponses({200, 202}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> update( @@ -101,8 +99,7 @@ Mono>> update( @Headers({"Content-Type: application/json"}) @Delete( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}") @ExpectedResponses({200, 202, 204}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> delete( @@ -116,8 +113,7 @@ Mono>> delete( @Headers({"Content-Type: application/json"}) @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> getByResourceGroup( @@ -131,8 +127,7 @@ Mono> getByResourceGroup( @Headers({"Content-Type: application/json"}) @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> listByResourceGroup( @@ -156,8 +151,7 @@ Mono> list( @Headers({"Content-Type: application/json"}) @Post( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/restart") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/restart") @ExpectedResponses({200, 202}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> restart( @@ -172,8 +166,7 @@ Mono>> restart( @Headers({"Content-Type: application/json"}) @Post( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/start") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/start") @ExpectedResponses({200, 202}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> start( @@ -187,8 +180,7 @@ Mono>> start( @Headers({"Content-Type: application/json"}) @Post( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL" - + "/flexibleServers/{serverName}/stop") + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{serverName}/stop") @ExpectedResponses({200, 202}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> stop( @@ -233,7 +225,7 @@ Mono> listNext( * @return represents a server along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> createWithResponseAsync( + public Mono>> createWithResponseAsync( String resourceGroupName, String serverName, ServerInner parameters) { if (this.client.getEndpoint() == null) { return Mono @@ -341,7 +333,7 @@ private Mono>> createWithResponseAsync( * @return the {@link PollerFlux} for polling of represents a server. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, ServerInner> beginCreateAsync( + public PollerFlux, ServerInner> beginCreateAsync( String resourceGroupName, String serverName, ServerInner parameters) { Mono>> mono = createWithResponseAsync(resourceGroupName, serverName, parameters); return this @@ -421,7 +413,7 @@ public SyncPoller, ServerInner> beginCreate( * @return represents a server on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono createAsync(String resourceGroupName, String serverName, ServerInner parameters) { + public Mono createAsync(String resourceGroupName, String serverName, ServerInner parameters) { return beginCreateAsync(resourceGroupName, serverName, parameters) .last() .flatMap(this.client::getLroFinalResultOrError); @@ -493,7 +485,7 @@ public ServerInner create(String resourceGroupName, String serverName, ServerInn * @return represents a server along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> updateWithResponseAsync( + public Mono>> updateWithResponseAsync( String resourceGroupName, String serverName, ServerForUpdate parameters) { if (this.client.getEndpoint() == null) { return Mono @@ -603,7 +595,7 @@ private Mono>> updateWithResponseAsync( * @return the {@link PollerFlux} for polling of represents a server. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, ServerInner> beginUpdateAsync( + public PollerFlux, ServerInner> beginUpdateAsync( String resourceGroupName, String serverName, ServerForUpdate parameters) { Mono>> mono = updateWithResponseAsync(resourceGroupName, serverName, parameters); return this @@ -687,7 +679,7 @@ public SyncPoller, ServerInner> beginUpdate( * @return represents a server on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono updateAsync(String resourceGroupName, String serverName, ServerForUpdate parameters) { + public Mono updateAsync(String resourceGroupName, String serverName, ServerForUpdate parameters) { return beginUpdateAsync(resourceGroupName, serverName, parameters) .last() .flatMap(this.client::getLroFinalResultOrError); @@ -761,7 +753,7 @@ public ServerInner update( * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> deleteWithResponseAsync(String resourceGroupName, String serverName) { + public Mono>> deleteWithResponseAsync(String resourceGroupName, String serverName) { if (this.client.getEndpoint() == null) { return Mono .error( @@ -854,7 +846,7 @@ private Mono>> deleteWithResponseAsync( * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, Void> beginDeleteAsync(String resourceGroupName, String serverName) { + public PollerFlux, Void> beginDeleteAsync(String resourceGroupName, String serverName) { Mono>> mono = deleteWithResponseAsync(resourceGroupName, serverName); return this .client @@ -926,7 +918,7 @@ public SyncPoller, Void> beginDelete( * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono deleteAsync(String resourceGroupName, String serverName) { + public Mono deleteAsync(String resourceGroupName, String serverName) { return beginDeleteAsync(resourceGroupName, serverName).last().flatMap(this.client::getLroFinalResultOrError); } @@ -988,7 +980,7 @@ public void delete(String resourceGroupName, String serverName, Context context) * @return information about a server along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> getByResourceGroupWithResponseAsync( + public Mono> getByResourceGroupWithResponseAsync( String resourceGroupName, String serverName) { if (this.client.getEndpoint() == null) { return Mono @@ -1082,7 +1074,7 @@ private Mono> getByResourceGroupWithResponseAsync( * @return information about a server on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono getByResourceGroupAsync(String resourceGroupName, String serverName) { + public Mono getByResourceGroupAsync(String resourceGroupName, String serverName) { return getByResourceGroupWithResponseAsync(resourceGroupName, serverName) .flatMap(res -> Mono.justOrEmpty(res.getValue())); } @@ -1230,7 +1222,7 @@ private Mono> listByResourceGroupSinglePageAsync( * @return a list of servers as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listByResourceGroupAsync(String resourceGroupName) { + public PagedFlux listByResourceGroupAsync(String resourceGroupName) { return new PagedFlux<>( () -> listByResourceGroupSinglePageAsync(resourceGroupName), nextLink -> listByResourceGroupNextSinglePageAsync(nextLink)); @@ -1377,7 +1369,7 @@ private Mono> listSinglePageAsync(Context context) { * @return a list of servers as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listAsync() { + public PagedFlux listAsync() { return new PagedFlux<>(() -> listSinglePageAsync(), nextLink -> listNextSinglePageAsync(nextLink)); } @@ -1434,7 +1426,7 @@ public PagedIterable list(Context context) { * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> restartWithResponseAsync( + public Mono>> restartWithResponseAsync( String resourceGroupName, String serverName, RestartParameter parameters) { if (this.client.getEndpoint() == null) { return Mono @@ -1538,7 +1530,7 @@ private Mono>> restartWithResponseAsync( * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, Void> beginRestartAsync( + public PollerFlux, Void> beginRestartAsync( String resourceGroupName, String serverName, RestartParameter parameters) { Mono>> mono = restartWithResponseAsync(resourceGroupName, serverName, parameters); return this @@ -1558,7 +1550,7 @@ private PollerFlux, Void> beginRestartAsync( * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, Void> beginRestartAsync(String resourceGroupName, String serverName) { + public PollerFlux, Void> beginRestartAsync(String resourceGroupName, String serverName) { final RestartParameter parameters = null; Mono>> mono = restartWithResponseAsync(resourceGroupName, serverName, parameters); return this @@ -1636,7 +1628,7 @@ public SyncPoller, Void> beginRestart( * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono restartAsync(String resourceGroupName, String serverName, RestartParameter parameters) { + public Mono restartAsync(String resourceGroupName, String serverName, RestartParameter parameters) { return beginRestartAsync(resourceGroupName, serverName, parameters) .last() .flatMap(this.client::getLroFinalResultOrError); @@ -1653,7 +1645,7 @@ private Mono restartAsync(String resourceGroupName, String serverName, Res * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono restartAsync(String resourceGroupName, String serverName) { + public Mono restartAsync(String resourceGroupName, String serverName) { final RestartParameter parameters = null; return beginRestartAsync(resourceGroupName, serverName, parameters) .last() @@ -1722,7 +1714,7 @@ public void restart(String resourceGroupName, String serverName, RestartParamete * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> startWithResponseAsync(String resourceGroupName, String serverName) { + public Mono>> startWithResponseAsync(String resourceGroupName, String serverName) { if (this.client.getEndpoint() == null) { return Mono .error( @@ -1815,7 +1807,7 @@ private Mono>> startWithResponseAsync( * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, Void> beginStartAsync(String resourceGroupName, String serverName) { + public PollerFlux, Void> beginStartAsync(String resourceGroupName, String serverName) { Mono>> mono = startWithResponseAsync(resourceGroupName, serverName); return this .client @@ -1886,7 +1878,7 @@ public SyncPoller, Void> beginStart(String resourceGroupName, S * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono startAsync(String resourceGroupName, String serverName) { + public Mono startAsync(String resourceGroupName, String serverName) { return beginStartAsync(resourceGroupName, serverName).last().flatMap(this.client::getLroFinalResultOrError); } @@ -1948,7 +1940,7 @@ public void start(String resourceGroupName, String serverName, Context context) * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> stopWithResponseAsync(String resourceGroupName, String serverName) { + public Mono>> stopWithResponseAsync(String resourceGroupName, String serverName) { if (this.client.getEndpoint() == null) { return Mono .error( @@ -2041,7 +2033,7 @@ private Mono>> stopWithResponseAsync( * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) - private PollerFlux, Void> beginStopAsync(String resourceGroupName, String serverName) { + public PollerFlux, Void> beginStopAsync(String resourceGroupName, String serverName) { Mono>> mono = stopWithResponseAsync(resourceGroupName, serverName); return this .client @@ -2112,7 +2104,7 @@ public SyncPoller, Void> beginStop(String resourceGroupName, St * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono stopAsync(String resourceGroupName, String serverName) { + public Mono stopAsync(String resourceGroupName, String serverName) { return beginStopAsync(resourceGroupName, serverName).last().flatMap(this.client::getLroFinalResultOrError); } diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/VirtualNetworkSubnetUsagesClientImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/VirtualNetworkSubnetUsagesClientImpl.java index 2981fc1c79e6e..157414058b671 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/VirtualNetworkSubnetUsagesClientImpl.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/VirtualNetworkSubnetUsagesClientImpl.java @@ -57,8 +57,7 @@ public final class VirtualNetworkSubnetUsagesClientImpl implements VirtualNetwor public interface VirtualNetworkSubnetUsagesService { @Headers({"Content-Type: application/json"}) @Post( - "/subscriptions/{subscriptionId}/providers/Microsoft.DBforPostgreSQL/locations/{locationName}" - + "/checkVirtualNetworkSubnetUsage") + "/subscriptions/{subscriptionId}/providers/Microsoft.DBforPostgreSQL/locations/{locationName}/checkVirtualNetworkSubnetUsage") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) Mono> execute( @@ -83,7 +82,7 @@ Mono> execute( * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> executeWithResponseAsync( + public Mono> executeWithResponseAsync( String locationName, VirtualNetworkSubnetUsageParameter parameters) { if (this.client.getEndpoint() == null) { return Mono @@ -180,7 +179,7 @@ private Mono> executeWithResponse * @return virtual network subnet usage for a given vNet resource id on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono executeAsync( + public Mono executeAsync( String locationName, VirtualNetworkSubnetUsageParameter parameters) { return executeWithResponseAsync(locationName, parameters).flatMap(res -> Mono.justOrEmpty(res.getValue())); } diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/ArmServerKeyType.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/ArmServerKeyType.java index 477e3a40541f9..175aed640fd91 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/ArmServerKeyType.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/ArmServerKeyType.java @@ -8,10 +8,10 @@ import com.fasterxml.jackson.annotation.JsonCreator; import java.util.Collection; -/** Data encryption type to depict if it is System assigned vs Azure Key vault. */ +/** Data encryption type to depict if it is System Managed vs Azure Key vault. */ public final class ArmServerKeyType extends ExpandableStringEnum { - /** Static value SystemAssigned for ArmServerKeyType. */ - public static final ArmServerKeyType SYSTEM_ASSIGNED = fromString("SystemAssigned"); + /** Static value SystemManaged for ArmServerKeyType. */ + public static final ArmServerKeyType SYSTEM_MANAGED = fromString("SystemManaged"); /** Static value AzureKeyVault for ArmServerKeyType. */ public static final ArmServerKeyType AZURE_KEY_VAULT = fromString("AzureKeyVault"); diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/DataEncryption.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/DataEncryption.java index f4e93e43c8243..1eb652d25833a 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/DataEncryption.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/DataEncryption.java @@ -23,7 +23,7 @@ public final class DataEncryption { private String primaryUserAssignedIdentityId; /* - * Data encryption type to depict if it is System assigned vs Azure Key vault. + * Data encryption type to depict if it is System Managed vs Azure Key vault. */ @JsonProperty(value = "type") private ArmServerKeyType type; @@ -75,7 +75,7 @@ public DataEncryption withPrimaryUserAssignedIdentityId(String primaryUserAssign } /** - * Get the type property: Data encryption type to depict if it is System assigned vs Azure Key vault. + * Get the type property: Data encryption type to depict if it is System Managed vs Azure Key vault. * * @return the type value. */ @@ -84,7 +84,7 @@ public ArmServerKeyType type() { } /** - * Set the type property: Data encryption type to depict if it is System assigned vs Azure Key vault. + * Set the type property: Data encryption type to depict if it is System Managed vs Azure Key vault. * * @param type the type value to set. * @return the DataEncryption object itself. diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/IdentityType.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/IdentityType.java index db12d0469af5a..f1be087b7a872 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/IdentityType.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/IdentityType.java @@ -13,9 +13,6 @@ public final class IdentityType extends ExpandableStringEnum { /** Static value None for IdentityType. */ public static final IdentityType NONE = fromString("None"); - /** Static value SystemAssigned for IdentityType. */ - public static final IdentityType SYSTEM_ASSIGNED = fromString("SystemAssigned"); - /** Static value UserAssigned for IdentityType. */ public static final IdentityType USER_ASSIGNED = fromString("UserAssigned"); diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/ReplicationRole.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/ReplicationRole.java index 1ccebc8fdae56..87bab08ef4ecf 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/ReplicationRole.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/ReplicationRole.java @@ -16,21 +16,9 @@ public final class ReplicationRole extends ExpandableStringEnum /** Static value Primary for ReplicationRole. */ public static final ReplicationRole PRIMARY = fromString("Primary"); - /** Static value Secondary for ReplicationRole. */ - public static final ReplicationRole SECONDARY = fromString("Secondary"); - - /** Static value WalReplica for ReplicationRole. */ - public static final ReplicationRole WAL_REPLICA = fromString("WalReplica"); - - /** Static value SyncReplica for ReplicationRole. */ - public static final ReplicationRole SYNC_REPLICA = fromString("SyncReplica"); - /** Static value AsyncReplica for ReplicationRole. */ public static final ReplicationRole ASYNC_REPLICA = fromString("AsyncReplica"); - /** Static value GeoSyncReplica for ReplicationRole. */ - public static final ReplicationRole GEO_SYNC_REPLICA = fromString("GeoSyncReplica"); - /** Static value GeoAsyncReplica for ReplicationRole. */ public static final ReplicationRole GEO_ASYNC_REPLICA = fromString("GeoAsyncReplica"); diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/UserAssignedIdentity.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/UserAssignedIdentity.java index 9d18ac92cd278..f2c2a9f40bc33 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/UserAssignedIdentity.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/UserAssignedIdentity.java @@ -12,7 +12,7 @@ /** Information describing the identities associated with this application. */ @Fluent -public class UserAssignedIdentity { +public final class UserAssignedIdentity { /* * represents user assigned identities map. */ diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/UserIdentity.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/UserIdentity.java index 7d21f69f1e4e8..0a9993034709c 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/UserIdentity.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/models/UserIdentity.java @@ -9,7 +9,7 @@ /** Describes a single user-assigned identity associated with the application. */ @Fluent -public class UserIdentity { +public final class UserIdentity { /* * the object identifier of the Service Principal which this identity represents. */ diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/samples/java/com/azure/resourcemanager/postgresqlflexibleserver/generated/ServersCreateSamples.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/samples/java/com/azure/resourcemanager/postgresqlflexibleserver/generated/ServersCreateSamples.java index 1b2916fbaa547..759cede2c3a55 100644 --- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/samples/java/com/azure/resourcemanager/postgresqlflexibleserver/generated/ServersCreateSamples.java +++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/samples/java/com/azure/resourcemanager/postgresqlflexibleserver/generated/ServersCreateSamples.java @@ -156,7 +156,7 @@ public static void createANewServerWithActiveDirectoryAuthenticationEnabled( .withActiveDirectoryAuth(ActiveDirectoryAuthEnum.ENABLED) .withPasswordAuth(PasswordAuthEnum.ENABLED) .withTenantId("tttttt-tttt-tttt-tttt-tttttttttttt")) - .withDataEncryption(new DataEncryption().withType(ArmServerKeyType.fromString("SystemManaged"))) + .withDataEncryption(new DataEncryption().withType(ArmServerKeyType.SYSTEM_MANAGED)) .withBackup(new Backup().withBackupRetentionDays(7).withGeoRedundantBackup(GeoRedundantBackupEnum.DISABLED)) .withNetwork( new Network()