Skip to content

Commit

Permalink
Initial KeyVaultAccessControlClient for Java (#12405)
Browse files Browse the repository at this point in the history
* Created azure-security-keyvault-administration module including its POM, README and CHANGELOG files.

* Created AutoRest README and generated artifacts.

* Added sync methods

* Modified the AutoRest specification to generate async methods only. Renamed the generated AccessControl client and builder.

* Created the AccessControl builder and clients (sync + async), public API for getting Role Definitions and some helper classes and resources.

* Regenerated classes with AutoRest v4 instead of v3.

* Added the 'KeyVault' prefix to all access control clients, implementation classes and their builders.

* Added an API for listing role definitions.

* Added APIs for creating, getting, deleting and listing role assignments.

* Polished README.

* Added the an entry for Key Vault Administration in version_client.txt

* Renamed to not break the CI build.

* Fixed copy/paste error on autorest.md

* Changed README references (keys -> administration).

* Addressed PR comments. Added a new ExpandableStringEnum: RoleScope. Corrected some of the Javadoc.

* Addressed more PR feedback.

* Added the new Key Vault Administration library to eng/jacoco-test-coverage/pom.xml

* Re-generated code from the Swagger specification.

* Renamed many of the implementation models.

* Added additional null checks for members in public methods that accept KeyVaultRoleAssignmentProperties.

* Added a module-info file.

* Made small formatting corrections.

* Removed an entry from module-info.java. Modified how KeyVaultAccessControlAsyncClient get error messages for parameter validation.

* Added missing package-info.java files.

* Corrected errors highlighted by APIView.

* Reverted implementation classes to their original names and hid them from public API signatures. Added convenience layer models to be exposed as public API.

* Renamed KeyVaultRoleScope to KeyVaultRoleAssignmentScope.

* Fixed build issues.

* Made model classes final.

* Updated module-info.java

* Renamed input parameter "scope" to "roleScope" in a multitude of public APIs. Corrected version number in files inside /eng.

* Fixed package-info.java Javadoc.

* Fixed some strings used for logging.

* Fixed JavaDoc formatting issues pointed out by @g2vinay.

* Added samples to README.md

* Fixed build analysis issues with the module's POM.

* Fixed Build analysis issue related to README.

* Fixed broken links in autorest.md and README.md

* Fixed a bug in `KeyVaultAccessControlAsyncClient.createRoleAssignmentWithResponse()`. Made fixes for tests cases.

* Updated azure-core versions.
  • Loading branch information
vcolin7 authored Sep 4, 2020
1 parent 8e7f5c0 commit 5eb4798
Show file tree
Hide file tree
Showing 44 changed files with 3,730 additions and 1 deletion.
1 change: 1 addition & 0 deletions eng/.docsettings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@ known_content_issues:
- ['sdk/eventhubs/README.md', '#3113']
- ['sdk/formrecognizer/azure-ai-formrecognizer/swagger/README.md', '#3113']
- ['sdk/keyvault/README.md', '#3113']
- ['sdk/keyvault/azure-security-keyvault-administration/README.md', '#3113']
- ['sdk/loganalytics/microsoft-azure-loganalytics/README.md', '#3113']
- ['sdk/parents/azure-client-sdk-parent/README.md', '#3113']
- ['sdk/search/azure-search-documents/swagger/readme.md', '#3113']
Expand Down
5 changes: 5 additions & 0 deletions eng/jacoco-test-coverage/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,11 @@
<artifactId>azure-search-documents</artifactId>
<version>11.1.0-beta.2</version> <!-- {x-version-update;com.azure:azure-search-documents;current} -->
</dependency>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-security-keyvault-administration</artifactId>
<version>4.0.0-beta.1</version> <!-- {x-version-update;com.azure:azure-security-keyvault-administration;current} -->
</dependency>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-security-keyvault-certificates</artifactId>
Expand Down
1 change: 1 addition & 0 deletions eng/versioning/version_client.txt
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ com.azure:azure-messaging-eventhubs-checkpointstore-blob;1.1.2;1.2.0-beta.3
com.azure:azure-messaging-servicebus;7.0.0-beta.5;7.0.0-beta.6
com.azure:azure-search-documents;11.0.0;11.1.0-beta.2
com.azure:azure-search-perf;1.0.0-beta.1;1.0.0-beta.1
com.azure:azure-security-keyvault-administration;4.0.0-beta.1;4.0.0-beta.1
com.azure:azure-security-keyvault-certificates;4.1.0;4.2.0-beta.1
com.azure:azure-security-keyvault-keys;4.2.0;4.3.0-beta.1
com.azure:azure-security-keyvault-secrets;4.2.0;4.3.0-beta.1
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Release History
## 4.0.0-beta.1 (Unreleased)
- Added `KeyVaultAccessControlClient`.
308 changes: 308 additions & 0 deletions sdk/keyvault/azure-security-keyvault-administration/README.md

Large diffs are not rendered by default.

121 changes: 121 additions & 0 deletions sdk/keyvault/azure-security-keyvault-administration/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,121 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<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>

<modelVersion>4.0.0</modelVersion>

<groupId>com.azure</groupId>
<artifactId>azure-security-keyvault-administration</artifactId>
<version>4.0.0-beta.1</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>
<url>https://github.com/Azure/azure-sdk-for-java</url>

<distributionManagement>
<site>
<id>azure-java-build-docs</id>
<url>${site.url}/site/${project.artifactId}</url>
</site>
</distributionManagement>

<scm>
<url>scm:git:https://github.com/Azure/azure-sdk-for-java</url>
<connection>scm:git:git@github.com:Azure/azure-sdk-for-java.git</connection>
<tag>HEAD</tag>
</scm>

<dependencies>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-core</artifactId>
<version>1.8.0</version> <!-- {x-version-update;com.azure:azure-core;dependency} -->
</dependency>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-core-http-netty</artifactId>
<version>1.6.0</version> <!-- {x-version-update;com.azure:azure-core-http-netty;dependency} -->
</dependency>
<!-- Test dependencies -->
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-api</artifactId>
<version>5.6.2</version> <!-- {x-version-update;org.junit.jupiter:junit-jupiter-api;external_dependency} -->
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-engine</artifactId>
<version>5.6.2</version> <!-- {x-version-update;org.junit.jupiter:junit-jupiter-engine;external_dependency} -->
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-params</artifactId>
<version>5.6.2</version> <!-- {x-version-update;org.junit.jupiter:junit-jupiter-params;external_dependency} -->
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-library</artifactId>
<version>2.2</version> <!-- {x-version-update;org.hamcrest:hamcrest-library;external_dependency} -->
<scope>test</scope>
</dependency>
<dependency>
<groupId>io.projectreactor</groupId>
<artifactId>reactor-test</artifactId>
<version>3.3.9.RELEASE</version> <!-- {x-version-update;io.projectreactor:reactor-test;external_dependency} -->
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-core-test</artifactId>
<version>1.4.1</version> <!-- {x-version-update;com.azure:azure-core-test;dependency} -->
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-core-http-okhttp</artifactId>
<version>1.3.0</version> <!-- {x-version-update;com.azure:azure-core-http-okhttp;dependency} -->
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-identity</artifactId>
<version>1.1.0</version> <!-- {x-version-update;com.azure:azure-identity;dependency} -->
<scope>test</scope>
</dependency>
</dependencies>

<profiles>
<profile>
<id>java-lts</id>
<activation>
<jdk>[11,)</jdk>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.0.0-M3</version> <!-- {x-version-update;org.apache.maven.plugins:maven-surefire-plugin;external_dependency} -->
<configuration>
<argLine>
--add-exports com.azure.core/com.azure.core.implementation.http=ALL-UNNAMED

--add-opens com.azure.security.keyvault.administration/com.azure.security.keyvault.administration=ALL-UNNAMED
</argLine>
</configuration>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>
Loading

0 comments on commit 5eb4798

Please sign in to comment.