Skip to content
Closed
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
@@ -1,14 +1,48 @@
# Release History

## 2.1.0-beta.1 (Unreleased)
## 2.1.0-beta.1 (2022-04-14)

- Azure Resource Manager MediaServices client library for Java. This package contains Microsoft Azure SDK for MediaServices Management SDK. This Swagger was generated by the API Framework. Package tag package-account-2021-11. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).

### Features Added

### Breaking Changes
* `models.MediaServiceOperationStatuses` was added

* `models.MediaServiceOperationResultsGetResponse` was added

* `models.MediaservicesCreateOrUpdateResponse` was added

* `models.MediaServiceOperationResultsGetHeaders` was added

* `models.MediaservicesUpdateResponse` was added

* `models.MediaservicesUpdateHeaders` was added

* `models.MediaServiceOperationResults` was added

* `models.MediaservicesCreateOrUpdateHeaders` was added

* `models.MediaServiceOperationStatus` was added

#### `MediaServicesManager` was modified

* `authenticate(com.azure.core.http.HttpPipeline,com.azure.core.management.profile.AzureProfile)` was added
* `mediaServiceOperationResults()` was added
* `mediaServiceOperationStatuses()` was added

#### `models.MediaService` was modified

* `privateEndpointConnections()` was added
* `provisioningState()` was added

#### `MediaServicesManager$Configurable` was modified

* `withRetryOptions(com.azure.core.http.policy.RetryOptions)` was added

### Bugs Fixed
#### `models.MediaServiceUpdate` was modified

### Other Changes
* `privateEndpointConnections()` was added
* `provisioningState()` was added

## 2.0.0 (2022-03-30)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Azure Resource Manager MediaServices client library for Java.

This package contains Microsoft Azure SDK for MediaServices Management SDK. This Swagger was generated by the API Framework. Package tag package-2021-11. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
This package contains Microsoft Azure SDK for MediaServices Management SDK. This Swagger was generated by the API Framework. Package tag package-account-2021-11. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).

## We'd love to hear your feedback

