Class DiagnosticSettingsResourceInner
java.lang.Object
com.azure.core.management.ProxyResource
com.azure.resourcemanager.monitor.fluent.models.DiagnosticSettingsResourceInner
- All Implemented Interfaces:
com.azure.json.JsonSerializable<com.azure.core.management.ProxyResource>
public final class DiagnosticSettingsResourceInner
extends com.azure.core.management.ProxyResource
The diagnostic setting resource.
-
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of DiagnosticSettingsResourceInner class. -
Method Summary
Modifier and TypeMethodDescriptionGet the eventHubAuthorizationRuleId property: The resource Id for the event hub authorization rule.Get the eventHubName property: The name of the event hub.fromJson
(com.azure.json.JsonReader jsonReader) Reads an instance of DiagnosticSettingsResourceInner from the JsonReader.id()
Get the id property: Fully qualified resource Id for the resource.Get the logAnalyticsDestinationType property: A string indicating whether the export to Log Analytics should use the default destination type, i.e.logs()
Get the logs property: The list of logs settings.Get the marketplacePartnerId property: The full ARM resource ID of the Marketplace resource to which you would like to send Diagnostic Logs.metrics()
Get the metrics property: The list of metric settings.name()
Get the name property: The name of the resource.Get the serviceBusRuleId property: The service bus rule Id of the diagnostic setting.Get the storageAccountId property: The resource ID of the storage account to which you would like to send Diagnostic Logs.com.azure.core.management.SystemData
Get the systemData property: The system metadata related to this resource.com.azure.json.JsonWriter
toJson
(com.azure.json.JsonWriter jsonWriter) type()
Get the type property: The type of the resource.void
validate()
Validates the instance.withEventHubAuthorizationRuleId
(String eventHubAuthorizationRuleId) Set the eventHubAuthorizationRuleId property: The resource Id for the event hub authorization rule.withEventHubName
(String eventHubName) Set the eventHubName property: The name of the event hub.withLogAnalyticsDestinationType
(String logAnalyticsDestinationType) Set the logAnalyticsDestinationType property: A string indicating whether the export to Log Analytics should use the default destination type, i.e.withLogs
(List<LogSettings> logs) Set the logs property: The list of logs settings.withMarketplacePartnerId
(String marketplacePartnerId) Set the marketplacePartnerId property: The full ARM resource ID of the Marketplace resource to which you would like to send Diagnostic Logs.withMetrics
(List<MetricSettings> metrics) Set the metrics property: The list of metric settings.withServiceBusRuleId
(String serviceBusRuleId) Set the serviceBusRuleId property: The service bus rule Id of the diagnostic setting.withStorageAccountId
(String storageAccountId) Set the storageAccountId property: The resource ID of the storage account to which you would like to send Diagnostic Logs.withWorkspaceId
(String workspaceId) Set the workspaceId property: The full ARM resource ID of the Log Analytics workspace to which you would like to send Diagnostic Logs.Get the workspaceId property: The full ARM resource ID of the Log Analytics workspace to which you would like to send Diagnostic Logs.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
DiagnosticSettingsResourceInner
public DiagnosticSettingsResourceInner()Creates an instance of DiagnosticSettingsResourceInner class.
-
-
Method Details
-
systemData
public com.azure.core.management.SystemData systemData()Get the systemData property: The system metadata related to this resource.- Returns:
- the systemData value.
-
id
Get the id property: Fully qualified resource Id for the resource.- Overrides:
id
in classcom.azure.core.management.ProxyResource
- Returns:
- the id value.
-
name
Get the name property: The name of the resource.- Overrides:
name
in classcom.azure.core.management.ProxyResource
- Returns:
- the name value.
-
type
Get the type property: The type of the resource.- Overrides:
type
in classcom.azure.core.management.ProxyResource
- Returns:
- the type value.
-
storageAccountId
Get the storageAccountId property: The resource ID of the storage account to which you would like to send Diagnostic Logs.- Returns:
- the storageAccountId value.
-
withStorageAccountId
Set the storageAccountId property: The resource ID of the storage account to which you would like to send Diagnostic Logs.- Parameters:
storageAccountId
- the storageAccountId value to set.- Returns:
- the DiagnosticSettingsResourceInner object itself.
-
serviceBusRuleId
Get the serviceBusRuleId property: The service bus rule Id of the diagnostic setting. This is here to maintain backwards compatibility.- Returns:
- the serviceBusRuleId value.
-
withServiceBusRuleId
Set the serviceBusRuleId property: The service bus rule Id of the diagnostic setting. This is here to maintain backwards compatibility.- Parameters:
serviceBusRuleId
- the serviceBusRuleId value to set.- Returns:
- the DiagnosticSettingsResourceInner object itself.
-
eventHubAuthorizationRuleId
Get the eventHubAuthorizationRuleId property: The resource Id for the event hub authorization rule.- Returns:
- the eventHubAuthorizationRuleId value.
-
withEventHubAuthorizationRuleId
public DiagnosticSettingsResourceInner withEventHubAuthorizationRuleId(String eventHubAuthorizationRuleId) Set the eventHubAuthorizationRuleId property: The resource Id for the event hub authorization rule.- Parameters:
eventHubAuthorizationRuleId
- the eventHubAuthorizationRuleId value to set.- Returns:
- the DiagnosticSettingsResourceInner object itself.
-
eventHubName
Get the eventHubName property: The name of the event hub. If none is specified, the default event hub will be selected.- Returns:
- the eventHubName value.
-
withEventHubName
Set the eventHubName property: The name of the event hub. If none is specified, the default event hub will be selected.- Parameters:
eventHubName
- the eventHubName value to set.- Returns:
- the DiagnosticSettingsResourceInner object itself.
-
metrics
Get the metrics property: The list of metric settings.- Returns:
- the metrics value.
-
withMetrics
Set the metrics property: The list of metric settings.- Parameters:
metrics
- the metrics value to set.- Returns:
- the DiagnosticSettingsResourceInner object itself.
-
logs
Get the logs property: The list of logs settings.- Returns:
- the logs value.
-
withLogs
Set the logs property: The list of logs settings.- Parameters:
logs
- the logs value to set.- Returns:
- the DiagnosticSettingsResourceInner object itself.
-
workspaceId
Get the workspaceId property: 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.- Returns:
- the workspaceId value.
-
withWorkspaceId
Set the workspaceId property: 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.- Parameters:
workspaceId
- the workspaceId value to set.- Returns:
- the DiagnosticSettingsResourceInner object itself.
-
marketplacePartnerId
Get the marketplacePartnerId property: The full ARM resource ID of the Marketplace resource to which you would like to send Diagnostic Logs.- Returns:
- the marketplacePartnerId value.
-
withMarketplacePartnerId
Set the marketplacePartnerId property: The full ARM resource ID of the Marketplace resource to which you would like to send Diagnostic Logs.- Parameters:
marketplacePartnerId
- the marketplacePartnerId value to set.- Returns:
- the DiagnosticSettingsResourceInner object itself.
-
logAnalyticsDestinationType
Get the logAnalyticsDestinationType property: 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.).- Returns:
- the logAnalyticsDestinationType value.
-
withLogAnalyticsDestinationType
public DiagnosticSettingsResourceInner withLogAnalyticsDestinationType(String logAnalyticsDestinationType) Set the logAnalyticsDestinationType property: 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.).- Parameters:
logAnalyticsDestinationType
- the logAnalyticsDestinationType value to set.- Returns:
- the DiagnosticSettingsResourceInner object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException
- thrown if the instance is not valid.
-
toJson
- Specified by:
toJson
in interfacecom.azure.json.JsonSerializable<com.azure.core.management.ProxyResource>
- Overrides:
toJson
in classcom.azure.core.management.ProxyResource
- Throws:
IOException
-
fromJson
public static DiagnosticSettingsResourceInner fromJson(com.azure.json.JsonReader jsonReader) throws IOException Reads an instance of DiagnosticSettingsResourceInner from the JsonReader.- Parameters:
jsonReader
- The JsonReader being read.- Returns:
- An instance of DiagnosticSettingsResourceInner if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
- Throws:
IllegalStateException
- If the deserialized JSON object was missing any required properties.IOException
- If an error occurs while reading the DiagnosticSettingsResourceInner.
-