Skip to content

Commit

Permalink
[PatchRelease] Prepare for July patch release for KV (#41342)
Browse files Browse the repository at this point in the history
* Prepare release July for Form recognizer and Metrics Advisor (#41338)

* Updated list of libraries to patch in patch-release.yml

* Reset sources for azure-security-keyvault-secrets to the release version 4.8.4.

* Prepare azure-security-keyvault-secrets for 4.8.5 patch release.

* Reset sources for azure-security-keyvault-certificates to the release version 4.6.4.

* Prepare azure-security-keyvault-certificates for 4.6.5 patch release.

* Reset sources for azure-security-keyvault-administration to the release version 4.5.5.

* Prepare azure-security-keyvault-administration for 4.5.6 patch release.

* Reset sources for azure-security-keyvault-keys to the release version 4.8.5.

* Prepare azure-security-keyvault-keys for 4.8.6 patch release.

* Updated dependencies in libraries and READMEs via version_client.txt

---------

Co-authored-by: Sameeksha Vaity <[email protected]>
Co-authored-by: azure-sdk <[email protected]>
  • Loading branch information
3 people authored Jul 29, 2024
1 parent 04f8a4f commit 7dad202
Show file tree
Hide file tree
Showing 74 changed files with 626 additions and 2,329 deletions.
22 changes: 13 additions & 9 deletions eng/pipelines/patch-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,20 @@ extends:
template: /eng/pipelines/templates/stages/archetype-sdk-client-patch.yml
parameters:
artifacts:
- name: azure-sdk-template
- name: azure-security-keyvault-secrets
groupId: com.azure
safeName: azuresdktemplate
ServiceDirectory: template
- name: azure-sdk-template-two
safeName: azuresecuritykeyvaultsecrets
ServiceDirectory: keyvault
- name: azure-security-keyvault-certificates
groupId: com.azure
safeName: azuresdktemplatetwo
ServiceDirectory: template
- name: azure-sdk-template-three
safeName: azuresecuritykeyvaultcertificates
ServiceDirectory: keyvault
- name: azure-security-keyvault-administration
groupId: com.azure
safeName: azuresdktemplatethree
ServiceDirectory: template
safeName: azuresecuritykeyvaultadministration
ServiceDirectory: keyvault
- name: azure-security-keyvault-keys
groupId: com.azure
safeName: azuresecuritykeyvaultkeys
ServiceDirectory: keyvault

8 changes: 4 additions & 4 deletions eng/versioning/version_client.txt
Original file line number Diff line number Diff line change
Expand Up @@ -176,12 +176,12 @@ com.azure:azure-search-documents;11.7.0;11.8.0-beta.1
com.azure:azure-search-perf;1.0.0-beta.1;1.0.0-beta.1
com.azure:azure-security-attestation;1.1.26;1.2.0-beta.1
com.azure:azure-security-confidentialledger;1.0.22;1.1.0-beta.1
com.azure:azure-security-keyvault-administration;4.5.5;4.6.0-beta.1
com.azure:azure-security-keyvault-certificates;4.6.4;4.7.0-beta.1
com.azure:azure-security-keyvault-administration;4.5.5;4.5.6
com.azure:azure-security-keyvault-certificates;4.6.4;4.6.5
com.azure:azure-security-keyvault-jca;2.8.1;2.9.0-beta.3
com.azure:azure-security-test-keyvault-jca;1.0.0;1.0.0
com.azure:azure-security-keyvault-keys;4.8.5;4.9.0-beta.1
com.azure:azure-security-keyvault-secrets;4.8.4;4.9.0-beta.1
com.azure:azure-security-keyvault-keys;4.8.5;4.8.6
com.azure:azure-security-keyvault-secrets;4.8.4;4.8.5
com.azure:azure-security-keyvault-perf;1.0.0-beta.1;1.0.0-beta.1
com.azure:azure-sdk-template;1.1.1234;1.2.2-beta.1
com.azure:azure-sdk-template-two;1.0.0-beta.1;1.0.0-beta.1
Expand Down
4 changes: 2 additions & 2 deletions sdk/clientcore/http-stress/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
<dependency>
<groupId>io.opentelemetry</groupId>
<artifactId>opentelemetry-api</artifactId>
<version>1.38.0</version> <!-- {x-version-update;io.opentelemetry:opentelemetry-api;external_dependency} -->
<version>1.40.0</version> <!-- {x-version-update;io.opentelemetry:opentelemetry-api;external_dependency} -->
</dependency>

<dependency>
Expand Down Expand Up @@ -89,7 +89,7 @@
<include>io.opentelemetry.instrumentation:opentelemetry-runtime-telemetry-java8:[2.6.0-alpha]</include> <!-- {x-include-update;io.opentelemetry.instrumentation:opentelemetry-runtime-telemetry-java8;external_dependency} -->
<include>io.opentelemetry.instrumentation:opentelemetry-logback-appender-1.0:[2.6.0-alpha]</include> <!-- {x-include-update;io.opentelemetry.instrumentation:opentelemetry-logback-appender-1.0;external_dependency} -->
<include>ch.qos.logback:logback-classic:[1.3.14]</include> <!-- {x-include-update;ch.qos.logback:logback-classic;external_dependency} -->
<include>io.opentelemetry:opentelemetry-api:[1.38.0]</include> <!-- {x-include-update;io.opentelemetry:opentelemetry-api;external_dependency} -->
<include>io.opentelemetry:opentelemetry-api:[1.40.0]</include> <!-- {x-include-update;io.opentelemetry:opentelemetry-api;external_dependency} -->
</includes>
</bannedDependencies>
</rules>
Expand Down
6 changes: 3 additions & 3 deletions sdk/e2e/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -44,17 +44,17 @@
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-security-keyvault-keys</artifactId>
<version>4.9.0-beta.1</version> <!-- {x-version-update;com.azure:azure-security-keyvault-keys;current} -->
<version>4.8.6</version> <!-- {x-version-update;com.azure:azure-security-keyvault-keys;current} -->
</dependency>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-security-keyvault-secrets</artifactId>
<version>4.9.0-beta.1</version> <!-- {x-version-update;com.azure:azure-security-keyvault-secrets;current} -->
<version>4.8.5</version> <!-- {x-version-update;com.azure:azure-security-keyvault-secrets;current} -->
</dependency>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-security-keyvault-certificates</artifactId>
<version>4.7.0-beta.1</version> <!-- {x-version-update;com.azure:azure-security-keyvault-certificates;current} -->
<version>4.6.5</version> <!-- {x-version-update;com.azure:azure-security-keyvault-certificates;current} -->
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
Expand Down
12 changes: 6 additions & 6 deletions sdk/keyvault/azure-security-keyvault-administration/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
# Release History

## 4.6.0-beta.1 (Unreleased)
## 4.5.6 (2024-07-29)

### Features Added

### Breaking Changes
### Other Changes

### Bugs Fixed
#### Dependency Updates

### Other Changes
- Upgraded `azure-core-http-netty` from `1.15.1` to version `1.15.2`.
- Upgraded `azure-json` from `1.1.0` to version `1.2.0`.
- Upgraded `azure-core` from `1.49.1` to version `1.50.0`.


## 4.5.5 (2024-06-27)
Expand Down
129 changes: 18 additions & 111 deletions sdk/keyvault/azure-security-keyvault-administration/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,14 +43,13 @@ If you want to take dependency on a particular version of the library that is no
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-security-keyvault-administration</artifactId>
<version>4.5.4</version>
<version>4.5.6</version>
</dependency>
```
[//]: # ({x-version-update-end})

### Prerequisites
- A [Java Development Kit (JDK)][jdk_link], version 8 or later.
- Here are details about [Java 8 client compatibility with Azure Certificate Authority](https://learn.microsoft.com/azure/security/fundamentals/azure-ca-details?tabs=root-and-subordinate-cas-list#client-compatibility-for-public-pkis).
- An [Azure Subscription][azure_subscription].
- An existing [Azure Key Vault Managed HSM][azure_keyvault_mhsm]. If you need to create a Managed HSM, you can do so using the Azure CLI by following the steps in [this document][azure_keyvault_mhsm_cli].

Expand Down Expand Up @@ -112,15 +111,9 @@ The Key Vault Backup Client provides both synchronous and asynchronous operation

> NOTE: The backing store for key backups is a blob storage container using Shared Access Signature authentication. For more details on creating a SAS token using the `BlobServiceClient`, see the [Azure Storage Blobs client README][storage_readme_sas_token]. Alternatively, it is possible to [generate a SAS token in Storage Explorer][portal_sas_token].
### Pre-Backup Operation
A pre-backup operation represents a long-running operation that checks if it is possible to perform a full key backup.

### Backup Operation
A backup operation represents a long-running operation for a full key backup.

### Pre-Restore Operation
A pre-restore operation represents a long-running operation that checks if it is possible to perform a full key restore from a backup.

### Restore Operation
A restore operation represents a long-running operation for both a full key and selective key restore.

Expand Down Expand Up @@ -347,47 +340,20 @@ keyVaultAccessControlAsyncClient.deleteRoleAssignment(KeyVaultRoleScope.GLOBAL,
### Examples
#### Sync API
The following sections provide several code snippets covering some of the most common Azure Key Vault Backup client tasks, including:
- [Pre-backup check for a Key Vault](#run-pre-backup-check-for-a-collection-of-keys)
- [Backup a Key Vault](#backup-a-collection-of-keys)
- [Pre-restore check for a Key Vault](#run-pre-restore-check-for-a-collection-of-keys)
- [Restore a Key Vault](#restore-a-collection-of-keys)
- [Restore a key](#selectively-restore-a-key)

##### Run pre-backup check for a collection of keys
Check if an entire collection of keys can be backed up by using `beginPreBackup()`.

```java readme-sample-beginPreBackup
String blobStorageUrl = "https://myaccount.blob.core.windows.net/myContainer";
String sasToken = "<sas-token>";

SyncPoller<KeyVaultBackupOperation, String> preBackupPoller =
keyVaultBackupClient.beginPreBackup(blobStorageUrl, sasToken);
PollResponse<KeyVaultBackupOperation> pollResponse = preBackupPoller.poll();

System.out.printf("The current status of the operation is: %s.%n", pollResponse.getStatus());

PollResponse<KeyVaultBackupOperation> finalPollResponse = preBackupPoller.waitForCompletion();

if (finalPollResponse.getStatus() == LongRunningOperationStatus.SUCCESSFULLY_COMPLETED) {
String folderUrl = preBackupPoller.getFinalResult();

System.out.printf("Pre-backup check completed successfully.%n");
} else {
KeyVaultBackupOperation operation = preBackupPoller.poll().getValue();

System.out.printf("Pre-backup check failed with error: %s.%n", operation.getError().getMessage());
}
```

##### Backup a collection of keys
Back up an entire collection of keys using `beginBackup()`.

```java readme-sample-beginBackup
String blobStorageUrl = "https://myaccount.blob.core.windows.net/myContainer";
String sasToken = "<sas-token>";
String sasToken = "sv=2020-02-10&ss=b&srt=o&sp=rwdlactfx&se=2021-06-17T07:13:07Z&st=2021-06-16T23:13:07Z&spr=https&sig=n5V6fnlkViEF9b7ij%2FttTHNwO2BdFIHKHppRxGAyJdc%3D";

SyncPoller<KeyVaultBackupOperation, String> backupPoller =
keyVaultBackupClient.beginBackup(blobStorageUrl, sasToken);

PollResponse<KeyVaultBackupOperation> pollResponse = backupPoller.poll();

System.out.printf("The current status of the operation is: %s.%n", pollResponse.getStatus());
Expand All @@ -405,49 +371,26 @@ if (finalPollResponse.getStatus() == LongRunningOperationStatus.SUCCESSFULLY_COM
}
```

##### Run pre-restore check for a collection of keys
Check if an entire collection of keys can be restored from a backup by using `beginPreRestore()`.

```java readme-sample-beginPreRestore
String folderUrl = "https://myaccount.blob.core.windows.net/myContainer/mhsm-myaccount-2020090117323313";
String sasToken = "<sas-token>";

SyncPoller<KeyVaultRestoreOperation, KeyVaultRestoreResult> preRestorePoller =
keyVaultBackupClient.beginPreRestore(folderUrl, sasToken);
PollResponse<KeyVaultRestoreOperation> pollResponse = preRestorePoller.poll();

System.out.printf("The current status of the operation is: %s.%n", pollResponse.getStatus());

PollResponse<KeyVaultRestoreOperation> finalPollResponse = preRestorePoller.waitForCompletion();

if (finalPollResponse.getStatus() == LongRunningOperationStatus.SUCCESSFULLY_COMPLETED) {
System.out.printf("Pre-restore check completed successfully.%n");
} else {
KeyVaultRestoreOperation operation = preRestorePoller.poll().getValue();

System.out.printf("Pre-restore check failed with error: %s.%n", operation.getError().getMessage());
}
```

##### Restore a collection of keys
Restore an entire collection of keys from a backup using `beginRestore()`.

```java readme-sample-beginRestore
String folderUrl = "https://myaccount.blob.core.windows.net/myContainer/mhsm-myaccount-2020090117323313";
String sasToken = "<sas-token>";
String sasToken = "sv=2020-02-10&ss=b&srt=o&sp=rwdlactfx&se=2021-06-17T07:13:07Z&st=2021-06-16T23:13:07Z&spr=https&sig=n5V6fnlkViEF9b7ij%2FttTHNwO2BdFIHKHppRxGAyJdc%3D";

SyncPoller<KeyVaultRestoreOperation, KeyVaultRestoreResult> restorePoller =
SyncPoller<KeyVaultRestoreOperation, KeyVaultRestoreResult> backupPoller =
keyVaultBackupClient.beginRestore(folderUrl, sasToken);
PollResponse<KeyVaultRestoreOperation> pollResponse = restorePoller.poll();

PollResponse<KeyVaultRestoreOperation> pollResponse = backupPoller.poll();

System.out.printf("The current status of the operation is: %s.%n", pollResponse.getStatus());

PollResponse<KeyVaultRestoreOperation> finalPollResponse = restorePoller.waitForCompletion();
PollResponse<KeyVaultRestoreOperation> finalPollResponse = backupPoller.waitForCompletion();

if (finalPollResponse.getStatus() == LongRunningOperationStatus.SUCCESSFULLY_COMPLETED) {
System.out.printf("Backup restored successfully.%n");
} else {
KeyVaultRestoreOperation operation = restorePoller.poll().getValue();
KeyVaultRestoreOperation operation = backupPoller.poll().getValue();

System.out.printf("Restore failed with error: %s.%n", operation.getError().getMessage());
}
Expand All @@ -458,60 +401,41 @@ Restore a specific key from a backup using `beginSelectiveRestore()`.

```java readme-sample-beginSelectiveKeyRestore
String folderUrl = "https://myaccount.blob.core.windows.net/myContainer/mhsm-myaccount-2020090117323313";
String sasToken = "<sas-token>";
String sasToken = "sv=2020-02-10&ss=b&srt=o&sp=rwdlactfx&se=2021-06-17T07:13:07Z&st=2021-06-16T23:13:07Z&spr=https&sig=n5V6fnlkViEF9b7ij%2FttTHNwO2BdFIHKHppRxGAyJdc%3D";
String keyName = "myKey";

SyncPoller<KeyVaultSelectiveKeyRestoreOperation, KeyVaultSelectiveKeyRestoreResult> restorePoller =
SyncPoller<KeyVaultSelectiveKeyRestoreOperation, KeyVaultSelectiveKeyRestoreResult> backupPoller =
keyVaultBackupClient.beginSelectiveKeyRestore(folderUrl, sasToken, keyName);
PollResponse<KeyVaultSelectiveKeyRestoreOperation> pollResponse = restorePoller.poll();

PollResponse<KeyVaultSelectiveKeyRestoreOperation> pollResponse = backupPoller.poll();

System.out.printf("The current status of the operation is: %s.%n", pollResponse.getStatus());

PollResponse<KeyVaultSelectiveKeyRestoreOperation> finalPollResponse = restorePoller.waitForCompletion();
PollResponse<KeyVaultSelectiveKeyRestoreOperation> finalPollResponse = backupPoller.waitForCompletion();

if (finalPollResponse.getStatus() == LongRunningOperationStatus.SUCCESSFULLY_COMPLETED) {
System.out.printf("Key restored successfully.%n");
} else {
KeyVaultSelectiveKeyRestoreOperation operation = restorePoller.poll().getValue();
KeyVaultSelectiveKeyRestoreOperation operation = backupPoller.poll().getValue();

System.out.printf("Key restore failed with error: %s.%n", operation.getError().getMessage());
}
```

#### Async API
The following sections provide several code snippets covering some of the most common asynchronous Azure Key Vault Backup client tasks, including:
- [Run pre-backup check for a collection of keys asynchronously](#run-pre-backup-check-for-a-collection-of-keys-asynchronously)
- [Backup a Key Vault asynchronously](#backup-a-collection-of-keys-asynchronously)
- [Run pre-restore check for a collection of keys asynchronously](#run-pre-restore-check-for-a-collection-of-keys-asynchronously)
- [Restore a Key Vault asynchronously](#restore-a-collection-of-keys-asynchronously)
- [Restore a key asynchronously](#selectively-restore-a-key-asynchronously)

> Note : You should add `System.in.read()` or `Thread.sleep()` after the function calls in the main class/thread to allow async functions/operations to execute and finish before the main application/thread exits.
##### Run pre-backup check for a collection of keys asynchronously
Check if an entire collection of keys can be backed up by using `beginPreBackup()`.

```java readme-sample-beginPreBackupAsync
String blobStorageUrl = "https://myaccount.blob.core.windows.net/myContainer";
String sasToken = "<sas-token>";

keyVaultBackupAsyncClient.beginPreBackup(blobStorageUrl, sasToken)
.setPollInterval(Duration.ofSeconds(1)) // You can set a custom polling interval.
.doOnError(e -> System.out.printf("Pre-backup check failed with error: %s.%n", e.getMessage()))
.doOnNext(pollResponse ->
System.out.printf("The current status of the operation is: %s.%n", pollResponse.getStatus()))
.filter(pollResponse -> pollResponse.getStatus() == LongRunningOperationStatus.SUCCESSFULLY_COMPLETED)
.flatMap(AsyncPollResponse::getFinalResult)
.subscribe(folderUrl ->
System.out.printf("Pre-backup check completed successfully.%n"));
```

##### Backup a collection of keys asynchronously
Back up an entire collection of keys using `beginBackup()`.

```java readme-sample-beginBackupAsync
String blobStorageUrl = "https://myaccount.blob.core.windows.net/myContainer";
String sasToken = "<sas-token>";
String sasToken = "sv=2020-02-10&ss=b&srt=o&sp=rwdlactfx&se=2021-06-17T07:13:07Z&st=2021-06-16T23:13:07Z&spr=https&sig=n5V6fnlkViEF9b7ij%2FttTHNwO2BdFIHKHppRxGAyJdc%3D";

keyVaultBackupAsyncClient.beginBackup(blobStorageUrl, sasToken)
.setPollInterval(Duration.ofSeconds(1)) // You can set a custom polling interval.
Expand All @@ -524,29 +448,12 @@ keyVaultBackupAsyncClient.beginBackup(blobStorageUrl, sasToken)
System.out.printf("Backup completed. The storage location of this backup is: %s.%n", folderUrl));
```

##### Run pre-restore check for a collection of keys asynchronously
Check if an entire collection of keys can be restored from a backup by using `beginPreRestore()`.

```java readme-sample-beginPreRestoreAsync
String folderUrl = "https://myaccount.blob.core.windows.net/myContainer/mhsm-myaccount-2020090117323313";
String sasToken = "<sas-token>";

keyVaultBackupAsyncClient.beginPreRestore(folderUrl, sasToken)
.setPollInterval(Duration.ofSeconds(1)) // You can set a custom polling interval.
.doOnError(e -> System.out.printf("Pre-restore check failed with error: %s.%n", e.getMessage()))
.doOnNext(pollResponse ->
System.out.printf("The current status of the operation is: %s.%n", pollResponse.getStatus()))
.filter(pollResponse -> pollResponse.getStatus() == LongRunningOperationStatus.SUCCESSFULLY_COMPLETED)
.flatMap(AsyncPollResponse::getFinalResult)
.subscribe(unused -> System.out.printf("Pre-restore check completed successfully.%n"));
```

##### Restore a collection of keys asynchronously
Restore an entire collection of keys from a backup using `beginRestore()`.

```java readme-sample-beginRestoreAsync
String folderUrl = "https://myaccount.blob.core.windows.net/myContainer/mhsm-myaccount-2020090117323313";
String sasToken = "<sas-token>";
String sasToken = "sv=2020-02-10&ss=b&srt=o&sp=rwdlactfx&se=2021-06-17T07:13:07Z&st=2021-06-16T23:13:07Z&spr=https&sig=n5V6fnlkViEF9b7ij%2FttTHNwO2BdFIHKHppRxGAyJdc%3D";

keyVaultBackupAsyncClient.beginRestore(folderUrl, sasToken)
.setPollInterval(Duration.ofSeconds(1)) // You can set a custom polling interval.
Expand All @@ -563,7 +470,7 @@ Restore an entire collection of keys from a backup using `beginSelectiveRestore(

```java readme-sample-beginSelectiveKeyRestoreAsync
String folderUrl = "https://myaccount.blob.core.windows.net/myContainer/mhsm-myaccount-2020090117323313";
String sasToken = "<sas-token>";
String sasToken = "sv=2020-02-10&ss=b&srt=o&sp=rwdlactfx&se=2021-06-17T07:13:07Z&st=2021-06-16T23:13:07Z&spr=https&sig=n5V6fnlkViEF9b7ij%2FttTHNwO2BdFIHKHppRxGAyJdc%3D";
String keyName = "myKey";

keyVaultBackupAsyncClient.beginSelectiveKeyRestore(folderUrl, sasToken, keyName)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
"AssetsRepo": "Azure/azure-sdk-assets",
"AssetsRepoPrefixPath": "java",
"TagPrefix": "java/keyvault/azure-security-keyvault-administration",
"Tag": "java/keyvault/azure-security-keyvault-administration_18fc6d4e27"
"Tag": "java/keyvault/azure-security-keyvault-administration_95d2cbb133"
}
4 changes: 2 additions & 2 deletions sdk/keyvault/azure-security-keyvault-administration/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

<groupId>com.azure</groupId>
<artifactId>azure-security-keyvault-administration</artifactId>
<version>4.6.0-beta.1</version> <!-- {x-version-update;com.azure:azure-security-keyvault-administration;current} -->
<version>4.5.6</version> <!-- {x-version-update;com.azure:azure-security-keyvault-administration;current} -->

<name>Microsoft Azure client library for KeyVault Administration</name>
<description>This module contains client library for Microsoft Azure KeyVault Administration.</description>
Expand Down Expand Up @@ -112,7 +112,7 @@
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-security-keyvault-keys</artifactId>
<version>4.9.0-beta.1</version> <!-- {x-version-update;com.azure:azure-security-keyvault-keys;current} -->
<version>4.8.6</version> <!-- {x-version-update;com.azure:azure-security-keyvault-keys;current} -->
<scope>test</scope>
</dependency>
<dependency>
Expand Down
Loading

0 comments on commit 7dad202

Please sign in to comment.