diff --git a/sdk/signalr/azure-resourcemanager-signalr/CHANGELOG.md b/sdk/signalr/azure-resourcemanager-signalr/CHANGELOG.md index 5f391c3d50036..8cbddbe6c9d03 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/CHANGELOG.md +++ b/sdk/signalr/azure-resourcemanager-signalr/CHANGELOG.md @@ -1,14 +1,66 @@ # Release History -## 1.0.0-beta.4 (Unreleased) +## 1.0.0-beta.4 (2022-04-11) + +- Azure Resource Manager SignalR client library for Java. This package contains Microsoft Azure SDK for SignalR Management SDK. REST API for Azure SignalR Service. Package tag package-2022-02-01. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt). ### Features Added -### Breaking Changes +* `models.CustomCertificate$DefinitionStages` was added + +* `models.CustomCertificateList` was added + +* `models.ResourceReference` was added + +* `models.CustomDomain$Definition` was added + +* `models.SignalRCustomCertificates` was added + +* `models.CustomDomain` was added + +* `models.CustomCertificate$Definition` was added + +* `models.CustomCertificate$UpdateStages` was added + +* `models.CustomDomainList` was added + +* `models.LiveTraceConfiguration` was added + +* `models.SignalRCustomDomains` was added + +* `models.CustomCertificate$Update` was added + +* `models.LiveTraceCategory` was added + +* `models.CustomDomain$Update` was added + +* `models.CustomDomain$UpdateStages` was added + +* `models.CustomDomain$DefinitionStages` was added + +* `models.CustomCertificate` was added + +#### `SignalRManager$Configurable` was modified + +* `withRetryOptions(com.azure.core.http.policy.RetryOptions)` was added + +#### `models.SignalRResource$Definition` was modified + +* `withLiveTraceConfiguration(models.LiveTraceConfiguration)` was added + +#### `models.SignalRResource` was modified + +* `liveTraceConfiguration()` was added + +#### `models.SignalRResource$Update` was modified + +* `withLiveTraceConfiguration(models.LiveTraceConfiguration)` was added -### Bugs Fixed +#### `SignalRManager` was modified -### Other Changes +* `signalRCustomDomains()` was added +* `authenticate(com.azure.core.http.HttpPipeline,com.azure.core.management.profile.AzureProfile)` was added +* `signalRCustomCertificates()` was added ## 1.0.0-beta.3 (2021-11-11) diff --git a/sdk/signalr/azure-resourcemanager-signalr/README.md b/sdk/signalr/azure-resourcemanager-signalr/README.md index d2438293701e9..7b692ce8f1dab 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/README.md +++ b/sdk/signalr/azure-resourcemanager-signalr/README.md @@ -2,7 +2,7 @@ Azure Resource Manager SignalR client library for Java. -This package contains Microsoft Azure SDK for SignalR Management SDK. REST API for Azure SignalR Service. Package tag package-2021-10-01. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt). +This package contains Microsoft Azure SDK for SignalR Management SDK. REST API for Azure SignalR Service. Package tag package-2022-02-01. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt). ## We'd love to hear your feedback @@ -32,7 +32,7 @@ Various documentation is available to help you get started com.azure.resourcemanager azure-resourcemanager-signalr - 1.0.0-beta.3 + 1.0.0-beta.4 ``` [//]: # ({x-version-update-end}) diff --git a/sdk/signalr/azure-resourcemanager-signalr/SAMPLE.md b/sdk/signalr/azure-resourcemanager-signalr/SAMPLE.md index 3b96cfc1efd10..2b5b2d29029d7 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/SAMPLE.md +++ b/sdk/signalr/azure-resourcemanager-signalr/SAMPLE.md @@ -19,6 +19,20 @@ - [Restart](#signalr_restart) - [Update](#signalr_update) +## SignalRCustomCertificates + +- [CreateOrUpdate](#signalrcustomcertificates_createorupdate) +- [Delete](#signalrcustomcertificates_delete) +- [Get](#signalrcustomcertificates_get) +- [List](#signalrcustomcertificates_list) + +## SignalRCustomDomains + +- [CreateOrUpdate](#signalrcustomdomains_createorupdate) +- [Delete](#signalrcustomdomains_delete) +- [Get](#signalrcustomdomains_get) +- [List](#signalrcustomdomains_list) + ## SignalRPrivateEndpointConnections - [Delete](#signalrprivateendpointconnections_delete) @@ -48,7 +62,7 @@ import com.azure.core.util.Context; /** Samples for Operations List. */ public final class OperationsListSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/Operations_List.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/Operations_List.json */ /** * Sample code: Operations_List. @@ -70,7 +84,7 @@ import com.azure.resourcemanager.signalr.models.NameAvailabilityParameters; /** Samples for SignalR CheckNameAvailability. */ public final class SignalRCheckNameAvailabilitySamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_CheckNameAvailability.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_CheckNameAvailability.json */ /** * Sample code: SignalR_CheckNameAvailability. @@ -95,6 +109,8 @@ public final class SignalRCheckNameAvailabilitySamples { ```java import com.azure.resourcemanager.signalr.models.AclAction; import com.azure.resourcemanager.signalr.models.FeatureFlags; +import com.azure.resourcemanager.signalr.models.LiveTraceCategory; +import com.azure.resourcemanager.signalr.models.LiveTraceConfiguration; import com.azure.resourcemanager.signalr.models.ManagedIdentity; import com.azure.resourcemanager.signalr.models.ManagedIdentitySettings; import com.azure.resourcemanager.signalr.models.ManagedIdentityType; @@ -119,7 +135,7 @@ import java.util.Map; /** Samples for SignalR CreateOrUpdate. */ public final class SignalRCreateOrUpdateSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_CreateOrUpdate.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_CreateOrUpdate.json */ /** * Sample code: SignalR_CreateOrUpdate. @@ -156,6 +172,11 @@ public final class SignalRCreateOrUpdateSamples { .withFlag(FeatureFlags.ENABLE_LIVE_TRACE) .withValue("False") .withProperties(mapOf()))) + .withLiveTraceConfiguration( + new LiveTraceConfiguration() + .withEnabled("false") + .withCategories( + Arrays.asList(new LiveTraceCategory().withName("ConnectivityLogs").withEnabled("true")))) .withCors(new SignalRCorsSettings().withAllowedOrigins(Arrays.asList("https://foo.com", "https://bar.com"))) .withUpstream( new ServerlessUpstreamSettings() @@ -209,7 +230,7 @@ import com.azure.core.util.Context; /** Samples for SignalR Delete. */ public final class SignalRDeleteSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_Delete.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_Delete.json */ /** * Sample code: SignalR_Delete. @@ -230,7 +251,7 @@ import com.azure.core.util.Context; /** Samples for SignalR GetByResourceGroup. */ public final class SignalRGetByResourceGroupSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_Get.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_Get.json */ /** * Sample code: SignalR_Get. @@ -251,7 +272,7 @@ import com.azure.core.util.Context; /** Samples for SignalR List. */ public final class SignalRListSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_ListBySubscription.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_ListBySubscription.json */ /** * Sample code: SignalR_ListBySubscription. @@ -272,7 +293,7 @@ import com.azure.core.util.Context; /** Samples for SignalR ListByResourceGroup. */ public final class SignalRListByResourceGroupSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_ListByResourceGroup.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_ListByResourceGroup.json */ /** * Sample code: SignalR_ListByResourceGroup. @@ -293,7 +314,7 @@ import com.azure.core.util.Context; /** Samples for SignalR ListKeys. */ public final class SignalRListKeysSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_ListKeys.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_ListKeys.json */ /** * Sample code: SignalR_ListKeys. @@ -314,7 +335,7 @@ import com.azure.core.util.Context; /** Samples for SignalR ListSkus. */ public final class SignalRListSkusSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_ListSkus.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_ListSkus.json */ /** * Sample code: SignalR_ListSkus. @@ -337,7 +358,7 @@ import com.azure.resourcemanager.signalr.models.RegenerateKeyParameters; /** Samples for SignalR RegenerateKey. */ public final class SignalRRegenerateKeySamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_RegenerateKey.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_RegenerateKey.json */ /** * Sample code: SignalR_RegenerateKey. @@ -364,7 +385,7 @@ import com.azure.core.util.Context; /** Samples for SignalR Restart. */ public final class SignalRRestartSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_Restart.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_Restart.json */ /** * Sample code: SignalR_Restart. @@ -383,6 +404,8 @@ public final class SignalRRestartSamples { import com.azure.core.util.Context; import com.azure.resourcemanager.signalr.models.AclAction; import com.azure.resourcemanager.signalr.models.FeatureFlags; +import com.azure.resourcemanager.signalr.models.LiveTraceCategory; +import com.azure.resourcemanager.signalr.models.LiveTraceConfiguration; import com.azure.resourcemanager.signalr.models.ManagedIdentity; import com.azure.resourcemanager.signalr.models.ManagedIdentitySettings; import com.azure.resourcemanager.signalr.models.ManagedIdentityType; @@ -407,7 +430,7 @@ import java.util.Map; /** Samples for SignalR Update. */ public final class SignalRUpdateSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_Update.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_Update.json */ /** * Sample code: SignalR_Update. @@ -445,6 +468,11 @@ public final class SignalRUpdateSamples { .withFlag(FeatureFlags.ENABLE_LIVE_TRACE) .withValue("False") .withProperties(mapOf()))) + .withLiveTraceConfiguration( + new LiveTraceConfiguration() + .withEnabled("false") + .withCategories( + Arrays.asList(new LiveTraceCategory().withName("ConnectivityLogs").withEnabled("true")))) .withCors(new SignalRCorsSettings().withAllowedOrigins(Arrays.asList("https://foo.com", "https://bar.com"))) .withUpstream( new ServerlessUpstreamSettings() @@ -490,6 +518,193 @@ public final class SignalRUpdateSamples { } ``` +### SignalRCustomCertificates_CreateOrUpdate + +```java +/** Samples for SignalRCustomCertificates CreateOrUpdate. */ +public final class SignalRCustomCertificatesCreateOrUpdateSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomCertificates_CreateOrUpdate.json + */ + /** + * Sample code: SignalRCustomCertificates_CreateOrUpdate. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomCertificatesCreateOrUpdate( + com.azure.resourcemanager.signalr.SignalRManager manager) { + manager + .signalRCustomCertificates() + .define("myCert") + .withExistingSignalR("myResourceGroup", "mySignalRService") + .withKeyVaultBaseUri("https://myvault.keyvault.azure.net/") + .withKeyVaultSecretName("mycert") + .withKeyVaultSecretVersion("bb6a44b2743f47f68dad0d6cc9756432") + .create(); + } +} +``` + +### SignalRCustomCertificates_Delete + +```java +import com.azure.core.util.Context; + +/** Samples for SignalRCustomCertificates Delete. */ +public final class SignalRCustomCertificatesDeleteSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomCertificates_Delete.json + */ + /** + * Sample code: SignalRCustomCertificates_Delete. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomCertificatesDelete(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager + .signalRCustomCertificates() + .deleteWithResponse("myResourceGroup", "mySignalRService", "myCert", Context.NONE); + } +} +``` + +### SignalRCustomCertificates_Get + +```java +import com.azure.core.util.Context; + +/** Samples for SignalRCustomCertificates Get. */ +public final class SignalRCustomCertificatesGetSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomCertificates_Get.json + */ + /** + * Sample code: SignalRCustomCertificates_Get. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomCertificatesGet(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager + .signalRCustomCertificates() + .getWithResponse("myResourceGroup", "mySignalRService", "myCert", Context.NONE); + } +} +``` + +### SignalRCustomCertificates_List + +```java +import com.azure.core.util.Context; + +/** Samples for SignalRCustomCertificates List. */ +public final class SignalRCustomCertificatesListSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomCertificates_List.json + */ + /** + * Sample code: SignalRCustomCertificates_List. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomCertificatesList(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager.signalRCustomCertificates().list("myResourceGroup", "mySignalRService", Context.NONE); + } +} +``` + +### SignalRCustomDomains_CreateOrUpdate + +```java +import com.azure.resourcemanager.signalr.models.ResourceReference; + +/** Samples for SignalRCustomDomains CreateOrUpdate. */ +public final class SignalRCustomDomainsCreateOrUpdateSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomDomains_CreateOrUpdate.json + */ + /** + * Sample code: SignalRCustomDomains_CreateOrUpdate. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomDomainsCreateOrUpdate(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager + .signalRCustomDomains() + .define("myDomain") + .withExistingSignalR("myResourceGroup", "mySignalRService") + .withDomainName("example.com") + .withCustomCertificate( + new ResourceReference() + .withId( + "/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/myResourceGroup/providers/Microsoft.SignalRService/SignalR/mySignalRService/customCertificates/myCert")) + .create(); + } +} +``` + +### SignalRCustomDomains_Delete + +```java +import com.azure.core.util.Context; + +/** Samples for SignalRCustomDomains Delete. */ +public final class SignalRCustomDomainsDeleteSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomDomains_Delete.json + */ + /** + * Sample code: SignalRCustomDomains_Delete. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomDomainsDelete(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager.signalRCustomDomains().delete("myResourceGroup", "mySignalRService", "example", Context.NONE); + } +} +``` + +### SignalRCustomDomains_Get + +```java +import com.azure.core.util.Context; + +/** Samples for SignalRCustomDomains Get. */ +public final class SignalRCustomDomainsGetSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomDomains_Get.json + */ + /** + * Sample code: SignalRCustomDomains_Get. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomDomainsGet(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager.signalRCustomDomains().getWithResponse("myResourceGroup", "mySignalRService", "example", Context.NONE); + } +} +``` + +### SignalRCustomDomains_List + +```java +import com.azure.core.util.Context; + +/** Samples for SignalRCustomDomains List. */ +public final class SignalRCustomDomainsListSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomDomains_List.json + */ + /** + * Sample code: SignalRCustomDomains_List. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomDomainsList(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager.signalRCustomDomains().list("myResourceGroup", "mySignalRService", Context.NONE); + } +} +``` + ### SignalRPrivateEndpointConnections_Delete ```java @@ -498,7 +713,7 @@ import com.azure.core.util.Context; /** Samples for SignalRPrivateEndpointConnections Delete. */ public final class SignalRPrivateEndpointConnectionsDeleteSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRPrivateEndpointConnections_Delete.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRPrivateEndpointConnections_Delete.json */ /** * Sample code: SignalRPrivateEndpointConnections_Delete. @@ -526,7 +741,7 @@ import com.azure.core.util.Context; /** Samples for SignalRPrivateEndpointConnections Get. */ public final class SignalRPrivateEndpointConnectionsGetSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRPrivateEndpointConnections_Get.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRPrivateEndpointConnections_Get.json */ /** * Sample code: SignalRPrivateEndpointConnections_Get. @@ -553,7 +768,7 @@ import com.azure.core.util.Context; /** Samples for SignalRPrivateEndpointConnections List. */ public final class SignalRPrivateEndpointConnectionsListSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRPrivateEndpointConnections_List.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRPrivateEndpointConnections_List.json */ /** * Sample code: SignalRPrivateEndpointConnections_List. @@ -578,7 +793,7 @@ import com.azure.resourcemanager.signalr.models.PrivateLinkServiceConnectionStat /** Samples for SignalRPrivateEndpointConnections Update. */ public final class SignalRPrivateEndpointConnectionsUpdateSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRPrivateEndpointConnections_Update.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRPrivateEndpointConnections_Update.json */ /** * Sample code: SignalRPrivateEndpointConnections_Update. @@ -615,7 +830,7 @@ import com.azure.core.util.Context; /** Samples for SignalRPrivateLinkResources List. */ public final class SignalRPrivateLinkResourcesListSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRPrivateLinkResources_List.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRPrivateLinkResources_List.json */ /** * Sample code: SignalRPrivateLinkResources_List. @@ -634,7 +849,7 @@ public final class SignalRPrivateLinkResourcesListSamples { /** Samples for SignalRSharedPrivateLinkResources CreateOrUpdate. */ public final class SignalRSharedPrivateLinkResourcesCreateOrUpdateSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRSharedPrivateLinkResources_CreateOrUpdate.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRSharedPrivateLinkResources_CreateOrUpdate.json */ /** * Sample code: SignalRSharedPrivateLinkResources_CreateOrUpdate. @@ -664,7 +879,7 @@ import com.azure.core.util.Context; /** Samples for SignalRSharedPrivateLinkResources Delete. */ public final class SignalRSharedPrivateLinkResourcesDeleteSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRSharedPrivateLinkResources_Delete.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRSharedPrivateLinkResources_Delete.json */ /** * Sample code: SignalRSharedPrivateLinkResources_Delete. @@ -688,7 +903,7 @@ import com.azure.core.util.Context; /** Samples for SignalRSharedPrivateLinkResources Get. */ public final class SignalRSharedPrivateLinkResourcesGetSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRSharedPrivateLinkResources_Get.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRSharedPrivateLinkResources_Get.json */ /** * Sample code: SignalRSharedPrivateLinkResources_Get. @@ -711,7 +926,7 @@ import com.azure.core.util.Context; /** Samples for SignalRSharedPrivateLinkResources List. */ public final class SignalRSharedPrivateLinkResourcesListSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRSharedPrivateLinkResources_List.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRSharedPrivateLinkResources_List.json */ /** * Sample code: SignalRSharedPrivateLinkResources_List. @@ -732,7 +947,7 @@ import com.azure.core.util.Context; /** Samples for Usages List. */ public final class UsagesListSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/Usages_List.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/Usages_List.json */ /** * Sample code: Usages_List. diff --git a/sdk/signalr/azure-resourcemanager-signalr/pom.xml b/sdk/signalr/azure-resourcemanager-signalr/pom.xml index 64c9cd8dda4f7..ea882cf6e1e91 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/pom.xml +++ b/sdk/signalr/azure-resourcemanager-signalr/pom.xml @@ -13,7 +13,7 @@ jar Microsoft Azure SDK for SignalR Management - This package contains Microsoft Azure SDK for SignalR Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. REST API for Azure SignalR Service. Package tag package-2021-10-01. + This package contains Microsoft Azure SDK for SignalR Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. REST API for Azure SignalR Service. Package tag package-2022-02-01. https://github.com/Azure/azure-sdk-for-java diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/SignalRManager.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/SignalRManager.java index ece20bd022b03..5c9b9ccd7fc53 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/SignalRManager.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/SignalRManager.java @@ -10,11 +10,13 @@ import com.azure.core.http.HttpPipelineBuilder; import com.azure.core.http.HttpPipelinePosition; import com.azure.core.http.policy.AddDatePolicy; +import com.azure.core.http.policy.AddHeadersFromContextPolicy; import com.azure.core.http.policy.HttpLogOptions; import com.azure.core.http.policy.HttpLoggingPolicy; import com.azure.core.http.policy.HttpPipelinePolicy; import com.azure.core.http.policy.HttpPolicyProviders; import com.azure.core.http.policy.RequestIdPolicy; +import com.azure.core.http.policy.RetryOptions; import com.azure.core.http.policy.RetryPolicy; import com.azure.core.http.policy.UserAgentPolicy; import com.azure.core.management.http.policy.ArmChallengeAuthenticationPolicy; @@ -23,6 +25,8 @@ import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.fluent.SignalRManagementClient; import com.azure.resourcemanager.signalr.implementation.OperationsImpl; +import com.azure.resourcemanager.signalr.implementation.SignalRCustomCertificatesImpl; +import com.azure.resourcemanager.signalr.implementation.SignalRCustomDomainsImpl; import com.azure.resourcemanager.signalr.implementation.SignalRManagementClientBuilder; import com.azure.resourcemanager.signalr.implementation.SignalRPrivateEndpointConnectionsImpl; import com.azure.resourcemanager.signalr.implementation.SignalRPrivateLinkResourcesImpl; @@ -30,6 +34,8 @@ import com.azure.resourcemanager.signalr.implementation.SignalRsImpl; import com.azure.resourcemanager.signalr.implementation.UsagesImpl; import com.azure.resourcemanager.signalr.models.Operations; +import com.azure.resourcemanager.signalr.models.SignalRCustomCertificates; +import com.azure.resourcemanager.signalr.models.SignalRCustomDomains; import com.azure.resourcemanager.signalr.models.SignalRPrivateEndpointConnections; import com.azure.resourcemanager.signalr.models.SignalRPrivateLinkResources; import com.azure.resourcemanager.signalr.models.SignalRSharedPrivateLinkResources; @@ -50,6 +56,10 @@ public final class SignalRManager { private Usages usages; + private SignalRCustomCertificates signalRCustomCertificates; + + private SignalRCustomDomains signalRCustomDomains; + private SignalRPrivateEndpointConnections signalRPrivateEndpointConnections; private SignalRPrivateLinkResources signalRPrivateLinkResources; @@ -83,6 +93,19 @@ public static SignalRManager authenticate(TokenCredential credential, AzureProfi return configure().authenticate(credential, profile); } + /** + * Creates an instance of SignalR service API entry point. + * + * @param httpPipeline the {@link HttpPipeline} configured with Azure authentication credential. + * @param profile the Azure profile for client. + * @return the SignalR service API instance. + */ + public static SignalRManager authenticate(HttpPipeline httpPipeline, AzureProfile profile) { + Objects.requireNonNull(httpPipeline, "'httpPipeline' cannot be null."); + Objects.requireNonNull(profile, "'profile' cannot be null."); + return new SignalRManager(httpPipeline, profile, null); + } + /** * Gets a Configurable instance that can be used to create SignalRManager with optional configuration. * @@ -94,13 +117,14 @@ public static Configurable configure() { /** The Configurable allowing configurations to be set. */ public static final class Configurable { - private final ClientLogger logger = new ClientLogger(Configurable.class); + private static final ClientLogger LOGGER = new ClientLogger(Configurable.class); private HttpClient httpClient; private HttpLogOptions httpLogOptions; private final List policies = new ArrayList<>(); private final List scopes = new ArrayList<>(); private RetryPolicy retryPolicy; + private RetryOptions retryOptions; private Duration defaultPollInterval; private Configurable() { @@ -161,6 +185,19 @@ public Configurable withRetryPolicy(RetryPolicy retryPolicy) { return this; } + /** + * Sets the retry options for the HTTP pipeline retry policy. + * + *

This setting has no effect, if retry policy is set via {@link #withRetryPolicy(RetryPolicy)}. + * + * @param retryOptions the retry options for the HTTP pipeline retry policy. + * @return the configurable object itself. + */ + public Configurable withRetryOptions(RetryOptions retryOptions) { + this.retryOptions = Objects.requireNonNull(retryOptions, "'retryOptions' cannot be null."); + return this; + } + /** * Sets the default poll interval, used when service does not provide "Retry-After" header. * @@ -168,9 +205,11 @@ public Configurable withRetryPolicy(RetryPolicy retryPolicy) { * @return the configurable object itself. */ public Configurable withDefaultPollInterval(Duration defaultPollInterval) { - this.defaultPollInterval = Objects.requireNonNull(defaultPollInterval, "'retryPolicy' cannot be null."); + this.defaultPollInterval = + Objects.requireNonNull(defaultPollInterval, "'defaultPollInterval' cannot be null."); if (this.defaultPollInterval.isNegative()) { - throw logger.logExceptionAsError(new IllegalArgumentException("'httpPipeline' cannot be negative")); + throw LOGGER + .logExceptionAsError(new IllegalArgumentException("'defaultPollInterval' cannot be negative")); } return this; } @@ -192,7 +231,7 @@ public SignalRManager authenticate(TokenCredential credential, AzureProfile prof .append("-") .append("com.azure.resourcemanager.signalr") .append("/") - .append("1.0.0-beta.3"); + .append("1.0.0-beta.4"); if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) { userAgentBuilder .append(" (") @@ -210,10 +249,15 @@ public SignalRManager authenticate(TokenCredential credential, AzureProfile prof scopes.add(profile.getEnvironment().getManagementEndpoint() + "/.default"); } if (retryPolicy == null) { - retryPolicy = new RetryPolicy("Retry-After", ChronoUnit.SECONDS); + if (retryOptions != null) { + retryPolicy = new RetryPolicy(retryOptions); + } else { + retryPolicy = new RetryPolicy("Retry-After", ChronoUnit.SECONDS); + } } List policies = new ArrayList<>(); policies.add(new UserAgentPolicy(userAgentBuilder.toString())); + policies.add(new AddHeadersFromContextPolicy()); policies.add(new RequestIdPolicy()); policies .addAll( @@ -268,6 +312,23 @@ public Usages usages() { return usages; } + /** @return Resource collection API of SignalRCustomCertificates. */ + public SignalRCustomCertificates signalRCustomCertificates() { + if (this.signalRCustomCertificates == null) { + this.signalRCustomCertificates = + new SignalRCustomCertificatesImpl(clientObject.getSignalRCustomCertificates(), this); + } + return signalRCustomCertificates; + } + + /** @return Resource collection API of SignalRCustomDomains. */ + public SignalRCustomDomains signalRCustomDomains() { + if (this.signalRCustomDomains == null) { + this.signalRCustomDomains = new SignalRCustomDomainsImpl(clientObject.getSignalRCustomDomains(), this); + } + return signalRCustomDomains; + } + /** @return Resource collection API of SignalRPrivateEndpointConnections. */ public SignalRPrivateEndpointConnections signalRPrivateEndpointConnections() { if (this.signalRPrivateEndpointConnections == null) { diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/OperationsClient.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/OperationsClient.java index a54c9407234de..de7d5c12fab9f 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/OperationsClient.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/OperationsClient.java @@ -17,7 +17,7 @@ public interface OperationsClient { * * @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 result of the request to list REST API operations. + * @return result of the request to list REST API operations as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(); @@ -29,7 +29,7 @@ public interface OperationsClient { * @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 result of the request to list REST API operations. + * @return result of the request to list REST API operations as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(Context context); diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRCustomCertificatesClient.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRCustomCertificatesClient.java new file mode 100644 index 0000000000000..afdd8cd9ea995 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRCustomCertificatesClient.java @@ -0,0 +1,187 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.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.signalr.fluent.models.CustomCertificateInner; + +/** An instance of this class provides access to all the operations defined in SignalRCustomCertificatesClient. */ +public interface SignalRCustomCertificatesClient { + /** + * List all custom certificates. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the 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 custom certificates list as paginated response with {@link PagedIterable}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedIterable list(String resourceGroupName, String resourceName); + + /** + * List all custom certificates. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the 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 custom certificates list as paginated response with {@link PagedIterable}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedIterable list(String resourceGroupName, String resourceName, Context context); + + /** + * Get a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 custom certificate. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + CustomCertificateInner get(String resourceGroupName, String resourceName, String certificateName); + + /** + * Get a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 custom certificate along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Response getWithResponse( + String resourceGroupName, String resourceName, String certificateName, Context context); + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 custom certificate. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + SyncPoller, CustomCertificateInner> beginCreateOrUpdate( + String resourceGroupName, String resourceName, String certificateName, CustomCertificateInner parameters); + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 custom certificate. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + SyncPoller, CustomCertificateInner> beginCreateOrUpdate( + String resourceGroupName, + String resourceName, + String certificateName, + CustomCertificateInner parameters, + Context context); + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 custom certificate. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + CustomCertificateInner createOrUpdate( + String resourceGroupName, String resourceName, String certificateName, CustomCertificateInner parameters); + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 custom certificate. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + CustomCertificateInner createOrUpdate( + String resourceGroupName, + String resourceName, + String certificateName, + CustomCertificateInner parameters, + Context context); + + /** + * Delete a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 resourceName, String certificateName); + + /** + * Delete a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Response deleteWithResponse( + String resourceGroupName, String resourceName, String certificateName, Context context); +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRCustomDomainsClient.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRCustomDomainsClient.java new file mode 100644 index 0000000000000..b1022be74850f --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRCustomDomainsClient.java @@ -0,0 +1,209 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.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.signalr.fluent.models.CustomDomainInner; + +/** An instance of this class provides access to all the operations defined in SignalRCustomDomainsClient. */ +public interface SignalRCustomDomainsClient { + /** + * List all custom domains. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the 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 custom domains list as paginated response with {@link PagedIterable}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedIterable list(String resourceGroupName, String resourceName); + + /** + * List all custom domains. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the 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 custom domains list as paginated response with {@link PagedIterable}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedIterable list(String resourceGroupName, String resourceName, Context context); + + /** + * Get a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 custom domain. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + CustomDomainInner get(String resourceGroupName, String resourceName, String name); + + /** + * Get a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 custom domain along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Response getWithResponse( + String resourceGroupName, String resourceName, String name, Context context); + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 custom domain. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + SyncPoller, CustomDomainInner> beginCreateOrUpdate( + String resourceGroupName, String resourceName, String name, CustomDomainInner parameters); + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 custom domain. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + SyncPoller, CustomDomainInner> beginCreateOrUpdate( + String resourceGroupName, String resourceName, String name, CustomDomainInner parameters, Context context); + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 custom domain. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + CustomDomainInner createOrUpdate( + String resourceGroupName, String resourceName, String name, CustomDomainInner parameters); + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 custom domain. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + CustomDomainInner createOrUpdate( + String resourceGroupName, String resourceName, String name, CustomDomainInner parameters, Context context); + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 resourceName, String name); + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 resourceName, String name, Context context); + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 resourceName, String name); + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 resourceName, String name, Context context); +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRManagementClient.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRManagementClient.java index b7e91d50f1775..2000fcc6df6be 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRManagementClient.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRManagementClient.java @@ -66,6 +66,20 @@ public interface SignalRManagementClient { */ UsagesClient getUsages(); + /** + * Gets the SignalRCustomCertificatesClient object to access its operations. + * + * @return the SignalRCustomCertificatesClient object. + */ + SignalRCustomCertificatesClient getSignalRCustomCertificates(); + + /** + * Gets the SignalRCustomDomainsClient object to access its operations. + * + * @return the SignalRCustomDomainsClient object. + */ + SignalRCustomDomainsClient getSignalRCustomDomains(); + /** * Gets the SignalRPrivateEndpointConnectionsClient object to access its operations. * diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRPrivateEndpointConnectionsClient.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRPrivateEndpointConnectionsClient.java index 6e41b9466be93..a3380552b956e 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRPrivateEndpointConnectionsClient.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRPrivateEndpointConnectionsClient.java @@ -26,7 +26,7 @@ public interface SignalRPrivateEndpointConnectionsClient { * @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 private endpoint connections. + * @return a list of private endpoint connections as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String resourceGroupName, String resourceName); @@ -41,7 +41,7 @@ public interface SignalRPrivateEndpointConnectionsClient { * @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 private endpoint connections. + * @return a list of private endpoint connections as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String resourceGroupName, String resourceName, Context context); @@ -73,7 +73,7 @@ PrivateEndpointConnectionInner get( * @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 specified private endpoint connection. + * @return the specified private endpoint connection along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response getWithResponse( @@ -111,7 +111,7 @@ PrivateEndpointConnectionInner update( * @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 to an azure resource. + * @return a private endpoint connection to an azure resource along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response updateWithResponse( @@ -131,7 +131,7 @@ Response updateWithResponse( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginDelete( @@ -148,7 +148,7 @@ SyncPoller, Void> beginDelete( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginDelete( diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRPrivateLinkResourcesClient.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRPrivateLinkResourcesClient.java index 2498aacd9f08e..cf37f7046317e 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRPrivateLinkResourcesClient.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRPrivateLinkResourcesClient.java @@ -21,7 +21,8 @@ public interface SignalRPrivateLinkResourcesClient { * @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 private link resources that need to be created for a resource. + * @return the private link resources that need to be created for a resource as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String resourceGroupName, String resourceName); @@ -36,7 +37,8 @@ public interface SignalRPrivateLinkResourcesClient { * @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 private link resources that need to be created for a resource. + * @return the private link resources that need to be created for a resource as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String resourceGroupName, String resourceName, Context context); diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRSharedPrivateLinkResourcesClient.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRSharedPrivateLinkResourcesClient.java index 1ba24dbe00c15..5302ecd373b5b 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRSharedPrivateLinkResourcesClient.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRSharedPrivateLinkResourcesClient.java @@ -26,7 +26,7 @@ public interface SignalRSharedPrivateLinkResourcesClient { * @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 shared private link resources. + * @return a list of shared private link resources as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String resourceGroupName, String resourceName); @@ -41,7 +41,7 @@ public interface SignalRSharedPrivateLinkResourcesClient { * @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 shared private link resources. + * @return a list of shared private link resources as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String resourceGroupName, String resourceName, Context context); @@ -73,7 +73,7 @@ SharedPrivateLinkResourceInner get( * @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 specified shared private link resource. + * @return the specified shared private link resource along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response getWithResponse( @@ -90,7 +90,7 @@ 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 describes a Shared Private Link Resource. + * @return the {@link SyncPoller} for polling of describes a Shared Private Link Resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, SharedPrivateLinkResourceInner> beginCreateOrUpdate( @@ -111,7 +111,7 @@ SyncPoller, SharedPrivateLinkResource * @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 describes a Shared Private Link Resource. + * @return the {@link SyncPoller} for polling of describes a Shared Private Link Resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, SharedPrivateLinkResourceInner> beginCreateOrUpdate( @@ -173,7 +173,7 @@ SharedPrivateLinkResourceInner createOrUpdate( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginDelete( @@ -190,7 +190,7 @@ SyncPoller, Void> beginDelete( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginDelete( diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRsClient.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRsClient.java index f268fec36e7e0..e5a66ddef57c1 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRsClient.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/SignalRsClient.java @@ -42,7 +42,7 @@ public interface SignalRsClient { * @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 result of the request to check name availability. + * @return result of the request to check name availability along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response checkNameAvailabilityWithResponse( @@ -53,7 +53,8 @@ Response checkNameAvailabilityWithResponse( * * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(); @@ -65,7 +66,8 @@ Response checkNameAvailabilityWithResponse( * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(Context context); @@ -78,7 +80,8 @@ Response checkNameAvailabilityWithResponse( * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable listByResourceGroup(String resourceGroupName); @@ -92,7 +95,8 @@ Response checkNameAvailabilityWithResponse( * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable listByResourceGroup(String resourceGroupName, Context context); @@ -121,7 +125,7 @@ Response checkNameAvailabilityWithResponse( * @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 resource and its properties. + * @return the resource and its properties along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response getByResourceGroupWithResponse( @@ -137,7 +141,7 @@ Response getByResourceGroupWithResponse( * @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 class represent a resource. + * @return the {@link SyncPoller} for polling of a class represent a resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, SignalRResourceInner> beginCreateOrUpdate( @@ -154,7 +158,7 @@ SyncPoller, SignalRResourceInner> beginCreateOr * @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 class represent a resource. + * @return the {@link SyncPoller} for polling of a class represent a resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, SignalRResourceInner> beginCreateOrUpdate( @@ -201,7 +205,7 @@ SignalRResourceInner createOrUpdate( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginDelete(String resourceGroupName, String resourceName); @@ -216,7 +220,7 @@ SignalRResourceInner createOrUpdate( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginDelete(String resourceGroupName, String resourceName, Context context); @@ -258,7 +262,7 @@ SignalRResourceInner createOrUpdate( * @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 class represent a resource. + * @return the {@link SyncPoller} for polling of a class represent a resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, SignalRResourceInner> beginUpdate( @@ -275,7 +279,7 @@ SyncPoller, SignalRResourceInner> beginUpdate( * @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 class represent a resource. + * @return the {@link SyncPoller} for polling of a class represent a resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, SignalRResourceInner> beginUpdate( @@ -337,7 +341,7 @@ SignalRResourceInner update( * @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 access keys of the resource. + * @return the access keys of the resource along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response listKeysWithResponse(String resourceGroupName, String resourceName, Context context); @@ -352,7 +356,7 @@ SignalRResourceInner update( * @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 class represents the access keys of the resource. + * @return the {@link SyncPoller} for polling of a class represents the access keys of the resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, SignalRKeysInner> beginRegenerateKey( @@ -369,7 +373,7 @@ SyncPoller, SignalRKeysInner> beginRegenerateKey( * @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 class represents the access keys of the resource. + * @return the {@link SyncPoller} for polling of a class represents the access keys of the resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, SignalRKeysInner> beginRegenerateKey( @@ -416,7 +420,7 @@ SignalRKeysInner regenerateKey( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginRestart(String resourceGroupName, String resourceName); @@ -431,7 +435,7 @@ SignalRKeysInner regenerateKey( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginRestart(String resourceGroupName, String resourceName, Context context); @@ -487,7 +491,7 @@ SignalRKeysInner regenerateKey( * @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 list skus operation response. + * @return the list skus operation response along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response listSkusWithResponse(String resourceGroupName, String resourceName, Context context); diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/UsagesClient.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/UsagesClient.java index 99667f1848832..a336c0857d109 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/UsagesClient.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/UsagesClient.java @@ -19,7 +19,8 @@ public interface UsagesClient { * @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 object that includes an array of the resource usages and a possible link for next set. + * @return object that includes an array of the resource usages and a possible link for next set as paginated + * response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String location); @@ -32,7 +33,8 @@ public interface UsagesClient { * @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 object that includes an array of the resource usages and a possible link for next set. + * @return object that includes an array of the resource usages and a possible link for next set as paginated + * response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String location, Context context); diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/CustomCertificateInner.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/CustomCertificateInner.java new file mode 100644 index 0000000000000..1b6df55f635fb --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/CustomCertificateInner.java @@ -0,0 +1,142 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.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.signalr.models.ProvisioningState; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** A custom certificate. */ +@Fluent +public final class CustomCertificateInner extends ProxyResource { + /* + * Metadata pertaining to creation and last modification of the resource. + */ + @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY) + private SystemData systemData; + + /* + * Custom certificate properties. + */ + @JsonProperty(value = "properties", required = true) + private CustomCertificateProperties innerProperties = new CustomCertificateProperties(); + + /** + * Get the systemData property: Metadata pertaining to creation and last modification of the resource. + * + * @return the systemData value. + */ + public SystemData systemData() { + return this.systemData; + } + + /** + * Get the innerProperties property: Custom certificate properties. + * + * @return the innerProperties value. + */ + private CustomCertificateProperties innerProperties() { + return this.innerProperties; + } + + /** + * Get the provisioningState property: Provisioning state of the resource. + * + * @return the provisioningState value. + */ + public ProvisioningState provisioningState() { + return this.innerProperties() == null ? null : this.innerProperties().provisioningState(); + } + + /** + * Get the keyVaultBaseUri property: Base uri of the KeyVault that stores certificate. + * + * @return the keyVaultBaseUri value. + */ + public String keyVaultBaseUri() { + return this.innerProperties() == null ? null : this.innerProperties().keyVaultBaseUri(); + } + + /** + * Set the keyVaultBaseUri property: Base uri of the KeyVault that stores certificate. + * + * @param keyVaultBaseUri the keyVaultBaseUri value to set. + * @return the CustomCertificateInner object itself. + */ + public CustomCertificateInner withKeyVaultBaseUri(String keyVaultBaseUri) { + if (this.innerProperties() == null) { + this.innerProperties = new CustomCertificateProperties(); + } + this.innerProperties().withKeyVaultBaseUri(keyVaultBaseUri); + return this; + } + + /** + * Get the keyVaultSecretName property: Certificate secret name. + * + * @return the keyVaultSecretName value. + */ + public String keyVaultSecretName() { + return this.innerProperties() == null ? null : this.innerProperties().keyVaultSecretName(); + } + + /** + * Set the keyVaultSecretName property: Certificate secret name. + * + * @param keyVaultSecretName the keyVaultSecretName value to set. + * @return the CustomCertificateInner object itself. + */ + public CustomCertificateInner withKeyVaultSecretName(String keyVaultSecretName) { + if (this.innerProperties() == null) { + this.innerProperties = new CustomCertificateProperties(); + } + this.innerProperties().withKeyVaultSecretName(keyVaultSecretName); + return this; + } + + /** + * Get the keyVaultSecretVersion property: Certificate secret version. + * + * @return the keyVaultSecretVersion value. + */ + public String keyVaultSecretVersion() { + return this.innerProperties() == null ? null : this.innerProperties().keyVaultSecretVersion(); + } + + /** + * Set the keyVaultSecretVersion property: Certificate secret version. + * + * @param keyVaultSecretVersion the keyVaultSecretVersion value to set. + * @return the CustomCertificateInner object itself. + */ + public CustomCertificateInner withKeyVaultSecretVersion(String keyVaultSecretVersion) { + if (this.innerProperties() == null) { + this.innerProperties = new CustomCertificateProperties(); + } + this.innerProperties().withKeyVaultSecretVersion(keyVaultSecretVersion); + 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 CustomCertificateInner")); + } else { + innerProperties().validate(); + } + } + + private static final ClientLogger LOGGER = new ClientLogger(CustomCertificateInner.class); +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/CustomCertificateProperties.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/CustomCertificateProperties.java new file mode 100644 index 0000000000000..1c27232c5661e --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/CustomCertificateProperties.java @@ -0,0 +1,129 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.util.logging.ClientLogger; +import com.azure.resourcemanager.signalr.models.ProvisioningState; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Custom certificate properties. */ +@Fluent +public final class CustomCertificateProperties { + /* + * Provisioning state of the resource. + */ + @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY) + private ProvisioningState provisioningState; + + /* + * Base uri of the KeyVault that stores certificate. + */ + @JsonProperty(value = "keyVaultBaseUri", required = true) + private String keyVaultBaseUri; + + /* + * Certificate secret name. + */ + @JsonProperty(value = "keyVaultSecretName", required = true) + private String keyVaultSecretName; + + /* + * Certificate secret version. + */ + @JsonProperty(value = "keyVaultSecretVersion") + private String keyVaultSecretVersion; + + /** + * Get the provisioningState property: Provisioning state of the resource. + * + * @return the provisioningState value. + */ + public ProvisioningState provisioningState() { + return this.provisioningState; + } + + /** + * Get the keyVaultBaseUri property: Base uri of the KeyVault that stores certificate. + * + * @return the keyVaultBaseUri value. + */ + public String keyVaultBaseUri() { + return this.keyVaultBaseUri; + } + + /** + * Set the keyVaultBaseUri property: Base uri of the KeyVault that stores certificate. + * + * @param keyVaultBaseUri the keyVaultBaseUri value to set. + * @return the CustomCertificateProperties object itself. + */ + public CustomCertificateProperties withKeyVaultBaseUri(String keyVaultBaseUri) { + this.keyVaultBaseUri = keyVaultBaseUri; + return this; + } + + /** + * Get the keyVaultSecretName property: Certificate secret name. + * + * @return the keyVaultSecretName value. + */ + public String keyVaultSecretName() { + return this.keyVaultSecretName; + } + + /** + * Set the keyVaultSecretName property: Certificate secret name. + * + * @param keyVaultSecretName the keyVaultSecretName value to set. + * @return the CustomCertificateProperties object itself. + */ + public CustomCertificateProperties withKeyVaultSecretName(String keyVaultSecretName) { + this.keyVaultSecretName = keyVaultSecretName; + return this; + } + + /** + * Get the keyVaultSecretVersion property: Certificate secret version. + * + * @return the keyVaultSecretVersion value. + */ + public String keyVaultSecretVersion() { + return this.keyVaultSecretVersion; + } + + /** + * Set the keyVaultSecretVersion property: Certificate secret version. + * + * @param keyVaultSecretVersion the keyVaultSecretVersion value to set. + * @return the CustomCertificateProperties object itself. + */ + public CustomCertificateProperties withKeyVaultSecretVersion(String keyVaultSecretVersion) { + this.keyVaultSecretVersion = keyVaultSecretVersion; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (keyVaultBaseUri() == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + "Missing required property keyVaultBaseUri in model CustomCertificateProperties")); + } + if (keyVaultSecretName() == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + "Missing required property keyVaultSecretName in model CustomCertificateProperties")); + } + } + + private static final ClientLogger LOGGER = new ClientLogger(CustomCertificateProperties.class); +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/CustomDomainInner.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/CustomDomainInner.java new file mode 100644 index 0000000000000..bd313e5d9a0c7 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/CustomDomainInner.java @@ -0,0 +1,120 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.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.signalr.models.ProvisioningState; +import com.azure.resourcemanager.signalr.models.ResourceReference; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** A custom domain. */ +@Fluent +public final class CustomDomainInner extends ProxyResource { + /* + * Metadata pertaining to creation and last modification of the resource. + */ + @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY) + private SystemData systemData; + + /* + * Properties of a custom domain. + */ + @JsonProperty(value = "properties", required = true) + private CustomDomainProperties innerProperties = new CustomDomainProperties(); + + /** + * Get the systemData property: Metadata pertaining to creation and last modification of the resource. + * + * @return the systemData value. + */ + public SystemData systemData() { + return this.systemData; + } + + /** + * Get the innerProperties property: Properties of a custom domain. + * + * @return the innerProperties value. + */ + private CustomDomainProperties innerProperties() { + return this.innerProperties; + } + + /** + * Get the provisioningState property: Provisioning state of the resource. + * + * @return the provisioningState value. + */ + public ProvisioningState provisioningState() { + return this.innerProperties() == null ? null : this.innerProperties().provisioningState(); + } + + /** + * Get the domainName property: The custom domain name. + * + * @return the domainName value. + */ + public String domainName() { + return this.innerProperties() == null ? null : this.innerProperties().domainName(); + } + + /** + * Set the domainName property: The custom domain name. + * + * @param domainName the domainName value to set. + * @return the CustomDomainInner object itself. + */ + public CustomDomainInner withDomainName(String domainName) { + if (this.innerProperties() == null) { + this.innerProperties = new CustomDomainProperties(); + } + this.innerProperties().withDomainName(domainName); + return this; + } + + /** + * Get the customCertificate property: Reference to a resource. + * + * @return the customCertificate value. + */ + public ResourceReference customCertificate() { + return this.innerProperties() == null ? null : this.innerProperties().customCertificate(); + } + + /** + * Set the customCertificate property: Reference to a resource. + * + * @param customCertificate the customCertificate value to set. + * @return the CustomDomainInner object itself. + */ + public CustomDomainInner withCustomCertificate(ResourceReference customCertificate) { + if (this.innerProperties() == null) { + this.innerProperties = new CustomDomainProperties(); + } + this.innerProperties().withCustomCertificate(customCertificate); + 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 CustomDomainInner")); + } else { + innerProperties().validate(); + } + } + + private static final ClientLogger LOGGER = new ClientLogger(CustomDomainInner.class); +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/CustomDomainProperties.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/CustomDomainProperties.java new file mode 100644 index 0000000000000..5f531b362aa44 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/CustomDomainProperties.java @@ -0,0 +1,106 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.util.logging.ClientLogger; +import com.azure.resourcemanager.signalr.models.ProvisioningState; +import com.azure.resourcemanager.signalr.models.ResourceReference; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Properties of a custom domain. */ +@Fluent +public final class CustomDomainProperties { + /* + * Provisioning state of the resource. + */ + @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY) + private ProvisioningState provisioningState; + + /* + * The custom domain name. + */ + @JsonProperty(value = "domainName", required = true) + private String domainName; + + /* + * Reference to a resource. + */ + @JsonProperty(value = "customCertificate", required = true) + private ResourceReference customCertificate; + + /** + * Get the provisioningState property: Provisioning state of the resource. + * + * @return the provisioningState value. + */ + public ProvisioningState provisioningState() { + return this.provisioningState; + } + + /** + * Get the domainName property: The custom domain name. + * + * @return the domainName value. + */ + public String domainName() { + return this.domainName; + } + + /** + * Set the domainName property: The custom domain name. + * + * @param domainName the domainName value to set. + * @return the CustomDomainProperties object itself. + */ + public CustomDomainProperties withDomainName(String domainName) { + this.domainName = domainName; + return this; + } + + /** + * Get the customCertificate property: Reference to a resource. + * + * @return the customCertificate value. + */ + public ResourceReference customCertificate() { + return this.customCertificate; + } + + /** + * Set the customCertificate property: Reference to a resource. + * + * @param customCertificate the customCertificate value to set. + * @return the CustomDomainProperties object itself. + */ + public CustomDomainProperties withCustomCertificate(ResourceReference customCertificate) { + this.customCertificate = customCertificate; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (domainName() == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + "Missing required property domainName in model CustomDomainProperties")); + } + if (customCertificate() == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + "Missing required property customCertificate in model CustomDomainProperties")); + } else { + customCertificate().validate(); + } + } + + private static final ClientLogger LOGGER = new ClientLogger(CustomDomainProperties.class); +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/NameAvailabilityInner.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/NameAvailabilityInner.java index 9424a59deac5d..9773a9b1a098d 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/NameAvailabilityInner.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/NameAvailabilityInner.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Result of the request to check name availability. It contains a flag and possible reason of failure. */ @Fluent public final class NameAvailabilityInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(NameAvailabilityInner.class); - /* * Indicates whether the name is available or not. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/OperationInner.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/OperationInner.java index bb9370a352a60..18d525ebffe75 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/OperationInner.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/OperationInner.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.signalr.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.models.OperationDisplay; import com.azure.resourcemanager.signalr.models.OperationProperties; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** REST API operation supported by resource provider. */ @Fluent public final class OperationInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationInner.class); - /* * Name of the operation with format: {provider}/{resource}/{operation} */ @@ -29,7 +25,7 @@ public final class OperationInner { private Boolean isDataAction; /* - * The object that describes the operation. + * The object that describes a operation. */ @JsonProperty(value = "display") private OperationDisplay display; @@ -42,7 +38,7 @@ public final class OperationInner { private String origin; /* - * Extra properties for the operation. + * Extra Operation properties. */ @JsonProperty(value = "properties") private OperationProperties properties; @@ -88,7 +84,7 @@ public OperationInner withIsDataAction(Boolean isDataAction) { } /** - * Get the display property: The object that describes the operation. + * Get the display property: The object that describes a operation. * * @return the display value. */ @@ -97,7 +93,7 @@ public OperationDisplay display() { } /** - * Set the display property: The object that describes the operation. + * Set the display property: The object that describes a operation. * * @param display the display value to set. * @return the OperationInner object itself. @@ -130,7 +126,7 @@ public OperationInner withOrigin(String origin) { } /** - * Get the properties property: Extra properties for the operation. + * Get the properties property: Extra Operation properties. * * @return the properties value. */ @@ -139,7 +135,7 @@ public OperationProperties properties() { } /** - * Set the properties property: Extra properties for the operation. + * Set the properties property: Extra Operation properties. * * @param properties the properties value to set. * @return the OperationInner object itself. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateEndpointConnectionInner.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateEndpointConnectionInner.java index 0e4fe613b4540..a42ff1123058b 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateEndpointConnectionInner.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateEndpointConnectionInner.java @@ -7,19 +7,15 @@ 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.signalr.models.PrivateEndpoint; import com.azure.resourcemanager.signalr.models.PrivateLinkServiceConnectionState; import com.azure.resourcemanager.signalr.models.ProvisioningState; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** A private endpoint connection to an azure resource. */ @Fluent public final class PrivateEndpointConnectionInner extends ProxyResource { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpointConnectionInner.class); - /* * Metadata pertaining to creation and last modification of the resource. */ @@ -27,7 +23,7 @@ public final class PrivateEndpointConnectionInner extends ProxyResource { private SystemData systemData; /* - * Properties of the private endpoint connection + * Private endpoint connection properties */ @JsonProperty(value = "properties") private PrivateEndpointConnectionProperties innerProperties; @@ -42,7 +38,7 @@ public SystemData systemData() { } /** - * Get the innerProperties property: Properties of the private endpoint connection. + * Get the innerProperties property: Private endpoint connection properties. * * @return the innerProperties value. */ @@ -51,7 +47,7 @@ private PrivateEndpointConnectionProperties innerProperties() { } /** - * Get the provisioningState property: Provisioning state of the private endpoint connection. + * Get the provisioningState property: Provisioning state of the resource. * * @return the provisioningState value. */ @@ -60,7 +56,7 @@ public ProvisioningState provisioningState() { } /** - * Get the privateEndpoint property: Private endpoint associated with the private endpoint connection. + * Get the privateEndpoint property: Private endpoint. * * @return the privateEndpoint value. */ @@ -69,7 +65,7 @@ public PrivateEndpoint privateEndpoint() { } /** - * Set the privateEndpoint property: Private endpoint associated with the private endpoint connection. + * Set the privateEndpoint property: Private endpoint. * * @param privateEndpoint the privateEndpoint value to set. * @return the PrivateEndpointConnectionInner object itself. @@ -92,7 +88,7 @@ public List groupIds() { } /** - * Get the privateLinkServiceConnectionState property: Connection state. + * Get the privateLinkServiceConnectionState property: Connection state of the private endpoint connection. * * @return the privateLinkServiceConnectionState value. */ @@ -101,7 +97,7 @@ public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() { } /** - * Set the privateLinkServiceConnectionState property: Connection state. + * Set the privateLinkServiceConnectionState property: Connection state of the private endpoint connection. * * @param privateLinkServiceConnectionState the privateLinkServiceConnectionState value to set. * @return the PrivateEndpointConnectionInner object itself. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateEndpointConnectionProperties.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateEndpointConnectionProperties.java index e6909603fb5db..ca3b12f84642c 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateEndpointConnectionProperties.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateEndpointConnectionProperties.java @@ -5,27 +5,23 @@ package com.azure.resourcemanager.signalr.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.models.PrivateEndpoint; import com.azure.resourcemanager.signalr.models.PrivateLinkServiceConnectionState; import com.azure.resourcemanager.signalr.models.ProvisioningState; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Private endpoint connection properties. */ @Fluent public final class PrivateEndpointConnectionProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpointConnectionProperties.class); - /* - * Provisioning state of the private endpoint connection + * Provisioning state of the resource. */ @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY) private ProvisioningState provisioningState; /* - * Private endpoint associated with the private endpoint connection + * Private endpoint */ @JsonProperty(value = "privateEndpoint") private PrivateEndpoint privateEndpoint; @@ -37,13 +33,13 @@ public final class PrivateEndpointConnectionProperties { private List groupIds; /* - * Connection state + * Connection state of the private endpoint connection */ @JsonProperty(value = "privateLinkServiceConnectionState") private PrivateLinkServiceConnectionState privateLinkServiceConnectionState; /** - * Get the provisioningState property: Provisioning state of the private endpoint connection. + * Get the provisioningState property: Provisioning state of the resource. * * @return the provisioningState value. */ @@ -52,7 +48,7 @@ public ProvisioningState provisioningState() { } /** - * Get the privateEndpoint property: Private endpoint associated with the private endpoint connection. + * Get the privateEndpoint property: Private endpoint. * * @return the privateEndpoint value. */ @@ -61,7 +57,7 @@ public PrivateEndpoint privateEndpoint() { } /** - * Set the privateEndpoint property: Private endpoint associated with the private endpoint connection. + * Set the privateEndpoint property: Private endpoint. * * @param privateEndpoint the privateEndpoint value to set. * @return the PrivateEndpointConnectionProperties object itself. @@ -81,7 +77,7 @@ public List groupIds() { } /** - * Get the privateLinkServiceConnectionState property: Connection state. + * Get the privateLinkServiceConnectionState property: Connection state of the private endpoint connection. * * @return the privateLinkServiceConnectionState value. */ @@ -90,7 +86,7 @@ public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() { } /** - * Set the privateLinkServiceConnectionState property: Connection state. + * Set the privateLinkServiceConnectionState property: Connection state of the private endpoint connection. * * @param privateLinkServiceConnectionState the privateLinkServiceConnectionState value to set. * @return the PrivateEndpointConnectionProperties object itself. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateLinkResourceInner.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateLinkResourceInner.java index e1e61c43f7a41..12674cb4a23a9 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateLinkResourceInner.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateLinkResourceInner.java @@ -6,25 +6,21 @@ import com.azure.core.annotation.Fluent; import com.azure.core.management.ProxyResource; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.models.ShareablePrivateLinkResourceType; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Private link resource. */ @Fluent public final class PrivateLinkResourceInner extends ProxyResource { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkResourceInner.class); - /* - * Properties of a private link resource + * Private link resource properties */ @JsonProperty(value = "properties") private PrivateLinkResourceProperties innerProperties; /** - * Get the innerProperties property: Properties of a private link resource. + * Get the innerProperties property: Private link resource properties. * * @return the innerProperties value. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateLinkResourceProperties.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateLinkResourceProperties.java index 99aee6934ab40..38c64d9b28b81 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateLinkResourceProperties.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/PrivateLinkResourceProperties.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.signalr.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.models.ShareablePrivateLinkResourceType; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Private link resource properties. */ @Fluent public final class PrivateLinkResourceProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkResourceProperties.class); - /* * Group Id of the private link resource */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SharedPrivateLinkResourceInner.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SharedPrivateLinkResourceInner.java index a9aacb9710560..5ee6d95ea7e17 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SharedPrivateLinkResourceInner.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SharedPrivateLinkResourceInner.java @@ -7,17 +7,13 @@ 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.signalr.models.ProvisioningState; import com.azure.resourcemanager.signalr.models.SharedPrivateLinkResourceStatus; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Describes a Shared Private Link Resource. */ @Fluent public final class SharedPrivateLinkResourceInner extends ProxyResource { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SharedPrivateLinkResourceInner.class); - /* * Metadata pertaining to creation and last modification of the resource. */ @@ -25,7 +21,7 @@ public final class SharedPrivateLinkResourceInner extends ProxyResource { private SystemData systemData; /* - * Describes the properties of a Shared Private Link Resource + * Describes the properties of an existing Shared Private Link Resource */ @JsonProperty(value = "properties") private SharedPrivateLinkResourceProperties innerProperties; @@ -40,7 +36,7 @@ public SystemData systemData() { } /** - * Get the innerProperties property: Describes the properties of a Shared Private Link Resource. + * Get the innerProperties property: Describes the properties of an existing Shared Private Link Resource. * * @return the innerProperties value. */ @@ -95,7 +91,7 @@ public SharedPrivateLinkResourceInner withPrivateLinkResourceId(String privateLi } /** - * Get the provisioningState property: Provisioning state of the shared private link resource. + * Get the provisioningState property: Provisioning state of the resource. * * @return the provisioningState value. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SharedPrivateLinkResourceProperties.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SharedPrivateLinkResourceProperties.java index b4f70972dae8d..41c19f056d887 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SharedPrivateLinkResourceProperties.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SharedPrivateLinkResourceProperties.java @@ -8,14 +8,11 @@ import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.models.ProvisioningState; import com.azure.resourcemanager.signalr.models.SharedPrivateLinkResourceStatus; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Describes the properties of an existing Shared Private Link Resource. */ @Fluent public final class SharedPrivateLinkResourceProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SharedPrivateLinkResourceProperties.class); - /* * The group id from the provider of resource the shared private link * resource is for @@ -30,7 +27,7 @@ public final class SharedPrivateLinkResourceProperties { private String privateLinkResourceId; /* - * Provisioning state of the shared private link resource + * Provisioning state of the resource. */ @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY) private ProvisioningState provisioningState; @@ -89,7 +86,7 @@ public SharedPrivateLinkResourceProperties withPrivateLinkResourceId(String priv } /** - * Get the provisioningState property: Provisioning state of the shared private link resource. + * Get the provisioningState property: Provisioning state of the resource. * * @return the provisioningState value. */ @@ -133,17 +130,19 @@ public SharedPrivateLinkResourceStatus status() { */ public void validate() { if (groupId() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( "Missing required property groupId in model SharedPrivateLinkResourceProperties")); } if (privateLinkResourceId() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( "Missing required property privateLinkResourceId in model" + " SharedPrivateLinkResourceProperties")); } } + + private static final ClientLogger LOGGER = new ClientLogger(SharedPrivateLinkResourceProperties.class); } diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRKeysInner.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRKeysInner.java index 1eb87201f5764..b3d66b10d69ed 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRKeysInner.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRKeysInner.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** A class represents the access keys of the resource. */ @Fluent public final class SignalRKeysInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRKeysInner.class); - /* * The primary access key. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRProperties.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRProperties.java index 05e1572ddceb2..9fce8520cc845 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRProperties.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRProperties.java @@ -5,7 +5,7 @@ package com.azure.resourcemanager.signalr.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; +import com.azure.resourcemanager.signalr.models.LiveTraceConfiguration; import com.azure.resourcemanager.signalr.models.ProvisioningState; import com.azure.resourcemanager.signalr.models.ResourceLogConfiguration; import com.azure.resourcemanager.signalr.models.ServerlessUpstreamSettings; @@ -13,15 +13,12 @@ import com.azure.resourcemanager.signalr.models.SignalRFeature; import com.azure.resourcemanager.signalr.models.SignalRNetworkACLs; import com.azure.resourcemanager.signalr.models.SignalRTlsSettings; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** A class that describes the properties of the resource. */ @Fluent public final class SignalRProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRProperties.class); - /* * Provisioning state of the resource. */ @@ -74,7 +71,7 @@ public final class SignalRProperties { private List sharedPrivateLinkResources; /* - * TLS settings. + * TLS settings for the resource */ @JsonProperty(value = "tls") private SignalRTlsSettings tls; @@ -99,12 +96,14 @@ public final class SignalRProperties { @JsonProperty(value = "features") private List features; + /* + * Live trace configuration of a Microsoft.SignalRService resource. + */ + @JsonProperty(value = "liveTraceConfiguration") + private LiveTraceConfiguration liveTraceConfiguration; + /* * Resource log configuration of a Microsoft.SignalRService resource. - * If resourceLogConfiguration isn't null or empty, it will override - * options "EnableConnectivityLog" and "EnableMessagingLogs" in features. - * Otherwise, use options "EnableConnectivityLog" and "EnableMessagingLogs" - * in features. */ @JsonProperty(value = "resourceLogConfiguration") private ResourceLogConfiguration resourceLogConfiguration; @@ -116,13 +115,13 @@ public final class SignalRProperties { private SignalRCorsSettings cors; /* - * Upstream settings when the service is in server-less mode. + * The settings for the Upstream when the service is in server-less mode. */ @JsonProperty(value = "upstream") private ServerlessUpstreamSettings upstream; /* - * Network ACLs + * Network ACLs for the resource */ @JsonProperty(value = "networkACLs") private SignalRNetworkACLs networkACLs; @@ -227,7 +226,7 @@ public List sharedPrivateLinkResources() { } /** - * Get the tls property: TLS settings. + * Get the tls property: TLS settings for the resource. * * @return the tls value. */ @@ -236,7 +235,7 @@ public SignalRTlsSettings tls() { } /** - * Set the tls property: TLS settings. + * Set the tls property: TLS settings for the resource. * * @param tls the tls value to set. * @return the SignalRProperties object itself. @@ -286,10 +285,27 @@ public SignalRProperties withFeatures(List features) { } /** - * Get the resourceLogConfiguration property: Resource log configuration of a Microsoft.SignalRService resource. If - * resourceLogConfiguration isn't null or empty, it will override options "EnableConnectivityLog" and - * "EnableMessagingLogs" in features. Otherwise, use options "EnableConnectivityLog" and "EnableMessagingLogs" in - * features. + * Get the liveTraceConfiguration property: Live trace configuration of a Microsoft.SignalRService resource. + * + * @return the liveTraceConfiguration value. + */ + public LiveTraceConfiguration liveTraceConfiguration() { + return this.liveTraceConfiguration; + } + + /** + * Set the liveTraceConfiguration property: Live trace configuration of a Microsoft.SignalRService resource. + * + * @param liveTraceConfiguration the liveTraceConfiguration value to set. + * @return the SignalRProperties object itself. + */ + public SignalRProperties withLiveTraceConfiguration(LiveTraceConfiguration liveTraceConfiguration) { + this.liveTraceConfiguration = liveTraceConfiguration; + return this; + } + + /** + * Get the resourceLogConfiguration property: Resource log configuration of a Microsoft.SignalRService resource. * * @return the resourceLogConfiguration value. */ @@ -298,10 +314,7 @@ public ResourceLogConfiguration resourceLogConfiguration() { } /** - * Set the resourceLogConfiguration property: Resource log configuration of a Microsoft.SignalRService resource. If - * resourceLogConfiguration isn't null or empty, it will override options "EnableConnectivityLog" and - * "EnableMessagingLogs" in features. Otherwise, use options "EnableConnectivityLog" and "EnableMessagingLogs" in - * features. + * Set the resourceLogConfiguration property: Resource log configuration of a Microsoft.SignalRService resource. * * @param resourceLogConfiguration the resourceLogConfiguration value to set. * @return the SignalRProperties object itself. @@ -332,7 +345,7 @@ public SignalRProperties withCors(SignalRCorsSettings cors) { } /** - * Get the upstream property: Upstream settings when the service is in server-less mode. + * Get the upstream property: The settings for the Upstream when the service is in server-less mode. * * @return the upstream value. */ @@ -341,7 +354,7 @@ public ServerlessUpstreamSettings upstream() { } /** - * Set the upstream property: Upstream settings when the service is in server-less mode. + * Set the upstream property: The settings for the Upstream when the service is in server-less mode. * * @param upstream the upstream value to set. * @return the SignalRProperties object itself. @@ -352,7 +365,7 @@ public SignalRProperties withUpstream(ServerlessUpstreamSettings upstream) { } /** - * Get the networkACLs property: Network ACLs. + * Get the networkACLs property: Network ACLs for the resource. * * @return the networkACLs value. */ @@ -361,7 +374,7 @@ public SignalRNetworkACLs networkACLs() { } /** - * Set the networkACLs property: Network ACLs. + * Set the networkACLs property: Network ACLs for the resource. * * @param networkACLs the networkACLs value to set. * @return the SignalRProperties object itself. @@ -457,6 +470,9 @@ public void validate() { if (features() != null) { features().forEach(e -> e.validate()); } + if (liveTraceConfiguration() != null) { + liveTraceConfiguration().validate(); + } if (resourceLogConfiguration() != null) { resourceLogConfiguration().validate(); } diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRResourceInner.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRResourceInner.java index 5f3b3703823e1..22bad5a8bb69f 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRResourceInner.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRResourceInner.java @@ -7,7 +7,7 @@ import com.azure.core.annotation.Fluent; import com.azure.core.management.Resource; import com.azure.core.management.SystemData; -import com.azure.core.util.logging.ClientLogger; +import com.azure.resourcemanager.signalr.models.LiveTraceConfiguration; import com.azure.resourcemanager.signalr.models.ManagedIdentity; import com.azure.resourcemanager.signalr.models.ProvisioningState; import com.azure.resourcemanager.signalr.models.ResourceLogConfiguration; @@ -18,7 +18,6 @@ import com.azure.resourcemanager.signalr.models.SignalRFeature; import com.azure.resourcemanager.signalr.models.SignalRNetworkACLs; import com.azure.resourcemanager.signalr.models.SignalRTlsSettings; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; import java.util.Map; @@ -26,29 +25,26 @@ /** A class represent a resource. */ @Fluent public final class SignalRResourceInner extends Resource { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRResourceInner.class); - /* - * The billing information of the resource.(e.g. Free, Standard) + * The billing information of the resource. */ @JsonProperty(value = "sku") private ResourceSku sku; /* - * Settings used to provision or configure the resource + * A class that describes the properties of the resource */ @JsonProperty(value = "properties") private SignalRProperties innerProperties; /* - * The kind of the service - e.g. "SignalR" for - * "Microsoft.SignalRService/SignalR" + * The kind of the service, it can be SignalR or RawWebSockets */ @JsonProperty(value = "kind") private ServiceKind kind; /* - * The managed identity response + * A class represent managed identities used for request and response */ @JsonProperty(value = "identity") private ManagedIdentity identity; @@ -60,7 +56,7 @@ public final class SignalRResourceInner extends Resource { private SystemData systemData; /** - * Get the sku property: The billing information of the resource.(e.g. Free, Standard). + * Get the sku property: The billing information of the resource. * * @return the sku value. */ @@ -69,7 +65,7 @@ public ResourceSku sku() { } /** - * Set the sku property: The billing information of the resource.(e.g. Free, Standard). + * Set the sku property: The billing information of the resource. * * @param sku the sku value to set. * @return the SignalRResourceInner object itself. @@ -80,7 +76,7 @@ public SignalRResourceInner withSku(ResourceSku sku) { } /** - * Get the innerProperties property: Settings used to provision or configure the resource. + * Get the innerProperties property: A class that describes the properties of the resource. * * @return the innerProperties value. */ @@ -89,7 +85,7 @@ private SignalRProperties innerProperties() { } /** - * Get the kind property: The kind of the service - e.g. "SignalR" for "Microsoft.SignalRService/SignalR". + * Get the kind property: The kind of the service, it can be SignalR or RawWebSockets. * * @return the kind value. */ @@ -98,7 +94,7 @@ public ServiceKind kind() { } /** - * Set the kind property: The kind of the service - e.g. "SignalR" for "Microsoft.SignalRService/SignalR". + * Set the kind property: The kind of the service, it can be SignalR or RawWebSockets. * * @param kind the kind value to set. * @return the SignalRResourceInner object itself. @@ -109,7 +105,7 @@ public SignalRResourceInner withKind(ServiceKind kind) { } /** - * Get the identity property: The managed identity response. + * Get the identity property: A class represent managed identities used for request and response. * * @return the identity value. */ @@ -118,7 +114,7 @@ public ManagedIdentity identity() { } /** - * Set the identity property: The managed identity response. + * Set the identity property: A class represent managed identities used for request and response. * * @param identity the identity value to set. * @return the SignalRResourceInner object itself. @@ -226,7 +222,7 @@ public List sharedPrivateLinkResources() { } /** - * Get the tls property: TLS settings. + * Get the tls property: TLS settings for the resource. * * @return the tls value. */ @@ -235,7 +231,7 @@ public SignalRTlsSettings tls() { } /** - * Set the tls property: TLS settings. + * Set the tls property: TLS settings for the resource. * * @param tls the tls value to set. * @return the SignalRResourceInner object itself. @@ -291,10 +287,30 @@ public SignalRResourceInner withFeatures(List features) { } /** - * Get the resourceLogConfiguration property: Resource log configuration of a Microsoft.SignalRService resource. If - * resourceLogConfiguration isn't null or empty, it will override options "EnableConnectivityLog" and - * "EnableMessagingLogs" in features. Otherwise, use options "EnableConnectivityLog" and "EnableMessagingLogs" in - * features. + * Get the liveTraceConfiguration property: Live trace configuration of a Microsoft.SignalRService resource. + * + * @return the liveTraceConfiguration value. + */ + public LiveTraceConfiguration liveTraceConfiguration() { + return this.innerProperties() == null ? null : this.innerProperties().liveTraceConfiguration(); + } + + /** + * Set the liveTraceConfiguration property: Live trace configuration of a Microsoft.SignalRService resource. + * + * @param liveTraceConfiguration the liveTraceConfiguration value to set. + * @return the SignalRResourceInner object itself. + */ + public SignalRResourceInner withLiveTraceConfiguration(LiveTraceConfiguration liveTraceConfiguration) { + if (this.innerProperties() == null) { + this.innerProperties = new SignalRProperties(); + } + this.innerProperties().withLiveTraceConfiguration(liveTraceConfiguration); + return this; + } + + /** + * Get the resourceLogConfiguration property: Resource log configuration of a Microsoft.SignalRService resource. * * @return the resourceLogConfiguration value. */ @@ -303,10 +319,7 @@ public ResourceLogConfiguration resourceLogConfiguration() { } /** - * Set the resourceLogConfiguration property: Resource log configuration of a Microsoft.SignalRService resource. If - * resourceLogConfiguration isn't null or empty, it will override options "EnableConnectivityLog" and - * "EnableMessagingLogs" in features. Otherwise, use options "EnableConnectivityLog" and "EnableMessagingLogs" in - * features. + * Set the resourceLogConfiguration property: Resource log configuration of a Microsoft.SignalRService resource. * * @param resourceLogConfiguration the resourceLogConfiguration value to set. * @return the SignalRResourceInner object itself. @@ -343,7 +356,7 @@ public SignalRResourceInner withCors(SignalRCorsSettings cors) { } /** - * Get the upstream property: Upstream settings when the service is in server-less mode. + * Get the upstream property: The settings for the Upstream when the service is in server-less mode. * * @return the upstream value. */ @@ -352,7 +365,7 @@ public ServerlessUpstreamSettings upstream() { } /** - * Set the upstream property: Upstream settings when the service is in server-less mode. + * Set the upstream property: The settings for the Upstream when the service is in server-less mode. * * @param upstream the upstream value to set. * @return the SignalRResourceInner object itself. @@ -366,7 +379,7 @@ public SignalRResourceInner withUpstream(ServerlessUpstreamSettings upstream) { } /** - * Get the networkACLs property: Network ACLs. + * Get the networkACLs property: Network ACLs for the resource. * * @return the networkACLs value. */ @@ -375,7 +388,7 @@ public SignalRNetworkACLs networkACLs() { } /** - * Set the networkACLs property: Network ACLs. + * Set the networkACLs property: Network ACLs for the resource. * * @param networkACLs the networkACLs value to set. * @return the SignalRResourceInner object itself. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRUsageInner.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRUsageInner.java index 5e56c07c34cd5..2213ffd1ae4e3 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRUsageInner.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SignalRUsageInner.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.signalr.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.models.SignalRUsageName; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Object that describes a specific usage of the resources. */ @Fluent public final class SignalRUsageInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRUsageInner.class); - /* * Fully qualified ARM resource id */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SkuListInner.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SkuListInner.java index 874f1dd5461fe..427847342e7ea 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SkuListInner.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/fluent/models/SkuListInner.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.signalr.fluent.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.models.Sku; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** The list skus operation response. */ @Immutable public final class SkuListInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SkuListInner.class); - /* * The list of skus available for the resource. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/CustomCertificateImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/CustomCertificateImpl.java new file mode 100644 index 0000000000000..be0dfd3110f37 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/CustomCertificateImpl.java @@ -0,0 +1,160 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.implementation; + +import com.azure.core.management.SystemData; +import com.azure.core.util.Context; +import com.azure.resourcemanager.signalr.fluent.models.CustomCertificateInner; +import com.azure.resourcemanager.signalr.models.CustomCertificate; +import com.azure.resourcemanager.signalr.models.ProvisioningState; + +public final class CustomCertificateImpl + implements CustomCertificate, CustomCertificate.Definition, CustomCertificate.Update { + private CustomCertificateInner innerObject; + + private final com.azure.resourcemanager.signalr.SignalRManager 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 ProvisioningState provisioningState() { + return this.innerModel().provisioningState(); + } + + public String keyVaultBaseUri() { + return this.innerModel().keyVaultBaseUri(); + } + + public String keyVaultSecretName() { + return this.innerModel().keyVaultSecretName(); + } + + public String keyVaultSecretVersion() { + return this.innerModel().keyVaultSecretVersion(); + } + + public CustomCertificateInner innerModel() { + return this.innerObject; + } + + private com.azure.resourcemanager.signalr.SignalRManager manager() { + return this.serviceManager; + } + + private String resourceGroupName; + + private String resourceName; + + private String certificateName; + + public CustomCertificateImpl withExistingSignalR(String resourceGroupName, String resourceName) { + this.resourceGroupName = resourceGroupName; + this.resourceName = resourceName; + return this; + } + + public CustomCertificate create() { + this.innerObject = + serviceManager + .serviceClient() + .getSignalRCustomCertificates() + .createOrUpdate(resourceGroupName, resourceName, certificateName, this.innerModel(), Context.NONE); + return this; + } + + public CustomCertificate create(Context context) { + this.innerObject = + serviceManager + .serviceClient() + .getSignalRCustomCertificates() + .createOrUpdate(resourceGroupName, resourceName, certificateName, this.innerModel(), context); + return this; + } + + CustomCertificateImpl(String name, com.azure.resourcemanager.signalr.SignalRManager serviceManager) { + this.innerObject = new CustomCertificateInner(); + this.serviceManager = serviceManager; + this.certificateName = name; + } + + public CustomCertificateImpl update() { + return this; + } + + public CustomCertificate apply() { + this.innerObject = + serviceManager + .serviceClient() + .getSignalRCustomCertificates() + .createOrUpdate(resourceGroupName, resourceName, certificateName, this.innerModel(), Context.NONE); + return this; + } + + public CustomCertificate apply(Context context) { + this.innerObject = + serviceManager + .serviceClient() + .getSignalRCustomCertificates() + .createOrUpdate(resourceGroupName, resourceName, certificateName, this.innerModel(), context); + return this; + } + + CustomCertificateImpl( + CustomCertificateInner innerObject, com.azure.resourcemanager.signalr.SignalRManager serviceManager) { + this.innerObject = innerObject; + this.serviceManager = serviceManager; + this.resourceGroupName = Utils.getValueFromIdByName(innerObject.id(), "resourceGroups"); + this.resourceName = Utils.getValueFromIdByName(innerObject.id(), "signalR"); + this.certificateName = Utils.getValueFromIdByName(innerObject.id(), "customCertificates"); + } + + public CustomCertificate refresh() { + this.innerObject = + serviceManager + .serviceClient() + .getSignalRCustomCertificates() + .getWithResponse(resourceGroupName, resourceName, certificateName, Context.NONE) + .getValue(); + return this; + } + + public CustomCertificate refresh(Context context) { + this.innerObject = + serviceManager + .serviceClient() + .getSignalRCustomCertificates() + .getWithResponse(resourceGroupName, resourceName, certificateName, context) + .getValue(); + return this; + } + + public CustomCertificateImpl withKeyVaultBaseUri(String keyVaultBaseUri) { + this.innerModel().withKeyVaultBaseUri(keyVaultBaseUri); + return this; + } + + public CustomCertificateImpl withKeyVaultSecretName(String keyVaultSecretName) { + this.innerModel().withKeyVaultSecretName(keyVaultSecretName); + return this; + } + + public CustomCertificateImpl withKeyVaultSecretVersion(String keyVaultSecretVersion) { + this.innerModel().withKeyVaultSecretVersion(keyVaultSecretVersion); + return this; + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/CustomDomainImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/CustomDomainImpl.java new file mode 100644 index 0000000000000..0d32e93ed3d17 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/CustomDomainImpl.java @@ -0,0 +1,150 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.implementation; + +import com.azure.core.management.SystemData; +import com.azure.core.util.Context; +import com.azure.resourcemanager.signalr.fluent.models.CustomDomainInner; +import com.azure.resourcemanager.signalr.models.CustomDomain; +import com.azure.resourcemanager.signalr.models.ProvisioningState; +import com.azure.resourcemanager.signalr.models.ResourceReference; + +public final class CustomDomainImpl implements CustomDomain, CustomDomain.Definition, CustomDomain.Update { + private CustomDomainInner innerObject; + + private final com.azure.resourcemanager.signalr.SignalRManager 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 ProvisioningState provisioningState() { + return this.innerModel().provisioningState(); + } + + public String domainName() { + return this.innerModel().domainName(); + } + + public ResourceReference customCertificate() { + return this.innerModel().customCertificate(); + } + + public CustomDomainInner innerModel() { + return this.innerObject; + } + + private com.azure.resourcemanager.signalr.SignalRManager manager() { + return this.serviceManager; + } + + private String resourceGroupName; + + private String resourceName; + + private String name; + + public CustomDomainImpl withExistingSignalR(String resourceGroupName, String resourceName) { + this.resourceGroupName = resourceGroupName; + this.resourceName = resourceName; + return this; + } + + public CustomDomain create() { + this.innerObject = + serviceManager + .serviceClient() + .getSignalRCustomDomains() + .createOrUpdate(resourceGroupName, resourceName, name, this.innerModel(), Context.NONE); + return this; + } + + public CustomDomain create(Context context) { + this.innerObject = + serviceManager + .serviceClient() + .getSignalRCustomDomains() + .createOrUpdate(resourceGroupName, resourceName, name, this.innerModel(), context); + return this; + } + + CustomDomainImpl(String name, com.azure.resourcemanager.signalr.SignalRManager serviceManager) { + this.innerObject = new CustomDomainInner(); + this.serviceManager = serviceManager; + this.name = name; + } + + public CustomDomainImpl update() { + return this; + } + + public CustomDomain apply() { + this.innerObject = + serviceManager + .serviceClient() + .getSignalRCustomDomains() + .createOrUpdate(resourceGroupName, resourceName, name, this.innerModel(), Context.NONE); + return this; + } + + public CustomDomain apply(Context context) { + this.innerObject = + serviceManager + .serviceClient() + .getSignalRCustomDomains() + .createOrUpdate(resourceGroupName, resourceName, name, this.innerModel(), context); + return this; + } + + CustomDomainImpl(CustomDomainInner innerObject, com.azure.resourcemanager.signalr.SignalRManager serviceManager) { + this.innerObject = innerObject; + this.serviceManager = serviceManager; + this.resourceGroupName = Utils.getValueFromIdByName(innerObject.id(), "resourceGroups"); + this.resourceName = Utils.getValueFromIdByName(innerObject.id(), "signalR"); + this.name = Utils.getValueFromIdByName(innerObject.id(), "customDomains"); + } + + public CustomDomain refresh() { + this.innerObject = + serviceManager + .serviceClient() + .getSignalRCustomDomains() + .getWithResponse(resourceGroupName, resourceName, name, Context.NONE) + .getValue(); + return this; + } + + public CustomDomain refresh(Context context) { + this.innerObject = + serviceManager + .serviceClient() + .getSignalRCustomDomains() + .getWithResponse(resourceGroupName, resourceName, name, context) + .getValue(); + return this; + } + + public CustomDomainImpl withDomainName(String domainName) { + this.innerModel().withDomainName(domainName); + return this; + } + + public CustomDomainImpl withCustomCertificate(ResourceReference customCertificate) { + this.innerModel().withCustomCertificate(customCertificate); + return this; + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/OperationsClientImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/OperationsClientImpl.java index a06a66759e711..557e347d0f427 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/OperationsClientImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/OperationsClientImpl.java @@ -25,7 +25,6 @@ import com.azure.core.management.exception.ManagementException; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.fluent.OperationsClient; import com.azure.resourcemanager.signalr.fluent.models.OperationInner; import com.azure.resourcemanager.signalr.models.OperationList; @@ -33,8 +32,6 @@ /** An instance of this class provides access to all the operations defined in OperationsClient. */ public final class OperationsClientImpl implements OperationsClient { - private final ClientLogger logger = new ClientLogger(OperationsClientImpl.class); - /** The proxy service used to perform REST calls. */ private final OperationsService service; @@ -85,7 +82,8 @@ Mono> listNext( * * @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 result of the request to list REST API operations. + * @return result of the request to list REST API operations along with {@link PagedResponse} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync() { @@ -118,7 +116,8 @@ private Mono> listSinglePageAsync() { * @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 result of the request to list REST API operations. + * @return result of the request to list REST API operations along with {@link PagedResponse} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync(Context context) { @@ -148,7 +147,7 @@ private Mono> listSinglePageAsync(Context context) * * @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 result of the request to list REST API operations. + * @return result of the request to list REST API operations as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync() { @@ -162,7 +161,7 @@ private PagedFlux listAsync() { * @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 result of the request to list REST API operations. + * @return result of the request to list REST API operations as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(Context context) { @@ -175,7 +174,7 @@ private PagedFlux listAsync(Context context) { * * @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 result of the request to list REST API operations. + * @return result of the request to list REST API operations as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list() { @@ -189,7 +188,7 @@ public PagedIterable list() { * @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 result of the request to list REST API operations. + * @return result of the request to list REST API operations as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(Context context) { @@ -203,7 +202,8 @@ public PagedIterable list(Context context) { * @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 result of the request to list REST API operations. + * @return result of the request to list REST API operations along with {@link PagedResponse} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink) { @@ -239,7 +239,8 @@ private Mono> listNextSinglePageAsync(String nextL * @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 result of the request to list REST API operations. + * @return result of the request to list REST API operations along with {@link PagedResponse} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink, Context context) { diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/OperationsImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/OperationsImpl.java index 4c19f68103831..49f2965eaa8fe 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/OperationsImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/OperationsImpl.java @@ -11,10 +11,9 @@ import com.azure.resourcemanager.signalr.fluent.models.OperationInner; import com.azure.resourcemanager.signalr.models.Operation; import com.azure.resourcemanager.signalr.models.Operations; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class OperationsImpl implements Operations { - @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationsImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(OperationsImpl.class); private final OperationsClient innerClient; diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRCustomCertificatesClientImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRCustomCertificatesClientImpl.java new file mode 100644 index 0000000000000..a2efe97095ca2 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRCustomCertificatesClientImpl.java @@ -0,0 +1,1051 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.implementation; + +import com.azure.core.annotation.BodyParam; +import com.azure.core.annotation.Delete; +import com.azure.core.annotation.ExpectedResponses; +import com.azure.core.annotation.Get; +import com.azure.core.annotation.HeaderParam; +import com.azure.core.annotation.Headers; +import com.azure.core.annotation.Host; +import com.azure.core.annotation.HostParam; +import com.azure.core.annotation.PathParam; +import com.azure.core.annotation.Put; +import com.azure.core.annotation.QueryParam; +import com.azure.core.annotation.ReturnType; +import com.azure.core.annotation.ServiceInterface; +import com.azure.core.annotation.ServiceMethod; +import com.azure.core.annotation.UnexpectedResponseExceptionType; +import com.azure.core.http.rest.PagedFlux; +import com.azure.core.http.rest.PagedIterable; +import com.azure.core.http.rest.PagedResponse; +import com.azure.core.http.rest.PagedResponseBase; +import com.azure.core.http.rest.Response; +import com.azure.core.http.rest.RestProxy; +import com.azure.core.management.exception.ManagementException; +import com.azure.core.management.polling.PollResult; +import com.azure.core.util.Context; +import com.azure.core.util.FluxUtil; +import com.azure.core.util.polling.PollerFlux; +import com.azure.core.util.polling.SyncPoller; +import com.azure.resourcemanager.signalr.fluent.SignalRCustomCertificatesClient; +import com.azure.resourcemanager.signalr.fluent.models.CustomCertificateInner; +import com.azure.resourcemanager.signalr.models.CustomCertificateList; +import java.nio.ByteBuffer; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; + +/** An instance of this class provides access to all the operations defined in SignalRCustomCertificatesClient. */ +public final class SignalRCustomCertificatesClientImpl implements SignalRCustomCertificatesClient { + /** The proxy service used to perform REST calls. */ + private final SignalRCustomCertificatesService service; + + /** The service client containing this operation class. */ + private final SignalRManagementClientImpl client; + + /** + * Initializes an instance of SignalRCustomCertificatesClientImpl. + * + * @param client the instance of the service client containing this operation class. + */ + SignalRCustomCertificatesClientImpl(SignalRManagementClientImpl client) { + this.service = + RestProxy + .create( + SignalRCustomCertificatesService.class, client.getHttpPipeline(), client.getSerializerAdapter()); + this.client = client; + } + + /** + * The interface defining all the services for SignalRManagementClientSignalRCustomCertificates to be used by the + * proxy service to perform REST calls. + */ + @Host("{$host}") + @ServiceInterface(name = "SignalRManagementCli") + private interface SignalRCustomCertificatesService { + @Headers({"Content-Type: application/json"}) + @Get( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService" + + "/signalR/{resourceName}/customCertificates") + @ExpectedResponses({200}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono> list( + @HostParam("$host") String endpoint, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("resourceName") String resourceName, + @QueryParam("api-version") String apiVersion, + @HeaderParam("Accept") String accept, + Context context); + + @Headers({"Content-Type: application/json"}) + @Get( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService" + + "/signalR/{resourceName}/customCertificates/{certificateName}") + @ExpectedResponses({200}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono> get( + @HostParam("$host") String endpoint, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("resourceName") String resourceName, + @PathParam("certificateName") String certificateName, + @QueryParam("api-version") String apiVersion, + @HeaderParam("Accept") String accept, + Context context); + + @Headers({"Content-Type: application/json"}) + @Put( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService" + + "/signalR/{resourceName}/customCertificates/{certificateName}") + @ExpectedResponses({200, 201}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono>> createOrUpdate( + @HostParam("$host") String endpoint, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("resourceName") String resourceName, + @PathParam("certificateName") String certificateName, + @QueryParam("api-version") String apiVersion, + @BodyParam("application/json") CustomCertificateInner parameters, + @HeaderParam("Accept") String accept, + Context context); + + @Headers({"Content-Type: application/json"}) + @Delete( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService" + + "/signalR/{resourceName}/customCertificates/{certificateName}") + @ExpectedResponses({200, 204}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono> delete( + @HostParam("$host") String endpoint, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("resourceName") String resourceName, + @PathParam("certificateName") String certificateName, + @QueryParam("api-version") String apiVersion, + @HeaderParam("Accept") String accept, + Context context); + + @Headers({"Content-Type: application/json"}) + @Get("{nextLink}") + @ExpectedResponses({200}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono> listNext( + @PathParam(value = "nextLink", encoded = true) String nextLink, + @HostParam("$host") String endpoint, + @HeaderParam("Accept") String accept, + Context context); + } + + /** + * List all custom certificates. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @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 custom certificates list along with {@link PagedResponse} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listSinglePageAsync( + String resourceGroupName, String resourceName) { + 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext( + context -> + service + .list( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + this.client.getApiVersion(), + 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 custom certificates. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @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 custom certificates list along with {@link PagedResponse} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listSinglePageAsync( + String resourceGroupName, String resourceName, 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service + .list( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + this.client.getApiVersion(), + accept, + context) + .map( + res -> + new PagedResponseBase<>( + res.getRequest(), + res.getStatusCode(), + res.getHeaders(), + res.getValue().value(), + res.getValue().nextLink(), + null)); + } + + /** + * List all custom certificates. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @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 custom certificates list as paginated response with {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + private PagedFlux listAsync(String resourceGroupName, String resourceName) { + return new PagedFlux<>( + () -> listSinglePageAsync(resourceGroupName, resourceName), nextLink -> listNextSinglePageAsync(nextLink)); + } + + /** + * List all custom certificates. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @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 custom certificates list as paginated response with {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + private PagedFlux listAsync( + String resourceGroupName, String resourceName, Context context) { + return new PagedFlux<>( + () -> listSinglePageAsync(resourceGroupName, resourceName, context), + nextLink -> listNextSinglePageAsync(nextLink, context)); + } + + /** + * List all custom certificates. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @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 custom certificates list as paginated response with {@link PagedIterable}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + public PagedIterable list(String resourceGroupName, String resourceName) { + return new PagedIterable<>(listAsync(resourceGroupName, resourceName)); + } + + /** + * List all custom certificates. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @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 custom certificates list as paginated response with {@link PagedIterable}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + public PagedIterable list(String resourceGroupName, String resourceName, Context context) { + return new PagedIterable<>(listAsync(resourceGroupName, resourceName, context)); + } + + /** + * Get a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 custom certificate along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> getWithResponseAsync( + String resourceGroupName, String resourceName, String certificateName) { + 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + if (certificateName == null) { + return Mono + .error(new IllegalArgumentException("Parameter certificateName is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext( + context -> + service + .get( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + certificateName, + this.client.getApiVersion(), + accept, + context)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } + + /** + * Get a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 custom certificate along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> getWithResponseAsync( + String resourceGroupName, String resourceName, String certificateName, 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + if (certificateName == null) { + return Mono + .error(new IllegalArgumentException("Parameter certificateName is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service + .get( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + certificateName, + this.client.getApiVersion(), + accept, + context); + } + + /** + * Get a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 custom certificate on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono getAsync( + String resourceGroupName, String resourceName, String certificateName) { + return getWithResponseAsync(resourceGroupName, resourceName, certificateName) + .flatMap( + (Response res) -> { + if (res.getValue() != null) { + return Mono.just(res.getValue()); + } else { + return Mono.empty(); + } + }); + } + + /** + * Get a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 custom certificate. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public CustomCertificateInner get(String resourceGroupName, String resourceName, String certificateName) { + return getAsync(resourceGroupName, resourceName, certificateName).block(); + } + + /** + * Get a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 custom certificate along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public Response getWithResponse( + String resourceGroupName, String resourceName, String certificateName, Context context) { + return getWithResponseAsync(resourceGroupName, resourceName, certificateName, context).block(); + } + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 custom certificate along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono>> createOrUpdateWithResponseAsync( + String resourceGroupName, String resourceName, String certificateName, CustomCertificateInner 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + if (certificateName == null) { + return Mono + .error(new IllegalArgumentException("Parameter certificateName 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 + .createOrUpdate( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + certificateName, + this.client.getApiVersion(), + parameters, + accept, + context)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 custom certificate along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono>> createOrUpdateWithResponseAsync( + String resourceGroupName, + String resourceName, + String certificateName, + CustomCertificateInner 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + if (certificateName == null) { + return Mono + .error(new IllegalArgumentException("Parameter certificateName 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 + .createOrUpdate( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + certificateName, + this.client.getApiVersion(), + parameters, + accept, + context); + } + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 a custom certificate. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, CustomCertificateInner> beginCreateOrUpdateAsync( + String resourceGroupName, String resourceName, String certificateName, CustomCertificateInner parameters) { + Mono>> mono = + createOrUpdateWithResponseAsync(resourceGroupName, resourceName, certificateName, parameters); + return this + .client + .getLroResult( + mono, + this.client.getHttpPipeline(), + CustomCertificateInner.class, + CustomCertificateInner.class, + this.client.getContext()); + } + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 a custom certificate. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, CustomCertificateInner> beginCreateOrUpdateAsync( + String resourceGroupName, + String resourceName, + String certificateName, + CustomCertificateInner parameters, + Context context) { + context = this.client.mergeContext(context); + Mono>> mono = + createOrUpdateWithResponseAsync(resourceGroupName, resourceName, certificateName, parameters, context); + return this + .client + .getLroResult( + mono, + this.client.getHttpPipeline(), + CustomCertificateInner.class, + CustomCertificateInner.class, + context); + } + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 a custom certificate. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, CustomCertificateInner> beginCreateOrUpdate( + String resourceGroupName, String resourceName, String certificateName, CustomCertificateInner parameters) { + return beginCreateOrUpdateAsync(resourceGroupName, resourceName, certificateName, parameters).getSyncPoller(); + } + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 a custom certificate. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, CustomCertificateInner> beginCreateOrUpdate( + String resourceGroupName, + String resourceName, + String certificateName, + CustomCertificateInner parameters, + Context context) { + return beginCreateOrUpdateAsync(resourceGroupName, resourceName, certificateName, parameters, context) + .getSyncPoller(); + } + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 custom certificate on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono createOrUpdateAsync( + String resourceGroupName, String resourceName, String certificateName, CustomCertificateInner parameters) { + return beginCreateOrUpdateAsync(resourceGroupName, resourceName, certificateName, parameters) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 custom certificate on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono createOrUpdateAsync( + String resourceGroupName, + String resourceName, + String certificateName, + CustomCertificateInner parameters, + Context context) { + return beginCreateOrUpdateAsync(resourceGroupName, resourceName, certificateName, parameters, context) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 custom certificate. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public CustomCertificateInner createOrUpdate( + String resourceGroupName, String resourceName, String certificateName, CustomCertificateInner parameters) { + return createOrUpdateAsync(resourceGroupName, resourceName, certificateName, parameters).block(); + } + + /** + * Create or update a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @param parameters A custom certificate. + * @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 custom certificate. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public CustomCertificateInner createOrUpdate( + String resourceGroupName, + String resourceName, + String certificateName, + CustomCertificateInner parameters, + Context context) { + return createOrUpdateAsync(resourceGroupName, resourceName, certificateName, parameters, context).block(); + } + + /** + * Delete a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> deleteWithResponseAsync( + String resourceGroupName, String resourceName, String certificateName) { + 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + if (certificateName == null) { + return Mono + .error(new IllegalArgumentException("Parameter certificateName is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext( + context -> + service + .delete( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + certificateName, + this.client.getApiVersion(), + accept, + context)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } + + /** + * Delete a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> deleteWithResponseAsync( + String resourceGroupName, String resourceName, String certificateName, 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + if (certificateName == null) { + return Mono + .error(new IllegalArgumentException("Parameter certificateName is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service + .delete( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + certificateName, + this.client.getApiVersion(), + accept, + context); + } + + /** + * Delete a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono deleteAsync(String resourceGroupName, String resourceName, String certificateName) { + return deleteWithResponseAsync(resourceGroupName, resourceName, certificateName) + .flatMap((Response res) -> Mono.empty()); + } + + /** + * Delete a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public void delete(String resourceGroupName, String resourceName, String certificateName) { + deleteAsync(resourceGroupName, resourceName, certificateName).block(); + } + + /** + * Delete a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public Response deleteWithResponse( + String resourceGroupName, String resourceName, String certificateName, Context context) { + return deleteWithResponseAsync(resourceGroupName, resourceName, certificateName, context).block(); + } + + /** + * Get the next page of items. + * + * @param nextLink 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 custom certificates list along with {@link PagedResponse} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listNextSinglePageAsync(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.listNext(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 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 custom certificates list along with {@link PagedResponse} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listNextSinglePageAsync(String nextLink, Context context) { + 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"; + context = this.client.mergeContext(context); + return service + .listNext(nextLink, this.client.getEndpoint(), accept, context) + .map( + res -> + new PagedResponseBase<>( + res.getRequest(), + res.getStatusCode(), + res.getHeaders(), + res.getValue().value(), + res.getValue().nextLink(), + null)); + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRCustomCertificatesImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRCustomCertificatesImpl.java new file mode 100644 index 0000000000000..c26e76ea98eb0 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRCustomCertificatesImpl.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.signalr.implementation; + +import com.azure.core.http.rest.PagedIterable; +import com.azure.core.http.rest.Response; +import com.azure.core.http.rest.SimpleResponse; +import com.azure.core.util.Context; +import com.azure.core.util.logging.ClientLogger; +import com.azure.resourcemanager.signalr.fluent.SignalRCustomCertificatesClient; +import com.azure.resourcemanager.signalr.fluent.models.CustomCertificateInner; +import com.azure.resourcemanager.signalr.models.CustomCertificate; +import com.azure.resourcemanager.signalr.models.SignalRCustomCertificates; + +public final class SignalRCustomCertificatesImpl implements SignalRCustomCertificates { + private static final ClientLogger LOGGER = new ClientLogger(SignalRCustomCertificatesImpl.class); + + private final SignalRCustomCertificatesClient innerClient; + + private final com.azure.resourcemanager.signalr.SignalRManager serviceManager; + + public SignalRCustomCertificatesImpl( + SignalRCustomCertificatesClient innerClient, com.azure.resourcemanager.signalr.SignalRManager serviceManager) { + this.innerClient = innerClient; + this.serviceManager = serviceManager; + } + + public PagedIterable list(String resourceGroupName, String resourceName) { + PagedIterable inner = this.serviceClient().list(resourceGroupName, resourceName); + return Utils.mapPage(inner, inner1 -> new CustomCertificateImpl(inner1, this.manager())); + } + + public PagedIterable list(String resourceGroupName, String resourceName, Context context) { + PagedIterable inner = + this.serviceClient().list(resourceGroupName, resourceName, context); + return Utils.mapPage(inner, inner1 -> new CustomCertificateImpl(inner1, this.manager())); + } + + public CustomCertificate get(String resourceGroupName, String resourceName, String certificateName) { + CustomCertificateInner inner = this.serviceClient().get(resourceGroupName, resourceName, certificateName); + if (inner != null) { + return new CustomCertificateImpl(inner, this.manager()); + } else { + return null; + } + } + + public Response getWithResponse( + String resourceGroupName, String resourceName, String certificateName, Context context) { + Response inner = + this.serviceClient().getWithResponse(resourceGroupName, resourceName, certificateName, context); + if (inner != null) { + return new SimpleResponse<>( + inner.getRequest(), + inner.getStatusCode(), + inner.getHeaders(), + new CustomCertificateImpl(inner.getValue(), this.manager())); + } else { + return null; + } + } + + public void delete(String resourceGroupName, String resourceName, String certificateName) { + this.serviceClient().delete(resourceGroupName, resourceName, certificateName); + } + + public Response deleteWithResponse( + String resourceGroupName, String resourceName, String certificateName, Context context) { + return this.serviceClient().deleteWithResponse(resourceGroupName, resourceName, certificateName, context); + } + + public CustomCertificate getById(String id) { + String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); + if (resourceGroupName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String + .format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id))); + } + String resourceName = Utils.getValueFromIdByName(id, "signalR"); + if (resourceName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); + } + String certificateName = Utils.getValueFromIdByName(id, "customCertificates"); + if (certificateName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String + .format( + "The resource ID '%s' is not valid. Missing path segment 'customCertificates'.", id))); + } + return this.getWithResponse(resourceGroupName, resourceName, certificateName, Context.NONE).getValue(); + } + + public Response getByIdWithResponse(String id, Context context) { + String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); + if (resourceGroupName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String + .format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id))); + } + String resourceName = Utils.getValueFromIdByName(id, "signalR"); + if (resourceName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); + } + String certificateName = Utils.getValueFromIdByName(id, "customCertificates"); + if (certificateName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String + .format( + "The resource ID '%s' is not valid. Missing path segment 'customCertificates'.", id))); + } + return this.getWithResponse(resourceGroupName, resourceName, certificateName, context); + } + + public void deleteById(String id) { + String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); + if (resourceGroupName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String + .format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id))); + } + String resourceName = Utils.getValueFromIdByName(id, "signalR"); + if (resourceName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); + } + String certificateName = Utils.getValueFromIdByName(id, "customCertificates"); + if (certificateName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String + .format( + "The resource ID '%s' is not valid. Missing path segment 'customCertificates'.", id))); + } + this.deleteWithResponse(resourceGroupName, resourceName, certificateName, Context.NONE); + } + + public Response deleteByIdWithResponse(String id, Context context) { + String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); + if (resourceGroupName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String + .format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id))); + } + String resourceName = Utils.getValueFromIdByName(id, "signalR"); + if (resourceName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); + } + String certificateName = Utils.getValueFromIdByName(id, "customCertificates"); + if (certificateName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String + .format( + "The resource ID '%s' is not valid. Missing path segment 'customCertificates'.", id))); + } + return this.deleteWithResponse(resourceGroupName, resourceName, certificateName, context); + } + + private SignalRCustomCertificatesClient serviceClient() { + return this.innerClient; + } + + private com.azure.resourcemanager.signalr.SignalRManager manager() { + return this.serviceManager; + } + + public CustomCertificateImpl define(String name) { + return new CustomCertificateImpl(name, this.manager()); + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRCustomDomainsClientImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRCustomDomainsClientImpl.java new file mode 100644 index 0000000000000..cf2658d454a4b --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRCustomDomainsClientImpl.java @@ -0,0 +1,1116 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.implementation; + +import com.azure.core.annotation.BodyParam; +import com.azure.core.annotation.Delete; +import com.azure.core.annotation.ExpectedResponses; +import com.azure.core.annotation.Get; +import com.azure.core.annotation.HeaderParam; +import com.azure.core.annotation.Headers; +import com.azure.core.annotation.Host; +import com.azure.core.annotation.HostParam; +import com.azure.core.annotation.PathParam; +import com.azure.core.annotation.Put; +import com.azure.core.annotation.QueryParam; +import com.azure.core.annotation.ReturnType; +import com.azure.core.annotation.ServiceInterface; +import com.azure.core.annotation.ServiceMethod; +import com.azure.core.annotation.UnexpectedResponseExceptionType; +import com.azure.core.http.rest.PagedFlux; +import com.azure.core.http.rest.PagedIterable; +import com.azure.core.http.rest.PagedResponse; +import com.azure.core.http.rest.PagedResponseBase; +import com.azure.core.http.rest.Response; +import com.azure.core.http.rest.RestProxy; +import com.azure.core.management.exception.ManagementException; +import com.azure.core.management.polling.PollResult; +import com.azure.core.util.Context; +import com.azure.core.util.FluxUtil; +import com.azure.core.util.polling.PollerFlux; +import com.azure.core.util.polling.SyncPoller; +import com.azure.resourcemanager.signalr.fluent.SignalRCustomDomainsClient; +import com.azure.resourcemanager.signalr.fluent.models.CustomDomainInner; +import com.azure.resourcemanager.signalr.models.CustomDomainList; +import java.nio.ByteBuffer; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; + +/** An instance of this class provides access to all the operations defined in SignalRCustomDomainsClient. */ +public final class SignalRCustomDomainsClientImpl implements SignalRCustomDomainsClient { + /** The proxy service used to perform REST calls. */ + private final SignalRCustomDomainsService service; + + /** The service client containing this operation class. */ + private final SignalRManagementClientImpl client; + + /** + * Initializes an instance of SignalRCustomDomainsClientImpl. + * + * @param client the instance of the service client containing this operation class. + */ + SignalRCustomDomainsClientImpl(SignalRManagementClientImpl client) { + this.service = + RestProxy + .create(SignalRCustomDomainsService.class, client.getHttpPipeline(), client.getSerializerAdapter()); + this.client = client; + } + + /** + * The interface defining all the services for SignalRManagementClientSignalRCustomDomains to be used by the proxy + * service to perform REST calls. + */ + @Host("{$host}") + @ServiceInterface(name = "SignalRManagementCli") + private interface SignalRCustomDomainsService { + @Headers({"Content-Type: application/json"}) + @Get( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService" + + "/signalR/{resourceName}/customDomains") + @ExpectedResponses({200}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono> list( + @HostParam("$host") String endpoint, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("resourceName") String resourceName, + @QueryParam("api-version") String apiVersion, + @HeaderParam("Accept") String accept, + Context context); + + @Headers({"Content-Type: application/json"}) + @Get( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService" + + "/signalR/{resourceName}/customDomains/{name}") + @ExpectedResponses({200}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono> get( + @HostParam("$host") String endpoint, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("resourceName") String resourceName, + @PathParam("name") String name, + @QueryParam("api-version") String apiVersion, + @HeaderParam("Accept") String accept, + Context context); + + @Headers({"Content-Type: application/json"}) + @Put( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService" + + "/signalR/{resourceName}/customDomains/{name}") + @ExpectedResponses({201}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono>> createOrUpdate( + @HostParam("$host") String endpoint, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("resourceName") String resourceName, + @PathParam("name") String name, + @QueryParam("api-version") String apiVersion, + @BodyParam("application/json") CustomDomainInner parameters, + @HeaderParam("Accept") String accept, + Context context); + + @Headers({"Content-Type: application/json"}) + @Delete( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService" + + "/signalR/{resourceName}/customDomains/{name}") + @ExpectedResponses({200, 202, 204}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono>> delete( + @HostParam("$host") String endpoint, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("resourceName") String resourceName, + @PathParam("name") String name, + @QueryParam("api-version") String apiVersion, + @HeaderParam("Accept") String accept, + Context context); + + @Headers({"Content-Type: application/json"}) + @Get("{nextLink}") + @ExpectedResponses({200}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono> listNext( + @PathParam(value = "nextLink", encoded = true) String nextLink, + @HostParam("$host") String endpoint, + @HeaderParam("Accept") String accept, + Context context); + } + + /** + * List all custom domains. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @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 custom domains list along with {@link PagedResponse} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listSinglePageAsync(String resourceGroupName, String resourceName) { + 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext( + context -> + service + .list( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + this.client.getApiVersion(), + 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 custom domains. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @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 custom domains list along with {@link PagedResponse} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listSinglePageAsync( + String resourceGroupName, String resourceName, 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service + .list( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + this.client.getApiVersion(), + accept, + context) + .map( + res -> + new PagedResponseBase<>( + res.getRequest(), + res.getStatusCode(), + res.getHeaders(), + res.getValue().value(), + res.getValue().nextLink(), + null)); + } + + /** + * List all custom domains. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @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 custom domains list as paginated response with {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + private PagedFlux listAsync(String resourceGroupName, String resourceName) { + return new PagedFlux<>( + () -> listSinglePageAsync(resourceGroupName, resourceName), nextLink -> listNextSinglePageAsync(nextLink)); + } + + /** + * List all custom domains. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @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 custom domains list as paginated response with {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + private PagedFlux listAsync(String resourceGroupName, String resourceName, Context context) { + return new PagedFlux<>( + () -> listSinglePageAsync(resourceGroupName, resourceName, context), + nextLink -> listNextSinglePageAsync(nextLink, context)); + } + + /** + * List all custom domains. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @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 custom domains list as paginated response with {@link PagedIterable}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + public PagedIterable list(String resourceGroupName, String resourceName) { + return new PagedIterable<>(listAsync(resourceGroupName, resourceName)); + } + + /** + * List all custom domains. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @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 custom domains list as paginated response with {@link PagedIterable}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + public PagedIterable list(String resourceGroupName, String resourceName, Context context) { + return new PagedIterable<>(listAsync(resourceGroupName, resourceName, context)); + } + + /** + * Get a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 custom domain along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> getWithResponseAsync( + String resourceGroupName, String resourceName, String name) { + 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + if (name == null) { + return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext( + context -> + service + .get( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + name, + this.client.getApiVersion(), + accept, + context)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } + + /** + * Get a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 custom domain along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> getWithResponseAsync( + String resourceGroupName, String resourceName, String name, 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + if (name == null) { + return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service + .get( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + name, + this.client.getApiVersion(), + accept, + context); + } + + /** + * Get a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 custom domain on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono getAsync(String resourceGroupName, String resourceName, String name) { + return getWithResponseAsync(resourceGroupName, resourceName, name) + .flatMap( + (Response res) -> { + if (res.getValue() != null) { + return Mono.just(res.getValue()); + } else { + return Mono.empty(); + } + }); + } + + /** + * Get a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 custom domain. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public CustomDomainInner get(String resourceGroupName, String resourceName, String name) { + return getAsync(resourceGroupName, resourceName, name).block(); + } + + /** + * Get a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 custom domain along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public Response getWithResponse( + String resourceGroupName, String resourceName, String name, Context context) { + return getWithResponseAsync(resourceGroupName, resourceName, name, context).block(); + } + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 custom domain along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono>> createOrUpdateWithResponseAsync( + String resourceGroupName, String resourceName, String name, CustomDomainInner 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + if (name == null) { + return Mono.error(new IllegalArgumentException("Parameter name 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 + .createOrUpdate( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + name, + this.client.getApiVersion(), + parameters, + accept, + context)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 custom domain along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono>> createOrUpdateWithResponseAsync( + String resourceGroupName, String resourceName, String name, CustomDomainInner 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + if (name == null) { + return Mono.error(new IllegalArgumentException("Parameter name 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 + .createOrUpdate( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + name, + this.client.getApiVersion(), + parameters, + accept, + context); + } + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 a custom domain. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, CustomDomainInner> beginCreateOrUpdateAsync( + String resourceGroupName, String resourceName, String name, CustomDomainInner parameters) { + Mono>> mono = + createOrUpdateWithResponseAsync(resourceGroupName, resourceName, name, parameters); + return this + .client + .getLroResult( + mono, + this.client.getHttpPipeline(), + CustomDomainInner.class, + CustomDomainInner.class, + this.client.getContext()); + } + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 a custom domain. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, CustomDomainInner> beginCreateOrUpdateAsync( + String resourceGroupName, String resourceName, String name, CustomDomainInner parameters, Context context) { + context = this.client.mergeContext(context); + Mono>> mono = + createOrUpdateWithResponseAsync(resourceGroupName, resourceName, name, parameters, context); + return this + .client + .getLroResult( + mono, this.client.getHttpPipeline(), CustomDomainInner.class, CustomDomainInner.class, context); + } + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 a custom domain. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, CustomDomainInner> beginCreateOrUpdate( + String resourceGroupName, String resourceName, String name, CustomDomainInner parameters) { + return beginCreateOrUpdateAsync(resourceGroupName, resourceName, name, parameters).getSyncPoller(); + } + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 a custom domain. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, CustomDomainInner> beginCreateOrUpdate( + String resourceGroupName, String resourceName, String name, CustomDomainInner parameters, Context context) { + return beginCreateOrUpdateAsync(resourceGroupName, resourceName, name, parameters, context).getSyncPoller(); + } + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 custom domain on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono createOrUpdateAsync( + String resourceGroupName, String resourceName, String name, CustomDomainInner parameters) { + return beginCreateOrUpdateAsync(resourceGroupName, resourceName, name, parameters) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 custom domain on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono createOrUpdateAsync( + String resourceGroupName, String resourceName, String name, CustomDomainInner parameters, Context context) { + return beginCreateOrUpdateAsync(resourceGroupName, resourceName, name, parameters, context) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 custom domain. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public CustomDomainInner createOrUpdate( + String resourceGroupName, String resourceName, String name, CustomDomainInner parameters) { + return createOrUpdateAsync(resourceGroupName, resourceName, name, parameters).block(); + } + + /** + * Create or update a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @param parameters A custom domain. + * @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 custom domain. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public CustomDomainInner createOrUpdate( + String resourceGroupName, String resourceName, String name, CustomDomainInner parameters, Context context) { + return createOrUpdateAsync(resourceGroupName, resourceName, name, parameters, context).block(); + } + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono>> deleteWithResponseAsync( + String resourceGroupName, String resourceName, String name) { + 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + if (name == null) { + return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext( + context -> + service + .delete( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + name, + this.client.getApiVersion(), + accept, + context)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono>> deleteWithResponseAsync( + String resourceGroupName, String resourceName, String name, 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 (resourceName == null) { + return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null.")); + } + if (name == null) { + return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service + .delete( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + resourceName, + name, + this.client.getApiVersion(), + accept, + context); + } + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, Void> beginDeleteAsync( + String resourceGroupName, String resourceName, String name) { + Mono>> mono = deleteWithResponseAsync(resourceGroupName, resourceName, name); + return this + .client + .getLroResult( + mono, this.client.getHttpPipeline(), Void.class, Void.class, this.client.getContext()); + } + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, Void> beginDeleteAsync( + String resourceGroupName, String resourceName, String name, Context context) { + context = this.client.mergeContext(context); + Mono>> mono = deleteWithResponseAsync(resourceGroupName, resourceName, name, context); + return this + .client + .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, context); + } + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, Void> beginDelete(String resourceGroupName, String resourceName, String name) { + return beginDeleteAsync(resourceGroupName, resourceName, name).getSyncPoller(); + } + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, Void> beginDelete( + String resourceGroupName, String resourceName, String name, Context context) { + return beginDeleteAsync(resourceGroupName, resourceName, name, context).getSyncPoller(); + } + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono deleteAsync(String resourceGroupName, String resourceName, String name) { + return beginDeleteAsync(resourceGroupName, resourceName, name) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono deleteAsync(String resourceGroupName, String resourceName, String name, Context context) { + return beginDeleteAsync(resourceGroupName, resourceName, name, context) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public void delete(String resourceGroupName, String resourceName, String name) { + deleteAsync(resourceGroupName, resourceName, name).block(); + } + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public void delete(String resourceGroupName, String resourceName, String name, Context context) { + deleteAsync(resourceGroupName, resourceName, name, context).block(); + } + + /** + * Get the next page of items. + * + * @param nextLink 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 custom domains list along with {@link PagedResponse} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listNextSinglePageAsync(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.listNext(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 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 custom domains list along with {@link PagedResponse} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listNextSinglePageAsync(String nextLink, Context context) { + 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"; + context = this.client.mergeContext(context); + return service + .listNext(nextLink, this.client.getEndpoint(), accept, context) + .map( + res -> + new PagedResponseBase<>( + res.getRequest(), + res.getStatusCode(), + res.getHeaders(), + res.getValue().value(), + res.getValue().nextLink(), + null)); + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRCustomDomainsImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRCustomDomainsImpl.java new file mode 100644 index 0000000000000..8aa937839ce6b --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRCustomDomainsImpl.java @@ -0,0 +1,187 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.implementation; + +import com.azure.core.http.rest.PagedIterable; +import com.azure.core.http.rest.Response; +import com.azure.core.http.rest.SimpleResponse; +import com.azure.core.util.Context; +import com.azure.core.util.logging.ClientLogger; +import com.azure.resourcemanager.signalr.fluent.SignalRCustomDomainsClient; +import com.azure.resourcemanager.signalr.fluent.models.CustomDomainInner; +import com.azure.resourcemanager.signalr.models.CustomDomain; +import com.azure.resourcemanager.signalr.models.SignalRCustomDomains; + +public final class SignalRCustomDomainsImpl implements SignalRCustomDomains { + private static final ClientLogger LOGGER = new ClientLogger(SignalRCustomDomainsImpl.class); + + private final SignalRCustomDomainsClient innerClient; + + private final com.azure.resourcemanager.signalr.SignalRManager serviceManager; + + public SignalRCustomDomainsImpl( + SignalRCustomDomainsClient innerClient, com.azure.resourcemanager.signalr.SignalRManager serviceManager) { + this.innerClient = innerClient; + this.serviceManager = serviceManager; + } + + public PagedIterable list(String resourceGroupName, String resourceName) { + PagedIterable inner = this.serviceClient().list(resourceGroupName, resourceName); + return Utils.mapPage(inner, inner1 -> new CustomDomainImpl(inner1, this.manager())); + } + + public PagedIterable list(String resourceGroupName, String resourceName, Context context) { + PagedIterable inner = this.serviceClient().list(resourceGroupName, resourceName, context); + return Utils.mapPage(inner, inner1 -> new CustomDomainImpl(inner1, this.manager())); + } + + public CustomDomain get(String resourceGroupName, String resourceName, String name) { + CustomDomainInner inner = this.serviceClient().get(resourceGroupName, resourceName, name); + if (inner != null) { + return new CustomDomainImpl(inner, this.manager()); + } else { + return null; + } + } + + public Response getWithResponse( + String resourceGroupName, String resourceName, String name, Context context) { + Response inner = + this.serviceClient().getWithResponse(resourceGroupName, resourceName, name, context); + if (inner != null) { + return new SimpleResponse<>( + inner.getRequest(), + inner.getStatusCode(), + inner.getHeaders(), + new CustomDomainImpl(inner.getValue(), this.manager())); + } else { + return null; + } + } + + public void delete(String resourceGroupName, String resourceName, String name) { + this.serviceClient().delete(resourceGroupName, resourceName, name); + } + + public void delete(String resourceGroupName, String resourceName, String name, Context context) { + this.serviceClient().delete(resourceGroupName, resourceName, name, context); + } + + public CustomDomain getById(String id) { + String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); + if (resourceGroupName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String + .format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id))); + } + String resourceName = Utils.getValueFromIdByName(id, "signalR"); + if (resourceName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); + } + String name = Utils.getValueFromIdByName(id, "customDomains"); + if (name == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String.format("The resource ID '%s' is not valid. Missing path segment 'customDomains'.", id))); + } + return this.getWithResponse(resourceGroupName, resourceName, name, Context.NONE).getValue(); + } + + public Response getByIdWithResponse(String id, Context context) { + String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); + if (resourceGroupName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String + .format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id))); + } + String resourceName = Utils.getValueFromIdByName(id, "signalR"); + if (resourceName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); + } + String name = Utils.getValueFromIdByName(id, "customDomains"); + if (name == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String.format("The resource ID '%s' is not valid. Missing path segment 'customDomains'.", id))); + } + return this.getWithResponse(resourceGroupName, resourceName, name, context); + } + + public void deleteById(String id) { + String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); + if (resourceGroupName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String + .format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id))); + } + String resourceName = Utils.getValueFromIdByName(id, "signalR"); + if (resourceName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); + } + String name = Utils.getValueFromIdByName(id, "customDomains"); + if (name == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String.format("The resource ID '%s' is not valid. Missing path segment 'customDomains'.", id))); + } + this.delete(resourceGroupName, resourceName, name, Context.NONE); + } + + public void deleteByIdWithResponse(String id, Context context) { + String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); + if (resourceGroupName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String + .format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id))); + } + String resourceName = Utils.getValueFromIdByName(id, "signalR"); + if (resourceName == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); + } + String name = Utils.getValueFromIdByName(id, "customDomains"); + if (name == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + String.format("The resource ID '%s' is not valid. Missing path segment 'customDomains'.", id))); + } + this.delete(resourceGroupName, resourceName, name, context); + } + + private SignalRCustomDomainsClient serviceClient() { + return this.innerClient; + } + + private com.azure.resourcemanager.signalr.SignalRManager manager() { + return this.serviceManager; + } + + public CustomDomainImpl define(String name) { + return new CustomDomainImpl(name, this.manager()); + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRManagementClientBuilder.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRManagementClientBuilder.java index 0b4dc0b02defd..ae76bfadccf46 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRManagementClientBuilder.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRManagementClientBuilder.java @@ -7,7 +7,6 @@ import com.azure.core.annotation.ServiceClientBuilder; import com.azure.core.http.HttpPipeline; import com.azure.core.http.HttpPipelineBuilder; -import com.azure.core.http.policy.CookiePolicy; import com.azure.core.http.policy.RetryPolicy; import com.azure.core.http.policy.UserAgentPolicy; import com.azure.core.management.AzureEnvironment; @@ -70,34 +69,34 @@ public SignalRManagementClientBuilder environment(AzureEnvironment environment) } /* - * The default poll interval for long-running operation + * The HTTP pipeline to send requests through */ - private Duration defaultPollInterval; + private HttpPipeline pipeline; /** - * Sets The default poll interval for long-running operation. + * Sets The HTTP pipeline to send requests through. * - * @param defaultPollInterval the defaultPollInterval value. + * @param pipeline the pipeline value. * @return the SignalRManagementClientBuilder. */ - public SignalRManagementClientBuilder defaultPollInterval(Duration defaultPollInterval) { - this.defaultPollInterval = defaultPollInterval; + public SignalRManagementClientBuilder pipeline(HttpPipeline pipeline) { + this.pipeline = pipeline; return this; } /* - * The HTTP pipeline to send requests through + * The default poll interval for long-running operation */ - private HttpPipeline pipeline; + private Duration defaultPollInterval; /** - * Sets The HTTP pipeline to send requests through. + * Sets The default poll interval for long-running operation. * - * @param pipeline the pipeline value. + * @param defaultPollInterval the defaultPollInterval value. * @return the SignalRManagementClientBuilder. */ - public SignalRManagementClientBuilder pipeline(HttpPipeline pipeline) { - this.pipeline = pipeline; + public SignalRManagementClientBuilder defaultPollInterval(Duration defaultPollInterval) { + this.defaultPollInterval = defaultPollInterval; return this; } @@ -123,21 +122,21 @@ public SignalRManagementClientBuilder serializerAdapter(SerializerAdapter serial * @return an instance of SignalRManagementClientImpl. */ public SignalRManagementClientImpl buildClient() { + if (pipeline == null) { + this.pipeline = new HttpPipelineBuilder().policies(new UserAgentPolicy(), new RetryPolicy()).build(); + } if (endpoint == null) { this.endpoint = "https://management.azure.com"; } if (environment == null) { this.environment = AzureEnvironment.AZURE; } + if (pipeline == null) { + this.pipeline = new HttpPipelineBuilder().policies(new UserAgentPolicy(), new RetryPolicy()).build(); + } if (defaultPollInterval == null) { this.defaultPollInterval = Duration.ofSeconds(30); } - if (pipeline == null) { - this.pipeline = - new HttpPipelineBuilder() - .policies(new UserAgentPolicy(), new RetryPolicy(), new CookiePolicy()) - .build(); - } if (serializerAdapter == null) { this.serializerAdapter = SerializerFactory.createDefaultManagementSerializerAdapter(); } diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRManagementClientImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRManagementClientImpl.java index babb2233e0a0b..a6f61485ff84f 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRManagementClientImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRManagementClientImpl.java @@ -22,6 +22,8 @@ import com.azure.core.util.serializer.SerializerAdapter; import com.azure.core.util.serializer.SerializerEncoding; import com.azure.resourcemanager.signalr.fluent.OperationsClient; +import com.azure.resourcemanager.signalr.fluent.SignalRCustomCertificatesClient; +import com.azure.resourcemanager.signalr.fluent.SignalRCustomDomainsClient; import com.azure.resourcemanager.signalr.fluent.SignalRManagementClient; import com.azure.resourcemanager.signalr.fluent.SignalRPrivateEndpointConnectionsClient; import com.azure.resourcemanager.signalr.fluent.SignalRPrivateLinkResourcesClient; @@ -41,8 +43,6 @@ /** Initializes a new instance of the SignalRManagementClientImpl type. */ @ServiceClient(builder = SignalRManagementClientBuilder.class) public final class SignalRManagementClientImpl implements SignalRManagementClient { - private final ClientLogger logger = new ClientLogger(SignalRManagementClientImpl.class); - /** * Gets subscription Id which uniquely identify the Microsoft Azure subscription. The subscription ID forms part of * the URI for every service call. @@ -155,6 +155,30 @@ public UsagesClient getUsages() { return this.usages; } + /** The SignalRCustomCertificatesClient object to access its operations. */ + private final SignalRCustomCertificatesClient signalRCustomCertificates; + + /** + * Gets the SignalRCustomCertificatesClient object to access its operations. + * + * @return the SignalRCustomCertificatesClient object. + */ + public SignalRCustomCertificatesClient getSignalRCustomCertificates() { + return this.signalRCustomCertificates; + } + + /** The SignalRCustomDomainsClient object to access its operations. */ + private final SignalRCustomDomainsClient signalRCustomDomains; + + /** + * Gets the SignalRCustomDomainsClient object to access its operations. + * + * @return the SignalRCustomDomainsClient object. + */ + public SignalRCustomDomainsClient getSignalRCustomDomains() { + return this.signalRCustomDomains; + } + /** The SignalRPrivateEndpointConnectionsClient object to access its operations. */ private final SignalRPrivateEndpointConnectionsClient signalRPrivateEndpointConnections; @@ -214,10 +238,12 @@ public SignalRSharedPrivateLinkResourcesClient getSignalRSharedPrivateLinkResour this.defaultPollInterval = defaultPollInterval; this.subscriptionId = subscriptionId; this.endpoint = endpoint; - this.apiVersion = "2021-10-01"; + this.apiVersion = "2022-02-01"; this.operations = new OperationsClientImpl(this); this.signalRs = new SignalRsClientImpl(this); this.usages = new UsagesClientImpl(this); + this.signalRCustomCertificates = new SignalRCustomCertificatesClientImpl(this); + this.signalRCustomDomains = new SignalRCustomDomainsClientImpl(this); this.signalRPrivateEndpointConnections = new SignalRPrivateEndpointConnectionsClientImpl(this); this.signalRPrivateLinkResources = new SignalRPrivateLinkResourcesClientImpl(this); this.signalRSharedPrivateLinkResources = new SignalRSharedPrivateLinkResourcesClientImpl(this); @@ -306,7 +332,7 @@ public Mono getLroFinalResultOrError(AsyncPollResponse, managementError = null; } } catch (IOException | RuntimeException ioe) { - logger.logThrowableAsWarning(ioe); + LOGGER.logThrowableAsWarning(ioe); } } } else { @@ -365,4 +391,6 @@ public Mono getBodyAsString(Charset charset) { return Mono.just(new String(responseBody, charset)); } } + + private static final ClientLogger LOGGER = new ClientLogger(SignalRManagementClientImpl.class); } diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateEndpointConnectionsClientImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateEndpointConnectionsClientImpl.java index f827a95dce59a..9be30bb0d9c2b 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateEndpointConnectionsClientImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateEndpointConnectionsClientImpl.java @@ -29,7 +29,6 @@ import com.azure.core.management.polling.PollResult; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.core.util.polling.PollerFlux; import com.azure.core.util.polling.SyncPoller; import com.azure.resourcemanager.signalr.fluent.SignalRPrivateEndpointConnectionsClient; @@ -43,8 +42,6 @@ * An instance of this class provides access to all the operations defined in SignalRPrivateEndpointConnectionsClient. */ public final class SignalRPrivateEndpointConnectionsClientImpl implements SignalRPrivateEndpointConnectionsClient { - private final ClientLogger logger = new ClientLogger(SignalRPrivateEndpointConnectionsClientImpl.class); - /** The proxy service used to perform REST calls. */ private final SignalRPrivateEndpointConnectionsService service; @@ -157,7 +154,8 @@ Mono> listNext( * @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 private endpoint connections. + * @return a list of private endpoint connections along with {@link PagedResponse} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync( @@ -216,7 +214,8 @@ private Mono> listSinglePageAsync( * @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 private endpoint connections. + * @return a list of private endpoint connections along with {@link PagedResponse} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync( @@ -271,7 +270,7 @@ private Mono> listSinglePageAsync( * @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 private endpoint connections. + * @return a list of private endpoint connections as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String resourceGroupName, String resourceName) { @@ -289,7 +288,7 @@ private PagedFlux listAsync(String resourceGroup * @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 private endpoint connections. + * @return a list of private endpoint connections as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync( @@ -308,7 +307,7 @@ private PagedFlux listAsync( * @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 private endpoint connections. + * @return a list of private endpoint connections as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(String resourceGroupName, String resourceName) { @@ -325,7 +324,7 @@ public PagedIterable list(String resourceGroupNa * @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 private endpoint connections. + * @return a list of private endpoint connections as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list( @@ -343,7 +342,8 @@ public PagedIterable list( * @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 specified private endpoint connection. + * @return the specified private endpoint connection along with {@link Response} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getWithResponseAsync( @@ -401,7 +401,8 @@ private Mono> getWithResponseAsync( * @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 specified private endpoint connection. + * @return the specified private endpoint connection along with {@link Response} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getWithResponseAsync( @@ -455,7 +456,7 @@ private Mono> getWithResponseAsync( * @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 specified private endpoint connection. + * @return the specified private endpoint connection on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono getAsync( @@ -500,7 +501,7 @@ public PrivateEndpointConnectionInner get( * @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 specified private endpoint connection. + * @return the specified private endpoint connection along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response getWithResponse( @@ -519,7 +520,8 @@ public Response getWithResponse( * @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 private endpoint connection to an azure resource. + * @return a private endpoint connection to an azure resource along with {@link Response} on successful completion + * of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> updateWithResponseAsync( @@ -587,7 +589,8 @@ private Mono> updateWithResponseAsync( * @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 private endpoint connection to an azure resource. + * @return a private endpoint connection to an azure resource along with {@link Response} on successful completion + * of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> updateWithResponseAsync( @@ -652,7 +655,7 @@ private Mono> updateWithResponseAsync( * @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 private endpoint connection to an azure resource. + * @return a private endpoint connection to an azure resource on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono updateAsync( @@ -705,7 +708,7 @@ public PrivateEndpointConnectionInner update( * @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 private endpoint connection to an azure resource. + * @return a private endpoint connection to an azure resource along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response updateWithResponse( @@ -729,7 +732,7 @@ public Response updateWithResponse( * @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 completion. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> deleteWithResponseAsync( @@ -787,7 +790,7 @@ private Mono>> deleteWithResponseAsync( * @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 completion. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> deleteWithResponseAsync( @@ -841,7 +844,7 @@ private Mono>> deleteWithResponseAsync( * @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 completion. + * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginDeleteAsync( @@ -850,7 +853,8 @@ private PollerFlux, Void> beginDeleteAsync( deleteWithResponseAsync(privateEndpointConnectionName, resourceGroupName, resourceName); return this .client - .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, Context.NONE); + .getLroResult( + mono, this.client.getHttpPipeline(), Void.class, Void.class, this.client.getContext()); } /** @@ -864,7 +868,7 @@ private PollerFlux, Void> beginDeleteAsync( * @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 completion. + * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginDeleteAsync( @@ -887,7 +891,7 @@ private PollerFlux, Void> beginDeleteAsync( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginDelete( @@ -906,7 +910,7 @@ public SyncPoller, Void> beginDelete( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginDelete( @@ -925,7 +929,7 @@ public SyncPoller, Void> beginDelete( * @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 completion. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono deleteAsync( @@ -946,7 +950,7 @@ private Mono deleteAsync( * @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 completion. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono deleteAsync( @@ -997,7 +1001,8 @@ public void delete( * @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 private endpoint connections. + * @return a list of private endpoint connections along with {@link PagedResponse} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink) { @@ -1033,7 +1038,8 @@ private Mono> listNextSinglePageAs * @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 private endpoint connections. + * @return a list of private endpoint connections along with {@link PagedResponse} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync( diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateEndpointConnectionsImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateEndpointConnectionsImpl.java index d45cbd04ab3a2..bda21d2d212ba 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateEndpointConnectionsImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateEndpointConnectionsImpl.java @@ -13,10 +13,9 @@ import com.azure.resourcemanager.signalr.fluent.models.PrivateEndpointConnectionInner; import com.azure.resourcemanager.signalr.models.PrivateEndpointConnection; import com.azure.resourcemanager.signalr.models.SignalRPrivateEndpointConnections; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class SignalRPrivateEndpointConnectionsImpl implements SignalRPrivateEndpointConnections { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRPrivateEndpointConnectionsImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(SignalRPrivateEndpointConnectionsImpl.class); private final SignalRPrivateEndpointConnectionsClient innerClient; diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateLinkResourcesClientImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateLinkResourcesClientImpl.java index 4741ed21e877d..65d62d1793b33 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateLinkResourcesClientImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateLinkResourcesClientImpl.java @@ -25,7 +25,6 @@ import com.azure.core.management.exception.ManagementException; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.fluent.SignalRPrivateLinkResourcesClient; import com.azure.resourcemanager.signalr.fluent.models.PrivateLinkResourceInner; import com.azure.resourcemanager.signalr.models.PrivateLinkResourceList; @@ -33,8 +32,6 @@ /** An instance of this class provides access to all the operations defined in SignalRPrivateLinkResourcesClient. */ public final class SignalRPrivateLinkResourcesClientImpl implements SignalRPrivateLinkResourcesClient { - private final ClientLogger logger = new ClientLogger(SignalRPrivateLinkResourcesClientImpl.class); - /** The proxy service used to perform REST calls. */ private final SignalRPrivateLinkResourcesService service; @@ -96,7 +93,8 @@ Mono> listNext( * @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 private link resources that need to be created for a resource. + * @return the private link resources that need to be created for a resource along with {@link PagedResponse} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync( @@ -155,7 +153,8 @@ private Mono> listSinglePageAsync( * @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 private link resources that need to be created for a resource. + * @return the private link resources that need to be created for a resource along with {@link PagedResponse} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync( @@ -210,7 +209,8 @@ private Mono> listSinglePageAsync( * @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 private link resources that need to be created for a resource. + * @return the private link resources that need to be created for a resource as paginated response with {@link + * PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String resourceGroupName, String resourceName) { @@ -228,7 +228,8 @@ private PagedFlux listAsync(String resourceGroupName, * @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 private link resources that need to be created for a resource. + * @return the private link resources that need to be created for a resource as paginated response with {@link + * PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync( @@ -247,7 +248,8 @@ private PagedFlux listAsync( * @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 private link resources that need to be created for a resource. + * @return the private link resources that need to be created for a resource as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(String resourceGroupName, String resourceName) { @@ -264,7 +266,8 @@ public PagedIterable list(String resourceGroupName, St * @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 private link resources that need to be created for a resource. + * @return the private link resources that need to be created for a resource as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list( @@ -279,7 +282,8 @@ public PagedIterable list( * @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 contains a list of PrivateLinkResource and a possible link to query more results. + * @return contains a list of PrivateLinkResource and a possible link to query more results along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink) { @@ -315,7 +319,8 @@ private Mono> listNextSinglePageAsync(St * @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 contains a list of PrivateLinkResource and a possible link to query more results. + * @return contains a list of PrivateLinkResource and a possible link to query more results along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink, Context context) { diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateLinkResourcesImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateLinkResourcesImpl.java index cd5ae5d86b534..46ad282857a00 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateLinkResourcesImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRPrivateLinkResourcesImpl.java @@ -11,10 +11,9 @@ import com.azure.resourcemanager.signalr.fluent.models.PrivateLinkResourceInner; import com.azure.resourcemanager.signalr.models.PrivateLinkResource; import com.azure.resourcemanager.signalr.models.SignalRPrivateLinkResources; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class SignalRPrivateLinkResourcesImpl implements SignalRPrivateLinkResources { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRPrivateLinkResourcesImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(SignalRPrivateLinkResourcesImpl.class); private final SignalRPrivateLinkResourcesClient innerClient; diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRResourceImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRResourceImpl.java index bcc7ef12607e5..c00a921baecc3 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRResourceImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRResourceImpl.java @@ -11,6 +11,7 @@ import com.azure.resourcemanager.signalr.fluent.models.PrivateEndpointConnectionInner; import com.azure.resourcemanager.signalr.fluent.models.SharedPrivateLinkResourceInner; import com.azure.resourcemanager.signalr.fluent.models.SignalRResourceInner; +import com.azure.resourcemanager.signalr.models.LiveTraceConfiguration; import com.azure.resourcemanager.signalr.models.ManagedIdentity; import com.azure.resourcemanager.signalr.models.PrivateEndpointConnection; import com.azure.resourcemanager.signalr.models.ProvisioningState; @@ -146,6 +147,10 @@ public List features() { } } + public LiveTraceConfiguration liveTraceConfiguration() { + return this.innerModel().liveTraceConfiguration(); + } + public ResourceLogConfiguration resourceLogConfiguration() { return this.innerModel().resourceLogConfiguration(); } @@ -337,6 +342,11 @@ public SignalRResourceImpl withFeatures(List features) { return this; } + public SignalRResourceImpl withLiveTraceConfiguration(LiveTraceConfiguration liveTraceConfiguration) { + this.innerModel().withLiveTraceConfiguration(liveTraceConfiguration); + return this; + } + public SignalRResourceImpl withResourceLogConfiguration(ResourceLogConfiguration resourceLogConfiguration) { this.innerModel().withResourceLogConfiguration(resourceLogConfiguration); return this; diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRSharedPrivateLinkResourcesClientImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRSharedPrivateLinkResourcesClientImpl.java index 6dd28baad06bd..2fc47408ffa8b 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRSharedPrivateLinkResourcesClientImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRSharedPrivateLinkResourcesClientImpl.java @@ -29,7 +29,6 @@ import com.azure.core.management.polling.PollResult; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.core.util.polling.PollerFlux; import com.azure.core.util.polling.SyncPoller; import com.azure.resourcemanager.signalr.fluent.SignalRSharedPrivateLinkResourcesClient; @@ -43,8 +42,6 @@ * An instance of this class provides access to all the operations defined in SignalRSharedPrivateLinkResourcesClient. */ public final class SignalRSharedPrivateLinkResourcesClientImpl implements SignalRSharedPrivateLinkResourcesClient { - private final ClientLogger logger = new ClientLogger(SignalRSharedPrivateLinkResourcesClientImpl.class); - /** The proxy service used to perform REST calls. */ private final SignalRSharedPrivateLinkResourcesService service; @@ -157,7 +154,8 @@ Mono> listNext( * @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 shared private link resources. + * @return a list of shared private link resources along with {@link PagedResponse} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync( @@ -216,7 +214,8 @@ private Mono> listSinglePageAsync( * @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 shared private link resources. + * @return a list of shared private link resources along with {@link PagedResponse} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync( @@ -271,7 +270,7 @@ private Mono> listSinglePageAsync( * @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 shared private link resources. + * @return a list of shared private link resources as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String resourceGroupName, String resourceName) { @@ -289,7 +288,7 @@ private PagedFlux listAsync(String resourceGroup * @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 shared private link resources. + * @return a list of shared private link resources as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync( @@ -308,7 +307,7 @@ private PagedFlux listAsync( * @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 shared private link resources. + * @return a list of shared private link resources as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(String resourceGroupName, String resourceName) { @@ -325,7 +324,7 @@ public PagedIterable list(String resourceGroupNa * @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 shared private link resources. + * @return a list of shared private link resources as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list( @@ -343,7 +342,8 @@ public PagedIterable list( * @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 specified shared private link resource. + * @return the specified shared private link resource along with {@link Response} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getWithResponseAsync( @@ -401,7 +401,8 @@ private Mono> getWithResponseAsync( * @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 specified shared private link resource. + * @return the specified shared private link resource along with {@link Response} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getWithResponseAsync( @@ -455,7 +456,7 @@ private Mono> getWithResponseAsync( * @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 specified shared private link resource. + * @return the specified shared private link resource on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono getAsync( @@ -500,7 +501,7 @@ public SharedPrivateLinkResourceInner get( * @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 specified shared private link resource. + * @return the specified shared private link resource along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response getWithResponse( @@ -519,7 +520,8 @@ public Response getWithResponse( * @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 describes a Shared Private Link Resource. + * @return describes a Shared Private Link Resource along with {@link Response} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> createOrUpdateWithResponseAsync( @@ -587,7 +589,8 @@ private Mono>> createOrUpdateWithResponseAsync( * @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 describes a Shared Private Link Resource. + * @return describes a Shared Private Link Resource along with {@link Response} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> createOrUpdateWithResponseAsync( @@ -652,7 +655,7 @@ private Mono>> createOrUpdateWithResponseAsync( * @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 describes a Shared Private Link Resource. + * @return the {@link PollerFlux} for polling of describes a Shared Private Link Resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, SharedPrivateLinkResourceInner> @@ -670,7 +673,7 @@ private Mono>> createOrUpdateWithResponseAsync( this.client.getHttpPipeline(), SharedPrivateLinkResourceInner.class, SharedPrivateLinkResourceInner.class, - Context.NONE); + this.client.getContext()); } /** @@ -685,7 +688,7 @@ private Mono>> createOrUpdateWithResponseAsync( * @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 describes a Shared Private Link Resource. + * @return the {@link PollerFlux} for polling of describes a Shared Private Link Resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, SharedPrivateLinkResourceInner> @@ -720,7 +723,7 @@ private Mono>> createOrUpdateWithResponseAsync( * @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 describes a Shared Private Link Resource. + * @return the {@link SyncPoller} for polling of describes a Shared Private Link Resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, SharedPrivateLinkResourceInner> beginCreateOrUpdate( @@ -744,7 +747,7 @@ public SyncPoller, SharedPrivateLinkR * @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 describes a Shared Private Link Resource. + * @return the {@link SyncPoller} for polling of describes a Shared Private Link Resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, SharedPrivateLinkResourceInner> beginCreateOrUpdate( @@ -769,7 +772,7 @@ public SyncPoller, SharedPrivateLinkR * @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 describes a Shared Private Link Resource. + * @return describes a Shared Private Link Resource on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono createOrUpdateAsync( @@ -794,7 +797,7 @@ private Mono createOrUpdateAsync( * @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 describes a Shared Private Link Resource. + * @return describes a Shared Private Link Resource on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono createOrUpdateAsync( @@ -866,7 +869,7 @@ public SharedPrivateLinkResourceInner createOrUpdate( * @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 completion. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> deleteWithResponseAsync( @@ -924,7 +927,7 @@ private Mono>> deleteWithResponseAsync( * @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 completion. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> deleteWithResponseAsync( @@ -978,7 +981,7 @@ private Mono>> deleteWithResponseAsync( * @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 completion. + * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginDeleteAsync( @@ -987,7 +990,8 @@ private PollerFlux, Void> beginDeleteAsync( deleteWithResponseAsync(sharedPrivateLinkResourceName, resourceGroupName, resourceName); return this .client - .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, Context.NONE); + .getLroResult( + mono, this.client.getHttpPipeline(), Void.class, Void.class, this.client.getContext()); } /** @@ -1001,7 +1005,7 @@ private PollerFlux, Void> beginDeleteAsync( * @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 completion. + * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginDeleteAsync( @@ -1024,7 +1028,7 @@ private PollerFlux, Void> beginDeleteAsync( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginDelete( @@ -1043,7 +1047,7 @@ public SyncPoller, Void> beginDelete( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginDelete( @@ -1062,7 +1066,7 @@ public SyncPoller, Void> beginDelete( * @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 completion. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono deleteAsync( @@ -1083,7 +1087,7 @@ private Mono deleteAsync( * @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 completion. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono deleteAsync( @@ -1134,7 +1138,8 @@ public void delete( * @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 shared private link resources. + * @return a list of shared private link resources along with {@link PagedResponse} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink) { @@ -1170,7 +1175,8 @@ private Mono> listNextSinglePageAs * @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 shared private link resources. + * @return a list of shared private link resources along with {@link PagedResponse} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync( diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRSharedPrivateLinkResourcesImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRSharedPrivateLinkResourcesImpl.java index a51e61a92cee1..843196b57b322 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRSharedPrivateLinkResourcesImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRSharedPrivateLinkResourcesImpl.java @@ -13,10 +13,9 @@ import com.azure.resourcemanager.signalr.fluent.models.SharedPrivateLinkResourceInner; import com.azure.resourcemanager.signalr.models.SharedPrivateLinkResource; import com.azure.resourcemanager.signalr.models.SignalRSharedPrivateLinkResources; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class SignalRSharedPrivateLinkResourcesImpl implements SignalRSharedPrivateLinkResources { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRSharedPrivateLinkResourcesImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(SignalRSharedPrivateLinkResourcesImpl.class); private final SignalRSharedPrivateLinkResourcesClient innerClient; @@ -82,7 +81,7 @@ public void delete( public SharedPrivateLinkResource getById(String id) { String sharedPrivateLinkResourceName = Utils.getValueFromIdByName(id, "sharedPrivateLinkResources"); if (sharedPrivateLinkResourceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -92,7 +91,7 @@ public SharedPrivateLinkResource getById(String id) { } String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -100,7 +99,7 @@ public SharedPrivateLinkResource getById(String id) { } String resourceName = Utils.getValueFromIdByName(id, "signalR"); if (resourceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); @@ -113,7 +112,7 @@ public SharedPrivateLinkResource getById(String id) { public Response getByIdWithResponse(String id, Context context) { String sharedPrivateLinkResourceName = Utils.getValueFromIdByName(id, "sharedPrivateLinkResources"); if (sharedPrivateLinkResourceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -123,7 +122,7 @@ public Response getByIdWithResponse(String id, Contex } String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -131,7 +130,7 @@ public Response getByIdWithResponse(String id, Contex } String resourceName = Utils.getValueFromIdByName(id, "signalR"); if (resourceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); @@ -142,7 +141,7 @@ public Response getByIdWithResponse(String id, Contex public void deleteById(String id) { String sharedPrivateLinkResourceName = Utils.getValueFromIdByName(id, "sharedPrivateLinkResources"); if (sharedPrivateLinkResourceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -152,7 +151,7 @@ public void deleteById(String id) { } String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -160,7 +159,7 @@ public void deleteById(String id) { } String resourceName = Utils.getValueFromIdByName(id, "signalR"); if (resourceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); @@ -171,7 +170,7 @@ public void deleteById(String id) { public void deleteByIdWithResponse(String id, Context context) { String sharedPrivateLinkResourceName = Utils.getValueFromIdByName(id, "sharedPrivateLinkResources"); if (sharedPrivateLinkResourceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -181,7 +180,7 @@ public void deleteByIdWithResponse(String id, Context context) { } String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -189,7 +188,7 @@ public void deleteByIdWithResponse(String id, Context context) { } String resourceName = Utils.getValueFromIdByName(id, "signalR"); if (resourceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRsClientImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRsClientImpl.java index b20cee750b5b9..f0530866d1ba9 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRsClientImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRsClientImpl.java @@ -31,7 +31,6 @@ import com.azure.core.management.polling.PollResult; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.core.util.polling.PollerFlux; import com.azure.core.util.polling.SyncPoller; import com.azure.resourcemanager.signalr.fluent.SignalRsClient; @@ -48,8 +47,6 @@ /** An instance of this class provides access to all the operations defined in SignalRsClient. */ public final class SignalRsClientImpl implements SignalRsClient { - private final ClientLogger logger = new ClientLogger(SignalRsClientImpl.class); - /** The proxy service used to perform REST calls. */ private final SignalRsService service; @@ -265,7 +262,8 @@ Mono> listByResourceGroupNext( * @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 result of the request to check name availability. + * @return result of the request to check name availability along with {@link Response} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> checkNameAvailabilityWithResponseAsync( @@ -315,7 +313,8 @@ private Mono> checkNameAvailabilityWithResponseA * @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 result of the request to check name availability. + * @return result of the request to check name availability along with {@link Response} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> checkNameAvailabilityWithResponseAsync( @@ -361,7 +360,7 @@ private Mono> checkNameAvailabilityWithResponseA * @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 result of the request to check name availability. + * @return result of the request to check name availability on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono checkNameAvailabilityAsync( @@ -401,7 +400,7 @@ public NameAvailabilityInner checkNameAvailability(String location, NameAvailabi * @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 result of the request to check name availability. + * @return result of the request to check name availability along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response checkNameAvailabilityWithResponse( @@ -414,7 +413,8 @@ public Response checkNameAvailabilityWithResponse( * * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync() { @@ -460,7 +460,8 @@ private Mono> listSinglePageAsync() { * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync(Context context) { @@ -501,7 +502,8 @@ private Mono> listSinglePageAsync(Context co * * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync() { @@ -516,7 +518,8 @@ private PagedFlux listAsync() { * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(Context context) { @@ -529,7 +532,8 @@ private PagedFlux listAsync(Context context) { * * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list() { @@ -543,7 +547,8 @@ public PagedIterable list() { * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(Context context) { @@ -558,7 +563,8 @@ public PagedIterable list(Context context) { * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listByResourceGroupSinglePageAsync(String resourceGroupName) { @@ -611,7 +617,8 @@ private Mono> listByResourceGroupSinglePageA * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listByResourceGroupSinglePageAsync( @@ -661,7 +668,8 @@ private Mono> listByResourceGroupSinglePageA * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listByResourceGroupAsync(String resourceGroupName) { @@ -679,7 +687,8 @@ private PagedFlux listByResourceGroupAsync(String resource * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listByResourceGroupAsync(String resourceGroupName, Context context) { @@ -696,7 +705,8 @@ private PagedFlux listByResourceGroupAsync(String resource * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable listByResourceGroup(String resourceGroupName) { @@ -712,7 +722,8 @@ public PagedIterable listByResourceGroup(String resourceGr * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable listByResourceGroup(String resourceGroupName, Context context) { @@ -728,7 +739,7 @@ public PagedIterable listByResourceGroup(String resourceGr * @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 resource and its properties. + * @return the resource and its properties along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getByResourceGroupWithResponseAsync( @@ -778,7 +789,7 @@ private Mono> getByResourceGroupWithResponseAsync * @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 resource and its properties. + * @return the resource and its properties along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getByResourceGroupWithResponseAsync( @@ -824,7 +835,7 @@ private Mono> getByResourceGroupWithResponseAsync * @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 resource and its properties. + * @return the resource and its properties on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono getByResourceGroupAsync(String resourceGroupName, String resourceName) { @@ -865,7 +876,7 @@ public SignalRResourceInner getByResourceGroup(String resourceGroupName, String * @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 resource and its properties. + * @return the resource and its properties along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response getByResourceGroupWithResponse( @@ -883,7 +894,7 @@ public Response getByResourceGroupWithResponse( * @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 class represent a resource. + * @return a class represent a resource along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> createOrUpdateWithResponseAsync( @@ -940,7 +951,7 @@ private Mono>> createOrUpdateWithResponseAsync( * @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 class represent a resource. + * @return a class represent a resource along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> createOrUpdateWithResponseAsync( @@ -993,7 +1004,7 @@ private Mono>> createOrUpdateWithResponseAsync( * @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 class represent a resource. + * @return the {@link PollerFlux} for polling of a class represent a resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, SignalRResourceInner> beginCreateOrUpdateAsync( @@ -1007,7 +1018,7 @@ private PollerFlux, SignalRResourceInner> begin this.client.getHttpPipeline(), SignalRResourceInner.class, SignalRResourceInner.class, - Context.NONE); + this.client.getContext()); } /** @@ -1021,7 +1032,7 @@ private PollerFlux, SignalRResourceInner> begin * @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 class represent a resource. + * @return the {@link PollerFlux} for polling of a class represent a resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, SignalRResourceInner> beginCreateOrUpdateAsync( @@ -1045,7 +1056,7 @@ private PollerFlux, SignalRResourceInner> begin * @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 class represent a resource. + * @return the {@link SyncPoller} for polling of a class represent a resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, SignalRResourceInner> beginCreateOrUpdate( @@ -1064,7 +1075,7 @@ public SyncPoller, SignalRResourceInner> beginC * @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 class represent a resource. + * @return the {@link SyncPoller} for polling of a class represent a resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, SignalRResourceInner> beginCreateOrUpdate( @@ -1082,7 +1093,7 @@ public SyncPoller, SignalRResourceInner> beginC * @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 class represent a resource. + * @return a class represent a resource on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono createOrUpdateAsync( @@ -1103,7 +1114,7 @@ private Mono createOrUpdateAsync( * @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 class represent a resource. + * @return a class represent a resource on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono createOrUpdateAsync( @@ -1159,7 +1170,7 @@ public SignalRResourceInner createOrUpdate( * @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 completion. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> deleteWithResponseAsync(String resourceGroupName, String resourceName) { @@ -1208,7 +1219,7 @@ private Mono>> deleteWithResponseAsync(String resource * @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 completion. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> deleteWithResponseAsync( @@ -1254,14 +1265,15 @@ private Mono>> deleteWithResponseAsync( * @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 completion. + * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginDeleteAsync(String resourceGroupName, String resourceName) { Mono>> mono = deleteWithResponseAsync(resourceGroupName, resourceName); return this .client - .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, Context.NONE); + .getLroResult( + mono, this.client.getHttpPipeline(), Void.class, Void.class, this.client.getContext()); } /** @@ -1274,7 +1286,7 @@ private PollerFlux, Void> beginDeleteAsync(String resourceGroup * @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 completion. + * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginDeleteAsync( @@ -1295,7 +1307,7 @@ private PollerFlux, Void> beginDeleteAsync( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginDelete(String resourceGroupName, String resourceName) { @@ -1312,7 +1324,7 @@ public SyncPoller, Void> beginDelete(String resourceGroupName, * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginDelete( @@ -1329,7 +1341,7 @@ public SyncPoller, Void> beginDelete( * @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 completion. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono deleteAsync(String resourceGroupName, String resourceName) { @@ -1346,7 +1358,7 @@ private Mono deleteAsync(String resourceGroupName, String resourceName) { * @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 completion. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono deleteAsync(String resourceGroupName, String resourceName, Context context) { @@ -1396,7 +1408,7 @@ public void delete(String resourceGroupName, String resourceName, Context contex * @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 class represent a resource. + * @return a class represent a resource along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> updateWithResponseAsync( @@ -1453,7 +1465,7 @@ private Mono>> updateWithResponseAsync( * @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 class represent a resource. + * @return a class represent a resource along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> updateWithResponseAsync( @@ -1506,7 +1518,7 @@ private Mono>> updateWithResponseAsync( * @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 class represent a resource. + * @return the {@link PollerFlux} for polling of a class represent a resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, SignalRResourceInner> beginUpdateAsync( @@ -1519,7 +1531,7 @@ private PollerFlux, SignalRResourceInner> begin this.client.getHttpPipeline(), SignalRResourceInner.class, SignalRResourceInner.class, - Context.NONE); + this.client.getContext()); } /** @@ -1533,7 +1545,7 @@ private PollerFlux, SignalRResourceInner> begin * @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 class represent a resource. + * @return the {@link PollerFlux} for polling of a class represent a resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, SignalRResourceInner> beginUpdateAsync( @@ -1557,7 +1569,7 @@ private PollerFlux, SignalRResourceInner> begin * @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 class represent a resource. + * @return the {@link SyncPoller} for polling of a class represent a resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, SignalRResourceInner> beginUpdate( @@ -1576,7 +1588,7 @@ public SyncPoller, SignalRResourceInner> beginU * @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 class represent a resource. + * @return the {@link SyncPoller} for polling of a class represent a resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, SignalRResourceInner> beginUpdate( @@ -1594,7 +1606,7 @@ public SyncPoller, SignalRResourceInner> beginU * @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 class represent a resource. + * @return a class represent a resource on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono updateAsync( @@ -1615,7 +1627,7 @@ private Mono updateAsync( * @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 class represent a resource. + * @return a class represent a resource on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono updateAsync( @@ -1670,7 +1682,7 @@ public SignalRResourceInner update( * @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 access keys of the resource. + * @return the access keys of the resource along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listKeysWithResponseAsync(String resourceGroupName, String resourceName) { @@ -1719,7 +1731,7 @@ private Mono> listKeysWithResponseAsync(String resour * @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 access keys of the resource. + * @return the access keys of the resource along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listKeysWithResponseAsync( @@ -1765,7 +1777,7 @@ private Mono> listKeysWithResponseAsync( * @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 access keys of the resource. + * @return the access keys of the resource on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono listKeysAsync(String resourceGroupName, String resourceName) { @@ -1806,7 +1818,7 @@ public SignalRKeysInner listKeys(String resourceGroupName, String resourceName) * @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 access keys of the resource. + * @return the access keys of the resource along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response listKeysWithResponse( @@ -1824,7 +1836,8 @@ public Response listKeysWithResponse( * @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 class represents the access keys of the resource. + * @return a class represents the access keys of the resource along with {@link Response} on successful completion + * of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> regenerateKeyWithResponseAsync( @@ -1881,7 +1894,8 @@ private Mono>> regenerateKeyWithResponseAsync( * @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 class represents the access keys of the resource. + * @return a class represents the access keys of the resource along with {@link Response} on successful completion + * of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> regenerateKeyWithResponseAsync( @@ -1934,7 +1948,7 @@ private Mono>> regenerateKeyWithResponseAsync( * @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 class represents the access keys of the resource. + * @return the {@link PollerFlux} for polling of a class represents the access keys of the resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, SignalRKeysInner> beginRegenerateKeyAsync( @@ -1944,7 +1958,11 @@ private PollerFlux, SignalRKeysInner> beginRegenera return this .client .getLroResult( - mono, this.client.getHttpPipeline(), SignalRKeysInner.class, SignalRKeysInner.class, Context.NONE); + mono, + this.client.getHttpPipeline(), + SignalRKeysInner.class, + SignalRKeysInner.class, + this.client.getContext()); } /** @@ -1958,7 +1976,7 @@ private PollerFlux, SignalRKeysInner> beginRegenera * @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 class represents the access keys of the resource. + * @return the {@link PollerFlux} for polling of a class represents the access keys of the resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, SignalRKeysInner> beginRegenerateKeyAsync( @@ -1982,7 +2000,7 @@ private PollerFlux, SignalRKeysInner> beginRegenera * @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 class represents the access keys of the resource. + * @return the {@link SyncPoller} for polling of a class represents the access keys of the resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, SignalRKeysInner> beginRegenerateKey( @@ -2001,7 +2019,7 @@ public SyncPoller, SignalRKeysInner> beginRegenerat * @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 class represents the access keys of the resource. + * @return the {@link SyncPoller} for polling of a class represents the access keys of the resource. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, SignalRKeysInner> beginRegenerateKey( @@ -2019,7 +2037,7 @@ public SyncPoller, SignalRKeysInner> beginRegenerat * @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 class represents the access keys of the resource. + * @return a class represents the access keys of the resource on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono regenerateKeyAsync( @@ -2040,7 +2058,7 @@ private Mono regenerateKeyAsync( * @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 class represents the access keys of the resource. + * @return a class represents the access keys of the resource on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono regenerateKeyAsync( @@ -2096,7 +2114,7 @@ public SignalRKeysInner regenerateKey( * @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 completion. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> restartWithResponseAsync(String resourceGroupName, String resourceName) { @@ -2145,7 +2163,7 @@ private Mono>> restartWithResponseAsync(String resourc * @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 completion. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> restartWithResponseAsync( @@ -2191,14 +2209,15 @@ private Mono>> restartWithResponseAsync( * @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 completion. + * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginRestartAsync(String resourceGroupName, String resourceName) { Mono>> mono = restartWithResponseAsync(resourceGroupName, resourceName); return this .client - .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, Context.NONE); + .getLroResult( + mono, this.client.getHttpPipeline(), Void.class, Void.class, this.client.getContext()); } /** @@ -2211,7 +2230,7 @@ private PollerFlux, Void> beginRestartAsync(String resourceGrou * @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 completion. + * @return the {@link PollerFlux} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginRestartAsync( @@ -2232,7 +2251,7 @@ private PollerFlux, Void> beginRestartAsync( * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginRestart(String resourceGroupName, String resourceName) { @@ -2249,7 +2268,7 @@ public SyncPoller, Void> beginRestart(String resourceGroupName, * @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 completion. + * @return the {@link SyncPoller} for polling of long-running operation. */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginRestart( @@ -2266,7 +2285,7 @@ public SyncPoller, Void> beginRestart( * @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 completion. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono restartAsync(String resourceGroupName, String resourceName) { @@ -2283,7 +2302,7 @@ private Mono restartAsync(String resourceGroupName, String resourceName) { * @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 completion. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono restartAsync(String resourceGroupName, String resourceName, Context context) { @@ -2332,7 +2351,7 @@ public void restart(String resourceGroupName, String resourceName, Context conte * @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 list skus operation response. + * @return the list skus operation response along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSkusWithResponseAsync(String resourceGroupName, String resourceName) { @@ -2381,7 +2400,7 @@ private Mono> listSkusWithResponseAsync(String resourceGr * @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 list skus operation response. + * @return the list skus operation response along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSkusWithResponseAsync( @@ -2427,7 +2446,7 @@ private Mono> listSkusWithResponseAsync( * @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 list skus operation response. + * @return the list skus operation response on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono listSkusAsync(String resourceGroupName, String resourceName) { @@ -2468,7 +2487,7 @@ public SkuListInner listSkus(String resourceGroupName, String resourceName) { * @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 list skus operation response. + * @return the list skus operation response along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response listSkusWithResponse(String resourceGroupName, String resourceName, Context context) { @@ -2482,7 +2501,8 @@ public Response listSkusWithResponse(String resourceGroupName, Str * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listBySubscriptionNextSinglePageAsync(String nextLink) { @@ -2519,7 +2539,8 @@ private Mono> listBySubscriptionNextSinglePa * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listBySubscriptionNextSinglePageAsync( @@ -2555,7 +2576,8 @@ private Mono> listBySubscriptionNextSinglePa * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listByResourceGroupNextSinglePageAsync(String nextLink) { @@ -2592,7 +2614,8 @@ private Mono> listByResourceGroupNextSingleP * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listByResourceGroupNextSinglePageAsync( diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRsImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRsImpl.java index 8942a1458c873..a94bd201bfefa 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRsImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/SignalRsImpl.java @@ -21,10 +21,9 @@ import com.azure.resourcemanager.signalr.models.SignalRResource; import com.azure.resourcemanager.signalr.models.SignalRs; import com.azure.resourcemanager.signalr.models.SkuList; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class SignalRsImpl implements SignalRs { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRsImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(SignalRsImpl.class); private final SignalRsClient innerClient; @@ -190,7 +189,7 @@ public Response listSkusWithResponse(String resourceGroupName, String r public SignalRResource getById(String id) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -198,7 +197,7 @@ public SignalRResource getById(String id) { } String resourceName = Utils.getValueFromIdByName(id, "signalR"); if (resourceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); @@ -209,7 +208,7 @@ public SignalRResource getById(String id) { public Response getByIdWithResponse(String id, Context context) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -217,7 +216,7 @@ public Response getByIdWithResponse(String id, Context context) } String resourceName = Utils.getValueFromIdByName(id, "signalR"); if (resourceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); @@ -228,7 +227,7 @@ public Response getByIdWithResponse(String id, Context context) public void deleteById(String id) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -236,7 +235,7 @@ public void deleteById(String id) { } String resourceName = Utils.getValueFromIdByName(id, "signalR"); if (resourceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); @@ -247,7 +246,7 @@ public void deleteById(String id) { public void deleteByIdWithResponse(String id, Context context) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -255,7 +254,7 @@ public void deleteByIdWithResponse(String id, Context context) { } String resourceName = Utils.getValueFromIdByName(id, "signalR"); if (resourceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'signalR'.", id))); diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/UsagesClientImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/UsagesClientImpl.java index f4e20dc352124..212ea476081b3 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/UsagesClientImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/UsagesClientImpl.java @@ -25,7 +25,6 @@ import com.azure.core.management.exception.ManagementException; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.fluent.UsagesClient; import com.azure.resourcemanager.signalr.fluent.models.SignalRUsageInner; import com.azure.resourcemanager.signalr.models.SignalRUsageList; @@ -33,8 +32,6 @@ /** An instance of this class provides access to all the operations defined in UsagesClient. */ public final class UsagesClientImpl implements UsagesClient { - private final ClientLogger logger = new ClientLogger(UsagesClientImpl.class); - /** The proxy service used to perform REST calls. */ private final UsagesService service; @@ -88,7 +85,8 @@ Mono> listNext( * @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 object that includes an array of the resource usages and a possible link for next set. + * @return object that includes an array of the resource usages and a possible link for next set along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync(String location) { @@ -139,7 +137,8 @@ private Mono> listSinglePageAsync(String locati * @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 object that includes an array of the resource usages and a possible link for next set. + * @return object that includes an array of the resource usages and a possible link for next set along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync(String location, Context context) { @@ -186,7 +185,8 @@ private Mono> listSinglePageAsync(String locati * @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 object that includes an array of the resource usages and a possible link for next set. + * @return object that includes an array of the resource usages and a possible link for next set as paginated + * response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String location) { @@ -201,7 +201,8 @@ private PagedFlux listAsync(String location) { * @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 object that includes an array of the resource usages and a possible link for next set. + * @return object that includes an array of the resource usages and a possible link for next set as paginated + * response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String location, Context context) { @@ -216,7 +217,8 @@ private PagedFlux listAsync(String location, Context context) * @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 object that includes an array of the resource usages and a possible link for next set. + * @return object that includes an array of the resource usages and a possible link for next set as paginated + * response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(String location) { @@ -231,7 +233,8 @@ public PagedIterable list(String location) { * @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 object that includes an array of the resource usages and a possible link for next set. + * @return object that includes an array of the resource usages and a possible link for next set as paginated + * response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(String location, Context context) { @@ -245,7 +248,8 @@ public PagedIterable list(String location, Context context) { * @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 object that includes an array of the resource usages and a possible link for next set. + * @return object that includes an array of the resource usages and a possible link for next set along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink) { @@ -281,7 +285,8 @@ private Mono> listNextSinglePageAsync(String ne * @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 object that includes an array of the resource usages and a possible link for next set. + * @return object that includes an array of the resource usages and a possible link for next set along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink, Context context) { diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/UsagesImpl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/UsagesImpl.java index 0bd798fb8477b..f338e884d1d02 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/UsagesImpl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/implementation/UsagesImpl.java @@ -11,10 +11,9 @@ import com.azure.resourcemanager.signalr.fluent.models.SignalRUsageInner; import com.azure.resourcemanager.signalr.models.SignalRUsage; import com.azure.resourcemanager.signalr.models.Usages; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class UsagesImpl implements Usages { - @JsonIgnore private final ClientLogger logger = new ClientLogger(UsagesImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(UsagesImpl.class); private final UsagesClient innerClient; diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/CustomCertificate.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/CustomCertificate.java new file mode 100644 index 0000000000000..53733fa715277 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/CustomCertificate.java @@ -0,0 +1,193 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.models; + +import com.azure.core.management.SystemData; +import com.azure.core.util.Context; +import com.azure.resourcemanager.signalr.fluent.models.CustomCertificateInner; + +/** An immutable client-side representation of CustomCertificate. */ +public interface CustomCertificate { + /** + * Gets the id property: Fully qualified resource Id for the resource. + * + * @return the id value. + */ + String id(); + + /** + * Gets the name property: The name of the resource. + * + * @return the name value. + */ + String name(); + + /** + * Gets the type property: The type of the resource. + * + * @return the type value. + */ + String type(); + + /** + * Gets the systemData property: Metadata pertaining to creation and last modification of the resource. + * + * @return the systemData value. + */ + SystemData systemData(); + + /** + * Gets the provisioningState property: Provisioning state of the resource. + * + * @return the provisioningState value. + */ + ProvisioningState provisioningState(); + + /** + * Gets the keyVaultBaseUri property: Base uri of the KeyVault that stores certificate. + * + * @return the keyVaultBaseUri value. + */ + String keyVaultBaseUri(); + + /** + * Gets the keyVaultSecretName property: Certificate secret name. + * + * @return the keyVaultSecretName value. + */ + String keyVaultSecretName(); + + /** + * Gets the keyVaultSecretVersion property: Certificate secret version. + * + * @return the keyVaultSecretVersion value. + */ + String keyVaultSecretVersion(); + + /** + * Gets the inner com.azure.resourcemanager.signalr.fluent.models.CustomCertificateInner object. + * + * @return the inner object. + */ + CustomCertificateInner innerModel(); + + /** The entirety of the CustomCertificate definition. */ + interface Definition + extends DefinitionStages.Blank, + DefinitionStages.WithParentResource, + DefinitionStages.WithKeyVaultBaseUri, + DefinitionStages.WithKeyVaultSecretName, + DefinitionStages.WithCreate { + } + /** The CustomCertificate definition stages. */ + interface DefinitionStages { + /** The first stage of the CustomCertificate definition. */ + interface Blank extends WithParentResource { + } + /** The stage of the CustomCertificate definition allowing to specify parent resource. */ + interface WithParentResource { + /** + * Specifies resourceGroupName, resourceName. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this + * value from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @return the next definition stage. + */ + WithKeyVaultBaseUri withExistingSignalR(String resourceGroupName, String resourceName); + } + /** The stage of the CustomCertificate definition allowing to specify keyVaultBaseUri. */ + interface WithKeyVaultBaseUri { + /** + * Specifies the keyVaultBaseUri property: Base uri of the KeyVault that stores certificate.. + * + * @param keyVaultBaseUri Base uri of the KeyVault that stores certificate. + * @return the next definition stage. + */ + WithKeyVaultSecretName withKeyVaultBaseUri(String keyVaultBaseUri); + } + /** The stage of the CustomCertificate definition allowing to specify keyVaultSecretName. */ + interface WithKeyVaultSecretName { + /** + * Specifies the keyVaultSecretName property: Certificate secret name.. + * + * @param keyVaultSecretName Certificate secret name. + * @return the next definition stage. + */ + WithCreate withKeyVaultSecretName(String keyVaultSecretName); + } + /** + * The stage of the CustomCertificate definition which contains all the minimum required properties for the + * resource to be created, but also allows for any other optional properties to be specified. + */ + interface WithCreate extends DefinitionStages.WithKeyVaultSecretVersion { + /** + * Executes the create request. + * + * @return the created resource. + */ + CustomCertificate create(); + + /** + * Executes the create request. + * + * @param context The context to associate with this operation. + * @return the created resource. + */ + CustomCertificate create(Context context); + } + /** The stage of the CustomCertificate definition allowing to specify keyVaultSecretVersion. */ + interface WithKeyVaultSecretVersion { + /** + * Specifies the keyVaultSecretVersion property: Certificate secret version.. + * + * @param keyVaultSecretVersion Certificate secret version. + * @return the next definition stage. + */ + WithCreate withKeyVaultSecretVersion(String keyVaultSecretVersion); + } + } + /** + * Begins update for the CustomCertificate resource. + * + * @return the stage of resource update. + */ + CustomCertificate.Update update(); + + /** The template for CustomCertificate update. */ + interface Update { + /** + * Executes the update request. + * + * @return the updated resource. + */ + CustomCertificate apply(); + + /** + * Executes the update request. + * + * @param context The context to associate with this operation. + * @return the updated resource. + */ + CustomCertificate apply(Context context); + } + /** The CustomCertificate update stages. */ + interface UpdateStages { + } + /** + * Refreshes the resource to sync with Azure. + * + * @return the refreshed resource. + */ + CustomCertificate refresh(); + + /** + * Refreshes the resource to sync with Azure. + * + * @param context The context to associate with this operation. + * @return the refreshed resource. + */ + CustomCertificate refresh(Context context); +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/CustomCertificateList.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/CustomCertificateList.java new file mode 100644 index 0000000000000..ad74fda13fedf --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/CustomCertificateList.java @@ -0,0 +1,81 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.models; + +import com.azure.core.annotation.Fluent; +import com.azure.resourcemanager.signalr.fluent.models.CustomCertificateInner; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** Custom certificates list. */ +@Fluent +public final class CustomCertificateList { + /* + * List of custom certificates of this resource. + */ + @JsonProperty(value = "value") + private List value; + + /* + * The URL the 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; + + /** + * Get the value property: List of custom certificates of this resource. + * + * @return the value value. + */ + public List value() { + return this.value; + } + + /** + * Set the value property: List of custom certificates of this resource. + * + * @param value the value value to set. + * @return the CustomCertificateList object itself. + */ + public CustomCertificateList withValue(List value) { + this.value = value; + return this; + } + + /** + * Get the nextLink property: The URL the 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: The URL the 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 CustomCertificateList object itself. + */ + public CustomCertificateList withNextLink(String nextLink) { + this.nextLink = nextLink; + 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/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/CustomDomain.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/CustomDomain.java new file mode 100644 index 0000000000000..3116fa7d4d084 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/CustomDomain.java @@ -0,0 +1,196 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.models; + +import com.azure.core.management.SystemData; +import com.azure.core.util.Context; +import com.azure.resourcemanager.signalr.fluent.models.CustomDomainInner; + +/** An immutable client-side representation of CustomDomain. */ +public interface CustomDomain { + /** + * Gets the id property: Fully qualified resource Id for the resource. + * + * @return the id value. + */ + String id(); + + /** + * Gets the name property: The name of the resource. + * + * @return the name value. + */ + String name(); + + /** + * Gets the type property: The type of the resource. + * + * @return the type value. + */ + String type(); + + /** + * Gets the systemData property: Metadata pertaining to creation and last modification of the resource. + * + * @return the systemData value. + */ + SystemData systemData(); + + /** + * Gets the provisioningState property: Provisioning state of the resource. + * + * @return the provisioningState value. + */ + ProvisioningState provisioningState(); + + /** + * Gets the domainName property: The custom domain name. + * + * @return the domainName value. + */ + String domainName(); + + /** + * Gets the customCertificate property: Reference to a resource. + * + * @return the customCertificate value. + */ + ResourceReference customCertificate(); + + /** + * Gets the inner com.azure.resourcemanager.signalr.fluent.models.CustomDomainInner object. + * + * @return the inner object. + */ + CustomDomainInner innerModel(); + + /** The entirety of the CustomDomain definition. */ + interface Definition + extends DefinitionStages.Blank, + DefinitionStages.WithParentResource, + DefinitionStages.WithDomainName, + DefinitionStages.WithCustomCertificate, + DefinitionStages.WithCreate { + } + /** The CustomDomain definition stages. */ + interface DefinitionStages { + /** The first stage of the CustomDomain definition. */ + interface Blank extends WithParentResource { + } + /** The stage of the CustomDomain definition allowing to specify parent resource. */ + interface WithParentResource { + /** + * Specifies resourceGroupName, resourceName. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this + * value from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @return the next definition stage. + */ + WithDomainName withExistingSignalR(String resourceGroupName, String resourceName); + } + /** The stage of the CustomDomain definition allowing to specify domainName. */ + interface WithDomainName { + /** + * Specifies the domainName property: The custom domain name.. + * + * @param domainName The custom domain name. + * @return the next definition stage. + */ + WithCustomCertificate withDomainName(String domainName); + } + /** The stage of the CustomDomain definition allowing to specify customCertificate. */ + interface WithCustomCertificate { + /** + * Specifies the customCertificate property: Reference to a resource.. + * + * @param customCertificate Reference to a resource. + * @return the next definition stage. + */ + WithCreate withCustomCertificate(ResourceReference customCertificate); + } + /** + * The stage of the CustomDomain definition which contains all the minimum required properties for the resource + * to be created, but also allows for any other optional properties to be specified. + */ + interface WithCreate { + /** + * Executes the create request. + * + * @return the created resource. + */ + CustomDomain create(); + + /** + * Executes the create request. + * + * @param context The context to associate with this operation. + * @return the created resource. + */ + CustomDomain create(Context context); + } + } + /** + * Begins update for the CustomDomain resource. + * + * @return the stage of resource update. + */ + CustomDomain.Update update(); + + /** The template for CustomDomain update. */ + interface Update extends UpdateStages.WithDomainName, UpdateStages.WithCustomCertificate { + /** + * Executes the update request. + * + * @return the updated resource. + */ + CustomDomain apply(); + + /** + * Executes the update request. + * + * @param context The context to associate with this operation. + * @return the updated resource. + */ + CustomDomain apply(Context context); + } + /** The CustomDomain update stages. */ + interface UpdateStages { + /** The stage of the CustomDomain update allowing to specify domainName. */ + interface WithDomainName { + /** + * Specifies the domainName property: The custom domain name.. + * + * @param domainName The custom domain name. + * @return the next definition stage. + */ + Update withDomainName(String domainName); + } + /** The stage of the CustomDomain update allowing to specify customCertificate. */ + interface WithCustomCertificate { + /** + * Specifies the customCertificate property: Reference to a resource.. + * + * @param customCertificate Reference to a resource. + * @return the next definition stage. + */ + Update withCustomCertificate(ResourceReference customCertificate); + } + } + /** + * Refreshes the resource to sync with Azure. + * + * @return the refreshed resource. + */ + CustomDomain refresh(); + + /** + * Refreshes the resource to sync with Azure. + * + * @param context The context to associate with this operation. + * @return the refreshed resource. + */ + CustomDomain refresh(Context context); +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/CustomDomainList.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/CustomDomainList.java new file mode 100644 index 0000000000000..869da450b3be9 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/CustomDomainList.java @@ -0,0 +1,81 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.models; + +import com.azure.core.annotation.Fluent; +import com.azure.resourcemanager.signalr.fluent.models.CustomDomainInner; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** Custom domains list. */ +@Fluent +public final class CustomDomainList { + /* + * List of custom domains that bind to this resource. + */ + @JsonProperty(value = "value") + private List value; + + /* + * The URL the 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; + + /** + * Get the value property: List of custom domains that bind to this resource. + * + * @return the value value. + */ + public List value() { + return this.value; + } + + /** + * Set the value property: List of custom domains that bind to this resource. + * + * @param value the value value to set. + * @return the CustomDomainList object itself. + */ + public CustomDomainList withValue(List value) { + this.value = value; + return this; + } + + /** + * Get the nextLink property: The URL the 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: The URL the 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 CustomDomainList object itself. + */ + public CustomDomainList withNextLink(String nextLink) { + this.nextLink = nextLink; + 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/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Dimension.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Dimension.java index 041c9dc5439e6..e49b825d0b397 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Dimension.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Dimension.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Specifications of the Dimension of metrics. */ @Fluent public final class Dimension { - @JsonIgnore private final ClientLogger logger = new ClientLogger(Dimension.class); - /* * The public facing name of the dimension. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/LiveTraceCategory.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/LiveTraceCategory.java new file mode 100644 index 0000000000000..3ee6f535f2cde --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/LiveTraceCategory.java @@ -0,0 +1,80 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Live trace category configuration of a Microsoft.SignalRService resource. */ +@Fluent +public final class LiveTraceCategory { + /* + * Gets or sets the live trace category's name. + * Available values: ConnectivityLogs, MessagingLogs. + * Case insensitive. + */ + @JsonProperty(value = "name") + private String name; + + /* + * Indicates whether or the live trace category is enabled. + * Available values: true, false. + * Case insensitive. + */ + @JsonProperty(value = "enabled") + private String enabled; + + /** + * Get the name property: Gets or sets the live trace category's name. Available values: ConnectivityLogs, + * MessagingLogs. Case insensitive. + * + * @return the name value. + */ + public String name() { + return this.name; + } + + /** + * Set the name property: Gets or sets the live trace category's name. Available values: ConnectivityLogs, + * MessagingLogs. Case insensitive. + * + * @param name the name value to set. + * @return the LiveTraceCategory object itself. + */ + public LiveTraceCategory withName(String name) { + this.name = name; + return this; + } + + /** + * Get the enabled property: Indicates whether or the live trace category is enabled. Available values: true, false. + * Case insensitive. + * + * @return the enabled value. + */ + public String enabled() { + return this.enabled; + } + + /** + * Set the enabled property: Indicates whether or the live trace category is enabled. Available values: true, false. + * Case insensitive. + * + * @param enabled the enabled value to set. + * @return the LiveTraceCategory object itself. + */ + public LiveTraceCategory withEnabled(String enabled) { + this.enabled = enabled; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/LiveTraceConfiguration.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/LiveTraceConfiguration.java new file mode 100644 index 0000000000000..839f84c5b3a03 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/LiveTraceConfiguration.java @@ -0,0 +1,86 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** Live trace configuration of a Microsoft.SignalRService resource. */ +@Fluent +public final class LiveTraceConfiguration { + /* + * Indicates whether or not enable live trace. + * When it's set to true, live trace client can connect to the service. + * Otherwise, live trace client can't connect to the service, so that you + * are unable to receive any log, no matter what you configure in + * "categories". + * Available values: true, false. + * Case insensitive. + */ + @JsonProperty(value = "enabled") + private String enabled; + + /* + * Gets or sets the list of category configurations. + */ + @JsonProperty(value = "categories") + private List categories; + + /** + * Get the enabled property: Indicates whether or not enable live trace. When it's set to true, live trace client + * can connect to the service. Otherwise, live trace client can't connect to the service, so that you are unable to + * receive any log, no matter what you configure in "categories". Available values: true, false. Case insensitive. + * + * @return the enabled value. + */ + public String enabled() { + return this.enabled; + } + + /** + * Set the enabled property: Indicates whether or not enable live trace. When it's set to true, live trace client + * can connect to the service. Otherwise, live trace client can't connect to the service, so that you are unable to + * receive any log, no matter what you configure in "categories". Available values: true, false. Case insensitive. + * + * @param enabled the enabled value to set. + * @return the LiveTraceConfiguration object itself. + */ + public LiveTraceConfiguration withEnabled(String enabled) { + this.enabled = enabled; + return this; + } + + /** + * Get the categories property: Gets or sets the list of category configurations. + * + * @return the categories value. + */ + public List categories() { + return this.categories; + } + + /** + * Set the categories property: Gets or sets the list of category configurations. + * + * @param categories the categories value to set. + * @return the LiveTraceConfiguration object itself. + */ + public LiveTraceConfiguration withCategories(List categories) { + this.categories = categories; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (categories() != null) { + categories().forEach(e -> e.validate()); + } + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/LogSpecification.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/LogSpecification.java index f0796e4fdc568..e5d97846d4c13 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/LogSpecification.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/LogSpecification.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Specifications of the Logs for Azure Monitoring. */ @Fluent public final class LogSpecification { - @JsonIgnore private final ClientLogger logger = new ClientLogger(LogSpecification.class); - /* * Name of the log. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ManagedIdentity.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ManagedIdentity.java index 64d5efa4d002d..63eeb1f741059 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ManagedIdentity.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ManagedIdentity.java @@ -5,8 +5,6 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.Map; @@ -14,10 +12,8 @@ /** A class represent managed identities used for request and response. */ @Fluent public class ManagedIdentity { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ManagedIdentity.class); - /* - * Represent the identity type: systemAssigned, userAssigned, None + * Represents the identity type: systemAssigned, userAssigned, None */ @JsonProperty(value = "type") private ManagedIdentityType type; @@ -44,7 +40,7 @@ public class ManagedIdentity { private String tenantId; /** - * Get the type property: Represent the identity type: systemAssigned, userAssigned, None. + * Get the type property: Represents the identity type: systemAssigned, userAssigned, None. * * @return the type value. */ @@ -53,7 +49,7 @@ public ManagedIdentityType type() { } /** - * Set the type property: Represent the identity type: systemAssigned, userAssigned, None. + * Set the type property: Represents the identity type: systemAssigned, userAssigned, None. * * @param type the type value to set. * @return the ManagedIdentity object itself. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ManagedIdentitySettings.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ManagedIdentitySettings.java index 21ad9d7911fa6..ab3c272eace31 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ManagedIdentitySettings.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ManagedIdentitySettings.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Managed identity settings for upstream. */ @Fluent public final class ManagedIdentitySettings { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ManagedIdentitySettings.class); - /* * The Resource indicating the App ID URI of the target resource. * It also appears in the aud (audience) claim of the issued token. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/MetricSpecification.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/MetricSpecification.java index 74d74dbef2dd6..6ed7ce0b463e1 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/MetricSpecification.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/MetricSpecification.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Specifications of the Metrics for Azure Monitoring. */ @Fluent public final class MetricSpecification { - @JsonIgnore private final ClientLogger logger = new ClientLogger(MetricSpecification.class); - /* * Name of the metric. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/NameAvailabilityParameters.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/NameAvailabilityParameters.java index ef26f2312e53a..14598a256d57f 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/NameAvailabilityParameters.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/NameAvailabilityParameters.java @@ -6,14 +6,11 @@ import com.azure.core.annotation.Fluent; import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Data POST-ed to the nameAvailability action. */ @Fluent public final class NameAvailabilityParameters { - @JsonIgnore private final ClientLogger logger = new ClientLogger(NameAvailabilityParameters.class); - /* * The resource type. Can be "Microsoft.SignalRService/SignalR" or * "Microsoft.SignalRService/webPubSub" @@ -76,14 +73,16 @@ public NameAvailabilityParameters withName(String name) { */ public void validate() { if (type() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property type in model NameAvailabilityParameters")); } if (name() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property name in model NameAvailabilityParameters")); } } + + private static final ClientLogger LOGGER = new ClientLogger(NameAvailabilityParameters.class); } diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/NetworkAcl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/NetworkAcl.java index 4e9ee934f5624..f6b15c073317e 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/NetworkAcl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/NetworkAcl.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Network ACL. */ @Fluent public class NetworkAcl { - @JsonIgnore private final ClientLogger logger = new ClientLogger(NetworkAcl.class); - /* * Allowed request types. The value can be one or more of: * ClientConnection, ServerConnection, RESTAPI. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Operation.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Operation.java index f450dba11b80e..674598c0f631b 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Operation.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Operation.java @@ -23,7 +23,7 @@ public interface Operation { Boolean isDataAction(); /** - * Gets the display property: The object that describes the operation. + * Gets the display property: The object that describes a operation. * * @return the display value. */ @@ -38,7 +38,7 @@ public interface Operation { String origin(); /** - * Gets the properties property: Extra properties for the operation. + * Gets the properties property: Extra Operation properties. * * @return the properties value. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/OperationDisplay.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/OperationDisplay.java index f7b6d72d5ee31..6ebb2a2371829 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/OperationDisplay.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/OperationDisplay.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The object that describes a operation. */ @Fluent public final class OperationDisplay { - @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationDisplay.class); - /* * Friendly name of the resource provider */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/OperationList.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/OperationList.java index 49bdda6dc2838..ece40143cf37a 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/OperationList.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/OperationList.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.fluent.models.OperationInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Result of the request to list REST API operations. It contains a list of operations. */ @Fluent public final class OperationList { - @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationList.class); - /* * List of operations supported by the resource provider. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/OperationProperties.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/OperationProperties.java index 8d5fb2a74040b..a3b55ab206f89 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/OperationProperties.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/OperationProperties.java @@ -5,23 +5,19 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Extra Operation properties. */ @Fluent public final class OperationProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationProperties.class); - /* - * The service specifications. + * An object that describes a specification. */ @JsonProperty(value = "serviceSpecification") private ServiceSpecification serviceSpecification; /** - * Get the serviceSpecification property: The service specifications. + * Get the serviceSpecification property: An object that describes a specification. * * @return the serviceSpecification value. */ @@ -30,7 +26,7 @@ public ServiceSpecification serviceSpecification() { } /** - * Set the serviceSpecification property: The service specifications. + * Set the serviceSpecification property: An object that describes a specification. * * @param serviceSpecification the serviceSpecification value to set. * @return the OperationProperties object itself. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Operations.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Operations.java index 76c7091bf237c..860853c575bc9 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Operations.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Operations.java @@ -14,7 +14,7 @@ public interface Operations { * * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return result of the request to list REST API operations. + * @return result of the request to list REST API operations as paginated response with {@link PagedIterable}. */ PagedIterable list(); @@ -25,7 +25,7 @@ public interface Operations { * @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 result of the request to list REST API operations. + * @return result of the request to list REST API operations as paginated response with {@link PagedIterable}. */ PagedIterable list(Context context); } diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpoint.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpoint.java index f8e1ed354c8f2..74949ba41e8f3 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpoint.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpoint.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Private endpoint. */ @Fluent public final class PrivateEndpoint { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpoint.class); - /* * Full qualified Id of the private endpoint */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpointAcl.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpointAcl.java index ba4b654787e9d..6b2db5bfa4f75 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpointAcl.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpointAcl.java @@ -6,15 +6,12 @@ import com.azure.core.annotation.Fluent; import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** ACL for a private endpoint. */ @Fluent public final class PrivateEndpointAcl extends NetworkAcl { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpointAcl.class); - /* * Name of the private endpoint connection */ @@ -64,9 +61,11 @@ public PrivateEndpointAcl withDeny(List deny) { public void validate() { super.validate(); if (name() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property name in model PrivateEndpointAcl")); } } + + private static final ClientLogger LOGGER = new ClientLogger(PrivateEndpointAcl.class); } diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpointConnection.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpointConnection.java index 70dc93f31acf4..1b548248aca62 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpointConnection.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpointConnection.java @@ -39,14 +39,14 @@ public interface PrivateEndpointConnection { SystemData systemData(); /** - * Gets the provisioningState property: Provisioning state of the private endpoint connection. + * Gets the provisioningState property: Provisioning state of the resource. * * @return the provisioningState value. */ ProvisioningState provisioningState(); /** - * Gets the privateEndpoint property: Private endpoint associated with the private endpoint connection. + * Gets the privateEndpoint property: Private endpoint. * * @return the privateEndpoint value. */ @@ -60,7 +60,7 @@ public interface PrivateEndpointConnection { List groupIds(); /** - * Gets the privateLinkServiceConnectionState property: Connection state. + * Gets the privateLinkServiceConnectionState property: Connection state of the private endpoint connection. * * @return the privateLinkServiceConnectionState value. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpointConnectionList.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpointConnectionList.java index a1d68736dbb7a..4322446850aef 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpointConnectionList.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateEndpointConnectionList.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.fluent.models.PrivateEndpointConnectionInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** A list of private endpoint connections. */ @Fluent public final class PrivateEndpointConnectionList { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpointConnectionList.class); - /* * The list of the private endpoint connections */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateLinkResourceList.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateLinkResourceList.java index 8ab80f8acc062..4d572e1175a01 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateLinkResourceList.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateLinkResourceList.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.fluent.models.PrivateLinkResourceInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Contains a list of PrivateLinkResource and a possible link to query more results. */ @Fluent public final class PrivateLinkResourceList { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkResourceList.class); - /* * List of PrivateLinkResource */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateLinkServiceConnectionState.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateLinkServiceConnectionState.java index 7118e7da2984a..3b25f8c76a07d 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateLinkServiceConnectionState.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/PrivateLinkServiceConnectionState.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Connection state of the private endpoint connection. */ @Fluent public final class PrivateLinkServiceConnectionState { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkServiceConnectionState.class); - /* * Indicates whether the connection has been Approved/Rejected/Removed by * the owner of the service. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/RegenerateKeyParameters.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/RegenerateKeyParameters.java index 026ab55c3175d..e570f89b4bd86 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/RegenerateKeyParameters.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/RegenerateKeyParameters.java @@ -5,24 +5,19 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Parameters describes the request to regenerate access keys. */ @Fluent public final class RegenerateKeyParameters { - @JsonIgnore private final ClientLogger logger = new ClientLogger(RegenerateKeyParameters.class); - /* - * The keyType to regenerate. Must be either 'primary' or - * 'secondary'(case-insensitive). + * The type of access key. */ @JsonProperty(value = "keyType") private KeyType keyType; /** - * Get the keyType property: The keyType to regenerate. Must be either 'primary' or 'secondary'(case-insensitive). + * Get the keyType property: The type of access key. * * @return the keyType value. */ @@ -31,7 +26,7 @@ public KeyType keyType() { } /** - * Set the keyType property: The keyType to regenerate. Must be either 'primary' or 'secondary'(case-insensitive). + * Set the keyType property: The type of access key. * * @param keyType the keyType value to set. * @return the RegenerateKeyParameters object itself. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceLogCategory.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceLogCategory.java index 37274c52b7ca7..f3d201e0669f8 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceLogCategory.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceLogCategory.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Resource log category configuration of a Microsoft.SignalRService resource. */ @Fluent public final class ResourceLogCategory { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ResourceLogCategory.class); - /* * Gets or sets the resource log category's name. * Available values: ConnectivityLogs, MessagingLogs. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceLogConfiguration.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceLogConfiguration.java index e5b5aff3ad0ba..132ef7884abdf 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceLogConfiguration.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceLogConfiguration.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Resource log configuration of a Microsoft.SignalRService resource. */ @Fluent public final class ResourceLogConfiguration { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ResourceLogConfiguration.class); - /* * Gets or sets the list of category configurations. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceReference.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceReference.java new file mode 100644 index 0000000000000..c4d37bc98607a --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceReference.java @@ -0,0 +1,46 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Reference to a resource. */ +@Fluent +public final class ResourceReference { + /* + * Resource ID. + */ + @JsonProperty(value = "id") + private String id; + + /** + * Get the id property: Resource ID. + * + * @return the id value. + */ + public String id() { + return this.id; + } + + /** + * Set the id property: Resource ID. + * + * @param id the id value to set. + * @return the ResourceReference object itself. + */ + public ResourceReference withId(String id) { + this.id = id; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceSku.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceSku.java index eda4647d899dc..064c8d89d1d75 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceSku.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ResourceSku.java @@ -6,14 +6,11 @@ import com.azure.core.annotation.Fluent; import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The billing information of the resource. */ @Fluent public final class ResourceSku { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ResourceSku.class); - /* * The name of the SKU. Required. * @@ -149,9 +146,11 @@ public ResourceSku withCapacity(Integer capacity) { */ public void validate() { if (name() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property name in model ResourceSku")); } } + + private static final ClientLogger LOGGER = new ClientLogger(ResourceSku.class); } diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ServerlessUpstreamSettings.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ServerlessUpstreamSettings.java index f0fc38ef2a357..e667550b4cd62 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ServerlessUpstreamSettings.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ServerlessUpstreamSettings.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** The settings for the Upstream when the service is in server-less mode. */ @Fluent public final class ServerlessUpstreamSettings { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ServerlessUpstreamSettings.class); - /* * Gets or sets the list of Upstream URL templates. Order matters, and the * first matching template takes effects. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ServiceSpecification.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ServiceSpecification.java index 8f051849ce813..09c3c18ab0aa2 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ServiceSpecification.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ServiceSpecification.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** An object that describes a specification. */ @Fluent public final class ServiceSpecification { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ServiceSpecification.class); - /* * Specifications of the Metrics for Azure Monitoring. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ShareablePrivateLinkResourceProperties.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ShareablePrivateLinkResourceProperties.java index 71374d780cbce..2f333aaac7ed8 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ShareablePrivateLinkResourceProperties.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ShareablePrivateLinkResourceProperties.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Describes the properties of a resource type that has been onboarded to private link service. */ @Fluent public final class ShareablePrivateLinkResourceProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ShareablePrivateLinkResourceProperties.class); - /* * The description of the resource type that has been onboarded to private * link service diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ShareablePrivateLinkResourceType.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ShareablePrivateLinkResourceType.java index 0edfc2cdb96f3..714120bccd0da 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ShareablePrivateLinkResourceType.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/ShareablePrivateLinkResourceType.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Describes a resource type that has been onboarded to private link service. */ @Fluent public final class ShareablePrivateLinkResourceType { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ShareablePrivateLinkResourceType.class); - /* * The name of the resource type that has been onboarded to private link * service diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SharedPrivateLinkResource.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SharedPrivateLinkResource.java index abae80602e183..d4469ed205c99 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SharedPrivateLinkResource.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SharedPrivateLinkResource.java @@ -53,7 +53,7 @@ public interface SharedPrivateLinkResource { String privateLinkResourceId(); /** - * Gets the provisioningState property: Provisioning state of the shared private link resource. + * Gets the provisioningState property: Provisioning state of the resource. * * @return the provisioningState value. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SharedPrivateLinkResourceList.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SharedPrivateLinkResourceList.java index a8c7addffed1a..5219a8770fdd4 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SharedPrivateLinkResourceList.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SharedPrivateLinkResourceList.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.fluent.models.SharedPrivateLinkResourceInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** A list of shared private link resources. */ @Fluent public final class SharedPrivateLinkResourceList { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SharedPrivateLinkResourceList.class); - /* * The list of the shared private link resources */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRCorsSettings.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRCorsSettings.java index d7323b4485132..2ddad56a95b58 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRCorsSettings.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRCorsSettings.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Cross-Origin Resource Sharing (CORS) settings. */ @Fluent public final class SignalRCorsSettings { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRCorsSettings.class); - /* * Gets or sets the list of origins that should be allowed to make * cross-origin calls (for example: http://example.com:12345). Use "*" to diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRCustomCertificates.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRCustomCertificates.java new file mode 100644 index 0000000000000..ec9fcc17c9a9c --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRCustomCertificates.java @@ -0,0 +1,151 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.models; + +import com.azure.core.http.rest.PagedIterable; +import com.azure.core.http.rest.Response; +import com.azure.core.util.Context; + +/** Resource collection API of SignalRCustomCertificates. */ +public interface SignalRCustomCertificates { + /** + * List all custom certificates. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the 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 custom certificates list as paginated response with {@link PagedIterable}. + */ + PagedIterable list(String resourceGroupName, String resourceName); + + /** + * List all custom certificates. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the 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 custom certificates list as paginated response with {@link PagedIterable}. + */ + PagedIterable list(String resourceGroupName, String resourceName, Context context); + + /** + * Get a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 custom certificate. + */ + CustomCertificate get(String resourceGroupName, String resourceName, String certificateName); + + /** + * Get a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 custom certificate along with {@link Response}. + */ + Response getWithResponse( + String resourceGroupName, String resourceName, String certificateName, Context context); + + /** + * Delete a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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. + */ + void delete(String resourceGroupName, String resourceName, String certificateName); + + /** + * Delete a custom certificate. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param certificateName Custom certificate name. + * @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 Response}. + */ + Response deleteWithResponse( + String resourceGroupName, String resourceName, String certificateName, Context context); + + /** + * Get a custom certificate. + * + * @param id the resource ID. + * @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 custom certificate along with {@link Response}. + */ + CustomCertificate getById(String id); + + /** + * Get a custom certificate. + * + * @param id the resource ID. + * @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 custom certificate along with {@link Response}. + */ + Response getByIdWithResponse(String id, Context context); + + /** + * Delete a custom certificate. + * + * @param id the resource ID. + * @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. + */ + void deleteById(String id); + + /** + * Delete a custom certificate. + * + * @param id the resource ID. + * @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 Response}. + */ + Response deleteByIdWithResponse(String id, Context context); + + /** + * Begins definition for a new CustomCertificate resource. + * + * @param name resource name. + * @return the first stage of the new CustomCertificate definition. + */ + CustomCertificate.DefinitionStages.Blank define(String name); +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRCustomDomains.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRCustomDomains.java new file mode 100644 index 0000000000000..013a7812bc3d4 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRCustomDomains.java @@ -0,0 +1,147 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.models; + +import com.azure.core.http.rest.PagedIterable; +import com.azure.core.http.rest.Response; +import com.azure.core.util.Context; + +/** Resource collection API of SignalRCustomDomains. */ +public interface SignalRCustomDomains { + /** + * List all custom domains. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the 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 custom domains list as paginated response with {@link PagedIterable}. + */ + PagedIterable list(String resourceGroupName, String resourceName); + + /** + * List all custom domains. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the 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 custom domains list as paginated response with {@link PagedIterable}. + */ + PagedIterable list(String resourceGroupName, String resourceName, Context context); + + /** + * Get a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 custom domain. + */ + CustomDomain get(String resourceGroupName, String resourceName, String name); + + /** + * Get a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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 custom domain along with {@link Response}. + */ + Response getWithResponse(String resourceGroupName, String resourceName, String name, Context context); + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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. + */ + void delete(String resourceGroupName, String resourceName, String name); + + /** + * Delete a custom domain. + * + * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value + * from the Azure Resource Manager API or the portal. + * @param resourceName The name of the resource. + * @param name Custom domain name. + * @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. + */ + void delete(String resourceGroupName, String resourceName, String name, Context context); + + /** + * Get a custom domain. + * + * @param id the resource ID. + * @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 custom domain along with {@link Response}. + */ + CustomDomain getById(String id); + + /** + * Get a custom domain. + * + * @param id the resource ID. + * @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 custom domain along with {@link Response}. + */ + Response getByIdWithResponse(String id, Context context); + + /** + * Delete a custom domain. + * + * @param id the resource ID. + * @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. + */ + void deleteById(String id); + + /** + * Delete a custom domain. + * + * @param id the resource ID. + * @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. + */ + void deleteByIdWithResponse(String id, Context context); + + /** + * Begins definition for a new CustomDomain resource. + * + * @param name resource name. + * @return the first stage of the new CustomDomain definition. + */ + CustomDomain.DefinitionStages.Blank define(String name); +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRFeature.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRFeature.java index 246dca5bbc1bb..66e4ec11cee9c 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRFeature.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRFeature.java @@ -6,7 +6,6 @@ import com.azure.core.annotation.Fluent; import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.Map; @@ -14,8 +13,6 @@ /** Feature of a resource, which controls the runtime behavior. */ @Fluent public final class SignalRFeature { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRFeature.class); - /* * FeatureFlags is the supported features of Azure SignalR service. * - ServiceMode: Flag for backend server for SignalR service. Values @@ -138,14 +135,16 @@ public SignalRFeature withProperties(Map properties) { */ public void validate() { if (flag() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property flag in model SignalRFeature")); } if (value() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property value in model SignalRFeature")); } } + + private static final ClientLogger LOGGER = new ClientLogger(SignalRFeature.class); } diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRNetworkACLs.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRNetworkACLs.java index 30ada44a6ec11..dbfc2c3f4bef8 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRNetworkACLs.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRNetworkACLs.java @@ -5,24 +5,20 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Network ACLs for the resource. */ @Fluent public final class SignalRNetworkACLs { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRNetworkACLs.class); - /* - * Default action when no other rule matches + * Azure Networking ACL Action. */ @JsonProperty(value = "defaultAction") private AclAction defaultAction; /* - * ACL for requests from public network + * Network ACL */ @JsonProperty(value = "publicNetwork") private NetworkAcl publicNetwork; @@ -34,7 +30,7 @@ public final class SignalRNetworkACLs { private List privateEndpoints; /** - * Get the defaultAction property: Default action when no other rule matches. + * Get the defaultAction property: Azure Networking ACL Action. * * @return the defaultAction value. */ @@ -43,7 +39,7 @@ public AclAction defaultAction() { } /** - * Set the defaultAction property: Default action when no other rule matches. + * Set the defaultAction property: Azure Networking ACL Action. * * @param defaultAction the defaultAction value to set. * @return the SignalRNetworkACLs object itself. @@ -54,7 +50,7 @@ public SignalRNetworkACLs withDefaultAction(AclAction defaultAction) { } /** - * Get the publicNetwork property: ACL for requests from public network. + * Get the publicNetwork property: Network ACL. * * @return the publicNetwork value. */ @@ -63,7 +59,7 @@ public NetworkAcl publicNetwork() { } /** - * Set the publicNetwork property: ACL for requests from public network. + * Set the publicNetwork property: Network ACL. * * @param publicNetwork the publicNetwork value to set. * @return the SignalRNetworkACLs object itself. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRPrivateEndpointConnections.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRPrivateEndpointConnections.java index 105d7e0b7b426..c116e513e7ea7 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRPrivateEndpointConnections.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRPrivateEndpointConnections.java @@ -20,7 +20,7 @@ public interface SignalRPrivateEndpointConnections { * @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 private endpoint connections. + * @return a list of private endpoint connections as paginated response with {@link PagedIterable}. */ PagedIterable list(String resourceGroupName, String resourceName); @@ -34,7 +34,7 @@ public interface SignalRPrivateEndpointConnections { * @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 private endpoint connections. + * @return a list of private endpoint connections as paginated response with {@link PagedIterable}. */ PagedIterable list(String resourceGroupName, String resourceName, Context context); @@ -63,7 +63,7 @@ public interface SignalRPrivateEndpointConnections { * @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 specified private endpoint connection. + * @return the specified private endpoint connection along with {@link Response}. */ Response getWithResponse( String privateEndpointConnectionName, String resourceGroupName, String resourceName, Context context); @@ -99,7 +99,7 @@ PrivateEndpointConnection update( * @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 to an azure resource. + * @return a private endpoint connection to an azure resource along with {@link Response}. */ Response updateWithResponse( String privateEndpointConnectionName, diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRPrivateLinkResources.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRPrivateLinkResources.java index 65f10864dd4b9..f58670322d1d4 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRPrivateLinkResources.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRPrivateLinkResources.java @@ -18,7 +18,8 @@ public interface SignalRPrivateLinkResources { * @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 private link resources that need to be created for a resource. + * @return the private link resources that need to be created for a resource as paginated response with {@link + * PagedIterable}. */ PagedIterable list(String resourceGroupName, String resourceName); @@ -32,7 +33,8 @@ public interface SignalRPrivateLinkResources { * @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 private link resources that need to be created for a resource. + * @return the private link resources that need to be created for a resource as paginated response with {@link + * PagedIterable}. */ PagedIterable list(String resourceGroupName, String resourceName, Context context); } diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRResource.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRResource.java index 9ebc5850bfe9d..af31aa8b98fd2 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRResource.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRResource.java @@ -50,21 +50,21 @@ public interface SignalRResource { Map tags(); /** - * Gets the sku property: The billing information of the resource.(e.g. Free, Standard). + * Gets the sku property: The billing information of the resource. * * @return the sku value. */ ResourceSku sku(); /** - * Gets the kind property: The kind of the service - e.g. "SignalR" for "Microsoft.SignalRService/SignalR". + * Gets the kind property: The kind of the service, it can be SignalR or RawWebSockets. * * @return the kind value. */ ServiceKind kind(); /** - * Gets the identity property: The managed identity response. + * Gets the identity property: A class represent managed identities used for request and response. * * @return the identity value. */ @@ -136,7 +136,7 @@ public interface SignalRResource { List sharedPrivateLinkResources(); /** - * Gets the tls property: TLS settings. + * Gets the tls property: TLS settings for the resource. * * @return the tls value. */ @@ -162,10 +162,14 @@ public interface SignalRResource { List features(); /** - * Gets the resourceLogConfiguration property: Resource log configuration of a Microsoft.SignalRService resource. If - * resourceLogConfiguration isn't null or empty, it will override options "EnableConnectivityLog" and - * "EnableMessagingLogs" in features. Otherwise, use options "EnableConnectivityLog" and "EnableMessagingLogs" in - * features. + * Gets the liveTraceConfiguration property: Live trace configuration of a Microsoft.SignalRService resource. + * + * @return the liveTraceConfiguration value. + */ + LiveTraceConfiguration liveTraceConfiguration(); + + /** + * Gets the resourceLogConfiguration property: Resource log configuration of a Microsoft.SignalRService resource. * * @return the resourceLogConfiguration value. */ @@ -179,14 +183,14 @@ public interface SignalRResource { SignalRCorsSettings cors(); /** - * Gets the upstream property: Upstream settings when the service is in server-less mode. + * Gets the upstream property: The settings for the Upstream when the service is in server-less mode. * * @return the upstream value. */ ServerlessUpstreamSettings upstream(); /** - * Gets the networkACLs property: Network ACLs. + * Gets the networkACLs property: Network ACLs for the resource. * * @return the networkACLs value. */ @@ -290,6 +294,7 @@ interface WithCreate DefinitionStages.WithIdentity, DefinitionStages.WithTls, DefinitionStages.WithFeatures, + DefinitionStages.WithLiveTraceConfiguration, DefinitionStages.WithResourceLogConfiguration, DefinitionStages.WithCors, DefinitionStages.WithUpstream, @@ -325,9 +330,9 @@ interface WithTags { /** The stage of the SignalRResource definition allowing to specify sku. */ interface WithSku { /** - * Specifies the sku property: The billing information of the resource.(e.g. Free, Standard). + * Specifies the sku property: The billing information of the resource.. * - * @param sku The billing information of the resource.(e.g. Free, Standard). + * @param sku The billing information of the resource. * @return the next definition stage. */ WithCreate withSku(ResourceSku sku); @@ -335,10 +340,9 @@ interface WithSku { /** The stage of the SignalRResource definition allowing to specify kind. */ interface WithKind { /** - * Specifies the kind property: The kind of the service - e.g. "SignalR" for - * "Microsoft.SignalRService/SignalR". + * Specifies the kind property: The kind of the service, it can be SignalR or RawWebSockets. * - * @param kind The kind of the service - e.g. "SignalR" for "Microsoft.SignalRService/SignalR". + * @param kind The kind of the service, it can be SignalR or RawWebSockets. * @return the next definition stage. */ WithCreate withKind(ServiceKind kind); @@ -346,9 +350,9 @@ interface WithKind { /** The stage of the SignalRResource definition allowing to specify identity. */ interface WithIdentity { /** - * Specifies the identity property: The managed identity response. + * Specifies the identity property: A class represent managed identities used for request and response. * - * @param identity The managed identity response. + * @param identity A class represent managed identities used for request and response. * @return the next definition stage. */ WithCreate withIdentity(ManagedIdentity identity); @@ -356,9 +360,9 @@ interface WithIdentity { /** The stage of the SignalRResource definition allowing to specify tls. */ interface WithTls { /** - * Specifies the tls property: TLS settings.. + * Specifies the tls property: TLS settings for the resource. * - * @param tls TLS settings. + * @param tls TLS settings for the resource. * @return the next definition stage. */ WithCreate withTls(SignalRTlsSettings tls); @@ -382,18 +386,24 @@ interface WithFeatures { */ WithCreate withFeatures(List features); } + /** The stage of the SignalRResource definition allowing to specify liveTraceConfiguration. */ + interface WithLiveTraceConfiguration { + /** + * Specifies the liveTraceConfiguration property: Live trace configuration of a Microsoft.SignalRService + * resource.. + * + * @param liveTraceConfiguration Live trace configuration of a Microsoft.SignalRService resource. + * @return the next definition stage. + */ + WithCreate withLiveTraceConfiguration(LiveTraceConfiguration liveTraceConfiguration); + } /** The stage of the SignalRResource definition allowing to specify resourceLogConfiguration. */ interface WithResourceLogConfiguration { /** * Specifies the resourceLogConfiguration property: Resource log configuration of a Microsoft.SignalRService - * resource. If resourceLogConfiguration isn't null or empty, it will override options - * "EnableConnectivityLog" and "EnableMessagingLogs" in features. Otherwise, use options - * "EnableConnectivityLog" and "EnableMessagingLogs" in features.. - * - * @param resourceLogConfiguration Resource log configuration of a Microsoft.SignalRService resource. If - * resourceLogConfiguration isn't null or empty, it will override options "EnableConnectivityLog" and - * "EnableMessagingLogs" in features. Otherwise, use options "EnableConnectivityLog" and - * "EnableMessagingLogs" in features. + * resource.. + * + * @param resourceLogConfiguration Resource log configuration of a Microsoft.SignalRService resource. * @return the next definition stage. */ WithCreate withResourceLogConfiguration(ResourceLogConfiguration resourceLogConfiguration); @@ -411,9 +421,9 @@ interface WithCors { /** The stage of the SignalRResource definition allowing to specify upstream. */ interface WithUpstream { /** - * Specifies the upstream property: Upstream settings when the service is in server-less mode.. + * Specifies the upstream property: The settings for the Upstream when the service is in server-less mode.. * - * @param upstream Upstream settings when the service is in server-less mode. + * @param upstream The settings for the Upstream when the service is in server-less mode. * @return the next definition stage. */ WithCreate withUpstream(ServerlessUpstreamSettings upstream); @@ -421,9 +431,9 @@ interface WithUpstream { /** The stage of the SignalRResource definition allowing to specify networkACLs. */ interface WithNetworkACLs { /** - * Specifies the networkACLs property: Network ACLs. + * Specifies the networkACLs property: Network ACLs for the resource. * - * @param networkACLs Network ACLs. + * @param networkACLs Network ACLs for the resource. * @return the next definition stage. */ WithCreate withNetworkACLs(SignalRNetworkACLs networkACLs); @@ -481,6 +491,7 @@ interface Update UpdateStages.WithIdentity, UpdateStages.WithTls, UpdateStages.WithFeatures, + UpdateStages.WithLiveTraceConfiguration, UpdateStages.WithResourceLogConfiguration, UpdateStages.WithCors, UpdateStages.WithUpstream, @@ -518,9 +529,9 @@ interface WithTags { /** The stage of the SignalRResource update allowing to specify sku. */ interface WithSku { /** - * Specifies the sku property: The billing information of the resource.(e.g. Free, Standard). + * Specifies the sku property: The billing information of the resource.. * - * @param sku The billing information of the resource.(e.g. Free, Standard). + * @param sku The billing information of the resource. * @return the next definition stage. */ Update withSku(ResourceSku sku); @@ -528,9 +539,9 @@ interface WithSku { /** The stage of the SignalRResource update allowing to specify identity. */ interface WithIdentity { /** - * Specifies the identity property: The managed identity response. + * Specifies the identity property: A class represent managed identities used for request and response. * - * @param identity The managed identity response. + * @param identity A class represent managed identities used for request and response. * @return the next definition stage. */ Update withIdentity(ManagedIdentity identity); @@ -538,9 +549,9 @@ interface WithIdentity { /** The stage of the SignalRResource update allowing to specify tls. */ interface WithTls { /** - * Specifies the tls property: TLS settings.. + * Specifies the tls property: TLS settings for the resource. * - * @param tls TLS settings. + * @param tls TLS settings for the resource. * @return the next definition stage. */ Update withTls(SignalRTlsSettings tls); @@ -564,18 +575,24 @@ interface WithFeatures { */ Update withFeatures(List features); } + /** The stage of the SignalRResource update allowing to specify liveTraceConfiguration. */ + interface WithLiveTraceConfiguration { + /** + * Specifies the liveTraceConfiguration property: Live trace configuration of a Microsoft.SignalRService + * resource.. + * + * @param liveTraceConfiguration Live trace configuration of a Microsoft.SignalRService resource. + * @return the next definition stage. + */ + Update withLiveTraceConfiguration(LiveTraceConfiguration liveTraceConfiguration); + } /** The stage of the SignalRResource update allowing to specify resourceLogConfiguration. */ interface WithResourceLogConfiguration { /** * Specifies the resourceLogConfiguration property: Resource log configuration of a Microsoft.SignalRService - * resource. If resourceLogConfiguration isn't null or empty, it will override options - * "EnableConnectivityLog" and "EnableMessagingLogs" in features. Otherwise, use options - * "EnableConnectivityLog" and "EnableMessagingLogs" in features.. - * - * @param resourceLogConfiguration Resource log configuration of a Microsoft.SignalRService resource. If - * resourceLogConfiguration isn't null or empty, it will override options "EnableConnectivityLog" and - * "EnableMessagingLogs" in features. Otherwise, use options "EnableConnectivityLog" and - * "EnableMessagingLogs" in features. + * resource.. + * + * @param resourceLogConfiguration Resource log configuration of a Microsoft.SignalRService resource. * @return the next definition stage. */ Update withResourceLogConfiguration(ResourceLogConfiguration resourceLogConfiguration); @@ -593,9 +610,9 @@ interface WithCors { /** The stage of the SignalRResource update allowing to specify upstream. */ interface WithUpstream { /** - * Specifies the upstream property: Upstream settings when the service is in server-less mode.. + * Specifies the upstream property: The settings for the Upstream when the service is in server-less mode.. * - * @param upstream Upstream settings when the service is in server-less mode. + * @param upstream The settings for the Upstream when the service is in server-less mode. * @return the next definition stage. */ Update withUpstream(ServerlessUpstreamSettings upstream); @@ -603,9 +620,9 @@ interface WithUpstream { /** The stage of the SignalRResource update allowing to specify networkACLs. */ interface WithNetworkACLs { /** - * Specifies the networkACLs property: Network ACLs. + * Specifies the networkACLs property: Network ACLs for the resource. * - * @param networkACLs Network ACLs. + * @param networkACLs Network ACLs for the resource. * @return the next definition stage. */ Update withNetworkACLs(SignalRNetworkACLs networkACLs); @@ -680,7 +697,7 @@ interface WithDisableAadAuth { * @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 access keys of the resource. + * @return the access keys of the resource along with {@link Response}. */ Response listKeysWithResponse(Context context); diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRResourceList.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRResourceList.java index 0fb3215fcf654..1ddb59dcc30db 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRResourceList.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRResourceList.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.fluent.models.SignalRResourceInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Object that includes an array of resources and a possible link for next set. */ @Fluent public final class SignalRResourceList { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRResourceList.class); - /* * List of the resources */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRSharedPrivateLinkResources.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRSharedPrivateLinkResources.java index 6a25e4623b2d4..6a4d4e5f41f12 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRSharedPrivateLinkResources.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRSharedPrivateLinkResources.java @@ -19,7 +19,7 @@ public interface SignalRSharedPrivateLinkResources { * @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 shared private link resources. + * @return a list of shared private link resources as paginated response with {@link PagedIterable}. */ PagedIterable list(String resourceGroupName, String resourceName); @@ -33,7 +33,7 @@ public interface SignalRSharedPrivateLinkResources { * @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 shared private link resources. + * @return a list of shared private link resources as paginated response with {@link PagedIterable}. */ PagedIterable list(String resourceGroupName, String resourceName, Context context); @@ -62,7 +62,7 @@ public interface SignalRSharedPrivateLinkResources { * @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 specified shared private link resource. + * @return the specified shared private link resource along with {@link Response}. */ Response getWithResponse( String sharedPrivateLinkResourceName, String resourceGroupName, String resourceName, Context context); @@ -101,7 +101,7 @@ 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 the specified shared private link resource. + * @return the specified shared private link resource along with {@link Response}. */ SharedPrivateLinkResource getById(String id); @@ -113,7 +113,7 @@ 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 the specified shared private link resource. + * @return the specified shared private link resource along with {@link Response}. */ Response getByIdWithResponse(String id, Context context); diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRTlsSettings.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRTlsSettings.java index 1f6b1e1d0eb78..17cb72b92ec36 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRTlsSettings.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRTlsSettings.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** TLS settings for the resource. */ @Fluent public final class SignalRTlsSettings { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRTlsSettings.class); - /* * Request client certificate during TLS handshake if enabled */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRUsageList.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRUsageList.java index 8a4f8293bff6d..bbdca85a2aed4 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRUsageList.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRUsageList.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.signalr.fluent.models.SignalRUsageInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Object that includes an array of the resource usages and a possible link for next set. */ @Fluent public final class SignalRUsageList { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRUsageList.class); - /* * List of the resource usages */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRUsageName.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRUsageName.java index 62b5b2428ba57..cd4aaa0eb3ee8 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRUsageName.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRUsageName.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Localizable String object containing the name and a localized value. */ @Fluent public final class SignalRUsageName { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SignalRUsageName.class); - /* * The identifier of the usage. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRs.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRs.java index 1d6825c774e65..9397375307414 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRs.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SignalRs.java @@ -31,7 +31,7 @@ public interface SignalRs { * @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 result of the request to check name availability. + * @return result of the request to check name availability along with {@link Response}. */ Response checkNameAvailabilityWithResponse( String location, NameAvailabilityParameters parameters, Context context); @@ -41,7 +41,8 @@ Response checkNameAvailabilityWithResponse( * * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedIterable}. */ PagedIterable list(); @@ -52,7 +53,8 @@ Response checkNameAvailabilityWithResponse( * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedIterable}. */ PagedIterable list(Context context); @@ -64,7 +66,8 @@ Response checkNameAvailabilityWithResponse( * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedIterable}. */ PagedIterable listByResourceGroup(String resourceGroupName); @@ -77,7 +80,8 @@ Response checkNameAvailabilityWithResponse( * @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 object that includes an array of resources and a possible link for next set. + * @return object that includes an array of resources and a possible link for next set as paginated response with + * {@link PagedIterable}. */ PagedIterable listByResourceGroup(String resourceGroupName, Context context); @@ -104,7 +108,7 @@ Response checkNameAvailabilityWithResponse( * @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 resource and its properties. + * @return the resource and its properties along with {@link Response}. */ Response getByResourceGroupWithResponse( String resourceGroupName, String resourceName, Context context); @@ -157,7 +161,7 @@ Response getByResourceGroupWithResponse( * @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 access keys of the resource. + * @return the access keys of the resource along with {@link Response}. */ Response listKeysWithResponse(String resourceGroupName, String resourceName, Context context); @@ -239,7 +243,7 @@ SignalRKeys regenerateKey( * @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 list skus operation response. + * @return the list skus operation response along with {@link Response}. */ Response listSkusWithResponse(String resourceGroupName, String resourceName, Context context); @@ -250,7 +254,7 @@ SignalRKeys regenerateKey( * @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 resource and its properties. + * @return the resource and its properties along with {@link Response}. */ SignalRResource getById(String id); @@ -262,7 +266,7 @@ SignalRKeys regenerateKey( * @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 resource and its properties. + * @return the resource and its properties along with {@link Response}. */ Response getByIdWithResponse(String id, Context context); diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Sku.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Sku.java index 9f07763e5a26e..18b2a6077810e 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Sku.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Sku.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Describes an available sku.". */ @Immutable public final class Sku { - @JsonIgnore private final ClientLogger logger = new ClientLogger(Sku.class); - /* * The resource type that this object applies to */ @@ -21,13 +17,13 @@ public final class Sku { private String resourceType; /* - * The exact set of keys that define this sku. + * The billing information of the resource. */ @JsonProperty(value = "sku", access = JsonProperty.Access.WRITE_ONLY) private ResourceSku sku; /* - * Specifies the unit of the resource. + * Describes scaling information of a sku. */ @JsonProperty(value = "capacity", access = JsonProperty.Access.WRITE_ONLY) private SkuCapacity capacity; @@ -42,7 +38,7 @@ public String resourceType() { } /** - * Get the sku property: The exact set of keys that define this sku. + * Get the sku property: The billing information of the resource. * * @return the sku value. */ @@ -51,7 +47,7 @@ public ResourceSku sku() { } /** - * Get the capacity property: Specifies the unit of the resource. + * Get the capacity property: Describes scaling information of a sku. * * @return the capacity value. */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SkuCapacity.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SkuCapacity.java index a7675d54fbf1c..368dd051d9236 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SkuCapacity.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/SkuCapacity.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Describes scaling information of a sku. */ @Immutable public final class SkuCapacity { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SkuCapacity.class); - /* * The lowest permitted capacity for this resource */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/UpstreamAuthSettings.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/UpstreamAuthSettings.java index 0ccdf1f3282ea..32f8fe3e8cfc7 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/UpstreamAuthSettings.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/UpstreamAuthSettings.java @@ -5,30 +5,25 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; -/** Upstream auth settings. */ +/** Upstream auth settings. If not set, no auth is used for upstream messages. */ @Fluent public final class UpstreamAuthSettings { - @JsonIgnore private final ClientLogger logger = new ClientLogger(UpstreamAuthSettings.class); - /* - * Gets or sets the type of auth. None or ManagedIdentity is supported now. + * Upstream auth type enum. */ @JsonProperty(value = "type") private UpstreamAuthType type; /* - * Gets or sets the managed identity settings. It's required if the auth - * type is set to ManagedIdentity. + * Managed identity settings for upstream. */ @JsonProperty(value = "managedIdentity") private ManagedIdentitySettings managedIdentity; /** - * Get the type property: Gets or sets the type of auth. None or ManagedIdentity is supported now. + * Get the type property: Upstream auth type enum. * * @return the type value. */ @@ -37,7 +32,7 @@ public UpstreamAuthType type() { } /** - * Set the type property: Gets or sets the type of auth. None or ManagedIdentity is supported now. + * Set the type property: Upstream auth type enum. * * @param type the type value to set. * @return the UpstreamAuthSettings object itself. @@ -48,8 +43,7 @@ public UpstreamAuthSettings withType(UpstreamAuthType type) { } /** - * Get the managedIdentity property: Gets or sets the managed identity settings. It's required if the auth type is - * set to ManagedIdentity. + * Get the managedIdentity property: Managed identity settings for upstream. * * @return the managedIdentity value. */ @@ -58,8 +52,7 @@ public ManagedIdentitySettings managedIdentity() { } /** - * Set the managedIdentity property: Gets or sets the managed identity settings. It's required if the auth type is - * set to ManagedIdentity. + * Set the managedIdentity property: Managed identity settings for upstream. * * @param managedIdentity the managedIdentity value to set. * @return the UpstreamAuthSettings object itself. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/UpstreamTemplate.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/UpstreamTemplate.java index 9f2b8b5cdd72c..e7675dd5b47d1 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/UpstreamTemplate.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/UpstreamTemplate.java @@ -6,7 +6,6 @@ import com.azure.core.annotation.Fluent; import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** @@ -15,16 +14,14 @@ */ @Fluent public final class UpstreamTemplate { - @JsonIgnore private final ClientLogger logger = new ClientLogger(UpstreamTemplate.class); - /* * Gets or sets the matching pattern for hub names. If not set, it matches * any hub. * There are 3 kind of patterns supported: - * 1. "*", it to matches any hub name + * 1. "*", it to matches any hub name. * 2. Combine multiple hubs with ",", for example "hub1,hub2", it matches - * "hub1" and "hub2" - * 3. The single hub name, for example, "hub1", it matches "hub1" + * "hub1" and "hub2". + * 3. The single hub name, for example, "hub1", it matches "hub1". */ @JsonProperty(value = "hubPattern") private String hubPattern; @@ -33,10 +30,10 @@ public final class UpstreamTemplate { * Gets or sets the matching pattern for event names. If not set, it * matches any event. * There are 3 kind of patterns supported: - * 1. "*", it to matches any event name + * 1. "*", it to matches any event name. * 2. Combine multiple events with ",", for example "connect,disconnect", - * it matches event "connect" and "disconnect" - * 3. The single event name, for example, "connect", it matches "connect" + * it matches event "connect" and "disconnect". + * 3. The single event name, for example, "connect", it matches "connect". */ @JsonProperty(value = "eventPattern") private String eventPattern; @@ -45,11 +42,12 @@ public final class UpstreamTemplate { * Gets or sets the matching pattern for category names. If not set, it * matches any category. * There are 3 kind of patterns supported: - * 1. "*", it to matches any category name + * 1. "*", it to matches any category name. * 2. Combine multiple categories with ",", for example - * "connections,messages", it matches category "connections" and "messages" + * "connections,messages", it matches category "connections" and + * "messages". * 3. The single category name, for example, "connections", it matches the - * category "connections" + * category "connections". */ @JsonProperty(value = "categoryPattern") private String categoryPattern; @@ -68,16 +66,17 @@ public final class UpstreamTemplate { private String urlTemplate; /* - * Gets or sets the auth settings for an upstream. If not set, no auth is - * used for upstream messages. + * Upstream auth settings. If not set, no auth is used for upstream + * messages. */ @JsonProperty(value = "auth") private UpstreamAuthSettings auth; /** * Get the hubPattern property: Gets or sets the matching pattern for hub names. If not set, it matches any hub. - * There are 3 kind of patterns supported: 1. "*", it to matches any hub name 2. Combine multiple hubs with ",", for - * example "hub1,hub2", it matches "hub1" and "hub2" 3. The single hub name, for example, "hub1", it matches "hub1". + * There are 3 kind of patterns supported: 1. "*", it to matches any hub name. 2. Combine multiple hubs with ",", + * for example "hub1,hub2", it matches "hub1" and "hub2". 3. The single hub name, for example, "hub1", it matches + * "hub1". * * @return the hubPattern value. */ @@ -87,8 +86,9 @@ public String hubPattern() { /** * Set the hubPattern property: Gets or sets the matching pattern for hub names. If not set, it matches any hub. - * There are 3 kind of patterns supported: 1. "*", it to matches any hub name 2. Combine multiple hubs with ",", for - * example "hub1,hub2", it matches "hub1" and "hub2" 3. The single hub name, for example, "hub1", it matches "hub1". + * There are 3 kind of patterns supported: 1. "*", it to matches any hub name. 2. Combine multiple hubs with ",", + * for example "hub1,hub2", it matches "hub1" and "hub2". 3. The single hub name, for example, "hub1", it matches + * "hub1". * * @param hubPattern the hubPattern value to set. * @return the UpstreamTemplate object itself. @@ -100,9 +100,9 @@ public UpstreamTemplate withHubPattern(String hubPattern) { /** * Get the eventPattern property: Gets or sets the matching pattern for event names. If not set, it matches any - * event. There are 3 kind of patterns supported: 1. "*", it to matches any event name 2. Combine multiple events - * with ",", for example "connect,disconnect", it matches event "connect" and "disconnect" 3. The single event name, - * for example, "connect", it matches "connect". + * event. There are 3 kind of patterns supported: 1. "*", it to matches any event name. 2. Combine multiple events + * with ",", for example "connect,disconnect", it matches event "connect" and "disconnect". 3. The single event + * name, for example, "connect", it matches "connect". * * @return the eventPattern value. */ @@ -112,9 +112,9 @@ public String eventPattern() { /** * Set the eventPattern property: Gets or sets the matching pattern for event names. If not set, it matches any - * event. There are 3 kind of patterns supported: 1. "*", it to matches any event name 2. Combine multiple events - * with ",", for example "connect,disconnect", it matches event "connect" and "disconnect" 3. The single event name, - * for example, "connect", it matches "connect". + * event. There are 3 kind of patterns supported: 1. "*", it to matches any event name. 2. Combine multiple events + * with ",", for example "connect,disconnect", it matches event "connect" and "disconnect". 3. The single event + * name, for example, "connect", it matches "connect". * * @param eventPattern the eventPattern value to set. * @return the UpstreamTemplate object itself. @@ -126,9 +126,9 @@ public UpstreamTemplate withEventPattern(String eventPattern) { /** * Get the categoryPattern property: Gets or sets the matching pattern for category names. If not set, it matches - * any category. There are 3 kind of patterns supported: 1. "*", it to matches any category name 2. Combine multiple - * categories with ",", for example "connections,messages", it matches category "connections" and "messages" 3. The - * single category name, for example, "connections", it matches the category "connections". + * any category. There are 3 kind of patterns supported: 1. "*", it to matches any category name. 2. Combine + * multiple categories with ",", for example "connections,messages", it matches category "connections" and + * "messages". 3. The single category name, for example, "connections", it matches the category "connections". * * @return the categoryPattern value. */ @@ -138,9 +138,9 @@ public String categoryPattern() { /** * Set the categoryPattern property: Gets or sets the matching pattern for category names. If not set, it matches - * any category. There are 3 kind of patterns supported: 1. "*", it to matches any category name 2. Combine multiple - * categories with ",", for example "connections,messages", it matches category "connections" and "messages" 3. The - * single category name, for example, "connections", it matches the category "connections". + * any category. There are 3 kind of patterns supported: 1. "*", it to matches any category name. 2. Combine + * multiple categories with ",", for example "connections,messages", it matches category "connections" and + * "messages". 3. The single category name, for example, "connections", it matches the category "connections". * * @param categoryPattern the categoryPattern value to set. * @return the UpstreamTemplate object itself. @@ -177,8 +177,7 @@ public UpstreamTemplate withUrlTemplate(String urlTemplate) { } /** - * Get the auth property: Gets or sets the auth settings for an upstream. If not set, no auth is used for upstream - * messages. + * Get the auth property: Upstream auth settings. If not set, no auth is used for upstream messages. * * @return the auth value. */ @@ -187,8 +186,7 @@ public UpstreamAuthSettings auth() { } /** - * Set the auth property: Gets or sets the auth settings for an upstream. If not set, no auth is used for upstream - * messages. + * Set the auth property: Upstream auth settings. If not set, no auth is used for upstream messages. * * @param auth the auth value to set. * @return the UpstreamTemplate object itself. @@ -205,7 +203,7 @@ public UpstreamTemplate withAuth(UpstreamAuthSettings auth) { */ public void validate() { if (urlTemplate() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property urlTemplate in model UpstreamTemplate")); } @@ -213,4 +211,6 @@ public void validate() { auth().validate(); } } + + private static final ClientLogger LOGGER = new ClientLogger(UpstreamTemplate.class); } diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Usages.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Usages.java index 9a7c9bb016278..bbe902ae71222 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Usages.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/Usages.java @@ -16,7 +16,8 @@ public interface Usages { * @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 object that includes an array of the resource usages and a possible link for next set. + * @return object that includes an array of the resource usages and a possible link for next set as paginated + * response with {@link PagedIterable}. */ PagedIterable list(String location); @@ -28,7 +29,8 @@ public interface Usages { * @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 object that includes an array of the resource usages and a possible link for next set. + * @return object that includes an array of the resource usages and a possible link for next set as paginated + * response with {@link PagedIterable}. */ PagedIterable list(String location, Context context); } diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/UserAssignedIdentityProperty.java b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/UserAssignedIdentityProperty.java index c0fbfbbee06fe..376ccc6dce79a 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/UserAssignedIdentityProperty.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/main/java/com/azure/resourcemanager/signalr/models/UserAssignedIdentityProperty.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.signalr.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Properties of user assigned identity. */ @Immutable public final class UserAssignedIdentityProperty { - @JsonIgnore private final ClientLogger logger = new ClientLogger(UserAssignedIdentityProperty.class); - /* * Get the principal id for the user assigned identity */ diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/OperationsListSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/OperationsListSamples.java index 386da70fcd90a..f3ff5c3cd6849 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/OperationsListSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/OperationsListSamples.java @@ -9,7 +9,7 @@ /** Samples for Operations List. */ public final class OperationsListSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/Operations_List.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/Operations_List.json */ /** * Sample code: Operations_List. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCheckNameAvailabilitySamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCheckNameAvailabilitySamples.java index 60058689e7e99..2052cae33a844 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCheckNameAvailabilitySamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCheckNameAvailabilitySamples.java @@ -10,7 +10,7 @@ /** Samples for SignalR CheckNameAvailability. */ public final class SignalRCheckNameAvailabilitySamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_CheckNameAvailability.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_CheckNameAvailability.json */ /** * Sample code: SignalR_CheckNameAvailability. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCreateOrUpdateSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCreateOrUpdateSamples.java index b6d097148dcaf..c4dbad5c0edec 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCreateOrUpdateSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCreateOrUpdateSamples.java @@ -6,6 +6,8 @@ import com.azure.resourcemanager.signalr.models.AclAction; import com.azure.resourcemanager.signalr.models.FeatureFlags; +import com.azure.resourcemanager.signalr.models.LiveTraceCategory; +import com.azure.resourcemanager.signalr.models.LiveTraceConfiguration; import com.azure.resourcemanager.signalr.models.ManagedIdentity; import com.azure.resourcemanager.signalr.models.ManagedIdentitySettings; import com.azure.resourcemanager.signalr.models.ManagedIdentityType; @@ -30,7 +32,7 @@ /** Samples for SignalR CreateOrUpdate. */ public final class SignalRCreateOrUpdateSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_CreateOrUpdate.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_CreateOrUpdate.json */ /** * Sample code: SignalR_CreateOrUpdate. @@ -67,6 +69,11 @@ public static void signalRCreateOrUpdate(com.azure.resourcemanager.signalr.Signa .withFlag(FeatureFlags.ENABLE_LIVE_TRACE) .withValue("False") .withProperties(mapOf()))) + .withLiveTraceConfiguration( + new LiveTraceConfiguration() + .withEnabled("false") + .withCategories( + Arrays.asList(new LiveTraceCategory().withName("ConnectivityLogs").withEnabled("true")))) .withCors(new SignalRCorsSettings().withAllowedOrigins(Arrays.asList("https://foo.com", "https://bar.com"))) .withUpstream( new ServerlessUpstreamSettings() diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomCertificatesCreateOrUpdateSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomCertificatesCreateOrUpdateSamples.java new file mode 100644 index 0000000000000..01100543e880d --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomCertificatesCreateOrUpdateSamples.java @@ -0,0 +1,28 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.generated; + +/** Samples for SignalRCustomCertificates CreateOrUpdate. */ +public final class SignalRCustomCertificatesCreateOrUpdateSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomCertificates_CreateOrUpdate.json + */ + /** + * Sample code: SignalRCustomCertificates_CreateOrUpdate. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomCertificatesCreateOrUpdate( + com.azure.resourcemanager.signalr.SignalRManager manager) { + manager + .signalRCustomCertificates() + .define("myCert") + .withExistingSignalR("myResourceGroup", "mySignalRService") + .withKeyVaultBaseUri("https://myvault.keyvault.azure.net/") + .withKeyVaultSecretName("mycert") + .withKeyVaultSecretVersion("bb6a44b2743f47f68dad0d6cc9756432") + .create(); + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomCertificatesDeleteSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomCertificatesDeleteSamples.java new file mode 100644 index 0000000000000..34cba85660831 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomCertificatesDeleteSamples.java @@ -0,0 +1,24 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.generated; + +import com.azure.core.util.Context; + +/** Samples for SignalRCustomCertificates Delete. */ +public final class SignalRCustomCertificatesDeleteSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomCertificates_Delete.json + */ + /** + * Sample code: SignalRCustomCertificates_Delete. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomCertificatesDelete(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager + .signalRCustomCertificates() + .deleteWithResponse("myResourceGroup", "mySignalRService", "myCert", Context.NONE); + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomCertificatesGetSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomCertificatesGetSamples.java new file mode 100644 index 0000000000000..c2ceb5ed71ad4 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomCertificatesGetSamples.java @@ -0,0 +1,24 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.generated; + +import com.azure.core.util.Context; + +/** Samples for SignalRCustomCertificates Get. */ +public final class SignalRCustomCertificatesGetSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomCertificates_Get.json + */ + /** + * Sample code: SignalRCustomCertificates_Get. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomCertificatesGet(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager + .signalRCustomCertificates() + .getWithResponse("myResourceGroup", "mySignalRService", "myCert", Context.NONE); + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomCertificatesListSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomCertificatesListSamples.java new file mode 100644 index 0000000000000..1fcf31cb72c19 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomCertificatesListSamples.java @@ -0,0 +1,22 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.generated; + +import com.azure.core.util.Context; + +/** Samples for SignalRCustomCertificates List. */ +public final class SignalRCustomCertificatesListSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomCertificates_List.json + */ + /** + * Sample code: SignalRCustomCertificates_List. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomCertificatesList(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager.signalRCustomCertificates().list("myResourceGroup", "mySignalRService", Context.NONE); + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomDomainsCreateOrUpdateSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomDomainsCreateOrUpdateSamples.java new file mode 100644 index 0000000000000..67db6da9f66b4 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomDomainsCreateOrUpdateSamples.java @@ -0,0 +1,31 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.generated; + +import com.azure.resourcemanager.signalr.models.ResourceReference; + +/** Samples for SignalRCustomDomains CreateOrUpdate. */ +public final class SignalRCustomDomainsCreateOrUpdateSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomDomains_CreateOrUpdate.json + */ + /** + * Sample code: SignalRCustomDomains_CreateOrUpdate. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomDomainsCreateOrUpdate(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager + .signalRCustomDomains() + .define("myDomain") + .withExistingSignalR("myResourceGroup", "mySignalRService") + .withDomainName("example.com") + .withCustomCertificate( + new ResourceReference() + .withId( + "/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/myResourceGroup/providers/Microsoft.SignalRService/SignalR/mySignalRService/customCertificates/myCert")) + .create(); + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomDomainsDeleteSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomDomainsDeleteSamples.java new file mode 100644 index 0000000000000..ef29b7ffd1bd1 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomDomainsDeleteSamples.java @@ -0,0 +1,22 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.generated; + +import com.azure.core.util.Context; + +/** Samples for SignalRCustomDomains Delete. */ +public final class SignalRCustomDomainsDeleteSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomDomains_Delete.json + */ + /** + * Sample code: SignalRCustomDomains_Delete. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomDomainsDelete(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager.signalRCustomDomains().delete("myResourceGroup", "mySignalRService", "example", Context.NONE); + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomDomainsGetSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomDomainsGetSamples.java new file mode 100644 index 0000000000000..3d9d6967579fc --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomDomainsGetSamples.java @@ -0,0 +1,22 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.generated; + +import com.azure.core.util.Context; + +/** Samples for SignalRCustomDomains Get. */ +public final class SignalRCustomDomainsGetSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomDomains_Get.json + */ + /** + * Sample code: SignalRCustomDomains_Get. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomDomainsGet(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager.signalRCustomDomains().getWithResponse("myResourceGroup", "mySignalRService", "example", Context.NONE); + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomDomainsListSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomDomainsListSamples.java new file mode 100644 index 0000000000000..aa0483d5617e0 --- /dev/null +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRCustomDomainsListSamples.java @@ -0,0 +1,22 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.signalr.generated; + +import com.azure.core.util.Context; + +/** Samples for SignalRCustomDomains List. */ +public final class SignalRCustomDomainsListSamples { + /* + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRCustomDomains_List.json + */ + /** + * Sample code: SignalRCustomDomains_List. + * + * @param manager Entry point to SignalRManager. + */ + public static void signalRCustomDomainsList(com.azure.resourcemanager.signalr.SignalRManager manager) { + manager.signalRCustomDomains().list("myResourceGroup", "mySignalRService", Context.NONE); + } +} diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRDeleteSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRDeleteSamples.java index 7994d1dd433ed..62e665cee6755 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRDeleteSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRDeleteSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalR Delete. */ public final class SignalRDeleteSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_Delete.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_Delete.json */ /** * Sample code: SignalR_Delete. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRGetByResourceGroupSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRGetByResourceGroupSamples.java index bd547e826fadd..96c0cce93a260 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRGetByResourceGroupSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRGetByResourceGroupSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalR GetByResourceGroup. */ public final class SignalRGetByResourceGroupSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_Get.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_Get.json */ /** * Sample code: SignalR_Get. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListByResourceGroupSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListByResourceGroupSamples.java index e4a497c8f1638..dec2b1d1b16b3 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListByResourceGroupSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListByResourceGroupSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalR ListByResourceGroup. */ public final class SignalRListByResourceGroupSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_ListByResourceGroup.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_ListByResourceGroup.json */ /** * Sample code: SignalR_ListByResourceGroup. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListKeysSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListKeysSamples.java index ec93b22d6ee85..7d76ecf7483fa 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListKeysSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListKeysSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalR ListKeys. */ public final class SignalRListKeysSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_ListKeys.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_ListKeys.json */ /** * Sample code: SignalR_ListKeys. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListSamples.java index 0c6aebe56a6dd..554fab158d453 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalR List. */ public final class SignalRListSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_ListBySubscription.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_ListBySubscription.json */ /** * Sample code: SignalR_ListBySubscription. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListSkusSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListSkusSamples.java index 2f7d97581041b..3b9633b2c8ad2 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListSkusSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRListSkusSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalR ListSkus. */ public final class SignalRListSkusSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_ListSkus.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_ListSkus.json */ /** * Sample code: SignalR_ListSkus. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsDeleteSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsDeleteSamples.java index 5551f9f3d6412..1075beaeab47c 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsDeleteSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsDeleteSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalRPrivateEndpointConnections Delete. */ public final class SignalRPrivateEndpointConnectionsDeleteSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRPrivateEndpointConnections_Delete.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRPrivateEndpointConnections_Delete.json */ /** * Sample code: SignalRPrivateEndpointConnections_Delete. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsGetSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsGetSamples.java index 89c96d0ce17ec..3abc5a3fee8d0 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsGetSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsGetSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalRPrivateEndpointConnections Get. */ public final class SignalRPrivateEndpointConnectionsGetSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRPrivateEndpointConnections_Get.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRPrivateEndpointConnections_Get.json */ /** * Sample code: SignalRPrivateEndpointConnections_Get. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsListSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsListSamples.java index 64ae4add8a5e3..1dae01e8c0f65 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsListSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsListSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalRPrivateEndpointConnections List. */ public final class SignalRPrivateEndpointConnectionsListSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRPrivateEndpointConnections_List.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRPrivateEndpointConnections_List.json */ /** * Sample code: SignalRPrivateEndpointConnections_List. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsUpdateSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsUpdateSamples.java index 700d8c2d8ece9..6e554bd138e60 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsUpdateSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateEndpointConnectionsUpdateSamples.java @@ -13,7 +13,7 @@ /** Samples for SignalRPrivateEndpointConnections Update. */ public final class SignalRPrivateEndpointConnectionsUpdateSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRPrivateEndpointConnections_Update.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRPrivateEndpointConnections_Update.json */ /** * Sample code: SignalRPrivateEndpointConnections_Update. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateLinkResourcesListSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateLinkResourcesListSamples.java index ab67cb7c59e26..a6ccce2ee6de0 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateLinkResourcesListSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRPrivateLinkResourcesListSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalRPrivateLinkResources List. */ public final class SignalRPrivateLinkResourcesListSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRPrivateLinkResources_List.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRPrivateLinkResources_List.json */ /** * Sample code: SignalRPrivateLinkResources_List. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRRegenerateKeySamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRRegenerateKeySamples.java index 56cd3e91c4fb0..b9a47bcddc851 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRRegenerateKeySamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRRegenerateKeySamples.java @@ -11,7 +11,7 @@ /** Samples for SignalR RegenerateKey. */ public final class SignalRRegenerateKeySamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_RegenerateKey.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_RegenerateKey.json */ /** * Sample code: SignalR_RegenerateKey. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRRestartSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRRestartSamples.java index f5f5aec1ec9a6..66673ceb827ed 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRRestartSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRRestartSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalR Restart. */ public final class SignalRRestartSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_Restart.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_Restart.json */ /** * Sample code: SignalR_Restart. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesCreateOrUpdateSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesCreateOrUpdateSamples.java index d839213926acb..141f3b3d128cf 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesCreateOrUpdateSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesCreateOrUpdateSamples.java @@ -7,7 +7,7 @@ /** Samples for SignalRSharedPrivateLinkResources CreateOrUpdate. */ public final class SignalRSharedPrivateLinkResourcesCreateOrUpdateSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRSharedPrivateLinkResources_CreateOrUpdate.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRSharedPrivateLinkResources_CreateOrUpdate.json */ /** * Sample code: SignalRSharedPrivateLinkResources_CreateOrUpdate. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesDeleteSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesDeleteSamples.java index d3ee50d8528e4..ac348940d8d45 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesDeleteSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesDeleteSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalRSharedPrivateLinkResources Delete. */ public final class SignalRSharedPrivateLinkResourcesDeleteSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRSharedPrivateLinkResources_Delete.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRSharedPrivateLinkResources_Delete.json */ /** * Sample code: SignalRSharedPrivateLinkResources_Delete. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesGetSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesGetSamples.java index 75b515909fd63..43df65fe7f24e 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesGetSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesGetSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalRSharedPrivateLinkResources Get. */ public final class SignalRSharedPrivateLinkResourcesGetSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRSharedPrivateLinkResources_Get.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRSharedPrivateLinkResources_Get.json */ /** * Sample code: SignalRSharedPrivateLinkResources_Get. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesListSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesListSamples.java index ce41e0e3b8852..4bdb825a5660e 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesListSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRSharedPrivateLinkResourcesListSamples.java @@ -9,7 +9,7 @@ /** Samples for SignalRSharedPrivateLinkResources List. */ public final class SignalRSharedPrivateLinkResourcesListSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalRSharedPrivateLinkResources_List.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalRSharedPrivateLinkResources_List.json */ /** * Sample code: SignalRSharedPrivateLinkResources_List. diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRUpdateSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRUpdateSamples.java index 1c4d233dcb45d..6f4157bde2161 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRUpdateSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/SignalRUpdateSamples.java @@ -7,6 +7,8 @@ import com.azure.core.util.Context; import com.azure.resourcemanager.signalr.models.AclAction; import com.azure.resourcemanager.signalr.models.FeatureFlags; +import com.azure.resourcemanager.signalr.models.LiveTraceCategory; +import com.azure.resourcemanager.signalr.models.LiveTraceConfiguration; import com.azure.resourcemanager.signalr.models.ManagedIdentity; import com.azure.resourcemanager.signalr.models.ManagedIdentitySettings; import com.azure.resourcemanager.signalr.models.ManagedIdentityType; @@ -31,7 +33,7 @@ /** Samples for SignalR Update. */ public final class SignalRUpdateSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/SignalR_Update.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/SignalR_Update.json */ /** * Sample code: SignalR_Update. @@ -69,6 +71,11 @@ public static void signalRUpdate(com.azure.resourcemanager.signalr.SignalRManage .withFlag(FeatureFlags.ENABLE_LIVE_TRACE) .withValue("False") .withProperties(mapOf()))) + .withLiveTraceConfiguration( + new LiveTraceConfiguration() + .withEnabled("false") + .withCategories( + Arrays.asList(new LiveTraceCategory().withName("ConnectivityLogs").withEnabled("true")))) .withCors(new SignalRCorsSettings().withAllowedOrigins(Arrays.asList("https://foo.com", "https://bar.com"))) .withUpstream( new ServerlessUpstreamSettings() diff --git a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/UsagesListSamples.java b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/UsagesListSamples.java index dc4dff4730883..2510f30bba1b3 100644 --- a/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/UsagesListSamples.java +++ b/sdk/signalr/azure-resourcemanager-signalr/src/samples/java/com/azure/resourcemanager/signalr/generated/UsagesListSamples.java @@ -9,7 +9,7 @@ /** Samples for Usages List. */ public final class UsagesListSamples { /* - * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2021-10-01/examples/Usages_List.json + * x-ms-original-file: specification/signalr/resource-manager/Microsoft.SignalRService/stable/2022-02-01/examples/Usages_List.json */ /** * Sample code: Usages_List.