Skip to content
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

[AutoPR azure-cognitiveservices-AnomalyDetector] Fixing S360 swagger issues for billing RP promotions #12224

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Release History

## 1.0.0-beta.1 (Unreleased)

- Azure AnomalyDetectorClient client library for Java. This package contains Microsoft Azure AnomalyDetectorClient client library.

### Features Added

### Breaking Changes

### Bugs Fixed

### Other Changes
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
# Azure AnomalyDetectorClient client library for Java

Azure AnomalyDetectorClient client library for Java.

This package contains Microsoft Azure AnomalyDetectorClient client library.

## Documentation

Various documentation is available to help you get started

- [API reference documentation][docs]
- [Product documentation][product_documentation]

## Getting started

### Prerequisites

- [Java Development Kit (JDK)][jdk] with version 8 or above
- [Azure Subscription][azure_subscription]

### Adding the package to your product

[//]: # ({x-version-update-start;com.azure:azure-cognitiveservices-AnomalyDetector;current})
```xml
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-cognitiveservices-AnomalyDetector</artifactId>
<version>1.0.0-beta.1</version>
</dependency>
```
[//]: # ({x-version-update-end})

### Authentication

[Azure Identity][azure_identity] package provides the default implementation for authenticating the client.

## Key concepts

## Examples

```java com.azure.cognitiveservices.anomalydetector.readme
```

## Troubleshooting

## Next steps

## Contributing

For details on contributing to this repository, see the [contributing guide](https://github.com/Azure/azure-sdk-for-java/blob/main/CONTRIBUTING.md).

1. Fork it
1. Create your feature branch (`git checkout -b my-new-feature`)
1. Commit your changes (`git commit -am 'Add some feature'`)
1. Push to the branch (`git push origin my-new-feature`)
1. Create new Pull Request

<!-- LINKS -->
[product_documentation]: https://azure.microsoft.com/services/
[docs]: https://azure.github.io/azure-sdk-for-java/
[jdk]: https://docs.microsoft.com/java/azure/jdk/
[azure_subscription]: https://azure.microsoft.com/free/
[azure_identity]: https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/identity/azure-identity
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.azure</groupId>
<artifactId>azure-client-sdk-parent</artifactId>
<version>1.7.0</version> <!-- {x-version-update;com.azure:azure-client-sdk-parent;current} -->
<relativePath>../../parents/azure-client-sdk-parent</relativePath>
</parent>

<groupId>com.azure</groupId>
<artifactId>azure-cognitiveservices-AnomalyDetector</artifactId>
<version>1.0.0-beta.1</version> <!-- {x-version-update;com.azure:azure-cognitiveservices-AnomalyDetector;current} -->
<packaging>jar</packaging>

<name>Microsoft Azure SDK for AnomalyDetectorClient Management</name>
<description>This package contains Microsoft Azure AnomalyDetectorClient client library.</description>
<url>https://github.com/Azure/azure-sdk-for-java</url>

<licenses>
<license>
<name>The MIT License (MIT)</name>
<url>http://opensource.org/licenses/MIT</url>
<distribution>repo</distribution>
</license>
</licenses>

<scm>
<url>https://github.com/Azure/azure-sdk-for-java</url>
<connection>scm:git:git@github.com:Azure/azure-sdk-for-java.git</connection>
<developerConnection>scm:git:git@github.com:Azure/azure-sdk-for-java.git</developerConnection>
<tag>HEAD</tag>
</scm>
<developers>
<developer>
<id>microsoft</id>
<name>Microsoft</name>
</developer>
</developers>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<jacoco.skip>true</jacoco.skip>
</properties>
<dependencies>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-core</artifactId>
<version>1.24.1</version> <!-- {x-version-update;com.azure:azure-core;dependency} -->
</dependency>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-core-http-netty</artifactId>
<version>1.11.6</version> <!-- {x-version-update;com.azure:azure-core-http-netty;dependency} -->
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-engine</artifactId>
<version>5.8.2</version> <!-- {x-version-update;org.junit.jupiter:junit-jupiter-engine;external_dependency} -->
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-core-test</artifactId>
<version>1.7.7</version> <!-- {x-version-update;com.azure:azure-core-test;dependency} -->
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-identity</artifactId>
<version>1.4.3</version> <!-- {x-version-update;com.azure:azure-identity;dependency} -->
<scope>test</scope>
</dependency>
</dependencies>
</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,199 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.cognitiveservices.anomalydetector;

import com.azure.cognitiveservices.anomalydetector.implementation.AnomalyDetectorClientImpl;
import com.azure.core.annotation.Generated;
import com.azure.core.annotation.ReturnType;
import com.azure.core.annotation.ServiceClient;
import com.azure.core.annotation.ServiceMethod;
import com.azure.core.exception.HttpResponseException;
import com.azure.core.http.rest.RequestOptions;
import com.azure.core.http.rest.Response;
import com.azure.core.util.BinaryData;
import reactor.core.publisher.Mono;

/** Initializes a new instance of the asynchronous AnomalyDetectorClient type. */
@ServiceClient(builder = AnomalyDetectorClientBuilder.class, isAsync = true)
public final class AnomalyDetectorAsyncClient {
@Generated private final AnomalyDetectorClientImpl serviceClient;

/**
* Initializes an instance of AnomalyDetectorClient client.
*
* @param serviceClient the service client implementation.
*/
@Generated
AnomalyDetectorAsyncClient(AnomalyDetectorClientImpl serviceClient) {
this.serviceClient = serviceClient;
}

/**
* This operation generates a model with an entire series, each point is detected with the same model. With this
* method, points before and after a certain point are used to determine whether it is an anomaly. The entire
* detection can give user an overall status of the time series.
*
* <p><strong>Request Body Schema</strong>
*
* <pre>{@code
* {
* series: [
* {
* timestamp: String
* value: float
* }
* ]
* granularity: String(yearly/monthly/weekly/daily/hourly/minutely/secondly/microsecond/none)
* customInterval: Integer
* period: Integer
* maxAnomalyRatio: Float
* sensitivity: Integer
* imputeMode: String(auto/previous/linear/fixed/zero/notFill)
* imputeFixedValue: Float
* }
* }</pre>
*
* <p><strong>Response Body Schema</strong>
*
* <pre>{@code
* {
* period: int
* expectedValues: [
* float
* ]
* upperMargins: [
* float
* ]
* lowerMargins: [
* float
* ]
* isAnomaly: [
* boolean
* ]
* isNegativeAnomaly: [
* boolean
* ]
* isPositiveAnomaly: [
* boolean
* ]
* severity: [
* float
* ]
* }
* }</pre>
*
* @param body Time series points and period if needed. Advanced model parameters can also be set in the request.
* @param requestOptions The options to configure the HTTP request before HTTP client sends it.
* @throws HttpResponseException thrown if the request is rejected by server.
* @return the response of entire anomaly detection along with {@link Response} on successful completion of {@link
* Mono}.
*/
@Generated
@ServiceMethod(returns = ReturnType.SINGLE)
public Mono<Response<BinaryData>> detectEntireSeriesWithResponse(BinaryData body, RequestOptions requestOptions) {
return this.serviceClient.detectEntireSeriesWithResponseAsync(body, requestOptions);
}

/**
* This operation generates a model using points before the latest one. With this method, only historical points are
* used to determine whether the target point is an anomaly. The latest point detecting operation matches the
* scenario of real-time monitoring of business metrics.
*
* <p><strong>Request Body Schema</strong>
*
* <pre>{@code
* {
* series: [
* {
* timestamp: String
* value: float
* }
* ]
* granularity: String(yearly/monthly/weekly/daily/hourly/minutely/secondly/microsecond/none)
* customInterval: Integer
* period: Integer
* maxAnomalyRatio: Float
* sensitivity: Integer
* imputeMode: String(auto/previous/linear/fixed/zero/notFill)
* imputeFixedValue: Float
* }
* }</pre>
*
* <p><strong>Response Body Schema</strong>
*
* <pre>{@code
* {
* period: int
* suggestedWindow: int
* expectedValue: float
* upperMargin: float
* lowerMargin: float
* isAnomaly: boolean
* isNegativeAnomaly: boolean
* isPositiveAnomaly: boolean
* severity: Float
* }
* }</pre>
*
* @param body Time series points and period if needed. Advanced model parameters can also be set in the request.
* @param requestOptions The options to configure the HTTP request before HTTP client sends it.
* @throws HttpResponseException thrown if the request is rejected by server.
* @return the response of last anomaly detection along with {@link Response} on successful completion of {@link
* Mono}.
*/
@Generated
@ServiceMethod(returns = ReturnType.SINGLE)
public Mono<Response<BinaryData>> detectLastPointWithResponse(BinaryData body, RequestOptions requestOptions) {
return this.serviceClient.detectLastPointWithResponseAsync(body, requestOptions);
}

/**
* Evaluate change point score of every series point.
*
* <p><strong>Request Body Schema</strong>
*
* <pre>{@code
* {
* series: [
* {
* timestamp: String
* value: float
* }
* ]
* granularity: String(yearly/monthly/weekly/daily/hourly/minutely/secondly/microsecond/none)
* customInterval: Integer
* period: Integer
* stableTrendWindow: Integer
* threshold: Float
* }
* }</pre>
*
* <p><strong>Response Body Schema</strong>
*
* <pre>{@code
* {
* period: Integer
* isChangePoint: [
* boolean
* ]
* confidenceScores: [
* float
* ]
* }
* }</pre>
*
* @param body Time series points and granularity is needed. Advanced model parameters can also be set in the
* request if needed.
* @param requestOptions The options to configure the HTTP request before HTTP client sends it.
* @throws HttpResponseException thrown if the request is rejected by server.
* @return the response of change point detection along with {@link Response} on successful completion of {@link
* Mono}.
*/
@Generated
@ServiceMethod(returns = ReturnType.SINGLE)
public Mono<Response<BinaryData>> detectChangePointWithResponse(BinaryData body, RequestOptions requestOptions) {
return this.serviceClient.detectChangePointWithResponseAsync(body, requestOptions);
}
}
Loading