Expand Down Expand Up @@ -32,7 +32,7 @@ Various documentation is available to help you get started
<dependency>
<groupId>com.azure.resourcemanager</groupId>
<artifactId>azure-resourcemanager-mediaservices</artifactId>
<version>2.0.0</version>
<version>2.1.0-beta.1</version>
</dependency>
```
[//]: # ({x-version-update-end})
Expand Down
136 changes: 113 additions & 23 deletions sdk/mediaservices/azure-resourcemanager-mediaservices/SAMPLE.md

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<packaging>jar</packaging>

<name>Microsoft Azure SDK for MediaServices Management</name>
<description>This package contains Microsoft Azure SDK for MediaServices Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. This Swagger was generated by the API Framework. Package tag package-2021-11.</description>
<description>This package contains Microsoft Azure SDK for MediaServices Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. This Swagger was generated by the API Framework. Package tag package-account-2021-11.</description>
<url>https://github.com/Azure/azure-sdk-for-java</url>

<licenses>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand All @@ -31,6 +33,8 @@
import com.azure.resourcemanager.mediaservices.implementation.LiveEventsImpl;
import com.azure.resourcemanager.mediaservices.implementation.LiveOutputsImpl;
import com.azure.resourcemanager.mediaservices.implementation.LocationsImpl;
import com.azure.resourcemanager.mediaservices.implementation.MediaServiceOperationResultsImpl;
import com.azure.resourcemanager.mediaservices.implementation.MediaServiceOperationStatusesImpl;
import com.azure.resourcemanager.mediaservices.implementation.MediaservicesImpl;
import com.azure.resourcemanager.mediaservices.implementation.OperationResultsImpl;
import com.azure.resourcemanager.mediaservices.implementation.OperationStatusesImpl;
Expand All @@ -50,6 +54,8 @@
import com.azure.resourcemanager.mediaservices.models.LiveEvents;
import com.azure.resourcemanager.mediaservices.models.LiveOutputs;
import com.azure.resourcemanager.mediaservices.models.Locations;
import com.azure.resourcemanager.mediaservices.models.MediaServiceOperationResults;
import com.azure.resourcemanager.mediaservices.models.MediaServiceOperationStatuses;
import com.azure.resourcemanager.mediaservices.models.Mediaservices;
import com.azure.resourcemanager.mediaservices.models.OperationResults;
import com.azure.resourcemanager.mediaservices.models.OperationStatuses;
Expand Down Expand Up @@ -82,6 +88,10 @@ public final class MediaServicesManager {

private Locations locations;

private MediaServiceOperationStatuses mediaServiceOperationStatuses;

private MediaServiceOperationResults mediaServiceOperationResults;

private Assets assets;

private AssetFilters assetFilters;
Expand Down Expand Up @@ -135,6 +145,19 @@ public static MediaServicesManager authenticate(TokenCredential credential, Azur
return configure().authenticate(credential, profile);
}

/**
* Creates an instance of MediaServices service API entry point.
*
* @param httpPipeline the {@link HttpPipeline} configured with Azure authentication credential.
* @param profile the Azure profile for client.
* @return the MediaServices service API instance.
*/
public static MediaServicesManager authenticate(HttpPipeline httpPipeline, AzureProfile profile) {
Objects.requireNonNull(httpPipeline, "'httpPipeline' cannot be null.");
Objects.requireNonNull(profile, "'profile' cannot be null.");
return new MediaServicesManager(httpPipeline, profile, null);
}

/**
* Gets a Configurable instance that can be used to create MediaServicesManager with optional configuration.
*
Expand All @@ -153,6 +176,7 @@ public static final class Configurable {
private final List<HttpPipelinePolicy> policies = new ArrayList<>();
private final List<String> scopes = new ArrayList<>();
private RetryPolicy retryPolicy;
private RetryOptions retryOptions;
private Duration defaultPollInterval;

private Configurable() {
Expand Down Expand Up @@ -213,6 +237,19 @@ public Configurable withRetryPolicy(RetryPolicy retryPolicy) {
return this;
}

/**
* Sets the retry options for the HTTP pipeline retry policy.
*
* <p>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.
*
Expand Down Expand Up @@ -246,7 +283,7 @@ public MediaServicesManager authenticate(TokenCredential credential, AzureProfil
.append("-")
.append("com.azure.resourcemanager.mediaservices")
.append("/")
.append("2.0.0");
.append("2.1.0-beta.1");
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
userAgentBuilder
.append(" (")
Expand All @@ -264,10 +301,15 @@ public MediaServicesManager authenticate(TokenCredential credential, AzureProfil
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<HttpPipelinePolicy> policies = new ArrayList<>();
policies.add(new UserAgentPolicy(userAgentBuilder.toString()));
policies.add(new AddHeadersFromContextPolicy());
policies.add(new RequestIdPolicy());
policies
.addAll(
Expand Down Expand Up @@ -347,6 +389,24 @@ public Locations locations() {
return locations;
}

/** @return Resource collection API of MediaServiceOperationStatuses. */
public MediaServiceOperationStatuses mediaServiceOperationStatuses() {
if (this.mediaServiceOperationStatuses == null) {
this.mediaServiceOperationStatuses =
new MediaServiceOperationStatusesImpl(clientObject.getMediaServiceOperationStatuses(), this);
}
return mediaServiceOperationStatuses;
}

/** @return Resource collection API of MediaServiceOperationResults. */
public MediaServiceOperationResults mediaServiceOperationResults() {
if (this.mediaServiceOperationResults == null) {
this.mediaServiceOperationResults =
new MediaServiceOperationResultsImpl(clientObject.getMediaServiceOperationResults(), this);
}
return mediaServiceOperationResults;
}

/** @return Resource collection API of Assets. */
public Assets assets() {
if (this.assets == null) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,13 @@ public interface AzureMediaServices {
*/
String getEndpoint();

/**
* Gets Api Version.
*
* @return the apiVersion value.
*/
String getApiVersion();

/**
* Gets The HTTP pipeline to send requests through.
*
Expand Down Expand Up @@ -79,6 +86,20 @@ public interface AzureMediaServices {
*/
LocationsClient getLocations();

/**
* Gets the MediaServiceOperationStatusesClient object to access its operations.
*
* @return the MediaServiceOperationStatusesClient object.
*/
MediaServiceOperationStatusesClient getMediaServiceOperationStatuses();

/**
* Gets the MediaServiceOperationResultsClient object to access its operations.
*
* @return the MediaServiceOperationResultsClient object.
*/
MediaServiceOperationResultsClient getMediaServiceOperationResults();

/**
* Gets the AssetsClient object to access its operations.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ public interface LocationsClient {
/**
* Checks whether the Media Service resource name is available.
*
* @param locationName The name of the location.
* @param locationName Location name.
* @param parameters The request parameters.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
Expand All @@ -30,7 +30,7 @@ EntityNameAvailabilityCheckOutputInner checkNameAvailability(
/**
* Checks whether the Media Service resource name is available.
*
* @param locationName The name of the location.
* @param locationName Location name.
* @param parameters The request parameters.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.resourcemanager.mediaservices.fluent;

import com.azure.core.annotation.ReturnType;
import com.azure.core.annotation.ServiceMethod;
import com.azure.core.util.Context;
import com.azure.resourcemanager.mediaservices.fluent.models.MediaServiceInner;
import com.azure.resourcemanager.mediaservices.models.MediaServiceOperationResultsGetResponse;

/** An instance of this class provides access to all the operations defined in MediaServiceOperationResultsClient. */
public interface MediaServiceOperationResultsClient {
/**
* Get media service operation result.
*
* @param locationName Location name.
* @param operationId Operation Id.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return media service operation result.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
MediaServiceInner get(String locationName, String operationId);

/**
* Get media service operation result.
*
* @param locationName Location name.
* @param operationId Operation Id.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return media service operation result.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
MediaServiceOperationResultsGetResponse getWithResponse(String locationName, String operationId, Context context);
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.resourcemanager.mediaservices.fluent;

import com.azure.core.annotation.ReturnType;
import com.azure.core.annotation.ServiceMethod;
import com.azure.core.http.rest.Response;
import com.azure.core.util.Context;
import com.azure.resourcemanager.mediaservices.fluent.models.MediaServiceOperationStatusInner;

/** An instance of this class provides access to all the operations defined in MediaServiceOperationStatusesClient. */
public interface MediaServiceOperationStatusesClient {
/**
* Get media service operation status.
*
* @param locationName Location name.
* @param operationId Operation ID.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return media service operation status.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
MediaServiceOperationStatusInner get(String locationName, String operationId);

/**
* Get media service operation status.
*
* @param locationName Location name.
* @param operationId Operation ID.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return media service operation status along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
Response<MediaServiceOperationStatusInner> getWithResponse(
String locationName, String operationId, Context context);
}
Loading