-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Add Javadocs for Monitor Query #38475
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
faf0d80
d373ddd
76d5707
7034644
5a5c73c
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -21,9 +21,23 @@ | |
| import com.azure.monitor.query.implementation.logs.AzureLogAnalyticsImplBuilder; | ||
|
|
||
| /** | ||
| * Fluent builder for creating instances of {@link LogsQueryClient} and {@link LogsQueryAsyncClient}. | ||
| * <p>Fluent builder for creating instances of {@link LogsQueryClient} and {@link LogsQueryAsyncClient}.</p> | ||
| * | ||
| * <p><strong>Instantiating an asynchronous Logs query Client</strong></p> | ||
| * <p>The LogsQueryClientBuilder is responsible for authenticating a building instances of {@link LogsQueryClient} and | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| * {@link LogsQueryAsyncClient}. Customizations can be applied to clients through the builder using the various options | ||
| * available.</p> | ||
| * | ||
| * <h2>Getting Started</h2> | ||
| * | ||
| * <p> | ||
| * To create instances of the clients, sufficient authentication credentials are required. {@link TokenCredential} is | ||
| * a common form of authentication. The resource / workspace is not required for client creation, but the authentication | ||
| * credentials must have access to the resources / workspaces utilized by the client. | ||
| * </p> | ||
| * | ||
| * <h3>Client Builder Usage</h3> | ||
| * | ||
| * <p>The following sample shows instantiating an asynchronous Logs query Client using Token Credential</p> | ||
| * | ||
| * <!-- src_embed com.azure.monitor.query.LogsQueryAsyncClient.instantiation --> | ||
| * <pre> | ||
|
|
@@ -33,7 +47,7 @@ | |
| * </pre> | ||
| * <!-- end com.azure.monitor.query.LogsQueryAsyncClient.instantiation --> | ||
| * | ||
| * <p><strong>Instantiating a synchronous Logs query Client</strong></p> | ||
| * <p>The following sample shows instantiating a synchronous Logs query Client using Token Credential</p> | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| * | ||
| * <!-- src_embed com.azure.monitor.query.LogsQueryClient.instantiation --> | ||
| * <pre> | ||
|
|
@@ -42,6 +56,15 @@ | |
| * .buildClient(); | ||
| * </pre> | ||
| * <!-- end com.azure.monitor.query.LogsQueryClient.instantiation --> | ||
| * | ||
| * <p> | ||
| * For more information about the other types of credentials that can be used to authenticate your client, please see | ||
| * this documentation: <a href="https://learn.microsoft.com/java/api/overview/azure/identity-readme?view=azure-java-stable">Azure Identity</a> | ||
| * </p> | ||
| * | ||
| * @see com.azure.monitor.query | ||
| * @see LogsQueryClient | ||
| * @see LogsQueryAsyncClient | ||
| */ | ||
| @ServiceClientBuilder(serviceClients = {LogsQueryClient.class, LogsQueryAsyncClient.class}) | ||
| public final class LogsQueryClientBuilder implements EndpointTrait<LogsQueryClientBuilder>, | ||
|
|
@@ -50,6 +73,11 @@ public final class LogsQueryClientBuilder implements EndpointTrait<LogsQueryClie | |
| private final AzureLogAnalyticsImplBuilder innerLogBuilder = new AzureLogAnalyticsImplBuilder(); | ||
| private LogsQueryServiceVersion serviceVersion; | ||
|
|
||
| /** | ||
| * Creates an instance of LogsQueryClientBuilder. | ||
| */ | ||
| public LogsQueryClientBuilder() { } | ||
|
|
||
| /** | ||
| * Sets the log query endpoint. | ||
| * @param endpoint the host value. | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -33,8 +33,19 @@ | |
| import static com.azure.monitor.query.implementation.metrics.models.MetricsHelper.convertToMetricsQueryResult; | ||
|
|
||
| /** | ||
| * The asynchronous client for querying Azure Monitor metrics. | ||
| * <p><strong>Instantiating an asynchronous Metrics query Client</strong></p> | ||
| * <p>The asynchronous client for querying Azure Monitor metrics.</p> | ||
| * | ||
| * <p>Azure Monitor Metrics is a feature of Azure Monitor that collects numeric data from monitored resources into a | ||
| * time-series database. Metrics are numerical values that are collected at regular intervals and describe some aspect | ||
| * of a system at a particular time. The MetricsQueryClient provides synchronous implementations of methods that query | ||
| * metrics from your Azure services.</p> | ||
|
Comment on lines
+40
to
+41
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This should be about the async client. |
||
| * | ||
| * <h2>Getting Started</h2> | ||
| * | ||
| * <p> | ||
| * Authenticating and building MetricsQueryAsyncClient instances are done through {@link MetricsQueryClientBuilder}. | ||
| * The following sample shows how to build a new MetricsQueryClient instance. | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| * </p> | ||
| * | ||
| * <!-- src_embed com.azure.monitor.query.MetricsQueryAsyncClient.instantiation --> | ||
| * <pre> | ||
|
|
@@ -43,6 +54,27 @@ | |
| * .buildAsyncClient(); | ||
| * </pre> | ||
| * <!-- end com.azure.monitor.query.MetricsQueryAsyncClient.instantiation --> | ||
| * | ||
| * <p> | ||
| * For more information on building and authenticating, see the {@link MetricsQueryClientBuilder} documentation. | ||
| * </p> | ||
| * | ||
| * <h3>Client Usage</h3> | ||
| * | ||
| * <p> | ||
| * For more information on using the MetricsQueryAsyncClient, see the following method documentation: | ||
| * </p> | ||
| * | ||
| * <ul> | ||
| * <li> | ||
| * {@link MetricsQueryAsyncClient#queryResource(String, List)} - Query metrics for an Azure resource. | ||
| * {@link MetricsQueryAsyncClient#listMetricNamespaces(String, OffsetDateTime)} - Lists all the metrics namespaces created for the resource URI. | ||
| * {@link MetricsQueryAsyncClient#listMetricDefinitions(String)} - Lists all the metrics definitions created for the resource URI. | ||
| * </li> | ||
| * </ul> | ||
| * | ||
| * @see com.azure.monitor.query | ||
| * @see MetricsQueryClientBuilder | ||
| */ | ||
| @ServiceClient(builder = MetricsQueryClientBuilder.class, isAsync = true) | ||
| public final class MetricsQueryAsyncClient { | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LogsQueryAsyncClient