, Void> beginDelete(
+ String resourceGroupName, String serverName, String privateEndpointConnectionName, Context context);
+
+ /**
+ * Deletes a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param privateEndpointConnectionName The privateEndpointConnectionName parameter.
+ * @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.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ void delete(String resourceGroupName, String serverName, String privateEndpointConnectionName);
+
+ /**
+ * Deletes a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param privateEndpointConnectionName The privateEndpointConnectionName parameter.
+ * @param context The context to associate with this operation.
+ * @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.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ void delete(String resourceGroupName, String serverName, String privateEndpointConnectionName, Context context);
+
+ /**
+ * Updates tags on private endpoint connection.
+ *
+ * Updates private endpoint connection with the specified tags.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param privateEndpointConnectionName The privateEndpointConnectionName parameter.
+ * @param parameters Parameters supplied to the Update private endpoint connection Tags operation.
+ * @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 SyncPoller} for polling of a private endpoint connection.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, PrivateEndpointConnectionInner> beginUpdateTags(
+ String resourceGroupName, String serverName, String privateEndpointConnectionName, TagsObject parameters);
+
+ /**
+ * Updates tags on private endpoint connection.
+ *
+ * Updates private endpoint connection with the specified tags.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param privateEndpointConnectionName The privateEndpointConnectionName parameter.
+ * @param parameters Parameters supplied to the Update private endpoint connection Tags operation.
+ * @param context The context to associate with this operation.
+ * @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 SyncPoller} for polling of a private endpoint connection.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, PrivateEndpointConnectionInner> beginUpdateTags(
+ String resourceGroupName,
+ String serverName,
+ String privateEndpointConnectionName,
+ TagsObject parameters,
+ Context context);
+
+ /**
+ * Updates tags on private endpoint connection.
+ *
+ * Updates private endpoint connection with the specified tags.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param privateEndpointConnectionName The privateEndpointConnectionName parameter.
+ * @param parameters Parameters supplied to the Update private endpoint connection Tags operation.
+ * @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 private endpoint connection.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateEndpointConnectionInner updateTags(
+ String resourceGroupName, String serverName, String privateEndpointConnectionName, TagsObject parameters);
+
+ /**
+ * Updates tags on private endpoint connection.
+ *
+ *
Updates private endpoint connection with the specified tags.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param privateEndpointConnectionName The privateEndpointConnectionName parameter.
+ * @param parameters Parameters supplied to the Update private endpoint connection Tags operation.
+ * @param context The context to associate with this operation.
+ * @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 private endpoint connection.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateEndpointConnectionInner updateTags(
+ String resourceGroupName,
+ String serverName,
+ String privateEndpointConnectionName,
+ TagsObject parameters,
+ Context context);
+
+ /**
+ * Gets all private endpoint connections on 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 all private endpoint connections on a server as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByServer(String resourceGroupName, String serverName);
+
+ /**
+ * Gets all private endpoint connections on a server.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param context The context to associate with this operation.
+ * @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 all private endpoint connections on a server as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByServer(
+ String resourceGroupName, String serverName, Context context);
+}
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/PrivateLinkResourcesClient.java
similarity index 67%
rename from sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/BackupsClient.java
rename to sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/PrivateLinkResourcesClient.java
index f247b57df09d5..e660f071c43cc 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/PrivateLinkResourcesClient.java
@@ -9,64 +9,64 @@
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 com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.PrivateLinkResourceInner;
-/** An instance of this class provides access to all the operations defined in BackupsClient. */
-public interface BackupsClient {
+/** An instance of this class provides access to all the operations defined in PrivateLinkResourcesClient. */
+public interface PrivateLinkResourcesClient {
/**
- * Get specific backup for a given server.
+ * Gets the private link resources for PostgreSQL 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.
- * @param context The context to associate with this operation.
* @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}.
+ * @return the private link resources for PostgreSQL server as paginated response with {@link PagedIterable}.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(
- String resourceGroupName, String serverName, String backupName, Context context);
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByServer(String resourceGroupName, String serverName);
/**
- * Get specific backup for a given server.
+ * Gets the private link resources for PostgreSQL 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.
+ * @param context The context to associate with this operation.
* @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.
+ * @return the private link resources for PostgreSQL server as paginated response with {@link PagedIterable}.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- ServerBackupInner get(String resourceGroupName, String serverName, String backupName);
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByServer(String resourceGroupName, String serverName, Context context);
/**
- * List all the backups for a given server.
+ * Gets a private link resource for PostgreSQL server.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param serverName The name of the server.
+ * @param groupName The name of the private link resource.
+ * @param context The context to associate with this operation.
* @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 PagedIterable}.
+ * @return a private link resource for PostgreSQL server along with {@link Response}.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByServer(String resourceGroupName, String serverName);
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(
+ String resourceGroupName, String serverName, String groupName, Context context);
/**
- * List all the backups for a given server.
+ * Gets a private link resource for PostgreSQL server.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param serverName The name of the server.
- * @param context The context to associate with this operation.
+ * @param groupName The name of the private link resource.
* @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 PagedIterable}.
+ * @return a private link resource for PostgreSQL server.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByServer(String resourceGroupName, String serverName, Context context);
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateLinkResourceInner get(String resourceGroupName, String serverName, String groupName);
}
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/RecoverableServersClient.java
similarity index 54%
rename from sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/GetPrivateDnsZoneSuffixesClient.java
rename to sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/RecoverableServersClient.java
index a1607d2650ff9..75692dc8823df 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/RecoverableServersClient.java
@@ -8,28 +8,35 @@
import com.azure.core.annotation.ServiceMethod;
import com.azure.core.http.rest.Response;
import com.azure.core.util.Context;
+import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.RecoverableServerResourceInner;
-/** An instance of this class provides access to all the operations defined in GetPrivateDnsZoneSuffixesClient. */
-public interface GetPrivateDnsZoneSuffixesClient {
+/** An instance of this class provides access to all the operations defined in RecoverableServersClient. */
+public interface RecoverableServersClient {
/**
- * Get private DNS zone suffix in the cloud.
+ * Gets a recoverable PostgreSQL Server.
*
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
* @param context The context to associate with this operation.
* @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 private DNS zone suffix in the cloud along with {@link Response}.
+ * @return a recoverable PostgreSQL Server along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response executeWithResponse(Context context);
+ Response getWithResponse(
+ String resourceGroupName, String serverName, Context context);
/**
- * Get private DNS zone suffix in the cloud.
+ * Gets a recoverable 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 private DNS zone suffix in the cloud.
+ * @return a recoverable PostgreSQL Server.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- String execute();
+ RecoverableServerResourceInner get(String resourceGroupName, String serverName);
}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerAdministratorsClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerAdministratorsClient.java
new file mode 100644
index 0000000000000..9a8e33f451997
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerAdministratorsClient.java
@@ -0,0 +1,192 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent;
+
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceMethod;
+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.SyncPoller;
+import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ServerAdministratorResourceInner;
+
+/** An instance of this class provides access to all the operations defined in ServerAdministratorsClient. */
+public interface ServerAdministratorsClient {
+ /**
+ * Gets information about a AAD server administrator.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param context The context to associate with this operation.
+ * @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 AAD server administrator along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(
+ String resourceGroupName, String serverName, Context context);
+
+ /**
+ * Gets information about a AAD server administrator.
+ *
+ * @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 AAD server administrator.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ServerAdministratorResourceInner get(String resourceGroupName, String serverName);
+
+ /**
+ * Creates or update active directory administrator on an existing server. The update action will overwrite the
+ * existing administrator.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param properties The required parameters for creating or updating an AAD server 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 SyncPoller} for polling of represents a and external administrator to be created.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ServerAdministratorResourceInner> beginCreateOrUpdate(
+ String resourceGroupName, String serverName, ServerAdministratorResourceInner properties);
+
+ /**
+ * Creates or update active directory administrator on an existing server. The update action will overwrite the
+ * existing administrator.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param properties The required parameters for creating or updating an AAD server administrator.
+ * @param context The context to associate with this operation.
+ * @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 SyncPoller} for polling of represents a and external administrator to be created.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ServerAdministratorResourceInner> beginCreateOrUpdate(
+ String resourceGroupName, String serverName, ServerAdministratorResourceInner properties, Context context);
+
+ /**
+ * Creates or update active directory administrator on an existing server. The update action will overwrite the
+ * existing administrator.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param properties The required parameters for creating or updating an AAD server 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 represents a and external administrator to be created.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ServerAdministratorResourceInner createOrUpdate(
+ String resourceGroupName, String serverName, ServerAdministratorResourceInner properties);
+
+ /**
+ * Creates or update active directory administrator on an existing server. The update action will overwrite the
+ * existing administrator.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param properties The required parameters for creating or updating an AAD server administrator.
+ * @param context The context to associate with this operation.
+ * @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 and external administrator to be created.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ServerAdministratorResourceInner createOrUpdate(
+ String resourceGroupName, String serverName, ServerAdministratorResourceInner properties, Context context);
+
+ /**
+ * Deletes server active directory administrator.
+ *
+ * @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 SyncPoller} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginDelete(String resourceGroupName, String serverName);
+
+ /**
+ * Deletes server active directory administrator.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param context The context to associate with this operation.
+ * @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 SyncPoller} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginDelete(String resourceGroupName, String serverName, Context context);
+
+ /**
+ * Deletes server active directory administrator.
+ *
+ * @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.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ void delete(String resourceGroupName, String serverName);
+
+ /**
+ * Deletes server active directory administrator.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param context The context to associate with this operation.
+ * @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.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ void delete(String resourceGroupName, String serverName, Context context);
+
+ /**
+ * Returns a list of server Administrators.
+ *
+ * @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 response to a list Active Directory Administrators request as paginated response with {@link
+ * PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(String resourceGroupName, String serverName);
+
+ /**
+ * Returns a list of server Administrators.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param context The context to associate with this operation.
+ * @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 response to a list Active Directory Administrators request as paginated response with {@link
+ * PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(String resourceGroupName, String serverName, Context context);
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerBasedPerformanceTiersClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerBasedPerformanceTiersClient.java
new file mode 100644
index 0000000000000..7e3d4bcd26156
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerBasedPerformanceTiersClient.java
@@ -0,0 +1,41 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent;
+
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceMethod;
+import com.azure.core.http.rest.PagedIterable;
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.PerformanceTierPropertiesInner;
+
+/** An instance of this class provides access to all the operations defined in ServerBasedPerformanceTiersClient. */
+public interface ServerBasedPerformanceTiersClient {
+ /**
+ * List all the performance tiers for a 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 performance tiers as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(String resourceGroupName, String serverName);
+
+ /**
+ * List all the performance tiers for a PostgreSQL server.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param context The context to associate with this operation.
+ * @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 performance tiers as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(String resourceGroupName, String serverName, Context context);
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerKeysClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerKeysClient.java
new file mode 100644
index 0000000000000..1e303cbddeb8a
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerKeysClient.java
@@ -0,0 +1,197 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent;
+
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceMethod;
+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.SyncPoller;
+import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ServerKeyInner;
+
+/** An instance of this class provides access to all the operations defined in ServerKeysClient. */
+public interface ServerKeysClient {
+ /**
+ * Gets a list of Server keys.
+ *
+ * @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 keys as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(String resourceGroupName, String serverName);
+
+ /**
+ * Gets a list of Server keys.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param context The context to associate with this operation.
+ * @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 keys as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(String resourceGroupName, String serverName, Context context);
+
+ /**
+ * Gets a PostgreSQL Server key.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param keyName The name of the PostgreSQL Server key to be retrieved.
+ * @param context The context to associate with this operation.
+ * @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 PostgreSQL Server key along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(
+ String resourceGroupName, String serverName, String keyName, Context context);
+
+ /**
+ * Gets a PostgreSQL Server key.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param keyName The name of the PostgreSQL Server key to be retrieved.
+ * @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 PostgreSQL Server key.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ServerKeyInner get(String resourceGroupName, String serverName, String keyName);
+
+ /**
+ * Creates or updates a PostgreSQL Server key.
+ *
+ * @param serverName The name of the server.
+ * @param keyName The name of the PostgreSQL Server key to be operated on (updated or created).
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param parameters The requested PostgreSQL Server key resource state.
+ * @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 SyncPoller} for polling of a PostgreSQL Server key.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ServerKeyInner> beginCreateOrUpdate(
+ String serverName, String keyName, String resourceGroupName, ServerKeyInner parameters);
+
+ /**
+ * Creates or updates a PostgreSQL Server key.
+ *
+ * @param serverName The name of the server.
+ * @param keyName The name of the PostgreSQL Server key to be operated on (updated or created).
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param parameters The requested PostgreSQL Server key resource state.
+ * @param context The context to associate with this operation.
+ * @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 SyncPoller} for polling of a PostgreSQL Server key.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ServerKeyInner> beginCreateOrUpdate(
+ String serverName, String keyName, String resourceGroupName, ServerKeyInner parameters, Context context);
+
+ /**
+ * Creates or updates a PostgreSQL Server key.
+ *
+ * @param serverName The name of the server.
+ * @param keyName The name of the PostgreSQL Server key to be operated on (updated or created).
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param parameters The requested PostgreSQL Server key resource state.
+ * @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 PostgreSQL Server key.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ServerKeyInner createOrUpdate(
+ String serverName, String keyName, String resourceGroupName, ServerKeyInner parameters);
+
+ /**
+ * Creates or updates a PostgreSQL Server key.
+ *
+ * @param serverName The name of the server.
+ * @param keyName The name of the PostgreSQL Server key to be operated on (updated or created).
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param parameters The requested PostgreSQL Server key resource state.
+ * @param context The context to associate with this operation.
+ * @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 PostgreSQL Server key.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ServerKeyInner createOrUpdate(
+ String serverName, String keyName, String resourceGroupName, ServerKeyInner parameters, Context context);
+
+ /**
+ * Deletes the PostgreSQL Server key with the given name.
+ *
+ * @param serverName The name of the server.
+ * @param keyName The name of the PostgreSQL Server key to be deleted.
+ * @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 the {@link SyncPoller} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginDelete(String serverName, String keyName, String resourceGroupName);
+
+ /**
+ * Deletes the PostgreSQL Server key with the given name.
+ *
+ * @param serverName The name of the server.
+ * @param keyName The name of the PostgreSQL Server key to be deleted.
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param context The context to associate with this operation.
+ * @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 SyncPoller} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginDelete(
+ String serverName, String keyName, String resourceGroupName, Context context);
+
+ /**
+ * Deletes the PostgreSQL Server key with the given name.
+ *
+ * @param serverName The name of the server.
+ * @param keyName The name of the PostgreSQL Server key to be deleted.
+ * @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.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ void delete(String serverName, String keyName, String resourceGroupName);
+
+ /**
+ * Deletes the PostgreSQL Server key with the given name.
+ *
+ * @param serverName The name of the server.
+ * @param keyName The name of the PostgreSQL Server key to be deleted.
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param context The context to associate with this operation.
+ * @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.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ void delete(String serverName, String keyName, String resourceGroupName, Context context);
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerParametersClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerParametersClient.java
new file mode 100644
index 0000000000000..9065d1c37d0a6
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerParametersClient.java
@@ -0,0 +1,77 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent;
+
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceMethod;
+import com.azure.core.management.polling.PollResult;
+import com.azure.core.util.Context;
+import com.azure.core.util.polling.SyncPoller;
+import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ConfigurationListResultInner;
+
+/** An instance of this class provides access to all the operations defined in ServerParametersClient. */
+public interface ServerParametersClient {
+ /**
+ * Update a list of 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.
+ * @param value The parameters for updating a list of 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 SyncPoller} for polling of a list of server configurations.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ConfigurationListResultInner> beginListUpdateConfigurations(
+ String resourceGroupName, String serverName, ConfigurationListResultInner value);
+
+ /**
+ * Update a list of 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.
+ * @param value The parameters for updating a list of server configuration.
+ * @param context The context to associate with this operation.
+ * @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 SyncPoller} for polling of a list of server configurations.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ConfigurationListResultInner> beginListUpdateConfigurations(
+ String resourceGroupName, String serverName, ConfigurationListResultInner value, Context context);
+
+ /**
+ * Update a list of 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.
+ * @param value The parameters for updating a list of 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 a list of server configurations.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ConfigurationListResultInner listUpdateConfigurations(
+ String resourceGroupName, String serverName, ConfigurationListResultInner value);
+
+ /**
+ * Update a list of 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.
+ * @param value The parameters for updating a list of server configuration.
+ * @param context The context to associate with this operation.
+ * @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.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ConfigurationListResultInner listUpdateConfigurations(
+ String resourceGroupName, String serverName, ConfigurationListResultInner value, Context context);
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerSecurityAlertPoliciesClient.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerSecurityAlertPoliciesClient.java
new file mode 100644
index 0000000000000..867647eb04e26
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/ServerSecurityAlertPoliciesClient.java
@@ -0,0 +1,157 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent;
+
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceMethod;
+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.SyncPoller;
+import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ServerSecurityAlertPolicyInner;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.SecurityAlertPolicyName;
+
+/** An instance of this class provides access to all the operations defined in ServerSecurityAlertPoliciesClient. */
+public interface ServerSecurityAlertPoliciesClient {
+ /**
+ * Get a server's security alert policy.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param securityAlertPolicyName The name of the security alert policy.
+ * @param context The context to associate with this operation.
+ * @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 server's security alert policy along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(
+ String resourceGroupName, String serverName, SecurityAlertPolicyName securityAlertPolicyName, Context context);
+
+ /**
+ * Get a server's security alert policy.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param securityAlertPolicyName The name of the security alert policy.
+ * @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 server's security alert policy.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ServerSecurityAlertPolicyInner get(
+ String resourceGroupName, String serverName, SecurityAlertPolicyName securityAlertPolicyName);
+
+ /**
+ * Creates or updates a threat detection policy.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param securityAlertPolicyName The name of the threat detection policy.
+ * @param parameters The server security alert policy.
+ * @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 SyncPoller} for polling of a server security alert policy.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ServerSecurityAlertPolicyInner> beginCreateOrUpdate(
+ String resourceGroupName,
+ String serverName,
+ SecurityAlertPolicyName securityAlertPolicyName,
+ ServerSecurityAlertPolicyInner parameters);
+
+ /**
+ * Creates or updates a threat detection policy.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param securityAlertPolicyName The name of the threat detection policy.
+ * @param parameters The server security alert policy.
+ * @param context The context to associate with this operation.
+ * @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 SyncPoller} for polling of a server security alert policy.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ServerSecurityAlertPolicyInner> beginCreateOrUpdate(
+ String resourceGroupName,
+ String serverName,
+ SecurityAlertPolicyName securityAlertPolicyName,
+ ServerSecurityAlertPolicyInner parameters,
+ Context context);
+
+ /**
+ * Creates or updates a threat detection policy.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param securityAlertPolicyName The name of the threat detection policy.
+ * @param parameters The server security alert policy.
+ * @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 server security alert policy.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ServerSecurityAlertPolicyInner createOrUpdate(
+ String resourceGroupName,
+ String serverName,
+ SecurityAlertPolicyName securityAlertPolicyName,
+ ServerSecurityAlertPolicyInner parameters);
+
+ /**
+ * Creates or updates a threat detection policy.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param securityAlertPolicyName The name of the threat detection policy.
+ * @param parameters The server security alert policy.
+ * @param context The context to associate with this operation.
+ * @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 server security alert policy.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ServerSecurityAlertPolicyInner createOrUpdate(
+ String resourceGroupName,
+ String serverName,
+ SecurityAlertPolicyName securityAlertPolicyName,
+ ServerSecurityAlertPolicyInner parameters,
+ Context context);
+
+ /**
+ * Get the server's threat detection policies.
+ *
+ * @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 server's threat detection policies as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByServer(String resourceGroupName, String serverName);
+
+ /**
+ * Get the server's threat detection policies.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param serverName The name of the server.
+ * @param context The context to associate with this operation.
+ * @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 server's threat detection policies as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByServer(
+ String resourceGroupName, String serverName, Context context);
+}
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..ad7ea5406d82f 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
@@ -12,13 +12,13 @@
import com.azure.core.util.Context;
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 com.azure.resourcemanager.postgresqlflexibleserver.models.ServerForCreate;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerUpdateParameters;
/** An instance of this class provides access to all the operations defined in ServersClient. */
public interface ServersClient {
/**
- * Creates a new server.
+ * Creates a new server, or will overwrite an existing server.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param serverName The name of the server.
@@ -30,10 +30,10 @@ public interface ServersClient {
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, ServerInner> beginCreate(
- String resourceGroupName, String serverName, ServerInner parameters);
+ String resourceGroupName, String serverName, ServerForCreate parameters);
/**
- * Creates a new server.
+ * Creates a new server, or will overwrite an existing server.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param serverName The name of the server.
@@ -46,10 +46,10 @@ SyncPoller, ServerInner> beginCreate(
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, ServerInner> beginCreate(
- String resourceGroupName, String serverName, ServerInner parameters, Context context);
+ String resourceGroupName, String serverName, ServerForCreate parameters, Context context);
/**
- * Creates a new server.
+ * Creates a new server, or will overwrite an existing server.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param serverName The name of the server.
@@ -60,10 +60,10 @@ SyncPoller, ServerInner> beginCreate(
* @return represents a server.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- ServerInner create(String resourceGroupName, String serverName, ServerInner parameters);
+ ServerInner create(String resourceGroupName, String serverName, ServerForCreate parameters);
/**
- * Creates a new server.
+ * Creates a new server, or will overwrite an existing server.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param serverName The name of the server.
@@ -75,7 +75,7 @@ SyncPoller, ServerInner> beginCreate(
* @return represents a server.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- ServerInner create(String resourceGroupName, String serverName, ServerInner parameters, Context context);
+ ServerInner create(String resourceGroupName, String serverName, ServerForCreate parameters, Context context);
/**
* Updates an existing server. The request body can contain one to many of the properties present in the normal
@@ -91,7 +91,7 @@ SyncPoller, ServerInner> beginCreate(
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, ServerInner> beginUpdate(
- String resourceGroupName, String serverName, ServerForUpdate parameters);
+ String resourceGroupName, String serverName, ServerUpdateParameters parameters);
/**
* Updates an existing server. The request body can contain one to many of the properties present in the normal
@@ -108,7 +108,7 @@ SyncPoller, ServerInner> beginUpdate(
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, ServerInner> beginUpdate(
- String resourceGroupName, String serverName, ServerForUpdate parameters, Context context);
+ String resourceGroupName, String serverName, ServerUpdateParameters parameters, Context context);
/**
* Updates an existing server. The request body can contain one to many of the properties present in the normal
@@ -123,7 +123,7 @@ SyncPoller, ServerInner> beginUpdate(
* @return represents a server.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- ServerInner update(String resourceGroupName, String serverName, ServerForUpdate parameters);
+ ServerInner update(String resourceGroupName, String serverName, ServerUpdateParameters parameters);
/**
* Updates an existing server. The request body can contain one to many of the properties present in the normal
@@ -139,7 +139,7 @@ SyncPoller, ServerInner> beginUpdate(
* @return represents a server.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- ServerInner update(String resourceGroupName, String serverName, ServerForUpdate parameters, Context context);
+ ServerInner update(String resourceGroupName, String serverName, ServerUpdateParameters parameters, Context context);
/**
* Deletes a server.
@@ -285,7 +285,6 @@ SyncPoller, ServerInner> beginUpdate(
*
* @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.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
@@ -293,8 +292,7 @@ SyncPoller, ServerInner> beginUpdate(
* @return the {@link SyncPoller} for polling of long-running operation.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, Void> beginRestart(
- String resourceGroupName, String serverName, RestartParameter parameters, Context context);
+ SyncPoller, Void> beginRestart(String resourceGroupName, String serverName, Context context);
/**
* Restarts a server.
@@ -313,116 +311,11 @@ SyncPoller, Void> beginRestart(
*
* @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.
* @param context The context to associate with this operation.
* @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.
*/
@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 SyncPoller} for polling of long-running operation.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, Void> beginStart(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.
- * @param context The context to associate with this operation.
- * @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 SyncPoller} for polling of long-running operation.
- */
- @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.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- void start(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.
- * @param context The context to associate with this operation.
- * @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.
- */
- @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 SyncPoller} for polling of long-running operation.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, Void> beginStop(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.
- * @param context The context to associate with this operation.
- * @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 SyncPoller} for polling of long-running operation.
- */
- @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.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- void stop(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.
- * @param context The context to associate with this operation.
- * @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.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- void stop(String resourceGroupName, String serverName, Context context);
+ void restart(String resourceGroupName, String serverName, Context context);
}
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/VirtualNetworkRulesClient.java
similarity index 65%
rename from sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/AdministratorsClient.java
rename to sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/VirtualNetworkRulesClient.java
index e162e63a20655..8d2a6785b6f74 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/VirtualNetworkRulesClient.java
@@ -11,187 +11,187 @@
import com.azure.core.management.polling.PollResult;
import com.azure.core.util.Context;
import com.azure.core.util.polling.SyncPoller;
-import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ActiveDirectoryAdministratorInner;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.ActiveDirectoryAdministratorAdd;
+import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.VirtualNetworkRuleInner;
-/** An instance of this class provides access to all the operations defined in AdministratorsClient. */
-public interface AdministratorsClient {
+/** An instance of this class provides access to all the operations defined in VirtualNetworkRulesClient. */
+public interface VirtualNetworkRulesClient {
/**
- * Creates a new server.
+ * Gets a virtual network rule.
*
* @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.
+ * @param virtualNetworkRuleName The name of the virtual network rule.
+ * @param context The context to associate with this operation.
* @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 SyncPoller} for polling of represents an Active Directory administrator.
+ * @return a virtual network rule along with {@link Response}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, ActiveDirectoryAdministratorInner> beginCreate(
- String resourceGroupName, String serverName, String objectId, ActiveDirectoryAdministratorAdd parameters);
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(
+ String resourceGroupName, String serverName, String virtualNetworkRuleName, Context context);
/**
- * Creates a new server.
+ * Gets a virtual network rule.
*
* @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.
- * @param context The context to associate with this operation.
+ * @param virtualNetworkRuleName The name of the virtual network 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 SyncPoller} for polling of represents an Active Directory administrator.
+ * @return a virtual network rule.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, ActiveDirectoryAdministratorInner> beginCreate(
- String resourceGroupName,
- String serverName,
- String objectId,
- ActiveDirectoryAdministratorAdd parameters,
- Context context);
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ VirtualNetworkRuleInner get(String resourceGroupName, String serverName, String virtualNetworkRuleName);
/**
- * Creates a new server.
+ * Creates or updates an existing virtual network rule.
*
* @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.
+ * @param virtualNetworkRuleName The name of the virtual network rule.
+ * @param parameters The requested virtual Network Rule Resource state.
* @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.
+ * @return the {@link SyncPoller} for polling of a virtual network rule.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- ActiveDirectoryAdministratorInner create(
- String resourceGroupName, String serverName, String objectId, ActiveDirectoryAdministratorAdd parameters);
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, VirtualNetworkRuleInner> beginCreateOrUpdate(
+ String resourceGroupName, String serverName, String virtualNetworkRuleName, VirtualNetworkRuleInner parameters);
/**
- * Creates a new server.
+ * Creates or updates an existing virtual network rule.
*
* @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.
+ * @param virtualNetworkRuleName The name of the virtual network rule.
+ * @param parameters The requested virtual Network Rule Resource state.
* @param context The context to associate with this operation.
* @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.
+ * @return the {@link SyncPoller} for polling of a virtual network rule.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- ActiveDirectoryAdministratorInner create(
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, VirtualNetworkRuleInner> beginCreateOrUpdate(
String resourceGroupName,
String serverName,
- String objectId,
- ActiveDirectoryAdministratorAdd parameters,
+ String virtualNetworkRuleName,
+ VirtualNetworkRuleInner parameters,
Context context);
/**
- * Deletes an Active Directory Administrator associated with the server.
+ * Creates or updates an existing virtual network rule.
*
* @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 virtualNetworkRuleName The name of the virtual network rule.
+ * @param parameters The requested virtual Network Rule Resource state.
* @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 SyncPoller} for polling of long-running operation.
+ * @return a virtual network rule.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, Void> beginDelete(String resourceGroupName, String serverName, String objectId);
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ VirtualNetworkRuleInner createOrUpdate(
+ String resourceGroupName, String serverName, String virtualNetworkRuleName, VirtualNetworkRuleInner parameters);
/**
- * Deletes an Active Directory Administrator associated with the server.
+ * Creates or updates an existing virtual network rule.
*
* @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 virtualNetworkRuleName The name of the virtual network rule.
+ * @param parameters The requested virtual Network Rule Resource state.
* @param context The context to associate with this operation.
* @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 SyncPoller} for polling of long-running operation.
+ * @return a virtual network rule.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, Void> beginDelete(
- String resourceGroupName, String serverName, String objectId, Context context);
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ VirtualNetworkRuleInner createOrUpdate(
+ String resourceGroupName,
+ String serverName,
+ String virtualNetworkRuleName,
+ VirtualNetworkRuleInner parameters,
+ Context context);
/**
- * Deletes an Active Directory Administrator associated with the server.
+ * Deletes the virtual network rule with the given name.
*
* @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 virtualNetworkRuleName The name of the virtual network 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 SyncPoller} for polling of long-running operation.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- void delete(String resourceGroupName, String serverName, String objectId);
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginDelete(
+ String resourceGroupName, String serverName, String virtualNetworkRuleName);
/**
- * Deletes an Active Directory Administrator associated with the server.
+ * Deletes the virtual network rule with the given name.
*
* @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 virtualNetworkRuleName The name of the virtual network rule.
* @param context The context to associate with this operation.
* @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 SyncPoller} for polling of long-running operation.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- void delete(String resourceGroupName, String serverName, String objectId, Context context);
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginDelete(
+ String resourceGroupName, String serverName, String virtualNetworkRuleName, Context context);
/**
- * Gets information about a server.
+ * Deletes the virtual network rule with the given name.
*
* @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 context The context to associate with this operation.
+ * @param virtualNetworkRuleName The name of the virtual network 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 information about a server along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(
- String resourceGroupName, String serverName, String objectId, Context context);
+ void delete(String resourceGroupName, String serverName, String virtualNetworkRuleName);
/**
- * Gets information about a server.
+ * Deletes the virtual network rule with the given name.
*
* @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 virtualNetworkRuleName The name of the virtual network rule.
+ * @param context The context to associate with this operation.
* @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.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- ActiveDirectoryAdministratorInner get(String resourceGroupName, String serverName, String objectId);
+ void delete(String resourceGroupName, String serverName, String virtualNetworkRuleName, Context context);
/**
- * List all the AAD administrators for a given server.
+ * Gets a list of virtual network rules in 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 list of active directory administrators as paginated response with {@link PagedIterable}.
+ * @return a list of virtual network rules in a server as paginated response with {@link PagedIterable}.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByServer(String resourceGroupName, String serverName);
+ PagedIterable listByServer(String resourceGroupName, String serverName);
/**
- * List all the AAD administrators for a given server.
+ * Gets a list of virtual network rules in a server.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param serverName The name of the server.
@@ -199,9 +199,8 @@ Response getWithResponse(
* @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 PagedIterable}.
+ * @return a list of virtual network rules in a server as paginated response with {@link PagedIterable}.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByServer(
- String resourceGroupName, String serverName, Context context);
+ PagedIterable listByServer(String resourceGroupName, String serverName, Context context);
}
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
deleted file mode 100644
index b830067d42266..0000000000000
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/VirtualNetworkSubnetUsagesClient.java
+++ /dev/null
@@ -1,43 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.postgresqlflexibleserver.fluent;
-
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.Response;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.VirtualNetworkSubnetUsageResultInner;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.VirtualNetworkSubnetUsageParameter;
-
-/** 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.
- * @param context The context to associate with this operation.
- * @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}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response executeWithResponse(
- String locationName, VirtualNetworkSubnetUsageParameter parameters, Context context);
-
- /**
- * 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.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- VirtualNetworkSubnetUsageResultInner execute(String locationName, VirtualNetworkSubnetUsageParameter parameters);
-}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ActiveDirectoryAdministratorInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ActiveDirectoryAdministratorInner.java
deleted file mode 100644
index 201440d018d73..0000000000000
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ActiveDirectoryAdministratorInner.java
+++ /dev/null
@@ -1,160 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.management.SystemData;
-import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.PrincipalType;
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-/** Represents an Active Directory administrator. */
-@Fluent
-public final class ActiveDirectoryAdministratorInner extends ProxyResource {
- /*
- * Properties of the active directory administrator.
- */
- @JsonProperty(value = "properties", required = true)
- private AdministratorProperties innerProperties = new AdministratorProperties();
-
- /*
- * Azure Resource Manager metadata containing createdBy and modifiedBy information.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
- /** Creates an instance of ActiveDirectoryAdministratorInner class. */
- public ActiveDirectoryAdministratorInner() {
- }
-
- /**
- * Get the innerProperties property: Properties of the active directory administrator.
- *
- * @return the innerProperties value.
- */
- private AdministratorProperties innerProperties() {
- return this.innerProperties;
- }
-
- /**
- * Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- public SystemData systemData() {
- return this.systemData;
- }
-
- /**
- * Get the principalType property: The principal type used to represent the type of Active Directory Administrator.
- *
- * @return the principalType value.
- */
- public PrincipalType principalType() {
- return this.innerProperties() == null ? null : this.innerProperties().principalType();
- }
-
- /**
- * Set the principalType property: The principal type used to represent the type of Active Directory Administrator.
- *
- * @param principalType the principalType value to set.
- * @return the ActiveDirectoryAdministratorInner object itself.
- */
- public ActiveDirectoryAdministratorInner withPrincipalType(PrincipalType principalType) {
- if (this.innerProperties() == null) {
- this.innerProperties = new AdministratorProperties();
- }
- this.innerProperties().withPrincipalType(principalType);
- return this;
- }
-
- /**
- * Get the principalName property: Active Directory administrator principal name.
- *
- * @return the principalName value.
- */
- public String principalName() {
- return this.innerProperties() == null ? null : this.innerProperties().principalName();
- }
-
- /**
- * Set the principalName property: Active Directory administrator principal name.
- *
- * @param principalName the principalName value to set.
- * @return the ActiveDirectoryAdministratorInner object itself.
- */
- public ActiveDirectoryAdministratorInner withPrincipalName(String principalName) {
- if (this.innerProperties() == null) {
- this.innerProperties = new AdministratorProperties();
- }
- this.innerProperties().withPrincipalName(principalName);
- return this;
- }
-
- /**
- * Get the objectId property: The objectId of the Active Directory administrator.
- *
- * @return the objectId value.
- */
- public String objectId() {
- return this.innerProperties() == null ? null : this.innerProperties().objectId();
- }
-
- /**
- * Set the objectId property: The objectId of the Active Directory administrator.
- *
- * @param objectId the objectId value to set.
- * @return the ActiveDirectoryAdministratorInner object itself.
- */
- public ActiveDirectoryAdministratorInner withObjectId(String objectId) {
- if (this.innerProperties() == null) {
- this.innerProperties = new AdministratorProperties();
- }
- this.innerProperties().withObjectId(objectId);
- return this;
- }
-
- /**
- * Get the tenantId property: The tenantId of the Active Directory administrator.
- *
- * @return the tenantId value.
- */
- public String tenantId() {
- return this.innerProperties() == null ? null : this.innerProperties().tenantId();
- }
-
- /**
- * Set the tenantId property: The tenantId of the Active Directory administrator.
- *
- * @param tenantId the tenantId value to set.
- * @return the ActiveDirectoryAdministratorInner object itself.
- */
- public ActiveDirectoryAdministratorInner withTenantId(String tenantId) {
- if (this.innerProperties() == null) {
- this.innerProperties = new AdministratorProperties();
- }
- this.innerProperties().withTenantId(tenantId);
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (innerProperties() == null) {
- throw LOGGER
- .logExceptionAsError(
- new IllegalArgumentException(
- "Missing required property innerProperties in model ActiveDirectoryAdministratorInner"));
- } else {
- innerProperties().validate();
- }
- }
-
- private static final ClientLogger LOGGER = new ClientLogger(ActiveDirectoryAdministratorInner.class);
-}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/AdministratorProperties.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/AdministratorProperties.java
deleted file mode 100644
index 8412529cb557d..0000000000000
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/AdministratorProperties.java
+++ /dev/null
@@ -1,129 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.PrincipalType;
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-/** The properties of an Active Directory administrator. */
-@Fluent
-public final class AdministratorProperties {
- /*
- * The principal type used to represent the type of Active Directory Administrator.
- */
- @JsonProperty(value = "principalType")
- private PrincipalType principalType;
-
- /*
- * Active Directory administrator principal name.
- */
- @JsonProperty(value = "principalName")
- private String principalName;
-
- /*
- * The objectId of the Active Directory administrator.
- */
- @JsonProperty(value = "objectId")
- private String objectId;
-
- /*
- * The tenantId of the Active Directory administrator.
- */
- @JsonProperty(value = "tenantId")
- private String tenantId;
-
- /** Creates an instance of AdministratorProperties class. */
- public AdministratorProperties() {
- }
-
- /**
- * Get the principalType property: The principal type used to represent the type of Active Directory Administrator.
- *
- * @return the principalType value.
- */
- public PrincipalType principalType() {
- return this.principalType;
- }
-
- /**
- * Set the principalType property: The principal type used to represent the type of Active Directory Administrator.
- *
- * @param principalType the principalType value to set.
- * @return the AdministratorProperties object itself.
- */
- public AdministratorProperties withPrincipalType(PrincipalType principalType) {
- this.principalType = principalType;
- return this;
- }
-
- /**
- * Get the principalName property: Active Directory administrator principal name.
- *
- * @return the principalName value.
- */
- public String principalName() {
- return this.principalName;
- }
-
- /**
- * Set the principalName property: Active Directory administrator principal name.
- *
- * @param principalName the principalName value to set.
- * @return the AdministratorProperties object itself.
- */
- public AdministratorProperties withPrincipalName(String principalName) {
- this.principalName = principalName;
- return this;
- }
-
- /**
- * Get the objectId property: The objectId of the Active Directory administrator.
- *
- * @return the objectId value.
- */
- public String objectId() {
- return this.objectId;
- }
-
- /**
- * Set the objectId property: The objectId of the Active Directory administrator.
- *
- * @param objectId the objectId value to set.
- * @return the AdministratorProperties object itself.
- */
- public AdministratorProperties withObjectId(String objectId) {
- this.objectId = objectId;
- return this;
- }
-
- /**
- * Get the tenantId property: The tenantId of the Active Directory administrator.
- *
- * @return the tenantId value.
- */
- public String tenantId() {
- return this.tenantId;
- }
-
- /**
- * Set the tenantId property: The tenantId of the Active Directory administrator.
- *
- * @param tenantId the tenantId value to set.
- * @return the AdministratorProperties object itself.
- */
- public AdministratorProperties withTenantId(String tenantId) {
- this.tenantId = tenantId;
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/AdministratorPropertiesForAdd.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/AdministratorPropertiesForAdd.java
deleted file mode 100644
index e2a26695b822d..0000000000000
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/AdministratorPropertiesForAdd.java
+++ /dev/null
@@ -1,103 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.PrincipalType;
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-/** The properties of an Active Directory administrator. */
-@Fluent
-public final class AdministratorPropertiesForAdd {
- /*
- * The principal type used to represent the type of Active Directory Administrator.
- */
- @JsonProperty(value = "principalType")
- private PrincipalType principalType;
-
- /*
- * Active Directory administrator principal name.
- */
- @JsonProperty(value = "principalName")
- private String principalName;
-
- /*
- * The tenantId of the Active Directory administrator.
- */
- @JsonProperty(value = "tenantId")
- private String tenantId;
-
- /** Creates an instance of AdministratorPropertiesForAdd class. */
- public AdministratorPropertiesForAdd() {
- }
-
- /**
- * Get the principalType property: The principal type used to represent the type of Active Directory Administrator.
- *
- * @return the principalType value.
- */
- public PrincipalType principalType() {
- return this.principalType;
- }
-
- /**
- * Set the principalType property: The principal type used to represent the type of Active Directory Administrator.
- *
- * @param principalType the principalType value to set.
- * @return the AdministratorPropertiesForAdd object itself.
- */
- public AdministratorPropertiesForAdd withPrincipalType(PrincipalType principalType) {
- this.principalType = principalType;
- return this;
- }
-
- /**
- * Get the principalName property: Active Directory administrator principal name.
- *
- * @return the principalName value.
- */
- public String principalName() {
- return this.principalName;
- }
-
- /**
- * Set the principalName property: Active Directory administrator principal name.
- *
- * @param principalName the principalName value to set.
- * @return the AdministratorPropertiesForAdd object itself.
- */
- public AdministratorPropertiesForAdd withPrincipalName(String principalName) {
- this.principalName = principalName;
- return this;
- }
-
- /**
- * Get the tenantId property: The tenantId of the Active Directory administrator.
- *
- * @return the tenantId value.
- */
- public String tenantId() {
- return this.tenantId;
- }
-
- /**
- * Set the tenantId property: The tenantId of the Active Directory administrator.
- *
- * @param tenantId the tenantId value to set.
- * @return the AdministratorPropertiesForAdd object itself.
- */
- public AdministratorPropertiesForAdd withTenantId(String tenantId) {
- this.tenantId = tenantId;
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/CapabilityPropertiesInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/CapabilityPropertiesInner.java
deleted file mode 100644
index e0ecfaae1617d..0000000000000
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/CapabilityPropertiesInner.java
+++ /dev/null
@@ -1,191 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
-
-import com.azure.core.annotation.Immutable;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.FastProvisioningEditionCapability;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.FlexibleServerEditionCapability;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.HyperscaleNodeEditionCapability;
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.List;
-
-/** Location capabilities. */
-@Immutable
-public final class CapabilityPropertiesInner {
- /*
- * zone name
- */
- @JsonProperty(value = "zone", access = JsonProperty.Access.WRITE_ONLY)
- private String zone;
-
- /*
- * Supported high availability mode
- */
- @JsonProperty(value = "supportedHAMode", access = JsonProperty.Access.WRITE_ONLY)
- private List supportedHAMode;
-
- /*
- * A value indicating whether a new server in this region can have geo-backups to paired region.
- */
- @JsonProperty(value = "geoBackupSupported", access = JsonProperty.Access.WRITE_ONLY)
- private Boolean geoBackupSupported;
-
- /*
- * A value indicating whether a new server in this region can support multi zone HA.
- */
- @JsonProperty(value = "zoneRedundantHaSupported", access = JsonProperty.Access.WRITE_ONLY)
- private Boolean zoneRedundantHaSupported;
-
- /*
- * A value indicating whether a new server in this region can have geo-backups to paired region.
- */
- @JsonProperty(value = "zoneRedundantHaAndGeoBackupSupported", access = JsonProperty.Access.WRITE_ONLY)
- private Boolean zoneRedundantHaAndGeoBackupSupported;
-
- /*
- * The supportedFlexibleServerEditions property.
- */
- @JsonProperty(value = "supportedFlexibleServerEditions", access = JsonProperty.Access.WRITE_ONLY)
- private List supportedFlexibleServerEditions;
-
- /*
- * The supportedHyperscaleNodeEditions property.
- */
- @JsonProperty(value = "supportedHyperscaleNodeEditions", access = JsonProperty.Access.WRITE_ONLY)
- private List supportedHyperscaleNodeEditions;
-
- /*
- * A value indicating whether fast provisioning is supported in this region.
- */
- @JsonProperty(value = "fastProvisioningSupported", access = JsonProperty.Access.WRITE_ONLY)
- private Boolean fastProvisioningSupported;
-
- /*
- * The supportedFastProvisioningEditions property.
- */
- @JsonProperty(value = "supportedFastProvisioningEditions", access = JsonProperty.Access.WRITE_ONLY)
- private List supportedFastProvisioningEditions;
-
- /*
- * The status
- */
- @JsonProperty(value = "status", access = JsonProperty.Access.WRITE_ONLY)
- private String status;
-
- /** Creates an instance of CapabilityPropertiesInner class. */
- public CapabilityPropertiesInner() {
- }
-
- /**
- * Get the zone property: zone name.
- *
- * @return the zone value.
- */
- public String zone() {
- return this.zone;
- }
-
- /**
- * Get the supportedHAMode property: Supported high availability mode.
- *
- * @return the supportedHAMode value.
- */
- public List supportedHAMode() {
- return this.supportedHAMode;
- }
-
- /**
- * Get the geoBackupSupported property: A value indicating whether a new server in this region can have geo-backups
- * to paired region.
- *
- * @return the geoBackupSupported value.
- */
- public Boolean geoBackupSupported() {
- return this.geoBackupSupported;
- }
-
- /**
- * Get the zoneRedundantHaSupported property: A value indicating whether a new server in this region can support
- * multi zone HA.
- *
- * @return the zoneRedundantHaSupported value.
- */
- public Boolean zoneRedundantHaSupported() {
- return this.zoneRedundantHaSupported;
- }
-
- /**
- * Get the zoneRedundantHaAndGeoBackupSupported property: A value indicating whether a new server in this region can
- * have geo-backups to paired region.
- *
- * @return the zoneRedundantHaAndGeoBackupSupported value.
- */
- public Boolean zoneRedundantHaAndGeoBackupSupported() {
- return this.zoneRedundantHaAndGeoBackupSupported;
- }
-
- /**
- * Get the supportedFlexibleServerEditions property: The supportedFlexibleServerEditions property.
- *
- * @return the supportedFlexibleServerEditions value.
- */
- public List supportedFlexibleServerEditions() {
- return this.supportedFlexibleServerEditions;
- }
-
- /**
- * Get the supportedHyperscaleNodeEditions property: The supportedHyperscaleNodeEditions property.
- *
- * @return the supportedHyperscaleNodeEditions value.
- */
- public List supportedHyperscaleNodeEditions() {
- return this.supportedHyperscaleNodeEditions;
- }
-
- /**
- * Get the fastProvisioningSupported property: A value indicating whether fast provisioning is supported in this
- * region.
- *
- * @return the fastProvisioningSupported value.
- */
- public Boolean fastProvisioningSupported() {
- return this.fastProvisioningSupported;
- }
-
- /**
- * Get the supportedFastProvisioningEditions property: The supportedFastProvisioningEditions property.
- *
- * @return the supportedFastProvisioningEditions value.
- */
- public List supportedFastProvisioningEditions() {
- return this.supportedFastProvisioningEditions;
- }
-
- /**
- * Get the status property: The status.
- *
- * @return the status value.
- */
- public String status() {
- return this.status;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (supportedFlexibleServerEditions() != null) {
- supportedFlexibleServerEditions().forEach(e -> e.validate());
- }
- if (supportedHyperscaleNodeEditions() != null) {
- supportedHyperscaleNodeEditions().forEach(e -> e.validate());
- }
- if (supportedFastProvisioningEditions() != null) {
- supportedFastProvisioningEditions().forEach(e -> e.validate());
- }
- }
-}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ConfigurationInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ConfigurationInner.java
index 2562a1c16be45..7f6d87282b32e 100644
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ConfigurationInner.java
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ConfigurationInner.java
@@ -6,8 +6,6 @@
import com.azure.core.annotation.Fluent;
import com.azure.core.management.ProxyResource;
-import com.azure.core.management.SystemData;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.ConfigurationDataType;
import com.fasterxml.jackson.annotation.JsonProperty;
/** Represents a Configuration. */
@@ -19,12 +17,6 @@ public final class ConfigurationInner extends ProxyResource {
@JsonProperty(value = "properties")
private ConfigurationProperties innerProperties;
- /*
- * Azure Resource Manager metadata containing createdBy and modifiedBy information.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
/** Creates an instance of ConfigurationInner class. */
public ConfigurationInner() {
}
@@ -38,15 +30,6 @@ private ConfigurationProperties innerProperties() {
return this.innerProperties;
}
- /**
- * Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- public SystemData systemData() {
- return this.systemData;
- }
-
/**
* Get the value property: Value of the configuration.
*
@@ -93,7 +76,7 @@ public String defaultValue() {
*
* @return the dataType value.
*/
- public ConfigurationDataType dataType() {
+ public String dataType() {
return this.innerProperties() == null ? null : this.innerProperties().dataType();
}
@@ -129,51 +112,6 @@ public ConfigurationInner withSource(String source) {
return this;
}
- /**
- * Get the isDynamicConfig property: Configuration dynamic or static.
- *
- * @return the isDynamicConfig value.
- */
- public Boolean isDynamicConfig() {
- return this.innerProperties() == null ? null : this.innerProperties().isDynamicConfig();
- }
-
- /**
- * Get the isReadOnly property: Configuration read-only or not.
- *
- * @return the isReadOnly value.
- */
- public Boolean isReadOnly() {
- return this.innerProperties() == null ? null : this.innerProperties().isReadOnly();
- }
-
- /**
- * Get the isConfigPendingRestart property: Configuration is pending restart or not.
- *
- * @return the isConfigPendingRestart value.
- */
- public Boolean isConfigPendingRestart() {
- return this.innerProperties() == null ? null : this.innerProperties().isConfigPendingRestart();
- }
-
- /**
- * Get the unit property: Configuration unit.
- *
- * @return the unit value.
- */
- public String unit() {
- return this.innerProperties() == null ? null : this.innerProperties().unit();
- }
-
- /**
- * Get the documentationLink property: Configuration documentation link.
- *
- * @return the documentationLink value.
- */
- public String documentationLink() {
- return this.innerProperties() == null ? null : this.innerProperties().documentationLink();
- }
-
/**
* Validates the instance.
*
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ConfigurationListResultInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ConfigurationListResultInner.java
new file mode 100644
index 0000000000000..7fab1fccbbbc1
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ConfigurationListResultInner.java
@@ -0,0 +1,54 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** A list of server configurations. */
+@Fluent
+public final class ConfigurationListResultInner {
+ /*
+ * The list of server configurations.
+ */
+ @JsonProperty(value = "value")
+ private List value;
+
+ /** Creates an instance of ConfigurationListResultInner class. */
+ public ConfigurationListResultInner() {
+ }
+
+ /**
+ * Get the value property: The list of server configurations.
+ *
+ * @return the value value.
+ */
+ public List value() {
+ return this.value;
+ }
+
+ /**
+ * Set the value property: The list of server configurations.
+ *
+ * @param value the value value to set.
+ * @return the ConfigurationListResultInner object itself.
+ */
+ public ConfigurationListResultInner withValue(List value) {
+ this.value = value;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (value() != null) {
+ value().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ConfigurationProperties.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ConfigurationProperties.java
index 18b44916b7acc..14dd9dbab4f0c 100644
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ConfigurationProperties.java
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ConfigurationProperties.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.ConfigurationDataType;
import com.fasterxml.jackson.annotation.JsonProperty;
/** The properties of a configuration. */
@@ -33,7 +32,7 @@ public final class ConfigurationProperties {
* Data type of the configuration.
*/
@JsonProperty(value = "dataType", access = JsonProperty.Access.WRITE_ONLY)
- private ConfigurationDataType dataType;
+ private String dataType;
/*
* Allowed values of the configuration.
@@ -47,36 +46,6 @@ public final class ConfigurationProperties {
@JsonProperty(value = "source")
private String source;
- /*
- * Configuration dynamic or static.
- */
- @JsonProperty(value = "isDynamicConfig", access = JsonProperty.Access.WRITE_ONLY)
- private Boolean isDynamicConfig;
-
- /*
- * Configuration read-only or not.
- */
- @JsonProperty(value = "isReadOnly", access = JsonProperty.Access.WRITE_ONLY)
- private Boolean isReadOnly;
-
- /*
- * Configuration is pending restart or not.
- */
- @JsonProperty(value = "isConfigPendingRestart", access = JsonProperty.Access.WRITE_ONLY)
- private Boolean isConfigPendingRestart;
-
- /*
- * Configuration unit.
- */
- @JsonProperty(value = "unit", access = JsonProperty.Access.WRITE_ONLY)
- private String unit;
-
- /*
- * Configuration documentation link.
- */
- @JsonProperty(value = "documentationLink", access = JsonProperty.Access.WRITE_ONLY)
- private String documentationLink;
-
/** Creates an instance of ConfigurationProperties class. */
public ConfigurationProperties() {
}
@@ -124,7 +93,7 @@ public String defaultValue() {
*
* @return the dataType value.
*/
- public ConfigurationDataType dataType() {
+ public String dataType() {
return this.dataType;
}
@@ -157,51 +126,6 @@ public ConfigurationProperties withSource(String source) {
return this;
}
- /**
- * Get the isDynamicConfig property: Configuration dynamic or static.
- *
- * @return the isDynamicConfig value.
- */
- public Boolean isDynamicConfig() {
- return this.isDynamicConfig;
- }
-
- /**
- * Get the isReadOnly property: Configuration read-only or not.
- *
- * @return the isReadOnly value.
- */
- public Boolean isReadOnly() {
- return this.isReadOnly;
- }
-
- /**
- * Get the isConfigPendingRestart property: Configuration is pending restart or not.
- *
- * @return the isConfigPendingRestart value.
- */
- public Boolean isConfigPendingRestart() {
- return this.isConfigPendingRestart;
- }
-
- /**
- * Get the unit property: Configuration unit.
- *
- * @return the unit value.
- */
- public String unit() {
- return this.unit;
- }
-
- /**
- * Get the documentationLink property: Configuration documentation link.
- *
- * @return the documentationLink value.
- */
- public String documentationLink() {
- return this.documentationLink;
- }
-
/**
* Validates the instance.
*
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/DatabaseInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/DatabaseInner.java
index 67aa3497dfaa6..8c1b7b16d59e2 100644
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/DatabaseInner.java
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/DatabaseInner.java
@@ -6,7 +6,6 @@
import com.azure.core.annotation.Fluent;
import com.azure.core.management.ProxyResource;
-import com.azure.core.management.SystemData;
import com.fasterxml.jackson.annotation.JsonProperty;
/** Represents a Database. */
@@ -18,12 +17,6 @@ public final class DatabaseInner extends ProxyResource {
@JsonProperty(value = "properties")
private DatabaseProperties innerProperties;
- /*
- * Azure Resource Manager metadata containing createdBy and modifiedBy information.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
/** Creates an instance of DatabaseInner class. */
public DatabaseInner() {
}
@@ -37,15 +30,6 @@ private DatabaseProperties innerProperties() {
return this.innerProperties;
}
- /**
- * Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- public SystemData systemData() {
- return this.systemData;
- }
-
/**
* Get the charset property: The charset of the database.
*
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/FirewallRuleInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/FirewallRuleInner.java
index 7f35a14cdf8d8..03515fe0ba7d4 100644
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/FirewallRuleInner.java
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/FirewallRuleInner.java
@@ -6,7 +6,6 @@
import com.azure.core.annotation.Fluent;
import com.azure.core.management.ProxyResource;
-import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
import com.fasterxml.jackson.annotation.JsonProperty;
@@ -19,12 +18,6 @@ public final class FirewallRuleInner extends ProxyResource {
@JsonProperty(value = "properties", required = true)
private FirewallRuleProperties innerProperties = new FirewallRuleProperties();
- /*
- * Azure Resource Manager metadata containing createdBy and modifiedBy information.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
/** Creates an instance of FirewallRuleInner class. */
public FirewallRuleInner() {
}
@@ -38,15 +31,6 @@ private FirewallRuleProperties innerProperties() {
return this.innerProperties;
}
- /**
- * Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- public SystemData systemData() {
- return this.systemData;
- }
-
/**
* Get the startIpAddress property: The start IP address of the server firewall rule. Must be IPv4 format.
*
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/LogFileInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/LogFileInner.java
new file mode 100644
index 0000000000000..2f8a8a66cf9f4
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/LogFileInner.java
@@ -0,0 +1,131 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.management.ProxyResource;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.time.OffsetDateTime;
+
+/** Represents a log file. */
+@Fluent
+public final class LogFileInner extends ProxyResource {
+ /*
+ * The properties of the log file.
+ */
+ @JsonProperty(value = "properties")
+ private LogFileProperties innerProperties;
+
+ /** Creates an instance of LogFileInner class. */
+ public LogFileInner() {
+ }
+
+ /**
+ * Get the innerProperties property: The properties of the log file.
+ *
+ * @return the innerProperties value.
+ */
+ private LogFileProperties innerProperties() {
+ return this.innerProperties;
+ }
+
+ /**
+ * Get the sizeInKB property: Size of the log file.
+ *
+ * @return the sizeInKB value.
+ */
+ public Long sizeInKB() {
+ return this.innerProperties() == null ? null : this.innerProperties().sizeInKB();
+ }
+
+ /**
+ * Set the sizeInKB property: Size of the log file.
+ *
+ * @param sizeInKB the sizeInKB value to set.
+ * @return the LogFileInner object itself.
+ */
+ public LogFileInner withSizeInKB(Long sizeInKB) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LogFileProperties();
+ }
+ this.innerProperties().withSizeInKB(sizeInKB);
+ return this;
+ }
+
+ /**
+ * Get the createdTime property: Creation timestamp of the log file.
+ *
+ * @return the createdTime value.
+ */
+ public OffsetDateTime createdTime() {
+ return this.innerProperties() == null ? null : this.innerProperties().createdTime();
+ }
+
+ /**
+ * Get the lastModifiedTime property: Last modified timestamp of the log file.
+ *
+ * @return the lastModifiedTime value.
+ */
+ public OffsetDateTime lastModifiedTime() {
+ return this.innerProperties() == null ? null : this.innerProperties().lastModifiedTime();
+ }
+
+ /**
+ * Get the type property: Type of the log file.
+ *
+ * @return the type value.
+ */
+ public String typePropertiesType() {
+ return this.innerProperties() == null ? null : this.innerProperties().type();
+ }
+
+ /**
+ * Set the type property: Type of the log file.
+ *
+ * @param type the type value to set.
+ * @return the LogFileInner object itself.
+ */
+ public LogFileInner withTypePropertiesType(String type) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LogFileProperties();
+ }
+ this.innerProperties().withType(type);
+ return this;
+ }
+
+ /**
+ * Get the url property: The url to download the log file from.
+ *
+ * @return the url value.
+ */
+ public String url() {
+ return this.innerProperties() == null ? null : this.innerProperties().url();
+ }
+
+ /**
+ * Set the url property: The url to download the log file from.
+ *
+ * @param url the url value to set.
+ * @return the LogFileInner object itself.
+ */
+ public LogFileInner withUrl(String url) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LogFileProperties();
+ }
+ this.innerProperties().withUrl(url);
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/LogFileProperties.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/LogFileProperties.java
new file mode 100644
index 0000000000000..9831c88cd856c
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/LogFileProperties.java
@@ -0,0 +1,133 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.time.OffsetDateTime;
+
+/** The properties of a log file. */
+@Fluent
+public final class LogFileProperties {
+ /*
+ * Size of the log file.
+ */
+ @JsonProperty(value = "sizeInKB")
+ private Long sizeInKB;
+
+ /*
+ * Creation timestamp of the log file.
+ */
+ @JsonProperty(value = "createdTime", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime createdTime;
+
+ /*
+ * Last modified timestamp of the log file.
+ */
+ @JsonProperty(value = "lastModifiedTime", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime lastModifiedTime;
+
+ /*
+ * Type of the log file.
+ */
+ @JsonProperty(value = "type")
+ private String type;
+
+ /*
+ * The url to download the log file from.
+ */
+ @JsonProperty(value = "url")
+ private String url;
+
+ /** Creates an instance of LogFileProperties class. */
+ public LogFileProperties() {
+ }
+
+ /**
+ * Get the sizeInKB property: Size of the log file.
+ *
+ * @return the sizeInKB value.
+ */
+ public Long sizeInKB() {
+ return this.sizeInKB;
+ }
+
+ /**
+ * Set the sizeInKB property: Size of the log file.
+ *
+ * @param sizeInKB the sizeInKB value to set.
+ * @return the LogFileProperties object itself.
+ */
+ public LogFileProperties withSizeInKB(Long sizeInKB) {
+ this.sizeInKB = sizeInKB;
+ return this;
+ }
+
+ /**
+ * Get the createdTime property: Creation timestamp of the log file.
+ *
+ * @return the createdTime value.
+ */
+ public OffsetDateTime createdTime() {
+ return this.createdTime;
+ }
+
+ /**
+ * Get the lastModifiedTime property: Last modified timestamp of the log file.
+ *
+ * @return the lastModifiedTime value.
+ */
+ public OffsetDateTime lastModifiedTime() {
+ return this.lastModifiedTime;
+ }
+
+ /**
+ * Get the type property: Type of the log file.
+ *
+ * @return the type value.
+ */
+ public String type() {
+ return this.type;
+ }
+
+ /**
+ * Set the type property: Type of the log file.
+ *
+ * @param type the type value to set.
+ * @return the LogFileProperties object itself.
+ */
+ public LogFileProperties withType(String type) {
+ this.type = type;
+ return this;
+ }
+
+ /**
+ * Get the url property: The url to download the log file from.
+ *
+ * @return the url value.
+ */
+ public String url() {
+ return this.url;
+ }
+
+ /**
+ * Set the url property: The url to download the log file from.
+ *
+ * @param url the url value to set.
+ * @return the LogFileProperties object itself.
+ */
+ public LogFileProperties withUrl(String url) {
+ this.url = url;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/NameAvailabilityInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/NameAvailabilityInner.java
index fff442a8ec670..83a6054a6cae8 100644
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/NameAvailabilityInner.java
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/NameAvailabilityInner.java
@@ -5,65 +5,90 @@
package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.CheckNameAvailabilityReason;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.CheckNameAvailabilityResponse;
import com.fasterxml.jackson.annotation.JsonProperty;
/** Represents a resource name availability. */
@Fluent
-public final class NameAvailabilityInner extends CheckNameAvailabilityResponse {
+public final class NameAvailabilityInner {
/*
- * name of the PostgreSQL server.
+ * Error Message.
*/
- @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY)
- private String name;
+ @JsonProperty(value = "message")
+ private String message;
/*
- * type of the server
+ * Indicates whether the resource name is available.
*/
- @JsonProperty(value = "type", access = JsonProperty.Access.WRITE_ONLY)
- private String type;
+ @JsonProperty(value = "nameAvailable")
+ private Boolean nameAvailable;
+
+ /*
+ * Reason for name being unavailable.
+ */
+ @JsonProperty(value = "reason")
+ private String reason;
/** Creates an instance of NameAvailabilityInner class. */
public NameAvailabilityInner() {
}
/**
- * Get the name property: name of the PostgreSQL server.
+ * Get the message property: Error Message.
*
- * @return the name value.
+ * @return the message value.
*/
- public String name() {
- return this.name;
+ public String message() {
+ return this.message;
}
/**
- * Get the type property: type of the server.
+ * Set the message property: Error Message.
*
- * @return the type value.
+ * @param message the message value to set.
+ * @return the NameAvailabilityInner object itself.
*/
- public String type() {
- return this.type;
+ public NameAvailabilityInner withMessage(String message) {
+ this.message = message;
+ return this;
}
- /** {@inheritDoc} */
- @Override
+ /**
+ * Get the nameAvailable property: Indicates whether the resource name is available.
+ *
+ * @return the nameAvailable value.
+ */
+ public Boolean nameAvailable() {
+ return this.nameAvailable;
+ }
+
+ /**
+ * Set the nameAvailable property: Indicates whether the resource name is available.
+ *
+ * @param nameAvailable the nameAvailable value to set.
+ * @return the NameAvailabilityInner object itself.
+ */
public NameAvailabilityInner withNameAvailable(Boolean nameAvailable) {
- super.withNameAvailable(nameAvailable);
+ this.nameAvailable = nameAvailable;
return this;
}
- /** {@inheritDoc} */
- @Override
- public NameAvailabilityInner withReason(CheckNameAvailabilityReason reason) {
- super.withReason(reason);
- return this;
+ /**
+ * Get the reason property: Reason for name being unavailable.
+ *
+ * @return the reason value.
+ */
+ public String reason() {
+ return this.reason;
}
- /** {@inheritDoc} */
- @Override
- public NameAvailabilityInner withMessage(String message) {
- super.withMessage(message);
+ /**
+ * Set the reason property: Reason for name being unavailable.
+ *
+ * @param reason the reason value to set.
+ * @return the NameAvailabilityInner object itself.
+ */
+ public NameAvailabilityInner withReason(String reason) {
+ this.reason = reason;
return this;
}
@@ -72,8 +97,6 @@ public NameAvailabilityInner withMessage(String message) {
*
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
- @Override
public void validate() {
- super.validate();
}
}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/OperationListResultInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/OperationListResultInner.java
index 990095f9e2107..2c3f69204bfcd 100644
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/OperationListResultInner.java
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/OperationListResultInner.java
@@ -13,24 +13,17 @@
@Fluent
public final class OperationListResultInner {
/*
- * Collection of available operation details
+ * The list of resource provider operations.
*/
@JsonProperty(value = "value")
private List value;
- /*
- * URL client should use to fetch the next page (per server side paging).
- * It's null for now, added for future use.
- */
- @JsonProperty(value = "nextLink")
- private String nextLink;
-
/** Creates an instance of OperationListResultInner class. */
public OperationListResultInner() {
}
/**
- * Get the value property: Collection of available operation details.
+ * Get the value property: The list of resource provider operations.
*
* @return the value value.
*/
@@ -39,7 +32,7 @@ public List value() {
}
/**
- * Set the value property: Collection of available operation details.
+ * Set the value property: The list of resource provider operations.
*
* @param value the value value to set.
* @return the OperationListResultInner object itself.
@@ -49,28 +42,6 @@ public OperationListResultInner withValue(List value) {
return this;
}
- /**
- * Get the nextLink property: URL client should use to fetch the next page (per server side paging). It's null for
- * now, added for future use.
- *
- * @return the nextLink value.
- */
- public String nextLink() {
- return this.nextLink;
- }
-
- /**
- * Set the nextLink property: URL client should use to fetch the next page (per server side paging). It's null for
- * now, added for future use.
- *
- * @param nextLink the nextLink value to set.
- * @return the OperationListResultInner object itself.
- */
- public OperationListResultInner withNextLink(String nextLink) {
- this.nextLink = nextLink;
- return this;
- }
-
/**
* Validates the instance.
*
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/PerformanceTierPropertiesInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/PerformanceTierPropertiesInner.java
new file mode 100644
index 0000000000000..b726369c8fb7e
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/PerformanceTierPropertiesInner.java
@@ -0,0 +1,238 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.PerformanceTierServiceLevelObjectives;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** Performance tier properties. */
+@Fluent
+public final class PerformanceTierPropertiesInner {
+ /*
+ * ID of the performance tier.
+ */
+ @JsonProperty(value = "id")
+ private String id;
+
+ /*
+ * Maximum Backup retention in days for the performance tier edition
+ */
+ @JsonProperty(value = "maxBackupRetentionDays")
+ private Integer maxBackupRetentionDays;
+
+ /*
+ * Minimum Backup retention in days for the performance tier edition
+ */
+ @JsonProperty(value = "minBackupRetentionDays")
+ private Integer minBackupRetentionDays;
+
+ /*
+ * Max storage allowed for a server.
+ */
+ @JsonProperty(value = "maxStorageMB")
+ private Integer maxStorageMB;
+
+ /*
+ * Max storage allowed for a server.
+ */
+ @JsonProperty(value = "minLargeStorageMB")
+ private Integer minLargeStorageMB;
+
+ /*
+ * Max storage allowed for a server.
+ */
+ @JsonProperty(value = "maxLargeStorageMB")
+ private Integer maxLargeStorageMB;
+
+ /*
+ * Max storage allowed for a server.
+ */
+ @JsonProperty(value = "minStorageMB")
+ private Integer minStorageMB;
+
+ /*
+ * Service level objectives associated with the performance tier
+ */
+ @JsonProperty(value = "serviceLevelObjectives")
+ private List serviceLevelObjectives;
+
+ /** Creates an instance of PerformanceTierPropertiesInner class. */
+ public PerformanceTierPropertiesInner() {
+ }
+
+ /**
+ * Get the id property: ID of the performance tier.
+ *
+ * @return the id value.
+ */
+ public String id() {
+ return this.id;
+ }
+
+ /**
+ * Set the id property: ID of the performance tier.
+ *
+ * @param id the id value to set.
+ * @return the PerformanceTierPropertiesInner object itself.
+ */
+ public PerformanceTierPropertiesInner withId(String id) {
+ this.id = id;
+ return this;
+ }
+
+ /**
+ * Get the maxBackupRetentionDays property: Maximum Backup retention in days for the performance tier edition.
+ *
+ * @return the maxBackupRetentionDays value.
+ */
+ public Integer maxBackupRetentionDays() {
+ return this.maxBackupRetentionDays;
+ }
+
+ /**
+ * Set the maxBackupRetentionDays property: Maximum Backup retention in days for the performance tier edition.
+ *
+ * @param maxBackupRetentionDays the maxBackupRetentionDays value to set.
+ * @return the PerformanceTierPropertiesInner object itself.
+ */
+ public PerformanceTierPropertiesInner withMaxBackupRetentionDays(Integer maxBackupRetentionDays) {
+ this.maxBackupRetentionDays = maxBackupRetentionDays;
+ return this;
+ }
+
+ /**
+ * Get the minBackupRetentionDays property: Minimum Backup retention in days for the performance tier edition.
+ *
+ * @return the minBackupRetentionDays value.
+ */
+ public Integer minBackupRetentionDays() {
+ return this.minBackupRetentionDays;
+ }
+
+ /**
+ * Set the minBackupRetentionDays property: Minimum Backup retention in days for the performance tier edition.
+ *
+ * @param minBackupRetentionDays the minBackupRetentionDays value to set.
+ * @return the PerformanceTierPropertiesInner object itself.
+ */
+ public PerformanceTierPropertiesInner withMinBackupRetentionDays(Integer minBackupRetentionDays) {
+ this.minBackupRetentionDays = minBackupRetentionDays;
+ return this;
+ }
+
+ /**
+ * Get the maxStorageMB property: Max storage allowed for a server.
+ *
+ * @return the maxStorageMB value.
+ */
+ public Integer maxStorageMB() {
+ return this.maxStorageMB;
+ }
+
+ /**
+ * Set the maxStorageMB property: Max storage allowed for a server.
+ *
+ * @param maxStorageMB the maxStorageMB value to set.
+ * @return the PerformanceTierPropertiesInner object itself.
+ */
+ public PerformanceTierPropertiesInner withMaxStorageMB(Integer maxStorageMB) {
+ this.maxStorageMB = maxStorageMB;
+ return this;
+ }
+
+ /**
+ * Get the minLargeStorageMB property: Max storage allowed for a server.
+ *
+ * @return the minLargeStorageMB value.
+ */
+ public Integer minLargeStorageMB() {
+ return this.minLargeStorageMB;
+ }
+
+ /**
+ * Set the minLargeStorageMB property: Max storage allowed for a server.
+ *
+ * @param minLargeStorageMB the minLargeStorageMB value to set.
+ * @return the PerformanceTierPropertiesInner object itself.
+ */
+ public PerformanceTierPropertiesInner withMinLargeStorageMB(Integer minLargeStorageMB) {
+ this.minLargeStorageMB = minLargeStorageMB;
+ return this;
+ }
+
+ /**
+ * Get the maxLargeStorageMB property: Max storage allowed for a server.
+ *
+ * @return the maxLargeStorageMB value.
+ */
+ public Integer maxLargeStorageMB() {
+ return this.maxLargeStorageMB;
+ }
+
+ /**
+ * Set the maxLargeStorageMB property: Max storage allowed for a server.
+ *
+ * @param maxLargeStorageMB the maxLargeStorageMB value to set.
+ * @return the PerformanceTierPropertiesInner object itself.
+ */
+ public PerformanceTierPropertiesInner withMaxLargeStorageMB(Integer maxLargeStorageMB) {
+ this.maxLargeStorageMB = maxLargeStorageMB;
+ return this;
+ }
+
+ /**
+ * Get the minStorageMB property: Max storage allowed for a server.
+ *
+ * @return the minStorageMB value.
+ */
+ public Integer minStorageMB() {
+ return this.minStorageMB;
+ }
+
+ /**
+ * Set the minStorageMB property: Max storage allowed for a server.
+ *
+ * @param minStorageMB the minStorageMB value to set.
+ * @return the PerformanceTierPropertiesInner object itself.
+ */
+ public PerformanceTierPropertiesInner withMinStorageMB(Integer minStorageMB) {
+ this.minStorageMB = minStorageMB;
+ return this;
+ }
+
+ /**
+ * Get the serviceLevelObjectives property: Service level objectives associated with the performance tier.
+ *
+ * @return the serviceLevelObjectives value.
+ */
+ public List serviceLevelObjectives() {
+ return this.serviceLevelObjectives;
+ }
+
+ /**
+ * Set the serviceLevelObjectives property: Service level objectives associated with the performance tier.
+ *
+ * @param serviceLevelObjectives the serviceLevelObjectives value to set.
+ * @return the PerformanceTierPropertiesInner object itself.
+ */
+ public PerformanceTierPropertiesInner withServiceLevelObjectives(
+ List serviceLevelObjectives) {
+ this.serviceLevelObjectives = serviceLevelObjectives;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (serviceLevelObjectives() != null) {
+ serviceLevelObjectives().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/PrivateEndpointConnectionInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/PrivateEndpointConnectionInner.java
new file mode 100644
index 0000000000000..bd5bf4143147d
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/PrivateEndpointConnectionInner.java
@@ -0,0 +1,101 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.management.ProxyResource;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.PrivateEndpointProperty;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.PrivateLinkServiceConnectionStateProperty;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** A private endpoint connection. */
+@Fluent
+public final class PrivateEndpointConnectionInner extends ProxyResource {
+ /*
+ * Resource properties.
+ */
+ @JsonProperty(value = "properties")
+ private PrivateEndpointConnectionProperties innerProperties;
+
+ /** Creates an instance of PrivateEndpointConnectionInner class. */
+ public PrivateEndpointConnectionInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Resource properties.
+ *
+ * @return the innerProperties value.
+ */
+ private PrivateEndpointConnectionProperties innerProperties() {
+ return this.innerProperties;
+ }
+
+ /**
+ * Get the privateEndpoint property: Private endpoint which the connection belongs to.
+ *
+ * @return the privateEndpoint value.
+ */
+ public PrivateEndpointProperty privateEndpoint() {
+ return this.innerProperties() == null ? null : this.innerProperties().privateEndpoint();
+ }
+
+ /**
+ * Set the privateEndpoint property: Private endpoint which the connection belongs to.
+ *
+ * @param privateEndpoint the privateEndpoint value to set.
+ * @return the PrivateEndpointConnectionInner object itself.
+ */
+ public PrivateEndpointConnectionInner withPrivateEndpoint(PrivateEndpointProperty privateEndpoint) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new PrivateEndpointConnectionProperties();
+ }
+ this.innerProperties().withPrivateEndpoint(privateEndpoint);
+ return this;
+ }
+
+ /**
+ * Get the privateLinkServiceConnectionState property: Connection state of the private endpoint connection.
+ *
+ * @return the privateLinkServiceConnectionState value.
+ */
+ public PrivateLinkServiceConnectionStateProperty privateLinkServiceConnectionState() {
+ return this.innerProperties() == null ? null : this.innerProperties().privateLinkServiceConnectionState();
+ }
+
+ /**
+ * Set the privateLinkServiceConnectionState property: Connection state of the private endpoint connection.
+ *
+ * @param privateLinkServiceConnectionState the privateLinkServiceConnectionState value to set.
+ * @return the PrivateEndpointConnectionInner object itself.
+ */
+ public PrivateEndpointConnectionInner withPrivateLinkServiceConnectionState(
+ PrivateLinkServiceConnectionStateProperty privateLinkServiceConnectionState) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new PrivateEndpointConnectionProperties();
+ }
+ this.innerProperties().withPrivateLinkServiceConnectionState(privateLinkServiceConnectionState);
+ return this;
+ }
+
+ /**
+ * Get the provisioningState property: State of the private endpoint connection.
+ *
+ * @return the provisioningState value.
+ */
+ public String provisioningState() {
+ return this.innerProperties() == null ? null : this.innerProperties().provisioningState();
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/PrivateEndpointConnectionProperties.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/PrivateEndpointConnectionProperties.java
new file mode 100644
index 0000000000000..795eee89609d8
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/PrivateEndpointConnectionProperties.java
@@ -0,0 +1,100 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.PrivateEndpointProperty;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.PrivateLinkServiceConnectionStateProperty;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** Properties of a private endpoint connection. */
+@Fluent
+public final class PrivateEndpointConnectionProperties {
+ /*
+ * Private endpoint which the connection belongs to.
+ */
+ @JsonProperty(value = "privateEndpoint")
+ private PrivateEndpointProperty privateEndpoint;
+
+ /*
+ * Connection state of the private endpoint connection.
+ */
+ @JsonProperty(value = "privateLinkServiceConnectionState")
+ private PrivateLinkServiceConnectionStateProperty privateLinkServiceConnectionState;
+
+ /*
+ * State of the private endpoint connection.
+ */
+ @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY)
+ private String provisioningState;
+
+ /** Creates an instance of PrivateEndpointConnectionProperties class. */
+ public PrivateEndpointConnectionProperties() {
+ }
+
+ /**
+ * Get the privateEndpoint property: Private endpoint which the connection belongs to.
+ *
+ * @return the privateEndpoint value.
+ */
+ public PrivateEndpointProperty privateEndpoint() {
+ return this.privateEndpoint;
+ }
+
+ /**
+ * Set the privateEndpoint property: Private endpoint which the connection belongs to.
+ *
+ * @param privateEndpoint the privateEndpoint value to set.
+ * @return the PrivateEndpointConnectionProperties object itself.
+ */
+ public PrivateEndpointConnectionProperties withPrivateEndpoint(PrivateEndpointProperty privateEndpoint) {
+ this.privateEndpoint = privateEndpoint;
+ return this;
+ }
+
+ /**
+ * Get the privateLinkServiceConnectionState property: Connection state of the private endpoint connection.
+ *
+ * @return the privateLinkServiceConnectionState value.
+ */
+ public PrivateLinkServiceConnectionStateProperty privateLinkServiceConnectionState() {
+ return this.privateLinkServiceConnectionState;
+ }
+
+ /**
+ * Set the privateLinkServiceConnectionState property: Connection state of the private endpoint connection.
+ *
+ * @param privateLinkServiceConnectionState the privateLinkServiceConnectionState value to set.
+ * @return the PrivateEndpointConnectionProperties object itself.
+ */
+ public PrivateEndpointConnectionProperties withPrivateLinkServiceConnectionState(
+ PrivateLinkServiceConnectionStateProperty privateLinkServiceConnectionState) {
+ this.privateLinkServiceConnectionState = privateLinkServiceConnectionState;
+ return this;
+ }
+
+ /**
+ * Get the provisioningState property: State of the private endpoint connection.
+ *
+ * @return the provisioningState value.
+ */
+ public String provisioningState() {
+ return this.provisioningState;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (privateEndpoint() != null) {
+ privateEndpoint().validate();
+ }
+ if (privateLinkServiceConnectionState() != null) {
+ privateLinkServiceConnectionState().validate();
+ }
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/PrivateLinkResourceInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/PrivateLinkResourceInner.java
new file mode 100644
index 0000000000000..782817b04cf6a
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/PrivateLinkResourceInner.java
@@ -0,0 +1,44 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.management.ProxyResource;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.PrivateLinkResourceProperties;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** A private link resource. */
+@Immutable
+public final class PrivateLinkResourceInner extends ProxyResource {
+ /*
+ * The private link resource group id.
+ */
+ @JsonProperty(value = "properties", access = JsonProperty.Access.WRITE_ONLY)
+ private PrivateLinkResourceProperties properties;
+
+ /** Creates an instance of PrivateLinkResourceInner class. */
+ public PrivateLinkResourceInner() {
+ }
+
+ /**
+ * Get the properties property: The private link resource group id.
+ *
+ * @return the properties value.
+ */
+ public PrivateLinkResourceProperties properties() {
+ return this.properties;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (properties() != null) {
+ properties().validate();
+ }
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/RecoverableServerProperties.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/RecoverableServerProperties.java
new file mode 100644
index 0000000000000..4fd7aa7cb6368
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/RecoverableServerProperties.java
@@ -0,0 +1,114 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Immutable;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** The recoverable server's properties. */
+@Immutable
+public final class RecoverableServerProperties {
+ /*
+ * The last available backup date time.
+ */
+ @JsonProperty(value = "lastAvailableBackupDateTime", access = JsonProperty.Access.WRITE_ONLY)
+ private String lastAvailableBackupDateTime;
+
+ /*
+ * The service level objective
+ */
+ @JsonProperty(value = "serviceLevelObjective", access = JsonProperty.Access.WRITE_ONLY)
+ private String serviceLevelObjective;
+
+ /*
+ * Edition of the performance tier.
+ */
+ @JsonProperty(value = "edition", access = JsonProperty.Access.WRITE_ONLY)
+ private String edition;
+
+ /*
+ * vCore associated with the service level objective
+ */
+ @JsonProperty(value = "vCore", access = JsonProperty.Access.WRITE_ONLY)
+ private Integer vCore;
+
+ /*
+ * Hardware generation associated with the service level objective
+ */
+ @JsonProperty(value = "hardwareGeneration", access = JsonProperty.Access.WRITE_ONLY)
+ private String hardwareGeneration;
+
+ /*
+ * The PostgreSQL version
+ */
+ @JsonProperty(value = "version", access = JsonProperty.Access.WRITE_ONLY)
+ private String version;
+
+ /** Creates an instance of RecoverableServerProperties class. */
+ public RecoverableServerProperties() {
+ }
+
+ /**
+ * Get the lastAvailableBackupDateTime property: The last available backup date time.
+ *
+ * @return the lastAvailableBackupDateTime value.
+ */
+ public String lastAvailableBackupDateTime() {
+ return this.lastAvailableBackupDateTime;
+ }
+
+ /**
+ * Get the serviceLevelObjective property: The service level objective.
+ *
+ * @return the serviceLevelObjective value.
+ */
+ public String serviceLevelObjective() {
+ return this.serviceLevelObjective;
+ }
+
+ /**
+ * Get the edition property: Edition of the performance tier.
+ *
+ * @return the edition value.
+ */
+ public String edition() {
+ return this.edition;
+ }
+
+ /**
+ * Get the vCore property: vCore associated with the service level objective.
+ *
+ * @return the vCore value.
+ */
+ public Integer vCore() {
+ return this.vCore;
+ }
+
+ /**
+ * Get the hardwareGeneration property: Hardware generation associated with the service level objective.
+ *
+ * @return the hardwareGeneration value.
+ */
+ public String hardwareGeneration() {
+ return this.hardwareGeneration;
+ }
+
+ /**
+ * Get the version property: The PostgreSQL version.
+ *
+ * @return the version value.
+ */
+ public String version() {
+ return this.version;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/RecoverableServerResourceInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/RecoverableServerResourceInner.java
new file mode 100644
index 0000000000000..b13e7362f9e8f
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/RecoverableServerResourceInner.java
@@ -0,0 +1,97 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.management.ProxyResource;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** A recoverable server resource. */
+@Immutable
+public final class RecoverableServerResourceInner extends ProxyResource {
+ /*
+ * Resource properties.
+ */
+ @JsonProperty(value = "properties")
+ private RecoverableServerProperties innerProperties;
+
+ /** Creates an instance of RecoverableServerResourceInner class. */
+ public RecoverableServerResourceInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Resource properties.
+ *
+ * @return the innerProperties value.
+ */
+ private RecoverableServerProperties innerProperties() {
+ return this.innerProperties;
+ }
+
+ /**
+ * Get the lastAvailableBackupDateTime property: The last available backup date time.
+ *
+ * @return the lastAvailableBackupDateTime value.
+ */
+ public String lastAvailableBackupDateTime() {
+ return this.innerProperties() == null ? null : this.innerProperties().lastAvailableBackupDateTime();
+ }
+
+ /**
+ * Get the serviceLevelObjective property: The service level objective.
+ *
+ * @return the serviceLevelObjective value.
+ */
+ public String serviceLevelObjective() {
+ return this.innerProperties() == null ? null : this.innerProperties().serviceLevelObjective();
+ }
+
+ /**
+ * Get the edition property: Edition of the performance tier.
+ *
+ * @return the edition value.
+ */
+ public String edition() {
+ return this.innerProperties() == null ? null : this.innerProperties().edition();
+ }
+
+ /**
+ * Get the vCore property: vCore associated with the service level objective.
+ *
+ * @return the vCore value.
+ */
+ public Integer vCore() {
+ return this.innerProperties() == null ? null : this.innerProperties().vCore();
+ }
+
+ /**
+ * Get the hardwareGeneration property: Hardware generation associated with the service level objective.
+ *
+ * @return the hardwareGeneration value.
+ */
+ public String hardwareGeneration() {
+ return this.innerProperties() == null ? null : this.innerProperties().hardwareGeneration();
+ }
+
+ /**
+ * Get the version property: The PostgreSQL version.
+ *
+ * @return the version value.
+ */
+ public String version() {
+ return this.innerProperties() == null ? null : this.innerProperties().version();
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/SecurityAlertPolicyProperties.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/SecurityAlertPolicyProperties.java
new file mode 100644
index 0000000000000..e17e7664eeb74
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/SecurityAlertPolicyProperties.java
@@ -0,0 +1,225 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerSecurityAlertPolicyState;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** Properties of a security alert policy. */
+@Fluent
+public final class SecurityAlertPolicyProperties {
+ /*
+ * Specifies the state of the policy, whether it is enabled or disabled.
+ */
+ @JsonProperty(value = "state", required = true)
+ private ServerSecurityAlertPolicyState state;
+
+ /*
+ * Specifies an array of alerts that are disabled. Allowed values are: Sql_Injection, Sql_Injection_Vulnerability,
+ * Access_Anomaly
+ */
+ @JsonProperty(value = "disabledAlerts")
+ private List disabledAlerts;
+
+ /*
+ * Specifies an array of e-mail addresses to which the alert is sent.
+ */
+ @JsonProperty(value = "emailAddresses")
+ private List emailAddresses;
+
+ /*
+ * Specifies that the alert is sent to the account administrators.
+ */
+ @JsonProperty(value = "emailAccountAdmins")
+ private Boolean emailAccountAdmins;
+
+ /*
+ * Specifies the blob storage endpoint (e.g. https://MyAccount.blob.core.windows.net). This blob storage will hold
+ * all Threat Detection audit logs.
+ */
+ @JsonProperty(value = "storageEndpoint")
+ private String storageEndpoint;
+
+ /*
+ * Specifies the identifier key of the Threat Detection audit storage account.
+ */
+ @JsonProperty(value = "storageAccountAccessKey")
+ private String storageAccountAccessKey;
+
+ /*
+ * Specifies the number of days to keep in the Threat Detection audit logs.
+ */
+ @JsonProperty(value = "retentionDays")
+ private Integer retentionDays;
+
+ /** Creates an instance of SecurityAlertPolicyProperties class. */
+ public SecurityAlertPolicyProperties() {
+ }
+
+ /**
+ * Get the state property: Specifies the state of the policy, whether it is enabled or disabled.
+ *
+ * @return the state value.
+ */
+ public ServerSecurityAlertPolicyState state() {
+ return this.state;
+ }
+
+ /**
+ * Set the state property: Specifies the state of the policy, whether it is enabled or disabled.
+ *
+ * @param state the state value to set.
+ * @return the SecurityAlertPolicyProperties object itself.
+ */
+ public SecurityAlertPolicyProperties withState(ServerSecurityAlertPolicyState state) {
+ this.state = state;
+ return this;
+ }
+
+ /**
+ * Get the disabledAlerts property: Specifies an array of alerts that are disabled. Allowed values are:
+ * Sql_Injection, Sql_Injection_Vulnerability, Access_Anomaly.
+ *
+ * @return the disabledAlerts value.
+ */
+ public List disabledAlerts() {
+ return this.disabledAlerts;
+ }
+
+ /**
+ * Set the disabledAlerts property: Specifies an array of alerts that are disabled. Allowed values are:
+ * Sql_Injection, Sql_Injection_Vulnerability, Access_Anomaly.
+ *
+ * @param disabledAlerts the disabledAlerts value to set.
+ * @return the SecurityAlertPolicyProperties object itself.
+ */
+ public SecurityAlertPolicyProperties withDisabledAlerts(List disabledAlerts) {
+ this.disabledAlerts = disabledAlerts;
+ return this;
+ }
+
+ /**
+ * Get the emailAddresses property: Specifies an array of e-mail addresses to which the alert is sent.
+ *
+ * @return the emailAddresses value.
+ */
+ public List emailAddresses() {
+ return this.emailAddresses;
+ }
+
+ /**
+ * Set the emailAddresses property: Specifies an array of e-mail addresses to which the alert is sent.
+ *
+ * @param emailAddresses the emailAddresses value to set.
+ * @return the SecurityAlertPolicyProperties object itself.
+ */
+ public SecurityAlertPolicyProperties withEmailAddresses(List emailAddresses) {
+ this.emailAddresses = emailAddresses;
+ return this;
+ }
+
+ /**
+ * Get the emailAccountAdmins property: Specifies that the alert is sent to the account administrators.
+ *
+ * @return the emailAccountAdmins value.
+ */
+ public Boolean emailAccountAdmins() {
+ return this.emailAccountAdmins;
+ }
+
+ /**
+ * Set the emailAccountAdmins property: Specifies that the alert is sent to the account administrators.
+ *
+ * @param emailAccountAdmins the emailAccountAdmins value to set.
+ * @return the SecurityAlertPolicyProperties object itself.
+ */
+ public SecurityAlertPolicyProperties withEmailAccountAdmins(Boolean emailAccountAdmins) {
+ this.emailAccountAdmins = emailAccountAdmins;
+ return this;
+ }
+
+ /**
+ * Get the storageEndpoint property: Specifies the blob storage endpoint (e.g.
+ * https://MyAccount.blob.core.windows.net). This blob storage will hold all Threat Detection audit logs.
+ *
+ * @return the storageEndpoint value.
+ */
+ public String storageEndpoint() {
+ return this.storageEndpoint;
+ }
+
+ /**
+ * Set the storageEndpoint property: Specifies the blob storage endpoint (e.g.
+ * https://MyAccount.blob.core.windows.net). This blob storage will hold all Threat Detection audit logs.
+ *
+ * @param storageEndpoint the storageEndpoint value to set.
+ * @return the SecurityAlertPolicyProperties object itself.
+ */
+ public SecurityAlertPolicyProperties withStorageEndpoint(String storageEndpoint) {
+ this.storageEndpoint = storageEndpoint;
+ return this;
+ }
+
+ /**
+ * Get the storageAccountAccessKey property: Specifies the identifier key of the Threat Detection audit storage
+ * account.
+ *
+ * @return the storageAccountAccessKey value.
+ */
+ public String storageAccountAccessKey() {
+ return this.storageAccountAccessKey;
+ }
+
+ /**
+ * Set the storageAccountAccessKey property: Specifies the identifier key of the Threat Detection audit storage
+ * account.
+ *
+ * @param storageAccountAccessKey the storageAccountAccessKey value to set.
+ * @return the SecurityAlertPolicyProperties object itself.
+ */
+ public SecurityAlertPolicyProperties withStorageAccountAccessKey(String storageAccountAccessKey) {
+ this.storageAccountAccessKey = storageAccountAccessKey;
+ return this;
+ }
+
+ /**
+ * Get the retentionDays property: Specifies the number of days to keep in the Threat Detection audit logs.
+ *
+ * @return the retentionDays value.
+ */
+ public Integer retentionDays() {
+ return this.retentionDays;
+ }
+
+ /**
+ * Set the retentionDays property: Specifies the number of days to keep in the Threat Detection audit logs.
+ *
+ * @param retentionDays the retentionDays value to set.
+ * @return the SecurityAlertPolicyProperties object itself.
+ */
+ public SecurityAlertPolicyProperties withRetentionDays(Integer retentionDays) {
+ this.retentionDays = retentionDays;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (state() == null) {
+ throw LOGGER
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ "Missing required property state in model SecurityAlertPolicyProperties"));
+ }
+ }
+
+ private static final ClientLogger LOGGER = new ClientLogger(SecurityAlertPolicyProperties.class);
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerAdministratorProperties.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerAdministratorProperties.java
new file mode 100644
index 0000000000000..15c0ff72c97f9
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerAdministratorProperties.java
@@ -0,0 +1,157 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.AdministratorType;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.UUID;
+
+/** The properties of an server Administrator. */
+@Fluent
+public final class ServerAdministratorProperties {
+ /*
+ * The type of administrator.
+ */
+ @JsonProperty(value = "administratorType", required = true)
+ private AdministratorType administratorType;
+
+ /*
+ * The server administrator login account name.
+ */
+ @JsonProperty(value = "login", required = true)
+ private String login;
+
+ /*
+ * The server administrator Sid (Secure ID).
+ */
+ @JsonProperty(value = "sid", required = true)
+ private UUID sid;
+
+ /*
+ * The server Active Directory Administrator tenant id.
+ */
+ @JsonProperty(value = "tenantId", required = true)
+ private UUID tenantId;
+
+ /** Creates an instance of ServerAdministratorProperties class. */
+ public ServerAdministratorProperties() {
+ }
+
+ /**
+ * Get the administratorType property: The type of administrator.
+ *
+ * @return the administratorType value.
+ */
+ public AdministratorType administratorType() {
+ return this.administratorType;
+ }
+
+ /**
+ * Set the administratorType property: The type of administrator.
+ *
+ * @param administratorType the administratorType value to set.
+ * @return the ServerAdministratorProperties object itself.
+ */
+ public ServerAdministratorProperties withAdministratorType(AdministratorType administratorType) {
+ this.administratorType = administratorType;
+ return this;
+ }
+
+ /**
+ * Get the login property: The server administrator login account name.
+ *
+ * @return the login value.
+ */
+ public String login() {
+ return this.login;
+ }
+
+ /**
+ * Set the login property: The server administrator login account name.
+ *
+ * @param login the login value to set.
+ * @return the ServerAdministratorProperties object itself.
+ */
+ public ServerAdministratorProperties withLogin(String login) {
+ this.login = login;
+ return this;
+ }
+
+ /**
+ * Get the sid property: The server administrator Sid (Secure ID).
+ *
+ * @return the sid value.
+ */
+ public UUID sid() {
+ return this.sid;
+ }
+
+ /**
+ * Set the sid property: The server administrator Sid (Secure ID).
+ *
+ * @param sid the sid value to set.
+ * @return the ServerAdministratorProperties object itself.
+ */
+ public ServerAdministratorProperties withSid(UUID sid) {
+ this.sid = sid;
+ return this;
+ }
+
+ /**
+ * Get the tenantId property: The server Active Directory Administrator tenant id.
+ *
+ * @return the tenantId value.
+ */
+ public UUID tenantId() {
+ return this.tenantId;
+ }
+
+ /**
+ * Set the tenantId property: The server Active Directory Administrator tenant id.
+ *
+ * @param tenantId the tenantId value to set.
+ * @return the ServerAdministratorProperties object itself.
+ */
+ public ServerAdministratorProperties withTenantId(UUID tenantId) {
+ this.tenantId = tenantId;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (administratorType() == null) {
+ throw LOGGER
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ "Missing required property administratorType in model ServerAdministratorProperties"));
+ }
+ if (login() == null) {
+ throw LOGGER
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ "Missing required property login in model ServerAdministratorProperties"));
+ }
+ if (sid() == null) {
+ throw LOGGER
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ "Missing required property sid in model ServerAdministratorProperties"));
+ }
+ if (tenantId() == null) {
+ throw LOGGER
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ "Missing required property tenantId in model ServerAdministratorProperties"));
+ }
+ }
+
+ private static final ClientLogger LOGGER = new ClientLogger(ServerAdministratorProperties.class);
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerAdministratorResourceInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerAdministratorResourceInner.java
new file mode 100644
index 0000000000000..b662cd971ae5e
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerAdministratorResourceInner.java
@@ -0,0 +1,137 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.management.ProxyResource;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.AdministratorType;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.UUID;
+
+/** Represents a and external administrator to be created. */
+@Fluent
+public final class ServerAdministratorResourceInner extends ProxyResource {
+ /*
+ * Properties of the server AAD administrator.
+ */
+ @JsonProperty(value = "properties")
+ private ServerAdministratorProperties innerProperties;
+
+ /** Creates an instance of ServerAdministratorResourceInner class. */
+ public ServerAdministratorResourceInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Properties of the server AAD administrator.
+ *
+ * @return the innerProperties value.
+ */
+ private ServerAdministratorProperties innerProperties() {
+ return this.innerProperties;
+ }
+
+ /**
+ * Get the administratorType property: The type of administrator.
+ *
+ * @return the administratorType value.
+ */
+ public AdministratorType administratorType() {
+ return this.innerProperties() == null ? null : this.innerProperties().administratorType();
+ }
+
+ /**
+ * Set the administratorType property: The type of administrator.
+ *
+ * @param administratorType the administratorType value to set.
+ * @return the ServerAdministratorResourceInner object itself.
+ */
+ public ServerAdministratorResourceInner withAdministratorType(AdministratorType administratorType) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ServerAdministratorProperties();
+ }
+ this.innerProperties().withAdministratorType(administratorType);
+ return this;
+ }
+
+ /**
+ * Get the login property: The server administrator login account name.
+ *
+ * @return the login value.
+ */
+ public String login() {
+ return this.innerProperties() == null ? null : this.innerProperties().login();
+ }
+
+ /**
+ * Set the login property: The server administrator login account name.
+ *
+ * @param login the login value to set.
+ * @return the ServerAdministratorResourceInner object itself.
+ */
+ public ServerAdministratorResourceInner withLogin(String login) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ServerAdministratorProperties();
+ }
+ this.innerProperties().withLogin(login);
+ return this;
+ }
+
+ /**
+ * Get the sid property: The server administrator Sid (Secure ID).
+ *
+ * @return the sid value.
+ */
+ public UUID sid() {
+ return this.innerProperties() == null ? null : this.innerProperties().sid();
+ }
+
+ /**
+ * Set the sid property: The server administrator Sid (Secure ID).
+ *
+ * @param sid the sid value to set.
+ * @return the ServerAdministratorResourceInner object itself.
+ */
+ public ServerAdministratorResourceInner withSid(UUID sid) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ServerAdministratorProperties();
+ }
+ this.innerProperties().withSid(sid);
+ return this;
+ }
+
+ /**
+ * Get the tenantId property: The server Active Directory Administrator tenant id.
+ *
+ * @return the tenantId value.
+ */
+ public UUID tenantId() {
+ return this.innerProperties() == null ? null : this.innerProperties().tenantId();
+ }
+
+ /**
+ * Set the tenantId property: The server Active Directory Administrator tenant id.
+ *
+ * @param tenantId the tenantId value to set.
+ * @return the ServerAdministratorResourceInner object itself.
+ */
+ public ServerAdministratorResourceInner withTenantId(UUID tenantId) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ServerAdministratorProperties();
+ }
+ this.innerProperties().withTenantId(tenantId);
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerBackupInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerBackupInner.java
deleted file mode 100644
index 8f49fa0b5af12..0000000000000
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerBackupInner.java
+++ /dev/null
@@ -1,130 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.management.SystemData;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.Origin;
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.time.OffsetDateTime;
-
-/** Server backup properties. */
-@Fluent
-public final class ServerBackupInner extends ProxyResource {
- /*
- * The properties of a server backup.
- */
- @JsonProperty(value = "properties")
- private ServerBackupProperties innerProperties;
-
- /*
- * Azure Resource Manager metadata containing createdBy and modifiedBy information.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
- /** Creates an instance of ServerBackupInner class. */
- public ServerBackupInner() {
- }
-
- /**
- * Get the innerProperties property: The properties of a server backup.
- *
- * @return the innerProperties value.
- */
- private ServerBackupProperties innerProperties() {
- return this.innerProperties;
- }
-
- /**
- * Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- public SystemData systemData() {
- return this.systemData;
- }
-
- /**
- * Get the backupType property: Backup type.
- *
- * @return the backupType value.
- */
- public Origin backupType() {
- return this.innerProperties() == null ? null : this.innerProperties().backupType();
- }
-
- /**
- * Set the backupType property: Backup type.
- *
- * @param backupType the backupType value to set.
- * @return the ServerBackupInner object itself.
- */
- public ServerBackupInner withBackupType(Origin backupType) {
- if (this.innerProperties() == null) {
- this.innerProperties = new ServerBackupProperties();
- }
- this.innerProperties().withBackupType(backupType);
- return this;
- }
-
- /**
- * Get the completedTime property: Backup completed time (ISO8601 format).
- *
- * @return the completedTime value.
- */
- public OffsetDateTime completedTime() {
- return this.innerProperties() == null ? null : this.innerProperties().completedTime();
- }
-
- /**
- * Set the completedTime property: Backup completed time (ISO8601 format).
- *
- * @param completedTime the completedTime value to set.
- * @return the ServerBackupInner object itself.
- */
- public ServerBackupInner withCompletedTime(OffsetDateTime completedTime) {
- if (this.innerProperties() == null) {
- this.innerProperties = new ServerBackupProperties();
- }
- this.innerProperties().withCompletedTime(completedTime);
- return this;
- }
-
- /**
- * Get the source property: Backup source.
- *
- * @return the source value.
- */
- public String source() {
- return this.innerProperties() == null ? null : this.innerProperties().source();
- }
-
- /**
- * Set the source property: Backup source.
- *
- * @param source the source value to set.
- * @return the ServerBackupInner object itself.
- */
- public ServerBackupInner withSource(String source) {
- if (this.innerProperties() == null) {
- this.innerProperties = new ServerBackupProperties();
- }
- this.innerProperties().withSource(source);
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (innerProperties() != null) {
- innerProperties().validate();
- }
- }
-}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerBackupProperties.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerBackupProperties.java
deleted file mode 100644
index 46fc68988eb7d..0000000000000
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerBackupProperties.java
+++ /dev/null
@@ -1,104 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.Origin;
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.time.OffsetDateTime;
-
-/** The properties of a server backup. */
-@Fluent
-public final class ServerBackupProperties {
- /*
- * Backup type.
- */
- @JsonProperty(value = "backupType")
- private Origin backupType;
-
- /*
- * Backup completed time (ISO8601 format).
- */
- @JsonProperty(value = "completedTime")
- private OffsetDateTime completedTime;
-
- /*
- * Backup source
- */
- @JsonProperty(value = "source")
- private String source;
-
- /** Creates an instance of ServerBackupProperties class. */
- public ServerBackupProperties() {
- }
-
- /**
- * Get the backupType property: Backup type.
- *
- * @return the backupType value.
- */
- public Origin backupType() {
- return this.backupType;
- }
-
- /**
- * Set the backupType property: Backup type.
- *
- * @param backupType the backupType value to set.
- * @return the ServerBackupProperties object itself.
- */
- public ServerBackupProperties withBackupType(Origin backupType) {
- this.backupType = backupType;
- return this;
- }
-
- /**
- * Get the completedTime property: Backup completed time (ISO8601 format).
- *
- * @return the completedTime value.
- */
- public OffsetDateTime completedTime() {
- return this.completedTime;
- }
-
- /**
- * Set the completedTime property: Backup completed time (ISO8601 format).
- *
- * @param completedTime the completedTime value to set.
- * @return the ServerBackupProperties object itself.
- */
- public ServerBackupProperties withCompletedTime(OffsetDateTime completedTime) {
- this.completedTime = completedTime;
- return this;
- }
-
- /**
- * Get the source property: Backup source.
- *
- * @return the source value.
- */
- public String source() {
- return this.source;
- }
-
- /**
- * Set the source property: Backup source.
- *
- * @param source the source value to set.
- * @return the ServerBackupProperties object itself.
- */
- public ServerBackupProperties withSource(String source) {
- this.source = source;
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerInner.java
index 3fc6de6cf5bdf..a25d550ad2683 100644
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerInner.java
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerInner.java
@@ -6,38 +6,35 @@
import com.azure.core.annotation.Fluent;
import com.azure.core.management.Resource;
-import com.azure.core.management.SystemData;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.AuthConfig;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.Backup;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.CreateMode;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.DataEncryption;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.HighAvailability;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.MaintenanceWindow;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.Network;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.ReplicationRole;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.InfrastructureEncryption;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.MinimalTlsVersionEnum;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.PublicNetworkAccessEnum;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.ResourceIdentity;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerPrivateEndpointConnection;
import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerState;
import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerVersion;
import com.azure.resourcemanager.postgresqlflexibleserver.models.Sku;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.Storage;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.UserAssignedIdentity;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.SslEnforcementEnum;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.StorageProfile;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.time.OffsetDateTime;
+import java.util.List;
import java.util.Map;
/** Represents a server. */
@Fluent
public final class ServerInner extends Resource {
/*
- * The SKU (pricing tier) of the server.
+ * The Azure Active Directory identity of the server.
*/
- @JsonProperty(value = "sku")
- private Sku sku;
+ @JsonProperty(value = "identity")
+ private ResourceIdentity identity;
/*
- * Describes the identity of the application.
+ * The SKU (pricing tier) of the server.
*/
- @JsonProperty(value = "identity")
- private UserAssignedIdentity identity;
+ @JsonProperty(value = "sku")
+ private Sku sku;
/*
* Properties of the server.
@@ -45,53 +42,47 @@ public final class ServerInner extends Resource {
@JsonProperty(value = "properties")
private ServerProperties innerProperties;
- /*
- * Azure Resource Manager metadata containing createdBy and modifiedBy information.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
/** Creates an instance of ServerInner class. */
public ServerInner() {
}
/**
- * Get the sku property: The SKU (pricing tier) of the server.
+ * Get the identity property: The Azure Active Directory identity of the server.
*
- * @return the sku value.
+ * @return the identity value.
*/
- public Sku sku() {
- return this.sku;
+ public ResourceIdentity identity() {
+ return this.identity;
}
/**
- * Set the sku property: The SKU (pricing tier) of the server.
+ * Set the identity property: The Azure Active Directory identity of the server.
*
- * @param sku the sku value to set.
+ * @param identity the identity value to set.
* @return the ServerInner object itself.
*/
- public ServerInner withSku(Sku sku) {
- this.sku = sku;
+ public ServerInner withIdentity(ResourceIdentity identity) {
+ this.identity = identity;
return this;
}
/**
- * Get the identity property: Describes the identity of the application.
+ * Get the sku property: The SKU (pricing tier) of the server.
*
- * @return the identity value.
+ * @return the sku value.
*/
- public UserAssignedIdentity identity() {
- return this.identity;
+ public Sku sku() {
+ return this.sku;
}
/**
- * Set the identity property: Describes the identity of the application.
+ * Set the sku property: The SKU (pricing tier) of the server.
*
- * @param identity the identity value to set.
+ * @param sku the sku value to set.
* @return the ServerInner object itself.
*/
- public ServerInner withIdentity(UserAssignedIdentity identity) {
- this.identity = identity;
+ public ServerInner withSku(Sku sku) {
+ this.sku = sku;
return this;
}
@@ -104,15 +95,6 @@ private ServerProperties innerProperties() {
return this.innerProperties;
}
- /**
- * Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- public SystemData systemData() {
- return this.systemData;
- }
-
/** {@inheritDoc} */
@Override
public ServerInner withLocation(String location) {
@@ -153,30 +135,7 @@ public ServerInner withAdministratorLogin(String administratorLogin) {
}
/**
- * Get the administratorLoginPassword property: The administrator login password (required for server creation).
- *
- * @return the administratorLoginPassword value.
- */
- public String administratorLoginPassword() {
- return this.innerProperties() == null ? null : this.innerProperties().administratorLoginPassword();
- }
-
- /**
- * Set the administratorLoginPassword property: The administrator login password (required for server creation).
- *
- * @param administratorLoginPassword the administratorLoginPassword value to set.
- * @return the ServerInner object itself.
- */
- public ServerInner withAdministratorLoginPassword(String administratorLoginPassword) {
- if (this.innerProperties() == null) {
- this.innerProperties = new ServerProperties();
- }
- this.innerProperties().withAdministratorLoginPassword(administratorLoginPassword);
- return this;
- }
-
- /**
- * Get the version property: PostgreSQL Server version.
+ * Get the version property: Server version.
*
* @return the version value.
*/
@@ -185,7 +144,7 @@ public ServerVersion version() {
}
/**
- * Set the version property: PostgreSQL Server version.
+ * Set the version property: Server version.
*
* @param version the version value to set.
* @return the ServerInner object itself.
@@ -199,291 +158,224 @@ public ServerInner withVersion(ServerVersion version) {
}
/**
- * Get the minorVersion property: The minor version of the server.
- *
- * @return the minorVersion value.
- */
- public String minorVersion() {
- return this.innerProperties() == null ? null : this.innerProperties().minorVersion();
- }
-
- /**
- * Get the state property: A state of a server that is visible to user.
- *
- * @return the state value.
- */
- public ServerState state() {
- return this.innerProperties() == null ? null : this.innerProperties().state();
- }
-
- /**
- * Get the fullyQualifiedDomainName property: The fully qualified domain name of a server.
- *
- * @return the fullyQualifiedDomainName value.
- */
- public String fullyQualifiedDomainName() {
- return this.innerProperties() == null ? null : this.innerProperties().fullyQualifiedDomainName();
- }
-
- /**
- * Get the storage property: Storage properties of a server.
- *
- * @return the storage value.
- */
- public Storage storage() {
- return this.innerProperties() == null ? null : this.innerProperties().storage();
- }
-
- /**
- * Set the storage property: Storage properties of a server.
- *
- * @param storage the storage value to set.
- * @return the ServerInner object itself.
- */
- public ServerInner withStorage(Storage storage) {
- if (this.innerProperties() == null) {
- this.innerProperties = new ServerProperties();
- }
- this.innerProperties().withStorage(storage);
- return this;
- }
-
- /**
- * Get the authConfig property: AuthConfig properties of a server.
+ * Get the sslEnforcement property: Enable ssl enforcement or not when connect to server.
*
- * @return the authConfig value.
+ * @return the sslEnforcement value.
*/
- public AuthConfig authConfig() {
- return this.innerProperties() == null ? null : this.innerProperties().authConfig();
+ public SslEnforcementEnum sslEnforcement() {
+ return this.innerProperties() == null ? null : this.innerProperties().sslEnforcement();
}
/**
- * Set the authConfig property: AuthConfig properties of a server.
+ * Set the sslEnforcement property: Enable ssl enforcement or not when connect to server.
*
- * @param authConfig the authConfig value to set.
+ * @param sslEnforcement the sslEnforcement value to set.
* @return the ServerInner object itself.
*/
- public ServerInner withAuthConfig(AuthConfig authConfig) {
+ public ServerInner withSslEnforcement(SslEnforcementEnum sslEnforcement) {
if (this.innerProperties() == null) {
this.innerProperties = new ServerProperties();
}
- this.innerProperties().withAuthConfig(authConfig);
+ this.innerProperties().withSslEnforcement(sslEnforcement);
return this;
}
/**
- * Get the dataEncryption property: Data encryption properties of a server.
+ * Get the minimalTlsVersion property: Enforce a minimal Tls version for the server.
*
- * @return the dataEncryption value.
+ * @return the minimalTlsVersion value.
*/
- public DataEncryption dataEncryption() {
- return this.innerProperties() == null ? null : this.innerProperties().dataEncryption();
+ public MinimalTlsVersionEnum minimalTlsVersion() {
+ return this.innerProperties() == null ? null : this.innerProperties().minimalTlsVersion();
}
/**
- * Set the dataEncryption property: Data encryption properties of a server.
+ * Set the minimalTlsVersion property: Enforce a minimal Tls version for the server.
*
- * @param dataEncryption the dataEncryption value to set.
+ * @param minimalTlsVersion the minimalTlsVersion value to set.
* @return the ServerInner object itself.
*/
- public ServerInner withDataEncryption(DataEncryption dataEncryption) {
+ public ServerInner withMinimalTlsVersion(MinimalTlsVersionEnum minimalTlsVersion) {
if (this.innerProperties() == null) {
this.innerProperties = new ServerProperties();
}
- this.innerProperties().withDataEncryption(dataEncryption);
+ this.innerProperties().withMinimalTlsVersion(minimalTlsVersion);
return this;
}
/**
- * Get the backup property: Backup properties of a server.
+ * Get the byokEnforcement property: Status showing whether the server data encryption is enabled with
+ * customer-managed keys.
*
- * @return the backup value.
+ * @return the byokEnforcement value.
*/
- public Backup backup() {
- return this.innerProperties() == null ? null : this.innerProperties().backup();
+ public String byokEnforcement() {
+ return this.innerProperties() == null ? null : this.innerProperties().byokEnforcement();
}
/**
- * Set the backup property: Backup properties of a server.
+ * Get the infrastructureEncryption property: Status showing whether the server enabled infrastructure encryption.
*
- * @param backup the backup value to set.
- * @return the ServerInner object itself.
+ * @return the infrastructureEncryption value.
*/
- public ServerInner withBackup(Backup backup) {
- if (this.innerProperties() == null) {
- this.innerProperties = new ServerProperties();
- }
- this.innerProperties().withBackup(backup);
- return this;
- }
-
- /**
- * Get the network property: Network properties of a server.
- *
- * @return the network value.
- */
- public Network network() {
- return this.innerProperties() == null ? null : this.innerProperties().network();
+ public InfrastructureEncryption infrastructureEncryption() {
+ return this.innerProperties() == null ? null : this.innerProperties().infrastructureEncryption();
}
/**
- * Set the network property: Network properties of a server.
+ * Set the infrastructureEncryption property: Status showing whether the server enabled infrastructure encryption.
*
- * @param network the network value to set.
+ * @param infrastructureEncryption the infrastructureEncryption value to set.
* @return the ServerInner object itself.
*/
- public ServerInner withNetwork(Network network) {
+ public ServerInner withInfrastructureEncryption(InfrastructureEncryption infrastructureEncryption) {
if (this.innerProperties() == null) {
this.innerProperties = new ServerProperties();
}
- this.innerProperties().withNetwork(network);
+ this.innerProperties().withInfrastructureEncryption(infrastructureEncryption);
return this;
}
/**
- * Get the highAvailability property: High availability properties of a server.
+ * Get the userVisibleState property: A state of a server that is visible to user.
*
- * @return the highAvailability value.
+ * @return the userVisibleState value.
*/
- public HighAvailability highAvailability() {
- return this.innerProperties() == null ? null : this.innerProperties().highAvailability();
+ public ServerState userVisibleState() {
+ return this.innerProperties() == null ? null : this.innerProperties().userVisibleState();
}
/**
- * Set the highAvailability property: High availability properties of a server.
+ * Set the userVisibleState property: A state of a server that is visible to user.
*
- * @param highAvailability the highAvailability value to set.
+ * @param userVisibleState the userVisibleState value to set.
* @return the ServerInner object itself.
*/
- public ServerInner withHighAvailability(HighAvailability highAvailability) {
+ public ServerInner withUserVisibleState(ServerState userVisibleState) {
if (this.innerProperties() == null) {
this.innerProperties = new ServerProperties();
}
- this.innerProperties().withHighAvailability(highAvailability);
+ this.innerProperties().withUserVisibleState(userVisibleState);
return this;
}
/**
- * Get the maintenanceWindow property: Maintenance window properties of a server.
+ * Get the fullyQualifiedDomainName property: The fully qualified domain name of a server.
*
- * @return the maintenanceWindow value.
+ * @return the fullyQualifiedDomainName value.
*/
- public MaintenanceWindow maintenanceWindow() {
- return this.innerProperties() == null ? null : this.innerProperties().maintenanceWindow();
+ public String fullyQualifiedDomainName() {
+ return this.innerProperties() == null ? null : this.innerProperties().fullyQualifiedDomainName();
}
/**
- * Set the maintenanceWindow property: Maintenance window properties of a server.
+ * Set the fullyQualifiedDomainName property: The fully qualified domain name of a server.
*
- * @param maintenanceWindow the maintenanceWindow value to set.
+ * @param fullyQualifiedDomainName the fullyQualifiedDomainName value to set.
* @return the ServerInner object itself.
*/
- public ServerInner withMaintenanceWindow(MaintenanceWindow maintenanceWindow) {
+ public ServerInner withFullyQualifiedDomainName(String fullyQualifiedDomainName) {
if (this.innerProperties() == null) {
this.innerProperties = new ServerProperties();
}
- this.innerProperties().withMaintenanceWindow(maintenanceWindow);
+ this.innerProperties().withFullyQualifiedDomainName(fullyQualifiedDomainName);
return this;
}
/**
- * Get the sourceServerResourceId property: The source server resource ID to restore from. It's required when
- * 'createMode' is 'PointInTimeRestore' or 'GeoRestore' or 'Replica'.
+ * Get the earliestRestoreDate property: Earliest restore point creation time (ISO8601 format).
*
- * @return the sourceServerResourceId value.
+ * @return the earliestRestoreDate value.
*/
- public String sourceServerResourceId() {
- return this.innerProperties() == null ? null : this.innerProperties().sourceServerResourceId();
+ public OffsetDateTime earliestRestoreDate() {
+ return this.innerProperties() == null ? null : this.innerProperties().earliestRestoreDate();
}
/**
- * Set the sourceServerResourceId property: The source server resource ID to restore from. It's required when
- * 'createMode' is 'PointInTimeRestore' or 'GeoRestore' or 'Replica'.
+ * Set the earliestRestoreDate property: Earliest restore point creation time (ISO8601 format).
*
- * @param sourceServerResourceId the sourceServerResourceId value to set.
+ * @param earliestRestoreDate the earliestRestoreDate value to set.
* @return the ServerInner object itself.
*/
- public ServerInner withSourceServerResourceId(String sourceServerResourceId) {
+ public ServerInner withEarliestRestoreDate(OffsetDateTime earliestRestoreDate) {
if (this.innerProperties() == null) {
this.innerProperties = new ServerProperties();
}
- this.innerProperties().withSourceServerResourceId(sourceServerResourceId);
+ this.innerProperties().withEarliestRestoreDate(earliestRestoreDate);
return this;
}
/**
- * Get the pointInTimeUtc property: Restore point creation time (ISO8601 format), specifying the time to restore
- * from. It's required when 'createMode' is 'PointInTimeRestore' or 'GeoRestore'.
+ * Get the storageProfile property: Storage profile of a server.
*
- * @return the pointInTimeUtc value.
+ * @return the storageProfile value.
*/
- public OffsetDateTime pointInTimeUtc() {
- return this.innerProperties() == null ? null : this.innerProperties().pointInTimeUtc();
+ public StorageProfile storageProfile() {
+ return this.innerProperties() == null ? null : this.innerProperties().storageProfile();
}
/**
- * Set the pointInTimeUtc property: Restore point creation time (ISO8601 format), specifying the time to restore
- * from. It's required when 'createMode' is 'PointInTimeRestore' or 'GeoRestore'.
+ * Set the storageProfile property: Storage profile of a server.
*
- * @param pointInTimeUtc the pointInTimeUtc value to set.
+ * @param storageProfile the storageProfile value to set.
* @return the ServerInner object itself.
*/
- public ServerInner withPointInTimeUtc(OffsetDateTime pointInTimeUtc) {
+ public ServerInner withStorageProfile(StorageProfile storageProfile) {
if (this.innerProperties() == null) {
this.innerProperties = new ServerProperties();
}
- this.innerProperties().withPointInTimeUtc(pointInTimeUtc);
+ this.innerProperties().withStorageProfile(storageProfile);
return this;
}
/**
- * Get the availabilityZone property: availability zone information of the server.
+ * Get the replicationRole property: The replication role of the server.
*
- * @return the availabilityZone value.
+ * @return the replicationRole value.
*/
- public String availabilityZone() {
- return this.innerProperties() == null ? null : this.innerProperties().availabilityZone();
+ public String replicationRole() {
+ return this.innerProperties() == null ? null : this.innerProperties().replicationRole();
}
/**
- * Set the availabilityZone property: availability zone information of the server.
+ * Set the replicationRole property: The replication role of the server.
*
- * @param availabilityZone the availabilityZone value to set.
+ * @param replicationRole the replicationRole value to set.
* @return the ServerInner object itself.
*/
- public ServerInner withAvailabilityZone(String availabilityZone) {
+ public ServerInner withReplicationRole(String replicationRole) {
if (this.innerProperties() == null) {
this.innerProperties = new ServerProperties();
}
- this.innerProperties().withAvailabilityZone(availabilityZone);
+ this.innerProperties().withReplicationRole(replicationRole);
return this;
}
/**
- * Get the replicationRole property: Replication role of the server.
+ * Get the masterServerId property: The master server id of a replica server.
*
- * @return the replicationRole value.
+ * @return the masterServerId value.
*/
- public ReplicationRole replicationRole() {
- return this.innerProperties() == null ? null : this.innerProperties().replicationRole();
+ public String masterServerId() {
+ return this.innerProperties() == null ? null : this.innerProperties().masterServerId();
}
/**
- * Set the replicationRole property: Replication role of the server.
+ * Set the masterServerId property: The master server id of a replica server.
*
- * @param replicationRole the replicationRole value to set.
+ * @param masterServerId the masterServerId value to set.
* @return the ServerInner object itself.
*/
- public ServerInner withReplicationRole(ReplicationRole replicationRole) {
+ public ServerInner withMasterServerId(String masterServerId) {
if (this.innerProperties() == null) {
this.innerProperties = new ServerProperties();
}
- this.innerProperties().withReplicationRole(replicationRole);
+ this.innerProperties().withMasterServerId(masterServerId);
return this;
}
/**
- * Get the replicaCapacity property: Replicas allowed for a server.
+ * Get the replicaCapacity property: The maximum number of replicas that a master server can have.
*
* @return the replicaCapacity value.
*/
@@ -492,7 +384,7 @@ public Integer replicaCapacity() {
}
/**
- * Set the replicaCapacity property: Replicas allowed for a server.
+ * Set the replicaCapacity property: The maximum number of replicas that a master server can have.
*
* @param replicaCapacity the replicaCapacity value to set.
* @return the ServerInner object itself.
@@ -506,40 +398,51 @@ public ServerInner withReplicaCapacity(Integer replicaCapacity) {
}
/**
- * Get the createMode property: The mode to create a new PostgreSQL server.
+ * Get the publicNetworkAccess property: Whether or not public network access is allowed for this server. Value is
+ * optional but if passed in, must be 'Enabled' or 'Disabled'.
*
- * @return the createMode value.
+ * @return the publicNetworkAccess value.
*/
- public CreateMode createMode() {
- return this.innerProperties() == null ? null : this.innerProperties().createMode();
+ public PublicNetworkAccessEnum publicNetworkAccess() {
+ return this.innerProperties() == null ? null : this.innerProperties().publicNetworkAccess();
}
/**
- * Set the createMode property: The mode to create a new PostgreSQL server.
+ * Set the publicNetworkAccess property: Whether or not public network access is allowed for this server. Value is
+ * optional but if passed in, must be 'Enabled' or 'Disabled'.
*
- * @param createMode the createMode value to set.
+ * @param publicNetworkAccess the publicNetworkAccess value to set.
* @return the ServerInner object itself.
*/
- public ServerInner withCreateMode(CreateMode createMode) {
+ public ServerInner withPublicNetworkAccess(PublicNetworkAccessEnum publicNetworkAccess) {
if (this.innerProperties() == null) {
this.innerProperties = new ServerProperties();
}
- this.innerProperties().withCreateMode(createMode);
+ this.innerProperties().withPublicNetworkAccess(publicNetworkAccess);
return this;
}
+ /**
+ * Get the privateEndpointConnections property: List of private endpoint connections on a server.
+ *
+ * @return the privateEndpointConnections value.
+ */
+ public List privateEndpointConnections() {
+ return this.innerProperties() == null ? null : this.innerProperties().privateEndpointConnections();
+ }
+
/**
* Validates the instance.
*
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (sku() != null) {
- sku().validate();
- }
if (identity() != null) {
identity().validate();
}
+ if (sku() != null) {
+ sku().validate();
+ }
if (innerProperties() != null) {
innerProperties().validate();
}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerKeyInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerKeyInner.java
new file mode 100644
index 0000000000000..2636e19326d9f
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerKeyInner.java
@@ -0,0 +1,115 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.management.ProxyResource;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerKeyType;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.time.OffsetDateTime;
+
+/** A PostgreSQL Server key. */
+@Fluent
+public final class ServerKeyInner extends ProxyResource {
+ /*
+ * Kind of encryption protector used to protect the key.
+ */
+ @JsonProperty(value = "kind", access = JsonProperty.Access.WRITE_ONLY)
+ private String kind;
+
+ /*
+ * Properties of the ServerKey Resource.
+ */
+ @JsonProperty(value = "properties")
+ private ServerKeyProperties innerProperties;
+
+ /** Creates an instance of ServerKeyInner class. */
+ public ServerKeyInner() {
+ }
+
+ /**
+ * Get the kind property: Kind of encryption protector used to protect the key.
+ *
+ * @return the kind value.
+ */
+ public String kind() {
+ return this.kind;
+ }
+
+ /**
+ * Get the innerProperties property: Properties of the ServerKey Resource.
+ *
+ * @return the innerProperties value.
+ */
+ private ServerKeyProperties innerProperties() {
+ return this.innerProperties;
+ }
+
+ /**
+ * Get the serverKeyType property: The key type like 'AzureKeyVault'.
+ *
+ * @return the serverKeyType value.
+ */
+ public ServerKeyType serverKeyType() {
+ return this.innerProperties() == null ? null : this.innerProperties().serverKeyType();
+ }
+
+ /**
+ * Set the serverKeyType property: The key type like 'AzureKeyVault'.
+ *
+ * @param serverKeyType the serverKeyType value to set.
+ * @return the ServerKeyInner object itself.
+ */
+ public ServerKeyInner withServerKeyType(ServerKeyType serverKeyType) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ServerKeyProperties();
+ }
+ this.innerProperties().withServerKeyType(serverKeyType);
+ return this;
+ }
+
+ /**
+ * Get the uri property: The URI of the key.
+ *
+ * @return the uri value.
+ */
+ public String uri() {
+ return this.innerProperties() == null ? null : this.innerProperties().uri();
+ }
+
+ /**
+ * Set the uri property: The URI of the key.
+ *
+ * @param uri the uri value to set.
+ * @return the ServerKeyInner object itself.
+ */
+ public ServerKeyInner withUri(String uri) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ServerKeyProperties();
+ }
+ this.innerProperties().withUri(uri);
+ return this;
+ }
+
+ /**
+ * Get the creationDate property: The key creation date.
+ *
+ * @return the creationDate value.
+ */
+ public OffsetDateTime creationDate() {
+ return this.innerProperties() == null ? null : this.innerProperties().creationDate();
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerKeyProperties.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerKeyProperties.java
new file mode 100644
index 0000000000000..bc2d02e3b3850
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerKeyProperties.java
@@ -0,0 +1,102 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerKeyType;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.time.OffsetDateTime;
+
+/** Properties for a key execution. */
+@Fluent
+public final class ServerKeyProperties {
+ /*
+ * The key type like 'AzureKeyVault'.
+ */
+ @JsonProperty(value = "serverKeyType", required = true)
+ private ServerKeyType serverKeyType;
+
+ /*
+ * The URI of the key.
+ */
+ @JsonProperty(value = "uri")
+ private String uri;
+
+ /*
+ * The key creation date.
+ */
+ @JsonProperty(value = "creationDate", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime creationDate;
+
+ /** Creates an instance of ServerKeyProperties class. */
+ public ServerKeyProperties() {
+ }
+
+ /**
+ * Get the serverKeyType property: The key type like 'AzureKeyVault'.
+ *
+ * @return the serverKeyType value.
+ */
+ public ServerKeyType serverKeyType() {
+ return this.serverKeyType;
+ }
+
+ /**
+ * Set the serverKeyType property: The key type like 'AzureKeyVault'.
+ *
+ * @param serverKeyType the serverKeyType value to set.
+ * @return the ServerKeyProperties object itself.
+ */
+ public ServerKeyProperties withServerKeyType(ServerKeyType serverKeyType) {
+ this.serverKeyType = serverKeyType;
+ return this;
+ }
+
+ /**
+ * Get the uri property: The URI of the key.
+ *
+ * @return the uri value.
+ */
+ public String uri() {
+ return this.uri;
+ }
+
+ /**
+ * Set the uri property: The URI of the key.
+ *
+ * @param uri the uri value to set.
+ * @return the ServerKeyProperties object itself.
+ */
+ public ServerKeyProperties withUri(String uri) {
+ this.uri = uri;
+ return this;
+ }
+
+ /**
+ * Get the creationDate property: The key creation date.
+ *
+ * @return the creationDate value.
+ */
+ public OffsetDateTime creationDate() {
+ return this.creationDate;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (serverKeyType() == null) {
+ throw LOGGER
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ "Missing required property serverKeyType in model ServerKeyProperties"));
+ }
+ }
+
+ private static final ClientLogger LOGGER = new ClientLogger(ServerKeyProperties.class);
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerProperties.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerProperties.java
index 95c1173a3b90c..046175f257da9 100644
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerProperties.java
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerProperties.java
@@ -5,19 +5,17 @@
package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.AuthConfig;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.Backup;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.CreateMode;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.DataEncryption;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.HighAvailability;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.MaintenanceWindow;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.Network;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.ReplicationRole;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.InfrastructureEncryption;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.MinimalTlsVersionEnum;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.PublicNetworkAccessEnum;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerPrivateEndpointConnection;
import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerState;
import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerVersion;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.Storage;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.SslEnforcementEnum;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.StorageProfile;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.time.OffsetDateTime;
+import java.util.List;
/** The properties of a server. */
@Fluent
@@ -30,114 +28,89 @@ public final class ServerProperties {
private String administratorLogin;
/*
- * The administrator login password (required for server creation).
- */
- @JsonProperty(value = "administratorLoginPassword")
- private String administratorLoginPassword;
-
- /*
- * PostgreSQL Server version.
+ * Server version.
*/
@JsonProperty(value = "version")
private ServerVersion version;
/*
- * The minor version of the server.
- */
- @JsonProperty(value = "minorVersion", access = JsonProperty.Access.WRITE_ONLY)
- private String minorVersion;
-
- /*
- * A state of a server that is visible to user.
- */
- @JsonProperty(value = "state", access = JsonProperty.Access.WRITE_ONLY)
- private ServerState state;
-
- /*
- * The fully qualified domain name of a server.
- */
- @JsonProperty(value = "fullyQualifiedDomainName", access = JsonProperty.Access.WRITE_ONLY)
- private String fullyQualifiedDomainName;
-
- /*
- * Storage properties of a server.
+ * Enable ssl enforcement or not when connect to server.
*/
- @JsonProperty(value = "storage")
- private Storage storage;
+ @JsonProperty(value = "sslEnforcement")
+ private SslEnforcementEnum sslEnforcement;
/*
- * AuthConfig properties of a server.
+ * Enforce a minimal Tls version for the server.
*/
- @JsonProperty(value = "authConfig")
- private AuthConfig authConfig;
+ @JsonProperty(value = "minimalTlsVersion")
+ private MinimalTlsVersionEnum minimalTlsVersion;
/*
- * Data encryption properties of a server.
+ * Status showing whether the server data encryption is enabled with customer-managed keys.
*/
- @JsonProperty(value = "dataEncryption")
- private DataEncryption dataEncryption;
+ @JsonProperty(value = "byokEnforcement", access = JsonProperty.Access.WRITE_ONLY)
+ private String byokEnforcement;
/*
- * Backup properties of a server.
+ * Status showing whether the server enabled infrastructure encryption.
*/
- @JsonProperty(value = "backup")
- private Backup backup;
+ @JsonProperty(value = "infrastructureEncryption")
+ private InfrastructureEncryption infrastructureEncryption;
/*
- * Network properties of a server.
+ * A state of a server that is visible to user.
*/
- @JsonProperty(value = "network")
- private Network network;
+ @JsonProperty(value = "userVisibleState")
+ private ServerState userVisibleState;
/*
- * High availability properties of a server.
+ * The fully qualified domain name of a server.
*/
- @JsonProperty(value = "highAvailability")
- private HighAvailability highAvailability;
+ @JsonProperty(value = "fullyQualifiedDomainName")
+ private String fullyQualifiedDomainName;
/*
- * Maintenance window properties of a server.
+ * Earliest restore point creation time (ISO8601 format)
*/
- @JsonProperty(value = "maintenanceWindow")
- private MaintenanceWindow maintenanceWindow;
+ @JsonProperty(value = "earliestRestoreDate")
+ private OffsetDateTime earliestRestoreDate;
/*
- * The source server resource ID to restore from. It's required when 'createMode' is 'PointInTimeRestore' or
- * 'GeoRestore' or 'Replica'.
+ * Storage profile of a server.
*/
- @JsonProperty(value = "sourceServerResourceId")
- private String sourceServerResourceId;
+ @JsonProperty(value = "storageProfile")
+ private StorageProfile storageProfile;
/*
- * Restore point creation time (ISO8601 format), specifying the time to restore from. It's required when
- * 'createMode' is 'PointInTimeRestore' or 'GeoRestore'.
+ * The replication role of the server.
*/
- @JsonProperty(value = "pointInTimeUTC")
- private OffsetDateTime pointInTimeUtc;
+ @JsonProperty(value = "replicationRole")
+ private String replicationRole;
/*
- * availability zone information of the server.
+ * The master server id of a replica server.
*/
- @JsonProperty(value = "availabilityZone")
- private String availabilityZone;
+ @JsonProperty(value = "masterServerId")
+ private String masterServerId;
/*
- * Replication role of the server
+ * The maximum number of replicas that a master server can have.
*/
- @JsonProperty(value = "replicationRole")
- private ReplicationRole replicationRole;
+ @JsonProperty(value = "replicaCapacity")
+ private Integer replicaCapacity;
/*
- * Replicas allowed for a server.
+ * Whether or not public network access is allowed for this server. Value is optional but if passed in, must be
+ * 'Enabled' or 'Disabled'
*/
- @JsonProperty(value = "replicaCapacity")
- private Integer replicaCapacity;
+ @JsonProperty(value = "publicNetworkAccess")
+ private PublicNetworkAccessEnum publicNetworkAccess;
/*
- * The mode to create a new PostgreSQL server.
+ * List of private endpoint connections on a server
*/
- @JsonProperty(value = "createMode")
- private CreateMode createMode;
+ @JsonProperty(value = "privateEndpointConnections", access = JsonProperty.Access.WRITE_ONLY)
+ private List privateEndpointConnections;
/** Creates an instance of ServerProperties class. */
public ServerProperties() {
@@ -166,27 +139,7 @@ public ServerProperties withAdministratorLogin(String administratorLogin) {
}
/**
- * Get the administratorLoginPassword property: The administrator login password (required for server creation).
- *
- * @return the administratorLoginPassword value.
- */
- public String administratorLoginPassword() {
- return this.administratorLoginPassword;
- }
-
- /**
- * Set the administratorLoginPassword property: The administrator login password (required for server creation).
- *
- * @param administratorLoginPassword the administratorLoginPassword value to set.
- * @return the ServerProperties object itself.
- */
- public ServerProperties withAdministratorLoginPassword(String administratorLoginPassword) {
- this.administratorLoginPassword = administratorLoginPassword;
- return this;
- }
-
- /**
- * Get the version property: PostgreSQL Server version.
+ * Get the version property: Server version.
*
* @return the version value.
*/
@@ -195,7 +148,7 @@ public ServerVersion version() {
}
/**
- * Set the version property: PostgreSQL Server version.
+ * Set the version property: Server version.
*
* @param version the version value to set.
* @return the ServerProperties object itself.
@@ -206,258 +159,197 @@ public ServerProperties withVersion(ServerVersion version) {
}
/**
- * Get the minorVersion property: The minor version of the server.
- *
- * @return the minorVersion value.
- */
- public String minorVersion() {
- return this.minorVersion;
- }
-
- /**
- * Get the state property: A state of a server that is visible to user.
- *
- * @return the state value.
- */
- public ServerState state() {
- return this.state;
- }
-
- /**
- * Get the fullyQualifiedDomainName property: The fully qualified domain name of a server.
- *
- * @return the fullyQualifiedDomainName value.
- */
- public String fullyQualifiedDomainName() {
- return this.fullyQualifiedDomainName;
- }
-
- /**
- * Get the storage property: Storage properties of a server.
- *
- * @return the storage value.
- */
- public Storage storage() {
- return this.storage;
- }
-
- /**
- * Set the storage property: Storage properties of a server.
- *
- * @param storage the storage value to set.
- * @return the ServerProperties object itself.
- */
- public ServerProperties withStorage(Storage storage) {
- this.storage = storage;
- return this;
- }
-
- /**
- * Get the authConfig property: AuthConfig properties of a server.
+ * Get the sslEnforcement property: Enable ssl enforcement or not when connect to server.
*
- * @return the authConfig value.
+ * @return the sslEnforcement value.
*/
- public AuthConfig authConfig() {
- return this.authConfig;
+ public SslEnforcementEnum sslEnforcement() {
+ return this.sslEnforcement;
}
/**
- * Set the authConfig property: AuthConfig properties of a server.
+ * Set the sslEnforcement property: Enable ssl enforcement or not when connect to server.
*
- * @param authConfig the authConfig value to set.
+ * @param sslEnforcement the sslEnforcement value to set.
* @return the ServerProperties object itself.
*/
- public ServerProperties withAuthConfig(AuthConfig authConfig) {
- this.authConfig = authConfig;
+ public ServerProperties withSslEnforcement(SslEnforcementEnum sslEnforcement) {
+ this.sslEnforcement = sslEnforcement;
return this;
}
/**
- * Get the dataEncryption property: Data encryption properties of a server.
+ * Get the minimalTlsVersion property: Enforce a minimal Tls version for the server.
*
- * @return the dataEncryption value.
+ * @return the minimalTlsVersion value.
*/
- public DataEncryption dataEncryption() {
- return this.dataEncryption;
+ public MinimalTlsVersionEnum minimalTlsVersion() {
+ return this.minimalTlsVersion;
}
/**
- * Set the dataEncryption property: Data encryption properties of a server.
+ * Set the minimalTlsVersion property: Enforce a minimal Tls version for the server.
*
- * @param dataEncryption the dataEncryption value to set.
+ * @param minimalTlsVersion the minimalTlsVersion value to set.
* @return the ServerProperties object itself.
*/
- public ServerProperties withDataEncryption(DataEncryption dataEncryption) {
- this.dataEncryption = dataEncryption;
+ public ServerProperties withMinimalTlsVersion(MinimalTlsVersionEnum minimalTlsVersion) {
+ this.minimalTlsVersion = minimalTlsVersion;
return this;
}
/**
- * Get the backup property: Backup properties of a server.
- *
- * @return the backup value.
- */
- public Backup backup() {
- return this.backup;
- }
-
- /**
- * Set the backup property: Backup properties of a server.
+ * Get the byokEnforcement property: Status showing whether the server data encryption is enabled with
+ * customer-managed keys.
*
- * @param backup the backup value to set.
- * @return the ServerProperties object itself.
+ * @return the byokEnforcement value.
*/
- public ServerProperties withBackup(Backup backup) {
- this.backup = backup;
- return this;
+ public String byokEnforcement() {
+ return this.byokEnforcement;
}
/**
- * Get the network property: Network properties of a server.
+ * Get the infrastructureEncryption property: Status showing whether the server enabled infrastructure encryption.
*
- * @return the network value.
+ * @return the infrastructureEncryption value.
*/
- public Network network() {
- return this.network;
+ public InfrastructureEncryption infrastructureEncryption() {
+ return this.infrastructureEncryption;
}
/**
- * Set the network property: Network properties of a server.
+ * Set the infrastructureEncryption property: Status showing whether the server enabled infrastructure encryption.
*
- * @param network the network value to set.
+ * @param infrastructureEncryption the infrastructureEncryption value to set.
* @return the ServerProperties object itself.
*/
- public ServerProperties withNetwork(Network network) {
- this.network = network;
+ public ServerProperties withInfrastructureEncryption(InfrastructureEncryption infrastructureEncryption) {
+ this.infrastructureEncryption = infrastructureEncryption;
return this;
}
/**
- * Get the highAvailability property: High availability properties of a server.
+ * Get the userVisibleState property: A state of a server that is visible to user.
*
- * @return the highAvailability value.
+ * @return the userVisibleState value.
*/
- public HighAvailability highAvailability() {
- return this.highAvailability;
+ public ServerState userVisibleState() {
+ return this.userVisibleState;
}
/**
- * Set the highAvailability property: High availability properties of a server.
+ * Set the userVisibleState property: A state of a server that is visible to user.
*
- * @param highAvailability the highAvailability value to set.
+ * @param userVisibleState the userVisibleState value to set.
* @return the ServerProperties object itself.
*/
- public ServerProperties withHighAvailability(HighAvailability highAvailability) {
- this.highAvailability = highAvailability;
+ public ServerProperties withUserVisibleState(ServerState userVisibleState) {
+ this.userVisibleState = userVisibleState;
return this;
}
/**
- * Get the maintenanceWindow property: Maintenance window properties of a server.
+ * Get the fullyQualifiedDomainName property: The fully qualified domain name of a server.
*
- * @return the maintenanceWindow value.
+ * @return the fullyQualifiedDomainName value.
*/
- public MaintenanceWindow maintenanceWindow() {
- return this.maintenanceWindow;
+ public String fullyQualifiedDomainName() {
+ return this.fullyQualifiedDomainName;
}
/**
- * Set the maintenanceWindow property: Maintenance window properties of a server.
+ * Set the fullyQualifiedDomainName property: The fully qualified domain name of a server.
*
- * @param maintenanceWindow the maintenanceWindow value to set.
+ * @param fullyQualifiedDomainName the fullyQualifiedDomainName value to set.
* @return the ServerProperties object itself.
*/
- public ServerProperties withMaintenanceWindow(MaintenanceWindow maintenanceWindow) {
- this.maintenanceWindow = maintenanceWindow;
+ public ServerProperties withFullyQualifiedDomainName(String fullyQualifiedDomainName) {
+ this.fullyQualifiedDomainName = fullyQualifiedDomainName;
return this;
}
/**
- * Get the sourceServerResourceId property: The source server resource ID to restore from. It's required when
- * 'createMode' is 'PointInTimeRestore' or 'GeoRestore' or 'Replica'.
+ * Get the earliestRestoreDate property: Earliest restore point creation time (ISO8601 format).
*
- * @return the sourceServerResourceId value.
+ * @return the earliestRestoreDate value.
*/
- public String sourceServerResourceId() {
- return this.sourceServerResourceId;
+ public OffsetDateTime earliestRestoreDate() {
+ return this.earliestRestoreDate;
}
/**
- * Set the sourceServerResourceId property: The source server resource ID to restore from. It's required when
- * 'createMode' is 'PointInTimeRestore' or 'GeoRestore' or 'Replica'.
+ * Set the earliestRestoreDate property: Earliest restore point creation time (ISO8601 format).
*
- * @param sourceServerResourceId the sourceServerResourceId value to set.
+ * @param earliestRestoreDate the earliestRestoreDate value to set.
* @return the ServerProperties object itself.
*/
- public ServerProperties withSourceServerResourceId(String sourceServerResourceId) {
- this.sourceServerResourceId = sourceServerResourceId;
+ public ServerProperties withEarliestRestoreDate(OffsetDateTime earliestRestoreDate) {
+ this.earliestRestoreDate = earliestRestoreDate;
return this;
}
/**
- * Get the pointInTimeUtc property: Restore point creation time (ISO8601 format), specifying the time to restore
- * from. It's required when 'createMode' is 'PointInTimeRestore' or 'GeoRestore'.
+ * Get the storageProfile property: Storage profile of a server.
*
- * @return the pointInTimeUtc value.
+ * @return the storageProfile value.
*/
- public OffsetDateTime pointInTimeUtc() {
- return this.pointInTimeUtc;
+ public StorageProfile storageProfile() {
+ return this.storageProfile;
}
/**
- * Set the pointInTimeUtc property: Restore point creation time (ISO8601 format), specifying the time to restore
- * from. It's required when 'createMode' is 'PointInTimeRestore' or 'GeoRestore'.
+ * Set the storageProfile property: Storage profile of a server.
*
- * @param pointInTimeUtc the pointInTimeUtc value to set.
+ * @param storageProfile the storageProfile value to set.
* @return the ServerProperties object itself.
*/
- public ServerProperties withPointInTimeUtc(OffsetDateTime pointInTimeUtc) {
- this.pointInTimeUtc = pointInTimeUtc;
+ public ServerProperties withStorageProfile(StorageProfile storageProfile) {
+ this.storageProfile = storageProfile;
return this;
}
/**
- * Get the availabilityZone property: availability zone information of the server.
+ * Get the replicationRole property: The replication role of the server.
*
- * @return the availabilityZone value.
+ * @return the replicationRole value.
*/
- public String availabilityZone() {
- return this.availabilityZone;
+ public String replicationRole() {
+ return this.replicationRole;
}
/**
- * Set the availabilityZone property: availability zone information of the server.
+ * Set the replicationRole property: The replication role of the server.
*
- * @param availabilityZone the availabilityZone value to set.
+ * @param replicationRole the replicationRole value to set.
* @return the ServerProperties object itself.
*/
- public ServerProperties withAvailabilityZone(String availabilityZone) {
- this.availabilityZone = availabilityZone;
+ public ServerProperties withReplicationRole(String replicationRole) {
+ this.replicationRole = replicationRole;
return this;
}
/**
- * Get the replicationRole property: Replication role of the server.
+ * Get the masterServerId property: The master server id of a replica server.
*
- * @return the replicationRole value.
+ * @return the masterServerId value.
*/
- public ReplicationRole replicationRole() {
- return this.replicationRole;
+ public String masterServerId() {
+ return this.masterServerId;
}
/**
- * Set the replicationRole property: Replication role of the server.
+ * Set the masterServerId property: The master server id of a replica server.
*
- * @param replicationRole the replicationRole value to set.
+ * @param masterServerId the masterServerId value to set.
* @return the ServerProperties object itself.
*/
- public ServerProperties withReplicationRole(ReplicationRole replicationRole) {
- this.replicationRole = replicationRole;
+ public ServerProperties withMasterServerId(String masterServerId) {
+ this.masterServerId = masterServerId;
return this;
}
/**
- * Get the replicaCapacity property: Replicas allowed for a server.
+ * Get the replicaCapacity property: The maximum number of replicas that a master server can have.
*
* @return the replicaCapacity value.
*/
@@ -466,7 +358,7 @@ public Integer replicaCapacity() {
}
/**
- * Set the replicaCapacity property: Replicas allowed for a server.
+ * Set the replicaCapacity property: The maximum number of replicas that a master server can have.
*
* @param replicaCapacity the replicaCapacity value to set.
* @return the ServerProperties object itself.
@@ -477,51 +369,47 @@ public ServerProperties withReplicaCapacity(Integer replicaCapacity) {
}
/**
- * Get the createMode property: The mode to create a new PostgreSQL server.
+ * Get the publicNetworkAccess property: Whether or not public network access is allowed for this server. Value is
+ * optional but if passed in, must be 'Enabled' or 'Disabled'.
*
- * @return the createMode value.
+ * @return the publicNetworkAccess value.
*/
- public CreateMode createMode() {
- return this.createMode;
+ public PublicNetworkAccessEnum publicNetworkAccess() {
+ return this.publicNetworkAccess;
}
/**
- * Set the createMode property: The mode to create a new PostgreSQL server.
+ * Set the publicNetworkAccess property: Whether or not public network access is allowed for this server. Value is
+ * optional but if passed in, must be 'Enabled' or 'Disabled'.
*
- * @param createMode the createMode value to set.
+ * @param publicNetworkAccess the publicNetworkAccess value to set.
* @return the ServerProperties object itself.
*/
- public ServerProperties withCreateMode(CreateMode createMode) {
- this.createMode = createMode;
+ public ServerProperties withPublicNetworkAccess(PublicNetworkAccessEnum publicNetworkAccess) {
+ this.publicNetworkAccess = publicNetworkAccess;
return this;
}
+ /**
+ * Get the privateEndpointConnections property: List of private endpoint connections on a server.
+ *
+ * @return the privateEndpointConnections value.
+ */
+ public List privateEndpointConnections() {
+ return this.privateEndpointConnections;
+ }
+
/**
* Validates the instance.
*
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (storage() != null) {
- storage().validate();
- }
- if (authConfig() != null) {
- authConfig().validate();
- }
- if (dataEncryption() != null) {
- dataEncryption().validate();
- }
- if (backup() != null) {
- backup().validate();
- }
- if (network() != null) {
- network().validate();
- }
- if (highAvailability() != null) {
- highAvailability().validate();
+ if (storageProfile() != null) {
+ storageProfile().validate();
}
- if (maintenanceWindow() != null) {
- maintenanceWindow().validate();
+ if (privateEndpointConnections() != null) {
+ privateEndpointConnections().forEach(e -> e.validate());
}
}
}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerPropertiesForUpdate.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerPropertiesForUpdate.java
deleted file mode 100644
index 47db10fbfcee9..0000000000000
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerPropertiesForUpdate.java
+++ /dev/null
@@ -1,311 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.AuthConfig;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.Backup;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.CreateModeForUpdate;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.DataEncryption;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.HighAvailability;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.MaintenanceWindow;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.ReplicationRole;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerVersion;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.Storage;
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-/** The ServerPropertiesForUpdate model. */
-@Fluent
-public final class ServerPropertiesForUpdate {
- /*
- * The password of the administrator login.
- */
- @JsonProperty(value = "administratorLoginPassword")
- private String administratorLoginPassword;
-
- /*
- * PostgreSQL Server version.
- */
- @JsonProperty(value = "version")
- private ServerVersion version;
-
- /*
- * Storage properties of a server.
- */
- @JsonProperty(value = "storage")
- private Storage storage;
-
- /*
- * Backup properties of a server.
- */
- @JsonProperty(value = "backup")
- private Backup backup;
-
- /*
- * High availability properties of a server.
- */
- @JsonProperty(value = "highAvailability")
- private HighAvailability highAvailability;
-
- /*
- * Maintenance window properties of a server.
- */
- @JsonProperty(value = "maintenanceWindow")
- private MaintenanceWindow maintenanceWindow;
-
- /*
- * AuthConfig properties of a server.
- */
- @JsonProperty(value = "authConfig")
- private AuthConfig authConfig;
-
- /*
- * Data encryption properties of a server.
- */
- @JsonProperty(value = "dataEncryption")
- private DataEncryption dataEncryption;
-
- /*
- * The mode to update a new PostgreSQL server.
- */
- @JsonProperty(value = "createMode")
- private CreateModeForUpdate createMode;
-
- /*
- * Replication role of the server
- */
- @JsonProperty(value = "replicationRole")
- private ReplicationRole replicationRole;
-
- /** Creates an instance of ServerPropertiesForUpdate class. */
- public ServerPropertiesForUpdate() {
- }
-
- /**
- * Get the administratorLoginPassword property: The password of the administrator login.
- *
- * @return the administratorLoginPassword value.
- */
- public String administratorLoginPassword() {
- return this.administratorLoginPassword;
- }
-
- /**
- * Set the administratorLoginPassword property: The password of the administrator login.
- *
- * @param administratorLoginPassword the administratorLoginPassword value to set.
- * @return the ServerPropertiesForUpdate object itself.
- */
- public ServerPropertiesForUpdate withAdministratorLoginPassword(String administratorLoginPassword) {
- this.administratorLoginPassword = administratorLoginPassword;
- return this;
- }
-
- /**
- * Get the version property: PostgreSQL Server version.
- *
- * @return the version value.
- */
- public ServerVersion version() {
- return this.version;
- }
-
- /**
- * Set the version property: PostgreSQL Server version.
- *
- * @param version the version value to set.
- * @return the ServerPropertiesForUpdate object itself.
- */
- public ServerPropertiesForUpdate withVersion(ServerVersion version) {
- this.version = version;
- return this;
- }
-
- /**
- * Get the storage property: Storage properties of a server.
- *
- * @return the storage value.
- */
- public Storage storage() {
- return this.storage;
- }
-
- /**
- * Set the storage property: Storage properties of a server.
- *
- * @param storage the storage value to set.
- * @return the ServerPropertiesForUpdate object itself.
- */
- public ServerPropertiesForUpdate withStorage(Storage storage) {
- this.storage = storage;
- return this;
- }
-
- /**
- * Get the backup property: Backup properties of a server.
- *
- * @return the backup value.
- */
- public Backup backup() {
- return this.backup;
- }
-
- /**
- * Set the backup property: Backup properties of a server.
- *
- * @param backup the backup value to set.
- * @return the ServerPropertiesForUpdate object itself.
- */
- public ServerPropertiesForUpdate withBackup(Backup backup) {
- this.backup = backup;
- return this;
- }
-
- /**
- * Get the highAvailability property: High availability properties of a server.
- *
- * @return the highAvailability value.
- */
- public HighAvailability highAvailability() {
- return this.highAvailability;
- }
-
- /**
- * Set the highAvailability property: High availability properties of a server.
- *
- * @param highAvailability the highAvailability value to set.
- * @return the ServerPropertiesForUpdate object itself.
- */
- public ServerPropertiesForUpdate withHighAvailability(HighAvailability highAvailability) {
- this.highAvailability = highAvailability;
- return this;
- }
-
- /**
- * Get the maintenanceWindow property: Maintenance window properties of a server.
- *
- * @return the maintenanceWindow value.
- */
- public MaintenanceWindow maintenanceWindow() {
- return this.maintenanceWindow;
- }
-
- /**
- * Set the maintenanceWindow property: Maintenance window properties of a server.
- *
- * @param maintenanceWindow the maintenanceWindow value to set.
- * @return the ServerPropertiesForUpdate object itself.
- */
- public ServerPropertiesForUpdate withMaintenanceWindow(MaintenanceWindow maintenanceWindow) {
- this.maintenanceWindow = maintenanceWindow;
- return this;
- }
-
- /**
- * Get the authConfig property: AuthConfig properties of a server.
- *
- * @return the authConfig value.
- */
- public AuthConfig authConfig() {
- return this.authConfig;
- }
-
- /**
- * Set the authConfig property: AuthConfig properties of a server.
- *
- * @param authConfig the authConfig value to set.
- * @return the ServerPropertiesForUpdate object itself.
- */
- public ServerPropertiesForUpdate withAuthConfig(AuthConfig authConfig) {
- this.authConfig = authConfig;
- return this;
- }
-
- /**
- * Get the dataEncryption property: Data encryption properties of a server.
- *
- * @return the dataEncryption value.
- */
- public DataEncryption dataEncryption() {
- return this.dataEncryption;
- }
-
- /**
- * Set the dataEncryption property: Data encryption properties of a server.
- *
- * @param dataEncryption the dataEncryption value to set.
- * @return the ServerPropertiesForUpdate object itself.
- */
- public ServerPropertiesForUpdate withDataEncryption(DataEncryption dataEncryption) {
- this.dataEncryption = dataEncryption;
- return this;
- }
-
- /**
- * Get the createMode property: The mode to update a new PostgreSQL server.
- *
- * @return the createMode value.
- */
- public CreateModeForUpdate createMode() {
- return this.createMode;
- }
-
- /**
- * Set the createMode property: The mode to update a new PostgreSQL server.
- *
- * @param createMode the createMode value to set.
- * @return the ServerPropertiesForUpdate object itself.
- */
- public ServerPropertiesForUpdate withCreateMode(CreateModeForUpdate createMode) {
- this.createMode = createMode;
- return this;
- }
-
- /**
- * Get the replicationRole property: Replication role of the server.
- *
- * @return the replicationRole value.
- */
- public ReplicationRole replicationRole() {
- return this.replicationRole;
- }
-
- /**
- * Set the replicationRole property: Replication role of the server.
- *
- * @param replicationRole the replicationRole value to set.
- * @return the ServerPropertiesForUpdate object itself.
- */
- public ServerPropertiesForUpdate withReplicationRole(ReplicationRole replicationRole) {
- this.replicationRole = replicationRole;
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (storage() != null) {
- storage().validate();
- }
- if (backup() != null) {
- backup().validate();
- }
- if (highAvailability() != null) {
- highAvailability().validate();
- }
- if (maintenanceWindow() != null) {
- maintenanceWindow().validate();
- }
- if (authConfig() != null) {
- authConfig().validate();
- }
- if (dataEncryption() != null) {
- dataEncryption().validate();
- }
- }
-}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerSecurityAlertPolicyInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerSecurityAlertPolicyInner.java
new file mode 100644
index 0000000000000..b8e2914a345c7
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerSecurityAlertPolicyInner.java
@@ -0,0 +1,212 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.management.ProxyResource;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerSecurityAlertPolicyState;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** A server security alert policy. */
+@Fluent
+public final class ServerSecurityAlertPolicyInner extends ProxyResource {
+ /*
+ * Resource properties.
+ */
+ @JsonProperty(value = "properties")
+ private SecurityAlertPolicyProperties innerProperties;
+
+ /** Creates an instance of ServerSecurityAlertPolicyInner class. */
+ public ServerSecurityAlertPolicyInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Resource properties.
+ *
+ * @return the innerProperties value.
+ */
+ private SecurityAlertPolicyProperties innerProperties() {
+ return this.innerProperties;
+ }
+
+ /**
+ * Get the state property: Specifies the state of the policy, whether it is enabled or disabled.
+ *
+ * @return the state value.
+ */
+ public ServerSecurityAlertPolicyState state() {
+ return this.innerProperties() == null ? null : this.innerProperties().state();
+ }
+
+ /**
+ * Set the state property: Specifies the state of the policy, whether it is enabled or disabled.
+ *
+ * @param state the state value to set.
+ * @return the ServerSecurityAlertPolicyInner object itself.
+ */
+ public ServerSecurityAlertPolicyInner withState(ServerSecurityAlertPolicyState state) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new SecurityAlertPolicyProperties();
+ }
+ this.innerProperties().withState(state);
+ return this;
+ }
+
+ /**
+ * Get the disabledAlerts property: Specifies an array of alerts that are disabled. Allowed values are:
+ * Sql_Injection, Sql_Injection_Vulnerability, Access_Anomaly.
+ *
+ * @return the disabledAlerts value.
+ */
+ public List disabledAlerts() {
+ return this.innerProperties() == null ? null : this.innerProperties().disabledAlerts();
+ }
+
+ /**
+ * Set the disabledAlerts property: Specifies an array of alerts that are disabled. Allowed values are:
+ * Sql_Injection, Sql_Injection_Vulnerability, Access_Anomaly.
+ *
+ * @param disabledAlerts the disabledAlerts value to set.
+ * @return the ServerSecurityAlertPolicyInner object itself.
+ */
+ public ServerSecurityAlertPolicyInner withDisabledAlerts(List disabledAlerts) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new SecurityAlertPolicyProperties();
+ }
+ this.innerProperties().withDisabledAlerts(disabledAlerts);
+ return this;
+ }
+
+ /**
+ * Get the emailAddresses property: Specifies an array of e-mail addresses to which the alert is sent.
+ *
+ * @return the emailAddresses value.
+ */
+ public List emailAddresses() {
+ return this.innerProperties() == null ? null : this.innerProperties().emailAddresses();
+ }
+
+ /**
+ * Set the emailAddresses property: Specifies an array of e-mail addresses to which the alert is sent.
+ *
+ * @param emailAddresses the emailAddresses value to set.
+ * @return the ServerSecurityAlertPolicyInner object itself.
+ */
+ public ServerSecurityAlertPolicyInner withEmailAddresses(List emailAddresses) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new SecurityAlertPolicyProperties();
+ }
+ this.innerProperties().withEmailAddresses(emailAddresses);
+ return this;
+ }
+
+ /**
+ * Get the emailAccountAdmins property: Specifies that the alert is sent to the account administrators.
+ *
+ * @return the emailAccountAdmins value.
+ */
+ public Boolean emailAccountAdmins() {
+ return this.innerProperties() == null ? null : this.innerProperties().emailAccountAdmins();
+ }
+
+ /**
+ * Set the emailAccountAdmins property: Specifies that the alert is sent to the account administrators.
+ *
+ * @param emailAccountAdmins the emailAccountAdmins value to set.
+ * @return the ServerSecurityAlertPolicyInner object itself.
+ */
+ public ServerSecurityAlertPolicyInner withEmailAccountAdmins(Boolean emailAccountAdmins) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new SecurityAlertPolicyProperties();
+ }
+ this.innerProperties().withEmailAccountAdmins(emailAccountAdmins);
+ return this;
+ }
+
+ /**
+ * Get the storageEndpoint property: Specifies the blob storage endpoint (e.g.
+ * https://MyAccount.blob.core.windows.net). This blob storage will hold all Threat Detection audit logs.
+ *
+ * @return the storageEndpoint value.
+ */
+ public String storageEndpoint() {
+ return this.innerProperties() == null ? null : this.innerProperties().storageEndpoint();
+ }
+
+ /**
+ * Set the storageEndpoint property: Specifies the blob storage endpoint (e.g.
+ * https://MyAccount.blob.core.windows.net). This blob storage will hold all Threat Detection audit logs.
+ *
+ * @param storageEndpoint the storageEndpoint value to set.
+ * @return the ServerSecurityAlertPolicyInner object itself.
+ */
+ public ServerSecurityAlertPolicyInner withStorageEndpoint(String storageEndpoint) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new SecurityAlertPolicyProperties();
+ }
+ this.innerProperties().withStorageEndpoint(storageEndpoint);
+ return this;
+ }
+
+ /**
+ * Get the storageAccountAccessKey property: Specifies the identifier key of the Threat Detection audit storage
+ * account.
+ *
+ * @return the storageAccountAccessKey value.
+ */
+ public String storageAccountAccessKey() {
+ return this.innerProperties() == null ? null : this.innerProperties().storageAccountAccessKey();
+ }
+
+ /**
+ * Set the storageAccountAccessKey property: Specifies the identifier key of the Threat Detection audit storage
+ * account.
+ *
+ * @param storageAccountAccessKey the storageAccountAccessKey value to set.
+ * @return the ServerSecurityAlertPolicyInner object itself.
+ */
+ public ServerSecurityAlertPolicyInner withStorageAccountAccessKey(String storageAccountAccessKey) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new SecurityAlertPolicyProperties();
+ }
+ this.innerProperties().withStorageAccountAccessKey(storageAccountAccessKey);
+ return this;
+ }
+
+ /**
+ * Get the retentionDays property: Specifies the number of days to keep in the Threat Detection audit logs.
+ *
+ * @return the retentionDays value.
+ */
+ public Integer retentionDays() {
+ return this.innerProperties() == null ? null : this.innerProperties().retentionDays();
+ }
+
+ /**
+ * Set the retentionDays property: Specifies the number of days to keep in the Threat Detection audit logs.
+ *
+ * @param retentionDays the retentionDays value to set.
+ * @return the ServerSecurityAlertPolicyInner object itself.
+ */
+ public ServerSecurityAlertPolicyInner withRetentionDays(Integer retentionDays) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new SecurityAlertPolicyProperties();
+ }
+ this.innerProperties().withRetentionDays(retentionDays);
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerUpdateParametersProperties.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerUpdateParametersProperties.java
new file mode 100644
index 0000000000000..96e0431f277dd
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/ServerUpdateParametersProperties.java
@@ -0,0 +1,217 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.MinimalTlsVersionEnum;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.PublicNetworkAccessEnum;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.ServerVersion;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.SslEnforcementEnum;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.StorageProfile;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** The properties that can be updated for a server. */
+@Fluent
+public final class ServerUpdateParametersProperties {
+ /*
+ * Storage profile of a server.
+ */
+ @JsonProperty(value = "storageProfile")
+ private StorageProfile storageProfile;
+
+ /*
+ * The password of the administrator login.
+ */
+ @JsonProperty(value = "administratorLoginPassword")
+ private String administratorLoginPassword;
+
+ /*
+ * The version of a server.
+ */
+ @JsonProperty(value = "version")
+ private ServerVersion version;
+
+ /*
+ * Enable ssl enforcement or not when connect to server.
+ */
+ @JsonProperty(value = "sslEnforcement")
+ private SslEnforcementEnum sslEnforcement;
+
+ /*
+ * Enforce a minimal Tls version for the server.
+ */
+ @JsonProperty(value = "minimalTlsVersion")
+ private MinimalTlsVersionEnum minimalTlsVersion;
+
+ /*
+ * Whether or not public network access is allowed for this server. Value is optional but if passed in, must be
+ * 'Enabled' or 'Disabled'
+ */
+ @JsonProperty(value = "publicNetworkAccess")
+ private PublicNetworkAccessEnum publicNetworkAccess;
+
+ /*
+ * The replication role of the server.
+ */
+ @JsonProperty(value = "replicationRole")
+ private String replicationRole;
+
+ /** Creates an instance of ServerUpdateParametersProperties class. */
+ public ServerUpdateParametersProperties() {
+ }
+
+ /**
+ * Get the storageProfile property: Storage profile of a server.
+ *
+ * @return the storageProfile value.
+ */
+ public StorageProfile storageProfile() {
+ return this.storageProfile;
+ }
+
+ /**
+ * Set the storageProfile property: Storage profile of a server.
+ *
+ * @param storageProfile the storageProfile value to set.
+ * @return the ServerUpdateParametersProperties object itself.
+ */
+ public ServerUpdateParametersProperties withStorageProfile(StorageProfile storageProfile) {
+ this.storageProfile = storageProfile;
+ return this;
+ }
+
+ /**
+ * Get the administratorLoginPassword property: The password of the administrator login.
+ *
+ * @return the administratorLoginPassword value.
+ */
+ public String administratorLoginPassword() {
+ return this.administratorLoginPassword;
+ }
+
+ /**
+ * Set the administratorLoginPassword property: The password of the administrator login.
+ *
+ * @param administratorLoginPassword the administratorLoginPassword value to set.
+ * @return the ServerUpdateParametersProperties object itself.
+ */
+ public ServerUpdateParametersProperties withAdministratorLoginPassword(String administratorLoginPassword) {
+ this.administratorLoginPassword = administratorLoginPassword;
+ return this;
+ }
+
+ /**
+ * Get the version property: The version of a server.
+ *
+ * @return the version value.
+ */
+ public ServerVersion version() {
+ return this.version;
+ }
+
+ /**
+ * Set the version property: The version of a server.
+ *
+ * @param version the version value to set.
+ * @return the ServerUpdateParametersProperties object itself.
+ */
+ public ServerUpdateParametersProperties withVersion(ServerVersion version) {
+ this.version = version;
+ return this;
+ }
+
+ /**
+ * Get the sslEnforcement property: Enable ssl enforcement or not when connect to server.
+ *
+ * @return the sslEnforcement value.
+ */
+ public SslEnforcementEnum sslEnforcement() {
+ return this.sslEnforcement;
+ }
+
+ /**
+ * Set the sslEnforcement property: Enable ssl enforcement or not when connect to server.
+ *
+ * @param sslEnforcement the sslEnforcement value to set.
+ * @return the ServerUpdateParametersProperties object itself.
+ */
+ public ServerUpdateParametersProperties withSslEnforcement(SslEnforcementEnum sslEnforcement) {
+ this.sslEnforcement = sslEnforcement;
+ return this;
+ }
+
+ /**
+ * Get the minimalTlsVersion property: Enforce a minimal Tls version for the server.
+ *
+ * @return the minimalTlsVersion value.
+ */
+ public MinimalTlsVersionEnum minimalTlsVersion() {
+ return this.minimalTlsVersion;
+ }
+
+ /**
+ * Set the minimalTlsVersion property: Enforce a minimal Tls version for the server.
+ *
+ * @param minimalTlsVersion the minimalTlsVersion value to set.
+ * @return the ServerUpdateParametersProperties object itself.
+ */
+ public ServerUpdateParametersProperties withMinimalTlsVersion(MinimalTlsVersionEnum minimalTlsVersion) {
+ this.minimalTlsVersion = minimalTlsVersion;
+ return this;
+ }
+
+ /**
+ * Get the publicNetworkAccess property: Whether or not public network access is allowed for this server. Value is
+ * optional but if passed in, must be 'Enabled' or 'Disabled'.
+ *
+ * @return the publicNetworkAccess value.
+ */
+ public PublicNetworkAccessEnum publicNetworkAccess() {
+ return this.publicNetworkAccess;
+ }
+
+ /**
+ * Set the publicNetworkAccess property: Whether or not public network access is allowed for this server. Value is
+ * optional but if passed in, must be 'Enabled' or 'Disabled'.
+ *
+ * @param publicNetworkAccess the publicNetworkAccess value to set.
+ * @return the ServerUpdateParametersProperties object itself.
+ */
+ public ServerUpdateParametersProperties withPublicNetworkAccess(PublicNetworkAccessEnum publicNetworkAccess) {
+ this.publicNetworkAccess = publicNetworkAccess;
+ return this;
+ }
+
+ /**
+ * Get the replicationRole property: The replication role of the server.
+ *
+ * @return the replicationRole value.
+ */
+ public String replicationRole() {
+ return this.replicationRole;
+ }
+
+ /**
+ * Set the replicationRole property: The replication role of the server.
+ *
+ * @param replicationRole the replicationRole value to set.
+ * @return the ServerUpdateParametersProperties object itself.
+ */
+ public ServerUpdateParametersProperties withReplicationRole(String replicationRole) {
+ this.replicationRole = replicationRole;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (storageProfile() != null) {
+ storageProfile().validate();
+ }
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/VirtualNetworkRuleInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/VirtualNetworkRuleInner.java
new file mode 100644
index 0000000000000..80dde2ae75657
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/VirtualNetworkRuleInner.java
@@ -0,0 +1,101 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.management.ProxyResource;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.VirtualNetworkRuleState;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** A virtual network rule. */
+@Fluent
+public final class VirtualNetworkRuleInner extends ProxyResource {
+ /*
+ * Resource properties.
+ */
+ @JsonProperty(value = "properties")
+ private VirtualNetworkRuleProperties innerProperties;
+
+ /** Creates an instance of VirtualNetworkRuleInner class. */
+ public VirtualNetworkRuleInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Resource properties.
+ *
+ * @return the innerProperties value.
+ */
+ private VirtualNetworkRuleProperties innerProperties() {
+ return this.innerProperties;
+ }
+
+ /**
+ * Get the virtualNetworkSubnetId property: The ARM resource id of the virtual network subnet.
+ *
+ * @return the virtualNetworkSubnetId value.
+ */
+ public String virtualNetworkSubnetId() {
+ return this.innerProperties() == null ? null : this.innerProperties().virtualNetworkSubnetId();
+ }
+
+ /**
+ * Set the virtualNetworkSubnetId property: The ARM resource id of the virtual network subnet.
+ *
+ * @param virtualNetworkSubnetId the virtualNetworkSubnetId value to set.
+ * @return the VirtualNetworkRuleInner object itself.
+ */
+ public VirtualNetworkRuleInner withVirtualNetworkSubnetId(String virtualNetworkSubnetId) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VirtualNetworkRuleProperties();
+ }
+ this.innerProperties().withVirtualNetworkSubnetId(virtualNetworkSubnetId);
+ return this;
+ }
+
+ /**
+ * Get the ignoreMissingVnetServiceEndpoint property: Create firewall rule before the virtual network has vnet
+ * service endpoint enabled.
+ *
+ * @return the ignoreMissingVnetServiceEndpoint value.
+ */
+ public Boolean ignoreMissingVnetServiceEndpoint() {
+ return this.innerProperties() == null ? null : this.innerProperties().ignoreMissingVnetServiceEndpoint();
+ }
+
+ /**
+ * Set the ignoreMissingVnetServiceEndpoint property: Create firewall rule before the virtual network has vnet
+ * service endpoint enabled.
+ *
+ * @param ignoreMissingVnetServiceEndpoint the ignoreMissingVnetServiceEndpoint value to set.
+ * @return the VirtualNetworkRuleInner object itself.
+ */
+ public VirtualNetworkRuleInner withIgnoreMissingVnetServiceEndpoint(Boolean ignoreMissingVnetServiceEndpoint) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VirtualNetworkRuleProperties();
+ }
+ this.innerProperties().withIgnoreMissingVnetServiceEndpoint(ignoreMissingVnetServiceEndpoint);
+ return this;
+ }
+
+ /**
+ * Get the state property: Virtual Network Rule State.
+ *
+ * @return the state value.
+ */
+ public VirtualNetworkRuleState state() {
+ return this.innerProperties() == null ? null : this.innerProperties().state();
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/VirtualNetworkRuleProperties.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/VirtualNetworkRuleProperties.java
new file mode 100644
index 0000000000000..9152b7581f58e
--- /dev/null
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/VirtualNetworkRuleProperties.java
@@ -0,0 +1,103 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.VirtualNetworkRuleState;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** Properties of a virtual network rule. */
+@Fluent
+public final class VirtualNetworkRuleProperties {
+ /*
+ * The ARM resource id of the virtual network subnet.
+ */
+ @JsonProperty(value = "virtualNetworkSubnetId", required = true)
+ private String virtualNetworkSubnetId;
+
+ /*
+ * Create firewall rule before the virtual network has vnet service endpoint enabled.
+ */
+ @JsonProperty(value = "ignoreMissingVnetServiceEndpoint")
+ private Boolean ignoreMissingVnetServiceEndpoint;
+
+ /*
+ * Virtual Network Rule State
+ */
+ @JsonProperty(value = "state", access = JsonProperty.Access.WRITE_ONLY)
+ private VirtualNetworkRuleState state;
+
+ /** Creates an instance of VirtualNetworkRuleProperties class. */
+ public VirtualNetworkRuleProperties() {
+ }
+
+ /**
+ * Get the virtualNetworkSubnetId property: The ARM resource id of the virtual network subnet.
+ *
+ * @return the virtualNetworkSubnetId value.
+ */
+ public String virtualNetworkSubnetId() {
+ return this.virtualNetworkSubnetId;
+ }
+
+ /**
+ * Set the virtualNetworkSubnetId property: The ARM resource id of the virtual network subnet.
+ *
+ * @param virtualNetworkSubnetId the virtualNetworkSubnetId value to set.
+ * @return the VirtualNetworkRuleProperties object itself.
+ */
+ public VirtualNetworkRuleProperties withVirtualNetworkSubnetId(String virtualNetworkSubnetId) {
+ this.virtualNetworkSubnetId = virtualNetworkSubnetId;
+ return this;
+ }
+
+ /**
+ * Get the ignoreMissingVnetServiceEndpoint property: Create firewall rule before the virtual network has vnet
+ * service endpoint enabled.
+ *
+ * @return the ignoreMissingVnetServiceEndpoint value.
+ */
+ public Boolean ignoreMissingVnetServiceEndpoint() {
+ return this.ignoreMissingVnetServiceEndpoint;
+ }
+
+ /**
+ * Set the ignoreMissingVnetServiceEndpoint property: Create firewall rule before the virtual network has vnet
+ * service endpoint enabled.
+ *
+ * @param ignoreMissingVnetServiceEndpoint the ignoreMissingVnetServiceEndpoint value to set.
+ * @return the VirtualNetworkRuleProperties object itself.
+ */
+ public VirtualNetworkRuleProperties withIgnoreMissingVnetServiceEndpoint(Boolean ignoreMissingVnetServiceEndpoint) {
+ this.ignoreMissingVnetServiceEndpoint = ignoreMissingVnetServiceEndpoint;
+ return this;
+ }
+
+ /**
+ * Get the state property: Virtual Network Rule State.
+ *
+ * @return the state value.
+ */
+ public VirtualNetworkRuleState state() {
+ return this.state;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (virtualNetworkSubnetId() == null) {
+ throw LOGGER
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ "Missing required property virtualNetworkSubnetId in model VirtualNetworkRuleProperties"));
+ }
+ }
+
+ private static final ClientLogger LOGGER = new ClientLogger(VirtualNetworkRuleProperties.class);
+}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/VirtualNetworkSubnetUsageResultInner.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/VirtualNetworkSubnetUsageResultInner.java
deleted file mode 100644
index 7b43add5a096b..0000000000000
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/fluent/models/VirtualNetworkSubnetUsageResultInner.java
+++ /dev/null
@@ -1,74 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.postgresqlflexibleserver.fluent.models;
-
-import com.azure.core.annotation.Immutable;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.DelegatedSubnetUsage;
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.List;
-
-/** Virtual network subnet usage data. */
-@Immutable
-public final class VirtualNetworkSubnetUsageResultInner {
- /*
- * The delegatedSubnetsUsage property.
- */
- @JsonProperty(value = "delegatedSubnetsUsage", access = JsonProperty.Access.WRITE_ONLY)
- private List delegatedSubnetsUsage;
-
- /*
- * location of the delegated subnet usage
- */
- @JsonProperty(value = "location", access = JsonProperty.Access.WRITE_ONLY)
- private String location;
-
- /*
- * subscriptionId of the delegated subnet usage
- */
- @JsonProperty(value = "subscriptionId", access = JsonProperty.Access.WRITE_ONLY)
- private String subscriptionId;
-
- /** Creates an instance of VirtualNetworkSubnetUsageResultInner class. */
- public VirtualNetworkSubnetUsageResultInner() {
- }
-
- /**
- * Get the delegatedSubnetsUsage property: The delegatedSubnetsUsage property.
- *
- * @return the delegatedSubnetsUsage value.
- */
- public List delegatedSubnetsUsage() {
- return this.delegatedSubnetsUsage;
- }
-
- /**
- * Get the location property: location of the delegated subnet usage.
- *
- * @return the location value.
- */
- public String location() {
- return this.location;
- }
-
- /**
- * Get the subscriptionId property: subscriptionId of the delegated subnet usage.
- *
- * @return the subscriptionId value.
- */
- public String subscriptionId() {
- return this.subscriptionId;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (delegatedSubnetsUsage() != null) {
- delegatedSubnetsUsage().forEach(e -> e.validate());
- }
- }
-}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ActiveDirectoryAdministratorImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ActiveDirectoryAdministratorImpl.java
deleted file mode 100644
index 141c17ba4dd81..0000000000000
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ActiveDirectoryAdministratorImpl.java
+++ /dev/null
@@ -1,141 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.postgresqlflexibleserver.implementation;
-
-import com.azure.core.management.SystemData;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ActiveDirectoryAdministratorInner;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.ActiveDirectoryAdministrator;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.ActiveDirectoryAdministratorAdd;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.PrincipalType;
-
-public final class ActiveDirectoryAdministratorImpl
- implements ActiveDirectoryAdministrator, ActiveDirectoryAdministrator.Definition {
- private ActiveDirectoryAdministratorInner innerObject;
-
- private final com.azure.resourcemanager.postgresqlflexibleserver.PostgreSqlManager serviceManager;
-
- ActiveDirectoryAdministratorImpl(
- ActiveDirectoryAdministratorInner innerObject,
- com.azure.resourcemanager.postgresqlflexibleserver.PostgreSqlManager serviceManager) {
- this.innerObject = innerObject;
- this.serviceManager = serviceManager;
- }
-
- public String id() {
- return this.innerModel().id();
- }
-
- public String name() {
- return this.innerModel().name();
- }
-
- public String type() {
- return this.innerModel().type();
- }
-
- public SystemData systemData() {
- return this.innerModel().systemData();
- }
-
- public PrincipalType principalType() {
- return this.innerModel().principalType();
- }
-
- public String principalName() {
- return this.innerModel().principalName();
- }
-
- public String objectId() {
- return this.innerModel().objectId();
- }
-
- public String tenantId() {
- return this.innerModel().tenantId();
- }
-
- public ActiveDirectoryAdministratorInner innerModel() {
- return this.innerObject;
- }
-
- private com.azure.resourcemanager.postgresqlflexibleserver.PostgreSqlManager manager() {
- return this.serviceManager;
- }
-
- private String resourceGroupName;
-
- private String serverName;
-
- private String objectId;
-
- private ActiveDirectoryAdministratorAdd createParameters;
-
- public ActiveDirectoryAdministratorImpl withExistingFlexibleServer(String resourceGroupName, String serverName) {
- this.resourceGroupName = resourceGroupName;
- this.serverName = serverName;
- return this;
- }
-
- public ActiveDirectoryAdministrator create() {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getAdministrators()
- .create(resourceGroupName, serverName, objectId, createParameters, Context.NONE);
- return this;
- }
-
- public ActiveDirectoryAdministrator create(Context context) {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getAdministrators()
- .create(resourceGroupName, serverName, objectId, createParameters, context);
- return this;
- }
-
- ActiveDirectoryAdministratorImpl(
- String name, com.azure.resourcemanager.postgresqlflexibleserver.PostgreSqlManager serviceManager) {
- this.innerObject = new ActiveDirectoryAdministratorInner();
- this.serviceManager = serviceManager;
- this.objectId = name;
- this.createParameters = new ActiveDirectoryAdministratorAdd();
- }
-
- public ActiveDirectoryAdministrator refresh() {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getAdministrators()
- .getWithResponse(resourceGroupName, serverName, objectId, Context.NONE)
- .getValue();
- return this;
- }
-
- public ActiveDirectoryAdministrator refresh(Context context) {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getAdministrators()
- .getWithResponse(resourceGroupName, serverName, objectId, context)
- .getValue();
- return this;
- }
-
- public ActiveDirectoryAdministratorImpl withPrincipalType(PrincipalType principalType) {
- this.createParameters.withPrincipalType(principalType);
- return this;
- }
-
- public ActiveDirectoryAdministratorImpl withPrincipalName(String principalName) {
- this.createParameters.withPrincipalName(principalName);
- return this;
- }
-
- public ActiveDirectoryAdministratorImpl withTenantId(String tenantId) {
- this.createParameters.withTenantId(tenantId);
- return this;
- }
-}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CapabilityPropertiesImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CapabilityPropertiesImpl.java
deleted file mode 100644
index 4698faa775da3..0000000000000
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CapabilityPropertiesImpl.java
+++ /dev/null
@@ -1,94 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.postgresqlflexibleserver.implementation;
-
-import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.CapabilityPropertiesInner;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.CapabilityProperties;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.FastProvisioningEditionCapability;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.FlexibleServerEditionCapability;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.HyperscaleNodeEditionCapability;
-import java.util.Collections;
-import java.util.List;
-
-public final class CapabilityPropertiesImpl implements CapabilityProperties {
- private CapabilityPropertiesInner innerObject;
-
- private final com.azure.resourcemanager.postgresqlflexibleserver.PostgreSqlManager serviceManager;
-
- CapabilityPropertiesImpl(
- CapabilityPropertiesInner innerObject,
- com.azure.resourcemanager.postgresqlflexibleserver.PostgreSqlManager serviceManager) {
- this.innerObject = innerObject;
- this.serviceManager = serviceManager;
- }
-
- public String zone() {
- return this.innerModel().zone();
- }
-
- public List supportedHAMode() {
- List inner = this.innerModel().supportedHAMode();
- if (inner != null) {
- return Collections.unmodifiableList(inner);
- } else {
- return Collections.emptyList();
- }
- }
-
- public Boolean geoBackupSupported() {
- return this.innerModel().geoBackupSupported();
- }
-
- public Boolean zoneRedundantHaSupported() {
- return this.innerModel().zoneRedundantHaSupported();
- }
-
- public Boolean zoneRedundantHaAndGeoBackupSupported() {
- return this.innerModel().zoneRedundantHaAndGeoBackupSupported();
- }
-
- public List supportedFlexibleServerEditions() {
- List inner = this.innerModel().supportedFlexibleServerEditions();
- if (inner != null) {
- return Collections.unmodifiableList(inner);
- } else {
- return Collections.emptyList();
- }
- }
-
- public List supportedHyperscaleNodeEditions() {
- List inner = this.innerModel().supportedHyperscaleNodeEditions();
- if (inner != null) {
- return Collections.unmodifiableList(inner);
- } else {
- return Collections.emptyList();
- }
- }
-
- public Boolean fastProvisioningSupported() {
- return this.innerModel().fastProvisioningSupported();
- }
-
- public List supportedFastProvisioningEditions() {
- List inner = this.innerModel().supportedFastProvisioningEditions();
- if (inner != null) {
- return Collections.unmodifiableList(inner);
- } else {
- return Collections.emptyList();
- }
- }
-
- public String status() {
- return this.innerModel().status();
- }
-
- public CapabilityPropertiesInner innerModel() {
- return this.innerObject;
- }
-
- private com.azure.resourcemanager.postgresqlflexibleserver.PostgreSqlManager manager() {
- return this.serviceManager;
- }
-}
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..fd02df45d8ccc 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
@@ -24,7 +24,7 @@
import com.azure.core.util.FluxUtil;
import com.azure.resourcemanager.postgresqlflexibleserver.fluent.CheckNameAvailabilitiesClient;
import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.NameAvailabilityInner;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.CheckNameAvailabilityRequest;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.NameAvailabilityRequest;
import reactor.core.publisher.Mono;
/** An instance of this class provides access to all the operations defined in CheckNameAvailabilitiesClient. */
@@ -62,7 +62,7 @@ Mono> execute(
@HostParam("$host") String endpoint,
@QueryParam("api-version") String apiVersion,
@PathParam("subscriptionId") String subscriptionId,
- @BodyParam("application/json") CheckNameAvailabilityRequest nameAvailabilityRequest,
+ @BodyParam("application/json") NameAvailabilityRequest nameAvailabilityRequest,
@HeaderParam("Accept") String accept,
Context context);
}
@@ -79,7 +79,7 @@ Mono> execute(
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono> executeWithResponseAsync(
- CheckNameAvailabilityRequest nameAvailabilityRequest) {
+ NameAvailabilityRequest nameAvailabilityRequest) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -99,6 +99,7 @@ private Mono> executeWithResponseAsync(
} else {
nameAvailabilityRequest.validate();
}
+ final String apiVersion = "2017-12-01";
final String accept = "application/json";
return FluxUtil
.withContext(
@@ -106,7 +107,7 @@ private Mono> executeWithResponseAsync(
service
.execute(
this.client.getEndpoint(),
- this.client.getApiVersion(),
+ apiVersion,
this.client.getSubscriptionId(),
nameAvailabilityRequest,
accept,
@@ -127,7 +128,7 @@ private Mono> executeWithResponseAsync(
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono> executeWithResponseAsync(
- CheckNameAvailabilityRequest nameAvailabilityRequest, Context context) {
+ NameAvailabilityRequest nameAvailabilityRequest, Context context) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -147,12 +148,13 @@ private Mono> executeWithResponseAsync(
} else {
nameAvailabilityRequest.validate();
}
+ final String apiVersion = "2017-12-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service
.execute(
this.client.getEndpoint(),
- this.client.getApiVersion(),
+ apiVersion,
this.client.getSubscriptionId(),
nameAvailabilityRequest,
accept,
@@ -169,7 +171,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) {
+ private Mono executeAsync(NameAvailabilityRequest nameAvailabilityRequest) {
return executeWithResponseAsync(nameAvailabilityRequest).flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
@@ -185,7 +187,7 @@ private Mono executeAsync(CheckNameAvailabilityRequest na
*/
@ServiceMethod(returns = ReturnType.SINGLE)
public Response executeWithResponse(
- CheckNameAvailabilityRequest nameAvailabilityRequest, Context context) {
+ NameAvailabilityRequest nameAvailabilityRequest, Context context) {
return executeWithResponseAsync(nameAvailabilityRequest, context).block();
}
@@ -199,7 +201,7 @@ public Response executeWithResponse(
* @return represents a resource name availability.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public NameAvailabilityInner execute(CheckNameAvailabilityRequest nameAvailabilityRequest) {
+ public NameAvailabilityInner execute(NameAvailabilityRequest nameAvailabilityRequest) {
return executeWithResponse(nameAvailabilityRequest, Context.NONE).getValue();
}
}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CheckNameAvailabilitiesImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CheckNameAvailabilitiesImpl.java
index 76c56db96d314..7cb164f9b7bcb 100644
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CheckNameAvailabilitiesImpl.java
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/CheckNameAvailabilitiesImpl.java
@@ -11,8 +11,8 @@
import com.azure.resourcemanager.postgresqlflexibleserver.fluent.CheckNameAvailabilitiesClient;
import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.NameAvailabilityInner;
import com.azure.resourcemanager.postgresqlflexibleserver.models.CheckNameAvailabilities;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.CheckNameAvailabilityRequest;
import com.azure.resourcemanager.postgresqlflexibleserver.models.NameAvailability;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.NameAvailabilityRequest;
public final class CheckNameAvailabilitiesImpl implements CheckNameAvailabilities {
private static final ClientLogger LOGGER = new ClientLogger(CheckNameAvailabilitiesImpl.class);
@@ -29,7 +29,7 @@ public CheckNameAvailabilitiesImpl(
}
public Response executeWithResponse(
- CheckNameAvailabilityRequest nameAvailabilityRequest, Context context) {
+ NameAvailabilityRequest nameAvailabilityRequest, Context context) {
Response inner =
this.serviceClient().executeWithResponse(nameAvailabilityRequest, context);
if (inner != null) {
@@ -43,7 +43,7 @@ public Response executeWithResponse(
}
}
- public NameAvailability execute(CheckNameAvailabilityRequest nameAvailabilityRequest) {
+ public NameAvailability execute(NameAvailabilityRequest nameAvailabilityRequest) {
NameAvailabilityInner inner = this.serviceClient().execute(nameAvailabilityRequest);
if (inner != null) {
return new NameAvailabilityImpl(inner, this.manager());
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ConfigurationImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ConfigurationImpl.java
index 3a485a380f8c0..47c60c4317951 100644
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ConfigurationImpl.java
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ConfigurationImpl.java
@@ -4,12 +4,9 @@
package com.azure.resourcemanager.postgresqlflexibleserver.implementation;
-import com.azure.core.management.SystemData;
import com.azure.core.util.Context;
import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ConfigurationInner;
import com.azure.resourcemanager.postgresqlflexibleserver.models.Configuration;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.ConfigurationDataType;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.ConfigurationForUpdate;
public final class ConfigurationImpl implements Configuration, Configuration.Definition, Configuration.Update {
private ConfigurationInner innerObject;
@@ -28,10 +25,6 @@ public String type() {
return this.innerModel().type();
}
- public SystemData systemData() {
- return this.innerModel().systemData();
- }
-
public String value() {
return this.innerModel().value();
}
@@ -44,7 +37,7 @@ public String defaultValue() {
return this.innerModel().defaultValue();
}
- public ConfigurationDataType dataType() {
+ public String dataType() {
return this.innerModel().dataType();
}
@@ -56,26 +49,6 @@ public String source() {
return this.innerModel().source();
}
- public Boolean isDynamicConfig() {
- return this.innerModel().isDynamicConfig();
- }
-
- public Boolean isReadOnly() {
- return this.innerModel().isReadOnly();
- }
-
- public Boolean isConfigPendingRestart() {
- return this.innerModel().isConfigPendingRestart();
- }
-
- public String unit() {
- return this.innerModel().unit();
- }
-
- public String documentationLink() {
- return this.innerModel().documentationLink();
- }
-
public String resourceGroupName() {
return resourceGroupName;
}
@@ -94,9 +67,7 @@ private com.azure.resourcemanager.postgresqlflexibleserver.PostgreSqlManager man
private String configurationName;
- private ConfigurationForUpdate updateParameters;
-
- public ConfigurationImpl withExistingFlexibleServer(String resourceGroupName, String serverName) {
+ public ConfigurationImpl withExistingServer(String resourceGroupName, String serverName) {
this.resourceGroupName = resourceGroupName;
this.serverName = serverName;
return this;
@@ -107,7 +78,7 @@ public Configuration create() {
serviceManager
.serviceClient()
.getConfigurations()
- .put(resourceGroupName, serverName, configurationName, this.innerModel(), Context.NONE);
+ .createOrUpdate(resourceGroupName, serverName, configurationName, this.innerModel(), Context.NONE);
return this;
}
@@ -116,7 +87,7 @@ public Configuration create(Context context) {
serviceManager
.serviceClient()
.getConfigurations()
- .put(resourceGroupName, serverName, configurationName, this.innerModel(), context);
+ .createOrUpdate(resourceGroupName, serverName, configurationName, this.innerModel(), context);
return this;
}
@@ -128,7 +99,6 @@ public Configuration create(Context context) {
}
public ConfigurationImpl update() {
- this.updateParameters = new ConfigurationForUpdate();
return this;
}
@@ -137,7 +107,7 @@ public Configuration apply() {
serviceManager
.serviceClient()
.getConfigurations()
- .update(resourceGroupName, serverName, configurationName, updateParameters, Context.NONE);
+ .createOrUpdate(resourceGroupName, serverName, configurationName, this.innerModel(), Context.NONE);
return this;
}
@@ -146,7 +116,7 @@ public Configuration apply(Context context) {
serviceManager
.serviceClient()
.getConfigurations()
- .update(resourceGroupName, serverName, configurationName, updateParameters, context);
+ .createOrUpdate(resourceGroupName, serverName, configurationName, this.innerModel(), context);
return this;
}
@@ -156,7 +126,7 @@ public Configuration apply(Context context) {
this.innerObject = innerObject;
this.serviceManager = serviceManager;
this.resourceGroupName = Utils.getValueFromIdByName(innerObject.id(), "resourceGroups");
- this.serverName = Utils.getValueFromIdByName(innerObject.id(), "flexibleServers");
+ this.serverName = Utils.getValueFromIdByName(innerObject.id(), "servers");
this.configurationName = Utils.getValueFromIdByName(innerObject.id(), "configurations");
}
@@ -181,26 +151,12 @@ public Configuration refresh(Context context) {
}
public ConfigurationImpl withValue(String value) {
- if (isInCreateMode()) {
- this.innerModel().withValue(value);
- return this;
- } else {
- this.updateParameters.withValue(value);
- return this;
- }
+ this.innerModel().withValue(value);
+ return this;
}
public ConfigurationImpl withSource(String source) {
- if (isInCreateMode()) {
- this.innerModel().withSource(source);
- return this;
- } else {
- this.updateParameters.withSource(source);
- return this;
- }
- }
-
- private boolean isInCreateMode() {
- return this.innerModel().id() == null;
+ this.innerModel().withSource(source);
+ return this;
}
}
diff --git a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/VirtualNetworkSubnetUsageResultImpl.java b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ConfigurationListResultImpl.java
similarity index 55%
rename from sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/VirtualNetworkSubnetUsageResultImpl.java
rename to sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ConfigurationListResultImpl.java
index 6f381d3f16735..732b8eb6a1b12 100644
--- a/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/VirtualNetworkSubnetUsageResultImpl.java
+++ b/sdk/postgresqlflexibleserver/azure-resourcemanager-postgresqlflexibleserver/src/main/java/com/azure/resourcemanager/postgresqlflexibleserver/implementation/ConfigurationListResultImpl.java
@@ -4,42 +4,41 @@
package com.azure.resourcemanager.postgresqlflexibleserver.implementation;
-import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.VirtualNetworkSubnetUsageResultInner;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.DelegatedSubnetUsage;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.VirtualNetworkSubnetUsageResult;
+import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ConfigurationInner;
+import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ConfigurationListResultInner;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.Configuration;
+import com.azure.resourcemanager.postgresqlflexibleserver.models.ConfigurationListResult;
import java.util.Collections;
import java.util.List;
+import java.util.stream.Collectors;
-public final class VirtualNetworkSubnetUsageResultImpl implements VirtualNetworkSubnetUsageResult {
- private VirtualNetworkSubnetUsageResultInner innerObject;
+public final class ConfigurationListResultImpl implements ConfigurationListResult {
+ private ConfigurationListResultInner innerObject;
private final com.azure.resourcemanager.postgresqlflexibleserver.PostgreSqlManager serviceManager;
- VirtualNetworkSubnetUsageResultImpl(
- VirtualNetworkSubnetUsageResultInner innerObject,
+ ConfigurationListResultImpl(
+ ConfigurationListResultInner innerObject,
com.azure.resourcemanager.postgresqlflexibleserver.PostgreSqlManager serviceManager) {
this.innerObject = innerObject;
this.serviceManager = serviceManager;
}
- public List delegatedSubnetsUsage() {
- List inner = this.innerModel().delegatedSubnetsUsage();
+ public List value() {
+ List inner = this.innerModel().value();
if (inner != null) {
- return Collections.unmodifiableList(inner);
+ return Collections
+ .unmodifiableList(
+ inner
+ .stream()
+ .map(inner1 -> new ConfigurationImpl(inner1, this.manager()))
+ .collect(Collectors.toList()));
} else {
return Collections.emptyList();
}
}
- public String location() {
- return this.innerModel().location();
- }
-
- public String subscriptionId() {
- return this.innerModel().subscriptionId();
- }
-
- public VirtualNetworkSubnetUsageResultInner innerModel() {
+ public ConfigurationListResultInner innerModel() {
return this.innerObject;
}
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..e8d1c8d0dde12 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
@@ -11,7 +11,6 @@
import com.azure.core.annotation.Headers;
import com.azure.core.annotation.Host;
import com.azure.core.annotation.HostParam;
-import com.azure.core.annotation.Patch;
import com.azure.core.annotation.PathParam;
import com.azure.core.annotation.Put;
import com.azure.core.annotation.QueryParam;
@@ -33,8 +32,7 @@
import com.azure.core.util.polling.SyncPoller;
import com.azure.resourcemanager.postgresqlflexibleserver.fluent.ConfigurationsClient;
import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ConfigurationInner;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.ConfigurationForUpdate;
-import com.azure.resourcemanager.postgresqlflexibleserver.models.ConfigurationListResult;
+import com.azure.resourcemanager.postgresqlflexibleserver.fluent.models.ConfigurationListResultInner;
import java.nio.ByteBuffer;
import reactor.core.publisher.Flux;
import reactor.core.publisher.Mono;
@@ -66,24 +64,24 @@ public final class ConfigurationsClientImpl implements ConfigurationsClient {
@ServiceInterface(name = "PostgreSqlManagement")
public interface ConfigurationsService {
@Headers({"Content-Type: application/json"})
- @Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL"
- + "/flexibleServers/{serverName}/configurations")
- @ExpectedResponses({200})
+ @Put(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/servers/{serverName}/configurations/{configurationName}")
+ @ExpectedResponses({200, 202})
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listByServer(
+ Mono>> createOrUpdate(
@HostParam("$host") String endpoint,
@QueryParam("api-version") String apiVersion,
@PathParam("subscriptionId") String subscriptionId,
@PathParam("resourceGroupName") String resourceGroupName,
@PathParam("serverName") String serverName,
+ @PathParam("configurationName") String configurationName,
+ @BodyParam("application/json") ConfigurationInner parameters,
@HeaderParam("Accept") String accept,
Context context);
@Headers({"Content-Type: application/json"})
@Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL"
- + "/flexibleServers/{serverName}/configurations/{configurationName}")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/servers/{serverName}/configurations/{configurationName}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ManagementException.class)
Mono> get(
@@ -97,64 +95,35 @@ Mono> get(
Context context);
@Headers({"Content-Type: application/json"})
- @Patch(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL"
- + "/flexibleServers/{serverName}/configurations/{configurationName}")
- @ExpectedResponses({200, 201, 202})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono>> update(
- @HostParam("$host") String endpoint,
- @QueryParam("api-version") String apiVersion,
- @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("serverName") String serverName,
- @PathParam("configurationName") String configurationName,
- @BodyParam("application/json") ConfigurationForUpdate parameters,
- @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({"Content-Type: application/json"})
- @Put(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL"
- + "/flexibleServers/{serverName}/configurations/{configurationName}")
- @ExpectedResponses({200, 201, 202})
+ @Get(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/servers/{serverName}/configurations")
+ @ExpectedResponses({200})
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono>> put(
+ Mono> listByServer(
@HostParam("$host") String endpoint,
@QueryParam("api-version") String apiVersion,
@PathParam("subscriptionId") String subscriptionId,
@PathParam("resourceGroupName") String resourceGroupName,
@PathParam("serverName") String serverName,
- @PathParam("configurationName") String configurationName,
- @BodyParam("application/json") ConfigurationInner parameters,
- @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({"Content-Type: application/json"})
- @Get("{nextLink}")
- @ExpectedResponses({200})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listByServerNext(
- @PathParam(value = "nextLink", encoded = true) String nextLink,
- @HostParam("$host") String endpoint,
@HeaderParam("Accept") String accept,
Context context);
}
/**
- * List all the configurations in a given server.
+ * 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 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 along with {@link PagedResponse} on successful completion of {@link
- * Mono}.
+ * @return represents a Configuration along with {@link Response} on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByServerSinglePageAsync(
- String resourceGroupName, String serverName) {
+ private Mono>> createOrUpdateWithResponseAsync(
+ String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -174,46 +143,54 @@ private Mono> listByServerSinglePageAsync(
if (serverName == null) {
return Mono.error(new IllegalArgumentException("Parameter serverName is required and cannot be null."));
}
+ if (configurationName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter configurationName is required and cannot be null."));
+ }
+ if (parameters == null) {
+ return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
+ } else {
+ parameters.validate();
+ }
+ final String apiVersion = "2017-12-01";
final String accept = "application/json";
return FluxUtil
.withContext(
context ->
service
- .listByServer(
+ .createOrUpdate(
this.client.getEndpoint(),
- this.client.getApiVersion(),
+ apiVersion,
this.client.getSubscriptionId(),
resourceGroupName,
serverName,
+ configurationName,
+ parameters,
accept,
context))
- .>map(
- res ->
- new PagedResponseBase<>(
- res.getRequest(),
- res.getStatusCode(),
- res.getHeaders(),
- res.getValue().value(),
- res.getValue().nextLink(),
- null))
.contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
}
/**
- * List all the configurations in a given server.
+ * 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.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws 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 along with {@link PagedResponse} on successful completion of {@link
- * Mono}.
+ * @return represents a Configuration along with {@link Response} on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByServerSinglePageAsync(
- String resourceGroupName, String serverName, Context context) {
+ private Mono>> createOrUpdateWithResponseAsync(
+ String resourceGroupName,
+ String serverName,
+ String configurationName,
+ ConfigurationInner parameters,
+ Context context) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -233,94 +210,216 @@ private Mono> listByServerSinglePageAsync(
if (serverName == null) {
return Mono.error(new IllegalArgumentException("Parameter serverName is required and cannot be null."));
}
+ if (configurationName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter configurationName is required and cannot be null."));
+ }
+ if (parameters == null) {
+ return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
+ } else {
+ parameters.validate();
+ }
+ final String apiVersion = "2017-12-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service
- .listByServer(
+ .createOrUpdate(
this.client.getEndpoint(),
- this.client.getApiVersion(),
+ apiVersion,
this.client.getSubscriptionId(),
resourceGroupName,
serverName,
+ configurationName,
+ parameters,
accept,
- context)
- .map(
- res ->
- new PagedResponseBase<>(
- res.getRequest(),
- res.getStatusCode(),
- res.getHeaders(),
- res.getValue().value(),
- res.getValue().nextLink(),
- null));
+ context);
}
/**
- * List all the configurations in a given server.
+ * 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 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}.
+ * @return the {@link PollerFlux} for polling of represents a Configuration.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listByServerAsync(String resourceGroupName, String serverName) {
- return new PagedFlux<>(
- () -> listByServerSinglePageAsync(resourceGroupName, serverName),
- nextLink -> listByServerNextSinglePageAsync(nextLink));
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, ConfigurationInner> beginCreateOrUpdateAsync(
+ String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters) {
+ Mono>> mono =
+ createOrUpdateWithResponseAsync(resourceGroupName, serverName, configurationName, parameters);
+ return this
+ .client
+ .getLroResult(
+ mono,
+ this.client.getHttpPipeline(),
+ ConfigurationInner.class,
+ ConfigurationInner.class,
+ this.client.getContext());
}
/**
- * List all the configurations in a given server.
+ * 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.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws 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}.
+ * @return the {@link PollerFlux} for polling of represents a Configuration.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listByServerAsync(
- String resourceGroupName, String serverName, Context context) {
- return new PagedFlux<>(
- () -> listByServerSinglePageAsync(resourceGroupName, serverName, context),
- nextLink -> listByServerNextSinglePageAsync(nextLink, context));
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, ConfigurationInner> beginCreateOrUpdateAsync(
+ String resourceGroupName,
+ String serverName,
+ String configurationName,
+ ConfigurationInner parameters,
+ Context context) {
+ context = this.client.mergeContext(context);
+ Mono>> mono =
+ createOrUpdateWithResponseAsync(resourceGroupName, serverName, configurationName, parameters, context);
+ return this
+ .client
+ .getLroResult(
+ mono, this.client.getHttpPipeline(), ConfigurationInner.class, ConfigurationInner.class, context);
}
/**
- * List all the configurations in a given server.
+ * 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 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 SyncPoller} for polling of represents a Configuration.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, ConfigurationInner> beginCreateOrUpdate(
+ String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters) {
+ return this
+ .beginCreateOrUpdateAsync(resourceGroupName, serverName, configurationName, parameters)
+ .getSyncPoller();
+ }
+
+ /**
+ * 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.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws 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 PagedIterable}.
+ * @return the {@link SyncPoller} for polling of represents a Configuration.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable listByServer(String resourceGroupName, String serverName) {
- return new PagedIterable<>(listByServerAsync(resourceGroupName, serverName));
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, ConfigurationInner> beginCreateOrUpdate(
+ String resourceGroupName,
+ String serverName,
+ String configurationName,
+ ConfigurationInner parameters,
+ Context context) {
+ return this
+ .beginCreateOrUpdateAsync(resourceGroupName, serverName, configurationName, parameters, context)
+ .getSyncPoller();
}
/**
- * List all the configurations in a given server.
+ * 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 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)
+ private Mono createOrUpdateAsync(
+ String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters) {
+ return beginCreateOrUpdateAsync(resourceGroupName, serverName, configurationName, parameters)
+ .last()
+ .flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * 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.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws 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 PagedIterable}.
+ * @return represents a Configuration on successful completion of {@link Mono}.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable listByServer(
- String resourceGroupName, String serverName, Context context) {
- return new PagedIterable<>(listByServerAsync(resourceGroupName, serverName, context));
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono createOrUpdateAsync(
+ String resourceGroupName,
+ String serverName,
+ String configurationName,
+ ConfigurationInner parameters,
+ Context context) {
+ return beginCreateOrUpdateAsync(resourceGroupName, serverName, configurationName, parameters, context)
+ .last()
+ .flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * 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 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.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public ConfigurationInner createOrUpdate(
+ String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters) {
+ return createOrUpdateAsync(resourceGroupName, serverName, configurationName, parameters).block();
+ }
+
+ /**
+ * 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.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws 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.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public ConfigurationInner createOrUpdate(
+ String resourceGroupName,
+ String serverName,
+ String configurationName,
+ ConfigurationInner parameters,
+ Context context) {
+ return createOrUpdateAsync(resourceGroupName, serverName, configurationName, parameters, context).block();
}
/**
@@ -361,6 +460,7 @@ private Mono> getWithResponseAsync(
return Mono
.error(new IllegalArgumentException("Parameter configurationName is required and cannot be null."));
}
+ final String apiVersion = "2017-12-01";
final String accept = "application/json";
return FluxUtil
.withContext(
@@ -368,7 +468,7 @@ private Mono> getWithResponseAsync(
service
.get(
this.client.getEndpoint(),
- this.client.getApiVersion(),
+ apiVersion,
this.client.getSubscriptionId(),
resourceGroupName,
serverName,
@@ -417,12 +517,13 @@ private Mono> getWithResponseAsync(
return Mono
.error(new IllegalArgumentException("Parameter configurationName is required and cannot be null."));
}
+ final String apiVersion = "2017-12-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service
.get(
this.client.getEndpoint(),
- this.client.getApiVersion(),
+ apiVersion,
this.client.getSubscriptionId(),
resourceGroupName,
serverName,
@@ -483,20 +584,19 @@ public ConfigurationInner get(String resourceGroupName, String serverName, Strin
}
/**
- * Updates a configuration of a server.
+ * 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.
- * @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 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}.
+ * @return a list of server configurations along with {@link PagedResponse} on successful completion of {@link
+ * Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> updateWithResponseAsync(
- String resourceGroupName, String serverName, String configurationName, ConfigurationForUpdate parameters) {
+ private Mono> listByServerSinglePageAsync(
+ String resourceGroupName, String serverName) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -516,362 +616,42 @@ private Mono>> updateWithResponseAsync(
if (serverName == null) {
return Mono.error(new IllegalArgumentException("Parameter serverName is required and cannot be null."));
}
- if (configurationName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter configurationName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
+ final String apiVersion = "2017-12-01";
final String accept = "application/json";
return FluxUtil
.withContext(
context ->
service
- .update(
+ .listByServer(
this.client.getEndpoint(),
- this.client.getApiVersion(),
+ apiVersion,
this.client.getSubscriptionId(),
resourceGroupName,
serverName,
- configurationName,
- parameters,
- accept,
- context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * 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.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws 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)
- private Mono>> updateWithResponseAsync(
- String resourceGroupName,
- String serverName,
- String configurationName,
- ConfigurationForUpdate parameters,
- Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (serverName == null) {
- return Mono.error(new IllegalArgumentException("Parameter serverName is required and cannot be null."));
- }
- if (configurationName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter configurationName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .update(
- this.client.getEndpoint(),
- this.client.getApiVersion(),
- this.client.getSubscriptionId(),
- resourceGroupName,
- serverName,
- configurationName,
- parameters,
- accept,
- 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 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)
- private PollerFlux, ConfigurationInner> beginUpdateAsync(
- String resourceGroupName, String serverName, String configurationName, ConfigurationForUpdate parameters) {
- Mono>> mono =
- updateWithResponseAsync(resourceGroupName, serverName, configurationName, parameters);
- return this
- .client
- .getLroResult(
- mono,
- this.client.getHttpPipeline(),
- ConfigurationInner.class,
- ConfigurationInner.class,
- this.client.getContext());
- }
-
- /**
- * 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.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws 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)
- private PollerFlux, ConfigurationInner> beginUpdateAsync(
- String resourceGroupName,
- String serverName,
- String configurationName,
- ConfigurationForUpdate parameters,
- Context context) {
- context = this.client.mergeContext(context);
- Mono>> mono =
- updateWithResponseAsync(resourceGroupName, serverName, configurationName, parameters, context);
- return this
- .client
- .getLroResult(
- mono, this.client.getHttpPipeline(), ConfigurationInner.class, ConfigurationInner.class, 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 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 SyncPoller} for polling of represents a Configuration.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, ConfigurationInner> beginUpdate(
- String resourceGroupName, String serverName, String configurationName, ConfigurationForUpdate parameters) {
- return this.beginUpdateAsync(resourceGroupName, serverName, configurationName, parameters).getSyncPoller();
- }
-
- /**
- * 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.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws 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 SyncPoller} for polling of represents a Configuration.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, ConfigurationInner> beginUpdate(
- String resourceGroupName,
- String serverName,
- String configurationName,
- ConfigurationForUpdate parameters,
- Context context) {
- return this
- .beginUpdateAsync(resourceGroupName, serverName, configurationName, parameters, context)
- .getSyncPoller();
- }
-
- /**
- * 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 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)
- private Mono updateAsync(
- String resourceGroupName, String serverName, String configurationName, ConfigurationForUpdate parameters) {
- return beginUpdateAsync(resourceGroupName, serverName, configurationName, parameters)
- .last()
- .flatMap(this.client::getLroFinalResultOrError);
- }
-
- /**
- * 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.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws 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)
- private Mono updateAsync(
- String resourceGroupName,
- String serverName,
- String configurationName,
- ConfigurationForUpdate parameters,
- Context context) {
- return beginUpdateAsync(resourceGroupName, serverName, configurationName, parameters, context)
- .last()
- .flatMap(this.client::getLroFinalResultOrError);
- }
-
- /**
- * 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 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.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public ConfigurationInner update(
- String resourceGroupName, String serverName, String configurationName, ConfigurationForUpdate parameters) {
- return updateAsync(resourceGroupName, serverName, configurationName, parameters).block();
- }
-
- /**
- * 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.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws 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.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public ConfigurationInner update(
- String resourceGroupName,
- String serverName,
- String configurationName,
- ConfigurationForUpdate parameters,
- Context context) {
- return updateAsync(resourceGroupName, serverName, configurationName, parameters, context).block();
- }
-
- /**
- * 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 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)
- private Mono>> putWithResponseAsync(
- String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters) {
- if (this.client.getEndpoint() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (serverName == null) {
- return Mono.error(new IllegalArgumentException("Parameter serverName is required and cannot be null."));
- }
- if (configurationName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter configurationName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(
- context ->
- service
- .put(
- this.client.getEndpoint(),
- this.client.getApiVersion(),
- this.client.getSubscriptionId(),
- resourceGroupName,
- serverName,
- configurationName,
- parameters,
accept,
context))
+ .>map(
+ res ->
+ new PagedResponseBase<>(
+ res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(), null, null))
.contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
}
/**
- * Updates a configuration of a server.
+ * 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.
- * @param configurationName The name of the server configuration.
- * @param parameters The required parameters for updating a server configuration.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws 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}.
+ * @return a list of server configurations along with {@link PagedResponse} on successful completion of {@link
+ * Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> putWithResponseAsync(
- String resourceGroupName,
- String serverName,
- String configurationName,
- ConfigurationInner parameters,
- Context context) {
+ private Mono> listByServerSinglePageAsync(
+ String resourceGroupName, String serverName, Context context) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -891,287 +671,85 @@ private Mono>> putWithResponseAsync(
if (serverName == null) {
return Mono.error(new IllegalArgumentException("Parameter serverName is required and cannot be null."));
}
- if (configurationName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter configurationName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
+ final String apiVersion = "2017-12-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service
- .put(
+ .listByServer(
this.client.getEndpoint(),
- this.client.getApiVersion(),
+ apiVersion,
this.client.getSubscriptionId(),
resourceGroupName,
serverName,
- configurationName,
- parameters,
accept,
- 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 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)
- private PollerFlux, ConfigurationInner> beginPutAsync(
- String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters) {
- Mono>> mono =
- putWithResponseAsync(resourceGroupName, serverName, configurationName, parameters);
- return this
- .client
- .getLroResult(
- mono,
- this.client.getHttpPipeline(),
- ConfigurationInner.class,
- ConfigurationInner.class,
- this.client.getContext());
- }
-
- /**
- * 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.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws 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)
- private PollerFlux, ConfigurationInner> beginPutAsync(
- String resourceGroupName,
- String serverName,
- String configurationName,
- ConfigurationInner parameters,
- Context context) {
- context = this.client.mergeContext(context);
- Mono>> mono =
- putWithResponseAsync(resourceGroupName, serverName, configurationName, parameters, context);
- return this
- .client
- .getLroResult(
- mono, this.client.getHttpPipeline(), ConfigurationInner.class, ConfigurationInner.class, 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 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 SyncPoller} for polling of represents a Configuration.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, ConfigurationInner> beginPut(
- String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters) {
- return this.beginPutAsync(resourceGroupName, serverName, configurationName, parameters).getSyncPoller();
- }
-
- /**
- * 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.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws 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 SyncPoller} for polling of represents a Configuration.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, ConfigurationInner> beginPut(
- String resourceGroupName,
- String serverName,
- String configurationName,
- ConfigurationInner parameters,
- Context context) {
- return this
- .beginPutAsync(resourceGroupName, serverName, configurationName, parameters, context)
- .getSyncPoller();
+ context)
+ .map(
+ res ->
+ new PagedResponseBase<>(
+ res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(), null, null));
}
/**
- * Updates a configuration of a server.
+ * 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.
- * @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 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}.
+ * @return a list of server configurations as paginated response with {@link PagedFlux}.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono putAsync(
- String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters) {
- return beginPutAsync(resourceGroupName, serverName, configurationName, parameters)
- .last()
- .flatMap(this.client::getLroFinalResultOrError);
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listByServerAsync(String resourceGroupName, String serverName) {
+ return new PagedFlux<>(() -> listByServerSinglePageAsync(resourceGroupName, serverName));
}
/**
- * Updates a configuration of a server.
+ * 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.
- * @param configurationName The name of the server configuration.
- * @param parameters The required parameters for updating a server configuration.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws 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}.
+ * @return a list of server configurations as paginated response with {@link PagedFlux}.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono putAsync(
- String resourceGroupName,
- String serverName,
- String configurationName,
- ConfigurationInner parameters,
- Context context) {
- return beginPutAsync(resourceGroupName, serverName, configurationName, parameters, context)
- .last()
- .flatMap(this.client::getLroFinalResultOrError);
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listByServerAsync(
+ String resourceGroupName, String serverName, Context context) {
+ return new PagedFlux<>(() -> listByServerSinglePageAsync(resourceGroupName, serverName, context));
}
/**
- * Updates a configuration of a server.
+ * 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.
- * @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 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.
+ * @return a list of server configurations as paginated response with {@link PagedIterable}.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- public ConfigurationInner put(
- String resourceGroupName, String serverName, String configurationName, ConfigurationInner parameters) {
- return putAsync(resourceGroupName, serverName, configurationName, parameters).block();
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listByServer(String resourceGroupName, String serverName) {
+ return new PagedIterable<>(listByServerAsync(resourceGroupName, serverName));
}
/**
- * Updates a configuration of a server.
+ * 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.
- * @param configurationName The name of the server configuration.
- * @param parameters The required parameters for updating a server configuration.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws 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.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public ConfigurationInner put(
- String resourceGroupName,
- String serverName,
- String configurationName,
- ConfigurationInner parameters,
- Context context) {
- return putAsync(resourceGroupName, serverName, configurationName, parameters, context).block();
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The URL to get the next list of items
- * The nextLink parameter.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws 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 along with {@link PagedResponse} on successful completion of {@link
- * Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByServerNextSinglePageAsync(String nextLink) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.listByServerNext(nextLink, this.client.getEndpoint(), accept, context))
- .>map(
- res ->
- new PagedResponseBase<>(
- res.getRequest(),
- res.getStatusCode(),
- res.getHeaders(),
- res.getValue().value(),
- res.getValue().nextLink(),
- null))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The URL to get the next list of items
- * The nextLink parameter.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws 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 along with {@link PagedResponse} on successful completion of {@link
- * Mono}.
+ * @return a list of server configurations as paginated response with {@link PagedIterable}.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono