diff --git a/sdk/kusto/azure-resourcemanager-kusto/CHANGELOG.md b/sdk/kusto/azure-resourcemanager-kusto/CHANGELOG.md
index 8acbf43302ff..cbbcb2797d63 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/CHANGELOG.md
+++ b/sdk/kusto/azure-resourcemanager-kusto/CHANGELOG.md
@@ -1,6 +1,8 @@
# Release History
-## 1.0.0-beta.5 (Unreleased)
+## 1.0.0-beta.1 (2022-06-14)
+
+- Azure Resource Manager Kusto client library for Java. This package contains Microsoft Azure SDK for Kusto Management SDK. The Azure Kusto management API provides a RESTful set of web services that interact with Azure Kusto services to manage your clusters and databases. The API enables you to create, update, and delete clusters and databases. Package tag package-2022-02. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
### Features Added
diff --git a/sdk/kusto/azure-resourcemanager-kusto/README.md b/sdk/kusto/azure-resourcemanager-kusto/README.md
index e7b742650327..e19d73a1ebed 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/README.md
+++ b/sdk/kusto/azure-resourcemanager-kusto/README.md
@@ -32,7 +32,7 @@ Various documentation is available to help you get started
com.azure.resourcemanagerazure-resourcemanager-kusto
- 1.0.0-beta.4
+ 1.0.0-beta.5
```
[//]: # ({x-version-update-end})
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/KustoManager.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/KustoManager.java
index 91a9d28610dd..d43e2ff045d7 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/KustoManager.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/KustoManager.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;
@@ -115,6 +117,19 @@ public static KustoManager authenticate(TokenCredential credential, AzureProfile
return configure().authenticate(credential, profile);
}
+ /**
+ * Creates an instance of Kusto service API entry point.
+ *
+ * @param httpPipeline the {@link HttpPipeline} configured with Azure authentication credential.
+ * @param profile the Azure profile for client.
+ * @return the Kusto service API instance.
+ */
+ public static KustoManager authenticate(HttpPipeline httpPipeline, AzureProfile profile) {
+ Objects.requireNonNull(httpPipeline, "'httpPipeline' cannot be null.");
+ Objects.requireNonNull(profile, "'profile' cannot be null.");
+ return new KustoManager(httpPipeline, profile, null);
+ }
+
/**
* Gets a Configurable instance that can be used to create KustoManager with optional configuration.
*
@@ -126,13 +141,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() {
@@ -193,6 +209,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.
*
@@ -200,9 +229,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;
}
@@ -224,7 +255,7 @@ public KustoManager authenticate(TokenCredential credential, AzureProfile profil
.append("-")
.append("com.azure.resourcemanager.kusto")
.append("/")
- .append("1.0.0-beta.4");
+ .append("1.0.0-beta.1");
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
userAgentBuilder
.append(" (")
@@ -242,10 +273,15 @@ public KustoManager authenticate(TokenCredential credential, AzureProfile profil
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(
@@ -276,7 +312,11 @@ public KustoManager authenticate(TokenCredential credential, AzureProfile profil
}
}
- /** @return Resource collection API of Clusters. */
+ /**
+ * Gets the resource collection API of Clusters. It manages Cluster.
+ *
+ * @return Resource collection API of Clusters.
+ */
public Clusters clusters() {
if (this.clusters == null) {
this.clusters = new ClustersImpl(clientObject.getClusters(), this);
@@ -284,7 +324,11 @@ public Clusters clusters() {
return clusters;
}
- /** @return Resource collection API of ClusterPrincipalAssignments. */
+ /**
+ * Gets the resource collection API of ClusterPrincipalAssignments. It manages ClusterPrincipalAssignment.
+ *
+ * @return Resource collection API of ClusterPrincipalAssignments.
+ */
public ClusterPrincipalAssignments clusterPrincipalAssignments() {
if (this.clusterPrincipalAssignments == null) {
this.clusterPrincipalAssignments =
@@ -293,7 +337,11 @@ public ClusterPrincipalAssignments clusterPrincipalAssignments() {
return clusterPrincipalAssignments;
}
- /** @return Resource collection API of Databases. */
+ /**
+ * Gets the resource collection API of Databases.
+ *
+ * @return Resource collection API of Databases.
+ */
public Databases databases() {
if (this.databases == null) {
this.databases = new DatabasesImpl(clientObject.getDatabases(), this);
@@ -301,7 +349,11 @@ public Databases databases() {
return databases;
}
- /** @return Resource collection API of AttachedDatabaseConfigurations. */
+ /**
+ * Gets the resource collection API of AttachedDatabaseConfigurations. It manages AttachedDatabaseConfiguration.
+ *
+ * @return Resource collection API of AttachedDatabaseConfigurations.
+ */
public AttachedDatabaseConfigurations attachedDatabaseConfigurations() {
if (this.attachedDatabaseConfigurations == null) {
this.attachedDatabaseConfigurations =
@@ -310,7 +362,11 @@ public AttachedDatabaseConfigurations attachedDatabaseConfigurations() {
return attachedDatabaseConfigurations;
}
- /** @return Resource collection API of ManagedPrivateEndpoints. */
+ /**
+ * Gets the resource collection API of ManagedPrivateEndpoints. It manages ManagedPrivateEndpoint.
+ *
+ * @return Resource collection API of ManagedPrivateEndpoints.
+ */
public ManagedPrivateEndpoints managedPrivateEndpoints() {
if (this.managedPrivateEndpoints == null) {
this.managedPrivateEndpoints =
@@ -319,7 +375,11 @@ public ManagedPrivateEndpoints managedPrivateEndpoints() {
return managedPrivateEndpoints;
}
- /** @return Resource collection API of DatabasePrincipalAssignments. */
+ /**
+ * Gets the resource collection API of DatabasePrincipalAssignments. It manages DatabasePrincipalAssignment.
+ *
+ * @return Resource collection API of DatabasePrincipalAssignments.
+ */
public DatabasePrincipalAssignments databasePrincipalAssignments() {
if (this.databasePrincipalAssignments == null) {
this.databasePrincipalAssignments =
@@ -328,7 +388,11 @@ public DatabasePrincipalAssignments databasePrincipalAssignments() {
return databasePrincipalAssignments;
}
- /** @return Resource collection API of Scripts. */
+ /**
+ * Gets the resource collection API of Scripts. It manages Script.
+ *
+ * @return Resource collection API of Scripts.
+ */
public Scripts scripts() {
if (this.scripts == null) {
this.scripts = new ScriptsImpl(clientObject.getScripts(), this);
@@ -336,7 +400,11 @@ public Scripts scripts() {
return scripts;
}
- /** @return Resource collection API of PrivateEndpointConnections. */
+ /**
+ * Gets the resource collection API of PrivateEndpointConnections. It manages PrivateEndpointConnection.
+ *
+ * @return Resource collection API of PrivateEndpointConnections.
+ */
public PrivateEndpointConnections privateEndpointConnections() {
if (this.privateEndpointConnections == null) {
this.privateEndpointConnections =
@@ -345,7 +413,11 @@ public PrivateEndpointConnections privateEndpointConnections() {
return privateEndpointConnections;
}
- /** @return Resource collection API of PrivateLinkResources. */
+ /**
+ * Gets the resource collection API of PrivateLinkResources.
+ *
+ * @return Resource collection API of PrivateLinkResources.
+ */
public PrivateLinkResources privateLinkResources() {
if (this.privateLinkResources == null) {
this.privateLinkResources = new PrivateLinkResourcesImpl(clientObject.getPrivateLinkResources(), this);
@@ -353,7 +425,11 @@ public PrivateLinkResources privateLinkResources() {
return privateLinkResources;
}
- /** @return Resource collection API of DataConnections. */
+ /**
+ * Gets the resource collection API of DataConnections.
+ *
+ * @return Resource collection API of DataConnections.
+ */
public DataConnections dataConnections() {
if (this.dataConnections == null) {
this.dataConnections = new DataConnectionsImpl(clientObject.getDataConnections(), this);
@@ -361,7 +437,11 @@ public DataConnections dataConnections() {
return dataConnections;
}
- /** @return Resource collection API of Operations. */
+ /**
+ * Gets the resource collection API of Operations.
+ *
+ * @return Resource collection API of Operations.
+ */
public Operations operations() {
if (this.operations == null) {
this.operations = new OperationsImpl(clientObject.getOperations(), this);
@@ -369,7 +449,11 @@ public Operations operations() {
return operations;
}
- /** @return Resource collection API of OperationsResults. */
+ /**
+ * Gets the resource collection API of OperationsResults.
+ *
+ * @return Resource collection API of OperationsResults.
+ */
public OperationsResults operationsResults() {
if (this.operationsResults == null) {
this.operationsResults = new OperationsResultsImpl(clientObject.getOperationsResults(), this);
@@ -377,7 +461,11 @@ public OperationsResults operationsResults() {
return operationsResults;
}
- /** @return Resource collection API of OperationsResultsLocations. */
+ /**
+ * Gets the resource collection API of OperationsResultsLocations.
+ *
+ * @return Resource collection API of OperationsResultsLocations.
+ */
public OperationsResultsLocations operationsResultsLocations() {
if (this.operationsResultsLocations == null) {
this.operationsResultsLocations =
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/AttachedDatabaseConfigurationInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/AttachedDatabaseConfigurationInner.java
index 6dd3fcaaee34..d7d28a8841c3 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/AttachedDatabaseConfigurationInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/AttachedDatabaseConfigurationInner.java
@@ -6,19 +6,15 @@
import com.azure.core.annotation.Fluent;
import com.azure.core.management.ProxyResource;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.DefaultPrincipalsModificationKind;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
import com.azure.resourcemanager.kusto.models.TableLevelSharingProperties;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;
/** Class representing an attached database configuration. */
@Fluent
public final class AttachedDatabaseConfigurationInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(AttachedDatabaseConfigurationInner.class);
-
/*
* Resource location.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/AttachedDatabaseConfigurationProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/AttachedDatabaseConfigurationProperties.java
index 820febeb8970..c18ce5748842 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/AttachedDatabaseConfigurationProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/AttachedDatabaseConfigurationProperties.java
@@ -9,15 +9,12 @@
import com.azure.resourcemanager.kusto.models.DefaultPrincipalsModificationKind;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
import com.azure.resourcemanager.kusto.models.TableLevelSharingProperties;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;
/** Class representing the an attached database configuration properties of kind specific. */
@Fluent
public final class AttachedDatabaseConfigurationProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(AttachedDatabaseConfigurationProperties.class);
-
/*
* The provisioned state of the resource.
*/
@@ -169,20 +166,20 @@ public AttachedDatabaseConfigurationProperties withTableLevelSharingProperties(
*/
public void validate() {
if (databaseName() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property databaseName in model AttachedDatabaseConfigurationProperties"));
}
if (clusterResourceId() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property clusterResourceId in model"
+ " AttachedDatabaseConfigurationProperties"));
}
if (defaultPrincipalsModificationKind() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property defaultPrincipalsModificationKind in model"
@@ -192,4 +189,6 @@ public void validate() {
tableLevelSharingProperties().validate();
}
}
+
+ private static final ClientLogger LOGGER = new ClientLogger(AttachedDatabaseConfigurationProperties.class);
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/AzureResourceSkuInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/AzureResourceSkuInner.java
index 70f01a247b23..3f1effd5fbea 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/AzureResourceSkuInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/AzureResourceSkuInner.java
@@ -5,17 +5,13 @@
package com.azure.resourcemanager.kusto.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.AzureCapacity;
import com.azure.resourcemanager.kusto.models.AzureSku;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** Azure resource SKU definition. */
@Fluent
public final class AzureResourceSkuInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(AzureResourceSkuInner.class);
-
/*
* Resource Namespace and Type.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/CheckNameResultInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/CheckNameResultInner.java
index 68673f699903..f62824a480bd 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/CheckNameResultInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/CheckNameResultInner.java
@@ -5,16 +5,12 @@
package com.azure.resourcemanager.kusto.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.Reason;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** The result returned from a check name availability request. */
@Fluent
public final class CheckNameResultInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(CheckNameResultInner.class);
-
/*
* Specifies a Boolean value that indicates if the name is available.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterInner.java
index 0ca9fa765467..a151a202f33f 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterInner.java
@@ -22,7 +22,6 @@
import com.azure.resourcemanager.kusto.models.State;
import com.azure.resourcemanager.kusto.models.TrustedExternalTenant;
import com.azure.resourcemanager.kusto.models.VirtualNetworkConfiguration;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;
import java.util.Map;
@@ -30,8 +29,6 @@
/** Class representing a Kusto cluster. */
@Fluent
public final class ClusterInner extends Resource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterInner.class);
-
/*
* The SKU of the cluster.
*/
@@ -638,7 +635,7 @@ public List privateEndpointConnections() {
*/
public void validate() {
if (sku() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException("Missing required property sku in model ClusterInner"));
} else {
@@ -651,4 +648,6 @@ public void validate() {
innerProperties().validate();
}
}
+
+ private static final ClientLogger LOGGER = new ClientLogger(ClusterInner.class);
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterPrincipalAssignmentInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterPrincipalAssignmentInner.java
index 390c1efe3331..9fd1fe89ccd6 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterPrincipalAssignmentInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterPrincipalAssignmentInner.java
@@ -6,18 +6,14 @@
import com.azure.core.annotation.Fluent;
import com.azure.core.management.ProxyResource;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.ClusterPrincipalRole;
import com.azure.resourcemanager.kusto.models.PrincipalType;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** Class representing a cluster principal assignment. */
@Fluent
public final class ClusterPrincipalAssignmentInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterPrincipalAssignmentInner.class);
-
/*
* The cluster principal.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterPrincipalProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterPrincipalProperties.java
index 5ecfc75b92c5..431c3f01f0fb 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterPrincipalProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterPrincipalProperties.java
@@ -9,14 +9,11 @@
import com.azure.resourcemanager.kusto.models.ClusterPrincipalRole;
import com.azure.resourcemanager.kusto.models.PrincipalType;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** A class representing cluster principal property. */
@Fluent
public final class ClusterPrincipalProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterPrincipalProperties.class);
-
/*
* The principal ID assigned to the cluster principal. It can be a user
* email, application ID, or security group name.
@@ -191,21 +188,23 @@ public String aadObjectId() {
*/
public void validate() {
if (principalId() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property principalId in model ClusterPrincipalProperties"));
}
if (role() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException("Missing required property role in model ClusterPrincipalProperties"));
}
if (principalType() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property principalType in model ClusterPrincipalProperties"));
}
}
+
+ private static final ClientLogger LOGGER = new ClientLogger(ClusterPrincipalProperties.class);
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterProperties.java
index 2d46169da798..23cb3e6041e7 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ClusterProperties.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.kusto.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.AcceptedAudiences;
import com.azure.resourcemanager.kusto.models.ClusterNetworkAccessFlag;
import com.azure.resourcemanager.kusto.models.EngineType;
@@ -18,15 +17,12 @@
import com.azure.resourcemanager.kusto.models.State;
import com.azure.resourcemanager.kusto.models.TrustedExternalTenant;
import com.azure.resourcemanager.kusto.models.VirtualNetworkConfiguration;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;
/** Class representing the Kusto cluster properties. */
@Fluent
public final class ClusterProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterProperties.class);
-
/*
* The state of the resource.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DataConnectionInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DataConnectionInner.java
index ba6d8314d502..1ed3f3ae5085 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DataConnectionInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DataConnectionInner.java
@@ -6,11 +6,9 @@
import com.azure.core.annotation.Fluent;
import com.azure.core.management.ProxyResource;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.EventGridDataConnection;
import com.azure.resourcemanager.kusto.models.EventHubDataConnection;
import com.azure.resourcemanager.kusto.models.IotHubDataConnection;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonSubTypes;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
@@ -30,8 +28,6 @@
})
@Fluent
public class DataConnectionInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(DataConnectionInner.class);
-
/*
* Resource location.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DataConnectionValidationInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DataConnectionValidationInner.java
index 1af06baf9738..5a0188af4e62 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DataConnectionValidationInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DataConnectionValidationInner.java
@@ -5,15 +5,11 @@
package com.azure.resourcemanager.kusto.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;
/** Class representing an data connection validation. */
@Fluent
public final class DataConnectionValidationInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(DataConnectionValidationInner.class);
-
/*
* The name of the data connection.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DataConnectionValidationListResultInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DataConnectionValidationListResultInner.java
index 1244c23b4dfb..f1f593b06bd3 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DataConnectionValidationListResultInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DataConnectionValidationListResultInner.java
@@ -5,17 +5,13 @@
package com.azure.resourcemanager.kusto.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.DataConnectionValidationResult;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;
/** The list Kusto data connection validation result. */
@Fluent
public final class DataConnectionValidationListResultInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(DataConnectionValidationListResultInner.class);
-
/*
* The list of Kusto data connection validation errors.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabaseInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabaseInner.java
index c9ae8759baae..fe1c964d6d84 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabaseInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabaseInner.java
@@ -6,10 +6,8 @@
import com.azure.core.annotation.Fluent;
import com.azure.core.management.ProxyResource;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.ReadOnlyFollowingDatabase;
import com.azure.resourcemanager.kusto.models.ReadWriteDatabase;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonSubTypes;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
@@ -28,8 +26,6 @@
})
@Fluent
public class DatabaseInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(DatabaseInner.class);
-
/*
* Resource location.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalAssignmentInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalAssignmentInner.java
index cbe068ed2cba..8af126884543 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalAssignmentInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalAssignmentInner.java
@@ -6,18 +6,14 @@
import com.azure.core.annotation.Fluent;
import com.azure.core.management.ProxyResource;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.DatabasePrincipalRole;
import com.azure.resourcemanager.kusto.models.PrincipalType;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** Class representing a database principal assignment. */
@Fluent
public final class DatabasePrincipalAssignmentInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(DatabasePrincipalAssignmentInner.class);
-
/*
* The database principal.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalInner.java
index c3bf3d9b6cbe..ba9cbc2ed10d 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalInner.java
@@ -8,14 +8,11 @@
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.DatabasePrincipalRole;
import com.azure.resourcemanager.kusto.models.DatabasePrincipalType;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** A class representing database principal entity. */
@Fluent
public final class DatabasePrincipalInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(DatabasePrincipalInner.class);
-
/*
* Database principal role.
*/
@@ -194,19 +191,21 @@ public String tenantName() {
*/
public void validate() {
if (role() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException("Missing required property role in model DatabasePrincipalInner"));
}
if (name() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException("Missing required property name in model DatabasePrincipalInner"));
}
if (type() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException("Missing required property type in model DatabasePrincipalInner"));
}
}
+
+ private static final ClientLogger LOGGER = new ClientLogger(DatabasePrincipalInner.class);
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalListResultInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalListResultInner.java
index 73313f38d677..de5db2b56fbf 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalListResultInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalListResultInner.java
@@ -5,16 +5,12 @@
package com.azure.resourcemanager.kusto.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;
import java.util.List;
/** The list Kusto database principals operation response. */
@Fluent
public final class DatabasePrincipalListResultInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(DatabasePrincipalListResultInner.class);
-
/*
* The list of Kusto database principals.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalProperties.java
index 00b21471a84c..b2e3346ad71b 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DatabasePrincipalProperties.java
@@ -9,14 +9,11 @@
import com.azure.resourcemanager.kusto.models.DatabasePrincipalRole;
import com.azure.resourcemanager.kusto.models.PrincipalType;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** A class representing database principal property. */
@Fluent
public final class DatabasePrincipalProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(DatabasePrincipalProperties.class);
-
/*
* The principal ID assigned to the database principal. It can be a user
* email, application ID, or security group name.
@@ -191,22 +188,24 @@ public String aadObjectId() {
*/
public void validate() {
if (principalId() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property principalId in model DatabasePrincipalProperties"));
}
if (role() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property role in model DatabasePrincipalProperties"));
}
if (principalType() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property principalType in model DatabasePrincipalProperties"));
}
}
+
+ private static final ClientLogger LOGGER = new ClientLogger(DatabasePrincipalProperties.class);
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DiagnoseVirtualNetworkResultInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DiagnoseVirtualNetworkResultInner.java
index 53be09782411..8609a947f528 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DiagnoseVirtualNetworkResultInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/DiagnoseVirtualNetworkResultInner.java
@@ -5,16 +5,12 @@
package com.azure.resourcemanager.kusto.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;
import java.util.List;
/** The DiagnoseVirtualNetworkResult model. */
@Fluent
public final class DiagnoseVirtualNetworkResultInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(DiagnoseVirtualNetworkResultInner.class);
-
/*
* The list of network connectivity diagnostic finding
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/EventGridConnectionProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/EventGridConnectionProperties.java
index 978dde91b846..c2472b23a629 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/EventGridConnectionProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/EventGridConnectionProperties.java
@@ -10,14 +10,11 @@
import com.azure.resourcemanager.kusto.models.DatabaseRouting;
import com.azure.resourcemanager.kusto.models.EventGridDataFormat;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** Class representing the Kusto event grid connection properties. */
@Fluent
public final class EventGridConnectionProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(EventGridConnectionProperties.class);
-
/*
* The resource ID of the storage account where the data resides.
*/
@@ -78,8 +75,9 @@ public final class EventGridConnectionProperties {
private BlobStorageEventType blobStorageEventType;
/*
- * The resource ID of a managed identity (system or user assigned) to be
- * used to authenticate with event hub and storage account.
+ * Empty for non-managed identity based data connection. For system
+ * assigned identity, provide cluster resource Id. For user assigned
+ * identity (UAI) provide the UAI resource Id.
*/
@JsonProperty(value = "managedIdentityResourceId")
private String managedIdentityResourceId;
@@ -294,8 +292,8 @@ public EventGridConnectionProperties withBlobStorageEventType(BlobStorageEventTy
}
/**
- * Get the managedIdentityResourceId property: The resource ID of a managed identity (system or user assigned) to be
- * used to authenticate with event hub and storage account.
+ * Get the managedIdentityResourceId property: Empty for non-managed identity based data connection. For system
+ * assigned identity, provide cluster resource Id. For user assigned identity (UAI) provide the UAI resource Id.
*
* @return the managedIdentityResourceId value.
*/
@@ -304,8 +302,8 @@ public String managedIdentityResourceId() {
}
/**
- * Set the managedIdentityResourceId property: The resource ID of a managed identity (system or user assigned) to be
- * used to authenticate with event hub and storage account.
+ * Set the managedIdentityResourceId property: Empty for non-managed identity based data connection. For system
+ * assigned identity, provide cluster resource Id. For user assigned identity (UAI) provide the UAI resource Id.
*
* @param managedIdentityResourceId the managedIdentityResourceId value to set.
* @return the EventGridConnectionProperties object itself.
@@ -362,22 +360,24 @@ public ProvisioningState provisioningState() {
*/
public void validate() {
if (storageAccountResourceId() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property storageAccountResourceId in model EventGridConnectionProperties"));
}
if (eventHubResourceId() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property eventHubResourceId in model EventGridConnectionProperties"));
}
if (consumerGroup() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property consumerGroup in model EventGridConnectionProperties"));
}
}
+
+ private static final ClientLogger LOGGER = new ClientLogger(EventGridConnectionProperties.class);
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/EventHubConnectionProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/EventHubConnectionProperties.java
index bb2d49a23b01..5d50899f232d 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/EventHubConnectionProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/EventHubConnectionProperties.java
@@ -10,15 +10,12 @@
import com.azure.resourcemanager.kusto.models.DatabaseRouting;
import com.azure.resourcemanager.kusto.models.EventHubDataFormat;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;
/** Class representing the Kusto event hub connection properties. */
@Fluent
public final class EventHubConnectionProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(EventHubConnectionProperties.class);
-
/*
* The resource ID of the event hub to be used to create a data connection.
*/
@@ -71,8 +68,9 @@ public final class EventHubConnectionProperties {
private ProvisioningState provisioningState;
/*
- * The resource ID of a managed identity (system or user assigned) to be
- * used to authenticate with event hub.
+ * Empty for non-managed identity based data connection. For system
+ * assigned identity, provide cluster resource Id. For user assigned
+ * identity (UAI) provide the UAI resource Id.
*/
@JsonProperty(value = "managedIdentityResourceId")
private String managedIdentityResourceId;
@@ -246,8 +244,8 @@ public ProvisioningState provisioningState() {
}
/**
- * Get the managedIdentityResourceId property: The resource ID of a managed identity (system or user assigned) to be
- * used to authenticate with event hub.
+ * Get the managedIdentityResourceId property: Empty for non-managed identity based data connection. For system
+ * assigned identity, provide cluster resource Id. For user assigned identity (UAI) provide the UAI resource Id.
*
* @return the managedIdentityResourceId value.
*/
@@ -256,8 +254,8 @@ public String managedIdentityResourceId() {
}
/**
- * Set the managedIdentityResourceId property: The resource ID of a managed identity (system or user assigned) to be
- * used to authenticate with event hub.
+ * Set the managedIdentityResourceId property: Empty for non-managed identity based data connection. For system
+ * assigned identity, provide cluster resource Id. For user assigned identity (UAI) provide the UAI resource Id.
*
* @param managedIdentityResourceId the managedIdentityResourceId value to set.
* @return the EventHubConnectionProperties object itself.
@@ -305,16 +303,18 @@ public EventHubConnectionProperties withDatabaseRouting(DatabaseRouting database
*/
public void validate() {
if (eventHubResourceId() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property eventHubResourceId in model EventHubConnectionProperties"));
}
if (consumerGroup() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property consumerGroup in model EventHubConnectionProperties"));
}
}
+
+ private static final ClientLogger LOGGER = new ClientLogger(EventHubConnectionProperties.class);
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/FollowerDatabaseDefinitionInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/FollowerDatabaseDefinitionInner.java
index c034c8bdf5bc..ffa435b0ff3d 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/FollowerDatabaseDefinitionInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/FollowerDatabaseDefinitionInner.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;
/** A class representing follower database request. */
@Fluent
public final class FollowerDatabaseDefinitionInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(FollowerDatabaseDefinitionInner.class);
-
/*
* Resource id of the cluster that follows a database owned by this
* cluster.
@@ -95,17 +92,19 @@ public String databaseName() {
*/
public void validate() {
if (clusterResourceId() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property clusterResourceId in model FollowerDatabaseDefinitionInner"));
}
if (attachedDatabaseConfigurationName() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property attachedDatabaseConfigurationName in model"
+ " FollowerDatabaseDefinitionInner"));
}
}
+
+ private static final ClientLogger LOGGER = new ClientLogger(FollowerDatabaseDefinitionInner.class);
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/IotHubConnectionProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/IotHubConnectionProperties.java
index 0473e6cddf3f..6b411c7d443a 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/IotHubConnectionProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/IotHubConnectionProperties.java
@@ -9,15 +9,12 @@
import com.azure.resourcemanager.kusto.models.DatabaseRouting;
import com.azure.resourcemanager.kusto.models.IotHubDataFormat;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;
/** Class representing the Kusto Iot hub connection properties. */
@Fluent
public final class IotHubConnectionProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(IotHubConnectionProperties.class);
-
/*
* The resource ID of the Iot hub to be used to create a data connection.
*/
@@ -260,22 +257,24 @@ public ProvisioningState provisioningState() {
*/
public void validate() {
if (iotHubResourceId() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property iotHubResourceId in model IotHubConnectionProperties"));
}
if (consumerGroup() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property consumerGroup in model IotHubConnectionProperties"));
}
if (sharedAccessPolicyName() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property sharedAccessPolicyName in model IotHubConnectionProperties"));
}
}
+
+ private static final ClientLogger LOGGER = new ClientLogger(IotHubConnectionProperties.class);
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/LanguageExtensionInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/LanguageExtensionInner.java
index c50b194ff78b..a9804d458e0c 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/LanguageExtensionInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/LanguageExtensionInner.java
@@ -5,16 +5,12 @@
package com.azure.resourcemanager.kusto.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.LanguageExtensionName;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** The language extension object. */
@Fluent
public final class LanguageExtensionInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(LanguageExtensionInner.class);
-
/*
* The language extension name.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ManagedPrivateEndpointInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ManagedPrivateEndpointInner.java
index ee015bdaf0cb..78882c5a20fe 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ManagedPrivateEndpointInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ManagedPrivateEndpointInner.java
@@ -7,16 +7,12 @@
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.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** Class representing a managed private endpoint. */
@Fluent
public final class ManagedPrivateEndpointInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ManagedPrivateEndpointInner.class);
-
/*
* A managed private endpoint.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ManagedPrivateEndpointProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ManagedPrivateEndpointProperties.java
index 53f0f40307f2..6f43bdd0accd 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ManagedPrivateEndpointProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ManagedPrivateEndpointProperties.java
@@ -7,14 +7,11 @@
import com.azure.core.annotation.Fluent;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** A class representing the properties of a managed private endpoint object. */
@Fluent
public final class ManagedPrivateEndpointProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ManagedPrivateEndpointProperties.class);
-
/*
* The ARM resource ID of the resource for which the managed private
* endpoint is created.
@@ -147,16 +144,18 @@ public ProvisioningState provisioningState() {
*/
public void validate() {
if (privateLinkResourceId() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property privateLinkResourceId in model ManagedPrivateEndpointProperties"));
}
if (groupId() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property groupId in model ManagedPrivateEndpointProperties"));
}
}
+
+ private static final ClientLogger LOGGER = new ClientLogger(ManagedPrivateEndpointProperties.class);
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationInner.java
index 35a0e1104550..33ea0a0006a8 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationInner.java
@@ -5,16 +5,12 @@
package com.azure.resourcemanager.kusto.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.OperationDisplay;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** A REST API operation. */
@Fluent
public final class OperationInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationInner.class);
-
/*
* The operation name. This is of the format
* {provider}/{resource}/{operation}.
@@ -35,7 +31,7 @@ public final class OperationInner {
private String origin;
/*
- * Any object
+ * Properties of the operation.
*/
@JsonProperty(value = "properties")
private Object properties;
@@ -101,7 +97,7 @@ public OperationInner withOrigin(String origin) {
}
/**
- * Get the properties property: Any object.
+ * Get the properties property: Properties of the operation.
*
* @return the properties value.
*/
@@ -110,7 +106,7 @@ public Object properties() {
}
/**
- * Set the properties property: Any object.
+ * Set the properties property: Properties of the operation.
*
* @param properties the properties value to set.
* @return the OperationInner object itself.
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationResultErrorProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationResultErrorProperties.java
index 124e0214b0f0..4c12411e8d70 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationResultErrorProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationResultErrorProperties.java
@@ -5,15 +5,11 @@
package com.azure.resourcemanager.kusto.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;
/** Operation result error properties. */
@Fluent
public final class OperationResultErrorProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationResultErrorProperties.class);
-
/*
* The code of the error.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationResultInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationResultInner.java
index fe0b75c1eb44..547a011faa64 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationResultInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationResultInner.java
@@ -5,18 +5,14 @@
package com.azure.resourcemanager.kusto.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
import com.azure.resourcemanager.kusto.models.Status;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.time.OffsetDateTime;
/** Operation Result Entity. */
@Fluent
public final class OperationResultInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationResultInner.class);
-
/*
* ID of the resource.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationResultProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationResultProperties.java
index f2684b67be30..f3c74a33b225 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationResultProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OperationResultProperties.java
@@ -5,16 +5,12 @@
package com.azure.resourcemanager.kusto.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** Operation result properties. */
@Fluent
public final class OperationResultProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationResultProperties.class);
-
/*
* The kind of the operation.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OutboundNetworkDependenciesEndpointInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OutboundNetworkDependenciesEndpointInner.java
index edaad6ddf49d..9e22a79c4c35 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OutboundNetworkDependenciesEndpointInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OutboundNetworkDependenciesEndpointInner.java
@@ -6,18 +6,14 @@
import com.azure.core.annotation.Fluent;
import com.azure.core.management.ProxyResource;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.EndpointDependency;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;
/** Endpoints accessed for a common purpose that the Kusto Service Environment requires outbound network access to. */
@Fluent
public final class OutboundNetworkDependenciesEndpointInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(OutboundNetworkDependenciesEndpointInner.class);
-
/*
* The outbound environment endpoint properties.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OutboundNetworkDependenciesEndpointProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OutboundNetworkDependenciesEndpointProperties.java
index 137259a593b0..f4e79da51751 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OutboundNetworkDependenciesEndpointProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/OutboundNetworkDependenciesEndpointProperties.java
@@ -5,19 +5,14 @@
package com.azure.resourcemanager.kusto.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.EndpointDependency;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;
/** Endpoints accessed for a common purpose that the Kusto Service Environment requires outbound network access to. */
@Fluent
public final class OutboundNetworkDependenciesEndpointProperties {
- @JsonIgnore
- private final ClientLogger logger = new ClientLogger(OutboundNetworkDependenciesEndpointProperties.class);
-
/*
* The type of service accessed by the Kusto Service Environment, e.g.,
* Azure Storage, Azure SQL Database, and Azure Active Directory.
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateEndpointConnectionInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateEndpointConnectionInner.java
index 8e0fdaa2c0a4..38e7a154c16a 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateEndpointConnectionInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateEndpointConnectionInner.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.kusto.models.PrivateEndpointProperty;
import com.azure.resourcemanager.kusto.models.PrivateLinkServiceConnectionStateProperty;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** A private endpoint connection. */
@Fluent
public final class PrivateEndpointConnectionInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpointConnectionInner.class);
-
/*
* Resource properties.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateEndpointConnectionProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateEndpointConnectionProperties.java
index 61b7a8e9e42d..2e54989b2816 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateEndpointConnectionProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateEndpointConnectionProperties.java
@@ -8,14 +8,11 @@
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.PrivateEndpointProperty;
import com.azure.resourcemanager.kusto.models.PrivateLinkServiceConnectionStateProperty;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** Properties of a private endpoint connection. */
@Fluent
public final class PrivateEndpointConnectionProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpointConnectionProperties.class);
-
/*
* Private endpoint which the connection belongs to.
*/
@@ -98,7 +95,7 @@ public void validate() {
privateEndpoint().validate();
}
if (privateLinkServiceConnectionState() == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property privateLinkServiceConnectionState in model"
@@ -107,4 +104,6 @@ public void validate() {
privateLinkServiceConnectionState().validate();
}
}
+
+ private static final ClientLogger LOGGER = new ClientLogger(PrivateEndpointConnectionProperties.class);
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateLinkResourceInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateLinkResourceInner.java
index 7f2c9d5f60ff..659c42256a0d 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateLinkResourceInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateLinkResourceInner.java
@@ -7,16 +7,12 @@
import com.azure.core.annotation.Fluent;
import com.azure.core.management.ProxyResource;
import com.azure.core.management.SystemData;
-import com.azure.core.util.logging.ClientLogger;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;
/** A private link resource. */
@Fluent
public final class PrivateLinkResourceInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkResourceInner.class);
-
/*
* Resource properties.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateLinkResourceProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateLinkResourceProperties.java
index 0022b8caae99..cbd112a374dd 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateLinkResourceProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/PrivateLinkResourceProperties.java
@@ -5,16 +5,12 @@
package com.azure.resourcemanager.kusto.fluent.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;
/** Properties of a private link resource. */
@Immutable
public final class PrivateLinkResourceProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkResourceProperties.class);
-
/*
* The private link resource group id.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ReadOnlyFollowingDatabaseProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ReadOnlyFollowingDatabaseProperties.java
index 20b4444e5a4d..748b4ff75f5d 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ReadOnlyFollowingDatabaseProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ReadOnlyFollowingDatabaseProperties.java
@@ -5,19 +5,15 @@
package com.azure.resourcemanager.kusto.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.DatabaseStatistics;
import com.azure.resourcemanager.kusto.models.PrincipalsModificationKind;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.time.Duration;
/** Class representing the Kusto database properties. */
@Fluent
public final class ReadOnlyFollowingDatabaseProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ReadOnlyFollowingDatabaseProperties.class);
-
/*
* The provisioned state of the resource.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ReadWriteDatabaseProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ReadWriteDatabaseProperties.java
index 50ea2493e673..88d53d56ec9c 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ReadWriteDatabaseProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ReadWriteDatabaseProperties.java
@@ -5,18 +5,14 @@
package com.azure.resourcemanager.kusto.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.DatabaseStatistics;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.time.Duration;
/** Class representing the Kusto database properties. */
@Fluent
public final class ReadWriteDatabaseProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ReadWriteDatabaseProperties.class);
-
/*
* The provisioned state of the resource.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ScriptInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ScriptInner.java
index 06a3498cfe13..e4d15a2ed459 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ScriptInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ScriptInner.java
@@ -7,16 +7,12 @@
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.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** Class representing a database script. */
@Fluent
public final class ScriptInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ScriptInner.class);
-
/*
* The database script.
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ScriptProperties.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ScriptProperties.java
index f904a179e530..e7ed6e57e749 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ScriptProperties.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/ScriptProperties.java
@@ -5,16 +5,12 @@
package com.azure.resourcemanager.kusto.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
/** A class representing database script property. */
@Fluent
public final class ScriptProperties {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ScriptProperties.class);
-
/*
* The url to the KQL script blob file. Must not be used together with
* scriptContent property
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/SkuDescriptionInner.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/SkuDescriptionInner.java
index f1104f4a5584..87f3dcc9824f 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/SkuDescriptionInner.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/fluent/models/SkuDescriptionInner.java
@@ -5,17 +5,13 @@
package com.azure.resourcemanager.kusto.fluent.models;
import com.azure.core.annotation.Immutable;
-import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.kusto.models.SkuLocationInfoItem;
-import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;
/** The Kusto SKU description of given resource type. */
@Immutable
public final class SkuDescriptionInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(SkuDescriptionInner.class);
-
/*
* The resource type
*/
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/AttachedDatabaseConfigurationImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/AttachedDatabaseConfigurationImpl.java
index ef8c970221a0..ba8c22e4a76d 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/AttachedDatabaseConfigurationImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/AttachedDatabaseConfigurationImpl.java
@@ -75,6 +75,10 @@ public String regionName() {
return this.location();
}
+ public String resourceGroupName() {
+ return resourceGroupName;
+ }
+
public AttachedDatabaseConfigurationInner innerModel() {
return this.innerObject;
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/AttachedDatabaseConfigurationsClientImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/AttachedDatabaseConfigurationsClientImpl.java
index 4407285f4bb1..efc3ea68cc77 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/AttachedDatabaseConfigurationsClientImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/AttachedDatabaseConfigurationsClientImpl.java
@@ -30,7 +30,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.kusto.fluent.AttachedDatabaseConfigurationsClient;
@@ -44,8 +43,6 @@
/** An instance of this class provides access to all the operations defined in AttachedDatabaseConfigurationsClient. */
public final class AttachedDatabaseConfigurationsClientImpl implements AttachedDatabaseConfigurationsClient {
- private final ClientLogger logger = new ClientLogger(AttachedDatabaseConfigurationsClientImpl.class);
-
/** The proxy service used to perform REST calls. */
private final AttachedDatabaseConfigurationsService service;
@@ -283,14 +280,7 @@ private Mono> checkNameAvailabilityWithResponseAs
private Mono checkNameAvailabilityAsync(
String resourceGroupName, String clusterName, AttachedDatabaseConfigurationsCheckNameRequest resourceName) {
return checkNameAvailabilityWithResponseAsync(resourceGroupName, clusterName, resourceName)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
@@ -632,14 +622,7 @@ private Mono> getWithResponseAsync(
private Mono getAsync(
String resourceGroupName, String clusterName, String attachedDatabaseConfigurationName) {
return getWithResponseAsync(resourceGroupName, clusterName, attachedDatabaseConfigurationName)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/AttachedDatabaseConfigurationsImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/AttachedDatabaseConfigurationsImpl.java
index c9b4eafba5e3..4b7302c68883 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/AttachedDatabaseConfigurationsImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/AttachedDatabaseConfigurationsImpl.java
@@ -16,10 +16,9 @@
import com.azure.resourcemanager.kusto.models.AttachedDatabaseConfigurations;
import com.azure.resourcemanager.kusto.models.AttachedDatabaseConfigurationsCheckNameRequest;
import com.azure.resourcemanager.kusto.models.CheckNameResult;
-import com.fasterxml.jackson.annotation.JsonIgnore;
public final class AttachedDatabaseConfigurationsImpl implements AttachedDatabaseConfigurations {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(AttachedDatabaseConfigurationsImpl.class);
+ private static final ClientLogger LOGGER = new ClientLogger(AttachedDatabaseConfigurationsImpl.class);
private final AttachedDatabaseConfigurationsClient innerClient;
@@ -115,7 +114,7 @@ public void delete(
public AttachedDatabaseConfiguration getById(String id) {
String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -123,14 +122,14 @@ public AttachedDatabaseConfiguration getById(String id) {
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
}
String attachedDatabaseConfigurationName = Utils.getValueFromIdByName(id, "attachedDatabaseConfigurations");
if (attachedDatabaseConfigurationName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -147,7 +146,7 @@ public AttachedDatabaseConfiguration 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
@@ -155,14 +154,14 @@ public Response getByIdWithResponse(String id, Co
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
}
String attachedDatabaseConfigurationName = Utils.getValueFromIdByName(id, "attachedDatabaseConfigurations");
if (attachedDatabaseConfigurationName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -177,7 +176,7 @@ public Response getByIdWithResponse(String id, Co
public void deleteById(String id) {
String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -185,14 +184,14 @@ public void deleteById(String id) {
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
}
String attachedDatabaseConfigurationName = Utils.getValueFromIdByName(id, "attachedDatabaseConfigurations");
if (attachedDatabaseConfigurationName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -207,7 +206,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
@@ -215,14 +214,14 @@ public void deleteByIdWithResponse(String id, Context context) {
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
}
String attachedDatabaseConfigurationName = Utils.getValueFromIdByName(id, "attachedDatabaseConfigurations");
if (attachedDatabaseConfigurationName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterImpl.java
index 8fdd4a522d05..ea4e115a12e7 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterImpl.java
@@ -225,6 +225,10 @@ public String regionName() {
return this.location();
}
+ public String resourceGroupName() {
+ return resourceGroupName;
+ }
+
public ClusterInner innerModel() {
return this.innerObject;
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterPrincipalAssignmentImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterPrincipalAssignmentImpl.java
index a02a4f865339..4714979ccba7 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterPrincipalAssignmentImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterPrincipalAssignmentImpl.java
@@ -61,6 +61,10 @@ public String aadObjectId() {
return this.innerModel().aadObjectId();
}
+ public String resourceGroupName() {
+ return resourceGroupName;
+ }
+
public ClusterPrincipalAssignmentInner innerModel() {
return this.innerObject;
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterPrincipalAssignmentsClientImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterPrincipalAssignmentsClientImpl.java
index 393c43c5c358..4ab4d4899c81 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterPrincipalAssignmentsClientImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterPrincipalAssignmentsClientImpl.java
@@ -30,7 +30,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.kusto.fluent.ClusterPrincipalAssignmentsClient;
@@ -44,8 +43,6 @@
/** An instance of this class provides access to all the operations defined in ClusterPrincipalAssignmentsClient. */
public final class ClusterPrincipalAssignmentsClientImpl implements ClusterPrincipalAssignmentsClient {
- private final ClientLogger logger = new ClientLogger(ClusterPrincipalAssignmentsClientImpl.class);
-
/** The proxy service used to perform REST calls. */
private final ClusterPrincipalAssignmentsService service;
@@ -289,14 +286,7 @@ private Mono checkNameAvailabilityAsync(
String clusterName,
ClusterPrincipalAssignmentCheckNameRequest principalAssignmentName) {
return checkNameAvailabilityWithResponseAsync(resourceGroupName, clusterName, principalAssignmentName)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
@@ -463,14 +453,7 @@ private Mono> getWithResponseAsync(
private Mono getAsync(
String resourceGroupName, String clusterName, String principalAssignmentName) {
return getWithResponseAsync(resourceGroupName, clusterName, principalAssignmentName)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterPrincipalAssignmentsImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterPrincipalAssignmentsImpl.java
index dd5ed3c5e76a..1d421f57ae5b 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterPrincipalAssignmentsImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClusterPrincipalAssignmentsImpl.java
@@ -16,10 +16,9 @@
import com.azure.resourcemanager.kusto.models.ClusterPrincipalAssignment;
import com.azure.resourcemanager.kusto.models.ClusterPrincipalAssignmentCheckNameRequest;
import com.azure.resourcemanager.kusto.models.ClusterPrincipalAssignments;
-import com.fasterxml.jackson.annotation.JsonIgnore;
public final class ClusterPrincipalAssignmentsImpl implements ClusterPrincipalAssignments {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterPrincipalAssignmentsImpl.class);
+ private static final ClientLogger LOGGER = new ClientLogger(ClusterPrincipalAssignmentsImpl.class);
private final ClusterPrincipalAssignmentsClient innerClient;
@@ -114,7 +113,7 @@ public PagedIterable list(
public ClusterPrincipalAssignment getById(String id) {
String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -122,14 +121,14 @@ public ClusterPrincipalAssignment getById(String id) {
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
}
String principalAssignmentName = Utils.getValueFromIdByName(id, "principalAssignments");
if (principalAssignmentName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -143,7 +142,7 @@ public ClusterPrincipalAssignment 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
@@ -151,14 +150,14 @@ public Response getByIdWithResponse(String id, Conte
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
}
String principalAssignmentName = Utils.getValueFromIdByName(id, "principalAssignments");
if (principalAssignmentName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -172,7 +171,7 @@ public Response getByIdWithResponse(String id, Conte
public void deleteById(String id) {
String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -180,14 +179,14 @@ public void deleteById(String id) {
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
}
String principalAssignmentName = Utils.getValueFromIdByName(id, "principalAssignments");
if (principalAssignmentName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -201,7 +200,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
@@ -209,14 +208,14 @@ public void deleteByIdWithResponse(String id, Context context) {
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
}
String principalAssignmentName = Utils.getValueFromIdByName(id, "principalAssignments");
if (principalAssignmentName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClustersClientImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClustersClientImpl.java
index 89047e216e5a..8a8a6586816a 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClustersClientImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClustersClientImpl.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.kusto.fluent.ClustersClient;
@@ -57,8 +56,6 @@
/** An instance of this class provides access to all the operations defined in ClustersClient. */
public final class ClustersClientImpl implements ClustersClient {
- private final ClientLogger logger = new ClientLogger(ClustersClientImpl.class);
-
/** The proxy service used to perform REST calls. */
private final ClustersService service;
@@ -465,14 +462,7 @@ private Mono> getByResourceGroupWithResponseAsync(
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono getByResourceGroupAsync(String resourceGroupName, String clusterName) {
return getByResourceGroupWithResponseAsync(resourceGroupName, clusterName)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
@@ -3103,14 +3093,7 @@ private Mono> checkNameAvailabilityWithResponseAs
private Mono checkNameAvailabilityAsync(
String location, ClusterCheckNameRequest clusterName) {
return checkNameAvailabilityWithResponseAsync(location, clusterName)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClustersImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClustersImpl.java
index 61505157f94d..3b60361f11d8 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClustersImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/ClustersImpl.java
@@ -29,10 +29,9 @@
import com.azure.resourcemanager.kusto.models.LanguageExtensionsList;
import com.azure.resourcemanager.kusto.models.OutboundNetworkDependenciesEndpoint;
import com.azure.resourcemanager.kusto.models.SkuDescription;
-import com.fasterxml.jackson.annotation.JsonIgnore;
public final class ClustersImpl implements Clusters {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ClustersImpl.class);
+ private static final ClientLogger LOGGER = new ClientLogger(ClustersImpl.class);
private final ClustersClient innerClient;
@@ -261,7 +260,7 @@ public void removeLanguageExtensions(
public Cluster getById(String id) {
String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -269,7 +268,7 @@ public Cluster getById(String id) {
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
@@ -280,7 +279,7 @@ public Cluster 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
@@ -288,7 +287,7 @@ public Response getByIdWithResponse(String id, Context context) {
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
@@ -299,7 +298,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
@@ -307,7 +306,7 @@ public void deleteById(String id) {
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
@@ -318,7 +317,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
@@ -326,7 +325,7 @@ public void deleteByIdWithResponse(String id, Context context) {
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DataConnectionsClientImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DataConnectionsClientImpl.java
index 29c8fc4621e0..5073a388823c 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DataConnectionsClientImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DataConnectionsClientImpl.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.kusto.fluent.DataConnectionsClient;
@@ -47,8 +46,6 @@
/** An instance of this class provides access to all the operations defined in DataConnectionsClient. */
public final class DataConnectionsClientImpl implements DataConnectionsClient {
- private final ClientLogger logger = new ClientLogger(DataConnectionsClientImpl.class);
-
/** The proxy service used to perform REST calls. */
private final DataConnectionsService service;
@@ -851,14 +848,7 @@ private Mono checkNameAvailabilityAsync(
String databaseName,
DataConnectionCheckNameRequest dataConnectionName) {
return checkNameAvailabilityWithResponseAsync(resourceGroupName, clusterName, databaseName, dataConnectionName)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
@@ -1041,14 +1031,7 @@ private Mono> getWithResponseAsync(
private Mono getAsync(
String resourceGroupName, String clusterName, String databaseName, String dataConnectionName) {
return getWithResponseAsync(resourceGroupName, clusterName, databaseName, dataConnectionName)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DataConnectionsImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DataConnectionsImpl.java
index 91905324bfbe..12f49e687511 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DataConnectionsImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DataConnectionsImpl.java
@@ -19,10 +19,9 @@
import com.azure.resourcemanager.kusto.models.DataConnectionCheckNameRequest;
import com.azure.resourcemanager.kusto.models.DataConnectionValidationListResult;
import com.azure.resourcemanager.kusto.models.DataConnections;
-import com.fasterxml.jackson.annotation.JsonIgnore;
public final class DataConnectionsImpl implements DataConnections {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(DataConnectionsImpl.class);
+ private static final ClientLogger LOGGER = new ClientLogger(DataConnectionsImpl.class);
private final DataConnectionsClient innerClient;
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasePrincipalAssignmentImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasePrincipalAssignmentImpl.java
index 48e8a5ec6431..34b47713c7dc 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasePrincipalAssignmentImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasePrincipalAssignmentImpl.java
@@ -61,6 +61,10 @@ public String aadObjectId() {
return this.innerModel().aadObjectId();
}
+ public String resourceGroupName() {
+ return resourceGroupName;
+ }
+
public DatabasePrincipalAssignmentInner innerModel() {
return this.innerObject;
}
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasePrincipalAssignmentsClientImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasePrincipalAssignmentsClientImpl.java
index 7a36e4097e99..64450f65fb28 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasePrincipalAssignmentsClientImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasePrincipalAssignmentsClientImpl.java
@@ -30,7 +30,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.kusto.fluent.DatabasePrincipalAssignmentsClient;
@@ -44,8 +43,6 @@
/** An instance of this class provides access to all the operations defined in DatabasePrincipalAssignmentsClient. */
public final class DatabasePrincipalAssignmentsClientImpl implements DatabasePrincipalAssignmentsClient {
- private final ClientLogger logger = new ClientLogger(DatabasePrincipalAssignmentsClientImpl.class);
-
/** The proxy service used to perform REST calls. */
private final DatabasePrincipalAssignmentsService service;
@@ -309,14 +306,7 @@ private Mono checkNameAvailabilityAsync(
DatabasePrincipalAssignmentCheckNameRequest principalAssignmentName) {
return checkNameAvailabilityWithResponseAsync(
resourceGroupName, clusterName, databaseName, principalAssignmentName)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
@@ -506,14 +496,7 @@ private Mono> getWithResponseAsync(
private Mono getAsync(
String resourceGroupName, String clusterName, String databaseName, String principalAssignmentName) {
return getWithResponseAsync(resourceGroupName, clusterName, databaseName, principalAssignmentName)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasePrincipalAssignmentsImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasePrincipalAssignmentsImpl.java
index 4933c6081113..146e96c2b5bc 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasePrincipalAssignmentsImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasePrincipalAssignmentsImpl.java
@@ -16,10 +16,9 @@
import com.azure.resourcemanager.kusto.models.DatabasePrincipalAssignment;
import com.azure.resourcemanager.kusto.models.DatabasePrincipalAssignmentCheckNameRequest;
import com.azure.resourcemanager.kusto.models.DatabasePrincipalAssignments;
-import com.fasterxml.jackson.annotation.JsonIgnore;
public final class DatabasePrincipalAssignmentsImpl implements DatabasePrincipalAssignments {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(DatabasePrincipalAssignmentsImpl.class);
+ private static final ClientLogger LOGGER = new ClientLogger(DatabasePrincipalAssignmentsImpl.class);
private final DatabasePrincipalAssignmentsClient innerClient;
@@ -132,7 +131,7 @@ public PagedIterable list(
public DatabasePrincipalAssignment getById(String id) {
String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -140,21 +139,21 @@ public DatabasePrincipalAssignment getById(String id) {
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
}
String databaseName = Utils.getValueFromIdByName(id, "databases");
if (databaseName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'databases'.", id)));
}
String principalAssignmentName = Utils.getValueFromIdByName(id, "principalAssignments");
if (principalAssignmentName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -170,7 +169,7 @@ public DatabasePrincipalAssignment 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
@@ -178,21 +177,21 @@ public Response getByIdWithResponse(String id, Cont
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
}
String databaseName = Utils.getValueFromIdByName(id, "databases");
if (databaseName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'databases'.", id)));
}
String principalAssignmentName = Utils.getValueFromIdByName(id, "principalAssignments");
if (principalAssignmentName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -206,7 +205,7 @@ public Response getByIdWithResponse(String id, Cont
public void deleteById(String id) {
String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -214,21 +213,21 @@ public void deleteById(String id) {
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
}
String databaseName = Utils.getValueFromIdByName(id, "databases");
if (databaseName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'databases'.", id)));
}
String principalAssignmentName = Utils.getValueFromIdByName(id, "principalAssignments");
if (principalAssignmentName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
@@ -242,7 +241,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
@@ -250,21 +249,21 @@ public void deleteByIdWithResponse(String id, Context context) {
}
String clusterName = Utils.getValueFromIdByName(id, "clusters");
if (clusterName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
}
String databaseName = Utils.getValueFromIdByName(id, "databases");
if (databaseName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'databases'.", id)));
}
String principalAssignmentName = Utils.getValueFromIdByName(id, "principalAssignments");
if (principalAssignmentName == null) {
- throw logger
+ throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
String
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasesClientImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasesClientImpl.java
index 4e750b8f6adc..4d3b8a240786 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasesClientImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasesClientImpl.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.kusto.fluent.DatabasesClient;
@@ -48,8 +47,6 @@
/** An instance of this class provides access to all the operations defined in DatabasesClient. */
public final class DatabasesClientImpl implements DatabasesClient {
- private final ClientLogger logger = new ClientLogger(DatabasesClientImpl.class);
-
/** The proxy service used to perform REST calls. */
private final DatabasesService service;
@@ -347,14 +344,7 @@ private Mono> checkNameAvailabilityWithResponseAs
private Mono checkNameAvailabilityAsync(
String resourceGroupName, String clusterName, CheckNameRequest resourceName) {
return checkNameAvailabilityWithResponseAsync(resourceGroupName, clusterName, resourceName)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
@@ -676,14 +666,7 @@ private Mono> getWithResponseAsync(
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono getAsync(String resourceGroupName, String clusterName, String databaseName) {
return getWithResponseAsync(resourceGroupName, clusterName, databaseName)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
@@ -1877,14 +1860,7 @@ private Mono addPrincipalsAsync(
String databaseName,
DatabasePrincipalListRequest databasePrincipalsToAdd) {
return addPrincipalsWithResponseAsync(resourceGroupName, clusterName, databaseName, databasePrincipalsToAdd)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
@@ -2086,14 +2062,7 @@ private Mono removePrincipalsAsync(
DatabasePrincipalListRequest databasePrincipalsToRemove) {
return removePrincipalsWithResponseAsync(
resourceGroupName, clusterName, databaseName, databasePrincipalsToRemove)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasesImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasesImpl.java
index 5cf62ad97ab6..3fb558a0accb 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasesImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/DatabasesImpl.java
@@ -21,10 +21,9 @@
import com.azure.resourcemanager.kusto.models.DatabasePrincipalListRequest;
import com.azure.resourcemanager.kusto.models.DatabasePrincipalListResult;
import com.azure.resourcemanager.kusto.models.Databases;
-import com.fasterxml.jackson.annotation.JsonIgnore;
public final class DatabasesImpl implements Databases {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(DatabasesImpl.class);
+ private static final ClientLogger LOGGER = new ClientLogger(DatabasesImpl.class);
private final DatabasesClient innerClient;
diff --git a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/KustoManagementClientBuilder.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/KustoManagementClientBuilder.java
index 4f125f56bacb..ad8e4ffee900 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/KustoManagementClientBuilder.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/KustoManagementClientBuilder.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 KustoManagementClientBuilder 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 KustoManagementClientBuilder.
*/
- public KustoManagementClientBuilder defaultPollInterval(Duration defaultPollInterval) {
- this.defaultPollInterval = defaultPollInterval;
+ public KustoManagementClientBuilder 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 KustoManagementClientBuilder.
*/
- public KustoManagementClientBuilder pipeline(HttpPipeline pipeline) {
- this.pipeline = pipeline;
+ public KustoManagementClientBuilder defaultPollInterval(Duration defaultPollInterval) {
+ this.defaultPollInterval = defaultPollInterval;
return this;
}
@@ -129,15 +128,12 @@ public KustoManagementClientImpl buildClient() {
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/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/KustoManagementClientImpl.java b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/KustoManagementClientImpl.java
index 7765f6e1434b..b1f504a5ab7a 100644
--- a/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/KustoManagementClientImpl.java
+++ b/sdk/kusto/azure-resourcemanager-kusto/src/main/java/com/azure/resourcemanager/kusto/implementation/KustoManagementClientImpl.java
@@ -15,6 +15,7 @@
import com.azure.core.management.polling.PollResult;
import com.azure.core.management.polling.PollerFactory;
import com.azure.core.util.Context;
+import com.azure.core.util.CoreUtils;
import com.azure.core.util.logging.ClientLogger;
import com.azure.core.util.polling.AsyncPollResponse;
import com.azure.core.util.polling.LongRunningOperationStatus;
@@ -41,15 +42,12 @@
import java.nio.charset.Charset;
import java.nio.charset.StandardCharsets;
import java.time.Duration;
-import java.util.Map;
import reactor.core.publisher.Flux;
import reactor.core.publisher.Mono;
/** Initializes a new instance of the KustoManagementClientImpl type. */
@ServiceClient(builder = KustoManagementClientBuilder.class)
public final class KustoManagementClientImpl implements KustoManagementClient {
- private final ClientLogger logger = new ClientLogger(KustoManagementClientImpl.class);
-
/**
* Gets subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms
* part of the URI for every service call.
@@ -337,10 +335,7 @@ public Context getContext() {
* @return the merged context.
*/
public Context mergeContext(Context context) {
- for (Map.Entry