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-resourcemanager-mediaservices] Delete the relevant code for track1 #13322

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
1,060 changes: 1,056 additions & 4 deletions sdk/mediaservices/azure-resourcemanager-mediaservices/CHANGELOG.md

Large diffs are not rendered by default.

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-account-2023-01. 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-metadata-2023-01. 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.4.0-beta.2</version>
<version>2.4.0-beta.3</version>
</dependency>
```
[//]: # ({x-version-update-end})
Expand Down
141 changes: 81 additions & 60 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 @@ -18,7 +18,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-account-2023-01.</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-metadata-2023-01.</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 @@ -11,6 +11,7 @@
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.BearerTokenAuthenticationPolicy;
import com.azure.core.http.policy.HttpLogOptions;
import com.azure.core.http.policy.HttpLoggingPolicy;
import com.azure.core.http.policy.HttpPipelinePolicy;
Expand All @@ -19,7 +20,6 @@
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;
import com.azure.core.management.profile.AzureProfile;
import com.azure.core.util.Configuration;
import com.azure.core.util.logging.ClientLogger;
Expand Down Expand Up @@ -285,7 +285,7 @@ public MediaServicesManager authenticate(TokenCredential credential, AzureProfil
.append("-")
.append("com.azure.resourcemanager.mediaservices")
.append("/")
.append("2.4.0-beta.2");
.append("1.0.0-beta.1");
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
userAgentBuilder.append(" (")
.append(Configuration.getGlobalConfiguration().get("java.version"))
Expand Down Expand Up @@ -318,7 +318,7 @@ public MediaServicesManager authenticate(TokenCredential credential, AzureProfil
HttpPolicyProviders.addBeforeRetryPolicies(policies);
policies.add(retryPolicy);
policies.add(new AddDatePolicy());
policies.add(new ArmChallengeAuthenticationPolicy(credential, scopes.toArray(new String[0])));
policies.add(new BearerTokenAuthenticationPolicy(credential, scopes.toArray(new String[0])));
policies.addAll(this.policies.stream()
.filter(p -> p.getPipelinePosition() == HttpPipelinePosition.PER_RETRY)
.collect(Collectors.toList()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,29 @@ public AssetStorageEncryptionFormat storageEncryptionFormat() {
return this.innerProperties() == null ? null : this.innerProperties().storageEncryptionFormat();
}

/**
* Get the encryptionScope property: The Asset container encryption scope in the storage account.
*
* @return the encryptionScope value.
*/
public String encryptionScope() {
return this.innerProperties() == null ? null : this.innerProperties().encryptionScope();
}

/**
* Set the encryptionScope property: The Asset container encryption scope in the storage account.
*
* @param encryptionScope the encryptionScope value to set.
* @return the AssetInner object itself.
*/
public AssetInner withEncryptionScope(String encryptionScope) {
if (this.innerProperties() == null) {
this.innerProperties = new AssetProperties();
}
this.innerProperties().withEncryptionScope(encryptionScope);
return this;
}

/**
* Validates the instance.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,11 @@ public final class AssetProperties implements JsonSerializable<AssetProperties>
*/
private AssetStorageEncryptionFormat storageEncryptionFormat;

/*
* The Asset container encryption scope in the storage account.
*/
private String encryptionScope;

/**
* Creates an instance of AssetProperties class.
*/
Expand Down Expand Up @@ -182,6 +187,26 @@ public AssetStorageEncryptionFormat storageEncryptionFormat() {
return this.storageEncryptionFormat;
}

/**
* Get the encryptionScope property: The Asset container encryption scope in the storage account.
*
* @return the encryptionScope value.
*/
public String encryptionScope() {
return this.encryptionScope;
}

/**
* Set the encryptionScope property: The Asset container encryption scope in the storage account.
*
* @param encryptionScope the encryptionScope value to set.
* @return the AssetProperties object itself.
*/
public AssetProperties withEncryptionScope(String encryptionScope) {
this.encryptionScope = encryptionScope;
return this;
}

/**
* Validates the instance.
*
Expand All @@ -200,6 +225,7 @@ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
jsonWriter.writeStringField("description", this.description);
jsonWriter.writeStringField("container", this.container);
jsonWriter.writeStringField("storageAccountName", this.storageAccountName);
jsonWriter.writeStringField("encryptionScope", this.encryptionScope);
return jsonWriter.writeEndObject();
}

Expand Down Expand Up @@ -238,6 +264,8 @@ public static AssetProperties fromJson(JsonReader jsonReader) throws IOException
} else if ("storageEncryptionFormat".equals(fieldName)) {
deserializedAssetProperties.storageEncryptionFormat
= AssetStorageEncryptionFormat.fromString(reader.getString());
} else if ("encryptionScope".equals(fieldName)) {
deserializedAssetProperties.encryptionScope = reader.getString();
} else {
reader.skipChildren();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ private Mono<PagedResponse<AccountFilterInner>> listSinglePageAsync(String resou
if (accountName == null) {
return Mono.error(new IllegalArgumentException("Parameter accountName is required and cannot be null."));
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
return FluxUtil
.withContext(context -> service.list(this.client.getEndpoint(), this.client.getSubscriptionId(),
Expand Down Expand Up @@ -197,7 +197,7 @@ private Mono<PagedResponse<AccountFilterInner>> listSinglePageAsync(String resou
if (accountName == null) {
return Mono.error(new IllegalArgumentException("Parameter accountName is required and cannot be null."));
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service
Expand Down Expand Up @@ -314,7 +314,7 @@ private Mono<Response<AccountFilterInner>> getWithResponseAsync(String resourceG
if (filterName == null) {
return Mono.error(new IllegalArgumentException("Parameter filterName is required and cannot be null."));
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
return FluxUtil
.withContext(context -> service.get(this.client.getEndpoint(), this.client.getSubscriptionId(),
Expand Down Expand Up @@ -358,7 +358,7 @@ private Mono<Response<AccountFilterInner>> getWithResponseAsync(String resourceG
if (filterName == null) {
return Mono.error(new IllegalArgumentException("Parameter filterName is required and cannot be null."));
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service.get(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName, accountName,
Expand Down Expand Up @@ -462,7 +462,7 @@ private Mono<Response<AccountFilterInner>> createOrUpdateWithResponseAsync(Strin
} else {
parameters.validate();
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
return FluxUtil
.withContext(context -> service.createOrUpdate(this.client.getEndpoint(), this.client.getSubscriptionId(),
Expand Down Expand Up @@ -511,7 +511,7 @@ private Mono<Response<AccountFilterInner>> createOrUpdateWithResponseAsync(Strin
} else {
parameters.validate();
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service.createOrUpdate(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName,
Expand Down Expand Up @@ -615,7 +615,7 @@ private Mono<Response<Void>> deleteWithResponseAsync(String resourceGroupName, S
if (filterName == null) {
return Mono.error(new IllegalArgumentException("Parameter filterName is required and cannot be null."));
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
return FluxUtil
.withContext(context -> service.delete(this.client.getEndpoint(), this.client.getSubscriptionId(),
Expand Down Expand Up @@ -658,7 +658,7 @@ private Mono<Response<Void>> deleteWithResponseAsync(String resourceGroupName, S
if (filterName == null) {
return Mono.error(new IllegalArgumentException("Parameter filterName is required and cannot be null."));
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service.delete(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName,
Expand Down Expand Up @@ -760,7 +760,7 @@ private Mono<Response<AccountFilterInner>> updateWithResponseAsync(String resour
} else {
parameters.validate();
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
return FluxUtil
.withContext(context -> service.update(this.client.getEndpoint(), this.client.getSubscriptionId(),
Expand Down Expand Up @@ -809,7 +809,7 @@ private Mono<Response<AccountFilterInner>> updateWithResponseAsync(String resour
} else {
parameters.validate();
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service.update(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ private Mono<PagedResponse<AssetFilterInner>> listSinglePageAsync(String resourc
if (assetName == null) {
return Mono.error(new IllegalArgumentException("Parameter assetName is required and cannot be null."));
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
return FluxUtil
.withContext(context -> service.list(this.client.getEndpoint(), this.client.getSubscriptionId(),
Expand Down Expand Up @@ -207,7 +207,7 @@ private Mono<PagedResponse<AssetFilterInner>> listSinglePageAsync(String resourc
if (assetName == null) {
return Mono.error(new IllegalArgumentException("Parameter assetName is required and cannot be null."));
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service
Expand Down Expand Up @@ -334,7 +334,7 @@ private Mono<Response<AssetFilterInner>> getWithResponseAsync(String resourceGro
if (filterName == null) {
return Mono.error(new IllegalArgumentException("Parameter filterName is required and cannot be null."));
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
return FluxUtil
.withContext(context -> service.get(this.client.getEndpoint(), this.client.getSubscriptionId(),
Expand Down Expand Up @@ -382,7 +382,7 @@ private Mono<Response<AssetFilterInner>> getWithResponseAsync(String resourceGro
if (filterName == null) {
return Mono.error(new IllegalArgumentException("Parameter filterName is required and cannot be null."));
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service.get(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName, accountName,
Expand Down Expand Up @@ -495,7 +495,7 @@ private Mono<Response<AssetFilterInner>> createOrUpdateWithResponseAsync(String
} else {
parameters.validate();
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
return FluxUtil
.withContext(context -> service.createOrUpdate(this.client.getEndpoint(), this.client.getSubscriptionId(),
Expand Down Expand Up @@ -548,7 +548,7 @@ private Mono<Response<AssetFilterInner>> createOrUpdateWithResponseAsync(String
} else {
parameters.validate();
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service.createOrUpdate(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName,
Expand Down Expand Up @@ -660,7 +660,7 @@ private Mono<Response<Void>> deleteWithResponseAsync(String resourceGroupName, S
if (filterName == null) {
return Mono.error(new IllegalArgumentException("Parameter filterName is required and cannot be null."));
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
return FluxUtil
.withContext(context -> service.delete(this.client.getEndpoint(), this.client.getSubscriptionId(),
Expand Down Expand Up @@ -707,7 +707,7 @@ private Mono<Response<Void>> deleteWithResponseAsync(String resourceGroupName, S
if (filterName == null) {
return Mono.error(new IllegalArgumentException("Parameter filterName is required and cannot be null."));
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service.delete(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName,
Expand Down Expand Up @@ -817,7 +817,7 @@ private Mono<Response<AssetFilterInner>> updateWithResponseAsync(String resource
} else {
parameters.validate();
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
return FluxUtil
.withContext(context -> service.update(this.client.getEndpoint(), this.client.getSubscriptionId(),
Expand Down Expand Up @@ -870,7 +870,7 @@ private Mono<Response<AssetFilterInner>> updateWithResponseAsync(String resource
} else {
parameters.validate();
}
final String apiVersion = "2022-08-01";
final String apiVersion = "2023-01-01";
final String accept = "application/json";
context = this.client.mergeContext(context);
return service.update(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,10 @@ public AssetStorageEncryptionFormat storageEncryptionFormat() {
return this.innerModel().storageEncryptionFormat();
}

public String encryptionScope() {
return this.innerModel().encryptionScope();
}

public String resourceGroupName() {
return resourceGroupName;
}
Expand Down Expand Up @@ -205,4 +209,9 @@ public AssetImpl withStorageAccountName(String storageAccountName) {
this.innerModel().withStorageAccountName(storageAccountName);
return this;
}

public AssetImpl withEncryptionScope(String encryptionScope) {
this.innerModel().withEncryptionScope(encryptionScope);
return this;
}
}
Loading