com.microsoft.azure.management.monitor.implementation.DiagnosticSettingsResourceInner Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of azure-mgmt-monitor Show documentation
Show all versions of azure-mgmt-monitor Show documentation
This package contains Microsoft Azure Monitor SDK. This package has been deprecated. A replacement package com.azure.resourcemanager:azure-resourcemanager-monitor is available as of 31-March-2022. We strongly encourage you to upgrade to continue receiving updates. See Migration Guide https://aka.ms/java-track2-migration-guide for guidance on upgrading. Refer to our deprecation policy https://azure.github.io/azure-sdk/policies_support.html for more details.
/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
*/
package com.microsoft.azure.management.monitor.implementation;
import java.util.List;
import com.microsoft.azure.management.monitor.MetricSettings;
import com.microsoft.azure.management.monitor.LogSettings;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.microsoft.rest.serializer.JsonFlatten;
import com.microsoft.azure.management.monitor.ProxyOnlyResource;
/**
* The diagnostic setting resource.
*/
@JsonFlatten
public class DiagnosticSettingsResourceInner extends ProxyOnlyResource {
/**
* The resource ID of the storage account to which you would like to send
* Diagnostic Logs.
*/
@JsonProperty(value = "properties.storageAccountId")
private String storageAccountId;
/**
* The service bus rule Id of the diagnostic setting. This is here to
* maintain backwards compatibility.
*/
@JsonProperty(value = "properties.serviceBusRuleId")
private String serviceBusRuleId;
/**
* The resource Id for the event hub authorization rule.
*/
@JsonProperty(value = "properties.eventHubAuthorizationRuleId")
private String eventHubAuthorizationRuleId;
/**
* The name of the event hub. If none is specified, the default event hub
* will be selected.
*/
@JsonProperty(value = "properties.eventHubName")
private String eventHubName;
/**
* The list of metric settings.
*/
@JsonProperty(value = "properties.metrics")
private List metrics;
/**
* The list of logs settings.
*/
@JsonProperty(value = "properties.logs")
private List logs;
/**
* The full ARM resource ID of the Log Analytics workspace to which you
* would like to send Diagnostic Logs. Example:
* /subscriptions/4b9e8510-67ab-4e9a-95a9-e2f1e570ea9c/resourceGroups/insights-integration/providers/Microsoft.OperationalInsights/workspaces/viruela2.
*/
@JsonProperty(value = "properties.workspaceId")
private String workspaceId;
/**
* A string indicating whether the export to Log Analytics should use the
* default destination type, i.e. AzureDiagnostics, or use a destination
* type constructed as follows: <normalized service
* identity>_<normalized category name>. Possible values are:
* Dedicated and null (null is default.).
*/
@JsonProperty(value = "properties.logAnalyticsDestinationType")
private String logAnalyticsDestinationType;
/**
* Get the resource ID of the storage account to which you would like to send Diagnostic Logs.
*
* @return the storageAccountId value
*/
public String storageAccountId() {
return this.storageAccountId;
}
/**
* Set the resource ID of the storage account to which you would like to send Diagnostic Logs.
*
* @param storageAccountId the storageAccountId value to set
* @return the DiagnosticSettingsResourceInner object itself.
*/
public DiagnosticSettingsResourceInner withStorageAccountId(String storageAccountId) {
this.storageAccountId = storageAccountId;
return this;
}
/**
* Get the service bus rule Id of the diagnostic setting. This is here to maintain backwards compatibility.
*
* @return the serviceBusRuleId value
*/
public String serviceBusRuleId() {
return this.serviceBusRuleId;
}
/**
* Set the service bus rule Id of the diagnostic setting. This is here to maintain backwards compatibility.
*
* @param serviceBusRuleId the serviceBusRuleId value to set
* @return the DiagnosticSettingsResourceInner object itself.
*/
public DiagnosticSettingsResourceInner withServiceBusRuleId(String serviceBusRuleId) {
this.serviceBusRuleId = serviceBusRuleId;
return this;
}
/**
* Get the resource Id for the event hub authorization rule.
*
* @return the eventHubAuthorizationRuleId value
*/
public String eventHubAuthorizationRuleId() {
return this.eventHubAuthorizationRuleId;
}
/**
* Set the resource Id for the event hub authorization rule.
*
* @param eventHubAuthorizationRuleId the eventHubAuthorizationRuleId value to set
* @return the DiagnosticSettingsResourceInner object itself.
*/
public DiagnosticSettingsResourceInner withEventHubAuthorizationRuleId(String eventHubAuthorizationRuleId) {
this.eventHubAuthorizationRuleId = eventHubAuthorizationRuleId;
return this;
}
/**
* Get the name of the event hub. If none is specified, the default event hub will be selected.
*
* @return the eventHubName value
*/
public String eventHubName() {
return this.eventHubName;
}
/**
* Set the name of the event hub. If none is specified, the default event hub will be selected.
*
* @param eventHubName the eventHubName value to set
* @return the DiagnosticSettingsResourceInner object itself.
*/
public DiagnosticSettingsResourceInner withEventHubName(String eventHubName) {
this.eventHubName = eventHubName;
return this;
}
/**
* Get the list of metric settings.
*
* @return the metrics value
*/
public List metrics() {
return this.metrics;
}
/**
* Set the list of metric settings.
*
* @param metrics the metrics value to set
* @return the DiagnosticSettingsResourceInner object itself.
*/
public DiagnosticSettingsResourceInner withMetrics(List metrics) {
this.metrics = metrics;
return this;
}
/**
* Get the list of logs settings.
*
* @return the logs value
*/
public List logs() {
return this.logs;
}
/**
* Set the list of logs settings.
*
* @param logs the logs value to set
* @return the DiagnosticSettingsResourceInner object itself.
*/
public DiagnosticSettingsResourceInner withLogs(List logs) {
this.logs = logs;
return this;
}
/**
* Get the full ARM resource ID of the Log Analytics workspace to which you would like to send Diagnostic Logs. Example: /subscriptions/4b9e8510-67ab-4e9a-95a9-e2f1e570ea9c/resourceGroups/insights-integration/providers/Microsoft.OperationalInsights/workspaces/viruela2.
*
* @return the workspaceId value
*/
public String workspaceId() {
return this.workspaceId;
}
/**
* Set the full ARM resource ID of the Log Analytics workspace to which you would like to send Diagnostic Logs. Example: /subscriptions/4b9e8510-67ab-4e9a-95a9-e2f1e570ea9c/resourceGroups/insights-integration/providers/Microsoft.OperationalInsights/workspaces/viruela2.
*
* @param workspaceId the workspaceId value to set
* @return the DiagnosticSettingsResourceInner object itself.
*/
public DiagnosticSettingsResourceInner withWorkspaceId(String workspaceId) {
this.workspaceId = workspaceId;
return this;
}
/**
* Get a string indicating whether the export to Log Analytics should use the default destination type, i.e. AzureDiagnostics, or use a destination type constructed as follows: <normalized service identity>_<normalized category name>. Possible values are: Dedicated and null (null is default.).
*
* @return the logAnalyticsDestinationType value
*/
public String logAnalyticsDestinationType() {
return this.logAnalyticsDestinationType;
}
/**
* Set a string indicating whether the export to Log Analytics should use the default destination type, i.e. AzureDiagnostics, or use a destination type constructed as follows: <normalized service identity>_<normalized category name>. Possible values are: Dedicated and null (null is default.).
*
* @param logAnalyticsDestinationType the logAnalyticsDestinationType value to set
* @return the DiagnosticSettingsResourceInner object itself.
*/
public DiagnosticSettingsResourceInner withLogAnalyticsDestinationType(String logAnalyticsDestinationType) {
this.logAnalyticsDestinationType = logAnalyticsDestinationType;
return this;
}
}