Skip to content
Merged
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
Expand Up @@ -9,7 +9,13 @@
"com\\.azure\\..+\\.implementation(\\..+)?",
"com\\.fasterxml\\.jackson\\..+",
"reactor\\.netty\\..+",
"io\\.netty\\..+"
"io\\.netty\\..+",
"com\\.nimbusds(\\..+)?",
"com\\.microsoft\\.azure\\..+",
"com\\.microsoft\\.spring\\..+",
"javax\\.jms(\\..+)?",
"javax\\.servlet(\\..+)?",
"io\\.micrometer(\\..+)?"
]
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1970,5 +1970,17 @@
<Package name="~com\.azure\.management(\.[^.]+)*\.samples(\.[^.]+)*"/>
<Bug pattern="REC_CATCH_EXCEPTION"/>
</Match>

<!-- Exclude from spring related classes -->
<Match>
<Or>
<Class name="com.microsoft.azure.utils.PropertyLoader"/> <!-- false positive -->
<Class name="com.microsoft.azure.spring.support.GetHashMac"/> <!-- false positive -->
</Or>
<Bug pattern="RCN_REDUNDANT_NULLCHECK_WOULD_HAVE_BEEN_A_NPE,
NP_LOAD_OF_KNOWN_NULL_VALUE,
RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE,
RCN_REDUNDANT_NULLCHECK_OF_NULL_VALUE"/>
</Match>

</FindBugsFilter>
26 changes: 25 additions & 1 deletion eng/versioning/external_dependencies.txt
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ io.netty:netty-transport-native-unix-common;4.1.45.Final
io.projectreactor.netty:reactor-netty;0.9.5.RELEASE
io.projectreactor:reactor-core;3.3.3.RELEASE
io.reactivex:rxjava;1.2.4
javax.annotation:javax.annotation-api;1.3.2
javax.servlet:javax.servlet-api;4.0.1
javax.validation:validation-api;2.0.1.Final
org.apache.httpcomponents:httpclient;4.3.6
org.apache.logging.log4j:log4j-api;2.11.1
org.apache.logging.log4j:log4j-core;2.11.1
Expand All @@ -45,10 +48,28 @@ org.apache.qpid:proton-j;0.33.2
org.asynchttpclient:async-http-client;2.10.5
org.codehaus.groovy:groovy-eclipse-batch;2.5.8-01
org.codehaus.groovy:groovy-eclipse-compiler;3.4.0-01
org.hibernate.validator:hibernate-validator;6.0.17.Final
org.powermock:powermock-api-mockito2;2.0.2
org.powermock:powermock-module-junit4;2.0.2
org.slf4j:slf4j-api;1.7.28
org.slf4j:slf4j-simple;1.7.25
org.springframework.boot:spring-boot-actuator-autoconfigure;2.2.0.RELEASE
org.springframework.boot:spring-boot-autoconfigure;2.2.0.RELEASE
org.springframework.boot:spring-boot-autoconfigure-processor;2.2.0.RELEASE
org.springframework.boot:spring-boot-configuration-processor;2.2.0.RELEASE
org.springframework.boot:spring-boot-dependencies;2.2.0.RELEASE
org.springframework.boot:spring-boot-starter;2.2.0.RELEASE
org.springframework.boot:spring-boot-starter-test;2.2.0.RELEASE
org.springframework.boot:spring-boot-starter-validation;2.2.0.RELEASE
org.springframework.boot:spring-boot-starter-web;2.2.0.RELEASE
org.springframework.security:spring-security-config;5.2.0.RELEASE
org.springframework.security:spring-security-core;5.2.0.RELEASE
org.springframework.security:spring-security-web;5.2.0.RELEASE
org.springframework.security:spring-security-oauth2-client;5.2.0.RELEASE
org.springframework.security:spring-security-oauth2-core;5.2.0.RELEASE
org.springframework.security:spring-security-oauth2-jose;5.2.0.RELEASE
org.springframework:spring-web;5.2.0.RELEASE
pl.pragmatists:JUnitParams;1.1.1

## Test dependency versions
cglib:cglib-nodep;3.2.7
Expand Down Expand Up @@ -103,7 +124,7 @@ uk.org.lidalia:slf4j-test;1.2.0
com.azure:sdk-build-tools;1.0.0
com.beust:jcommander;1.58
com.google.code.findbugs:jsr305;3.0.2
com.nimbusds:nimbus-jose-jwt;6.0.1
com.nimbusds:nimbus-jose-jwt;7.9
com.nimbusds:oauth2-oidc-sdk;6.14
com.puppycrawl.tools:checkstyle;8.29
commons-io:commons-io;2.5
Expand Down Expand Up @@ -189,6 +210,9 @@ eventgrid_commons-io:commons-io;2.6
# sdk\eventhubs\microsoft-azure-eventhubs-extensions\pom.xml
eventhubs_com.microsoft.azure:msal4j;0.4.0-preview

# sdk\eventhubs\microsoft-azure-eventhubs\pom.xml
eventhubs_com.nimbusds:nimbus-jose-jwt;6.0.1

# sdk\keyvault\microsoft-azure-keyvault-extensions\pom.xml
keyvault_org.mockito:mockito-core;1.10.19
# sdk\keyvault\microsoft-azure-keyvault-test\pom.xml
Expand Down
9 changes: 5 additions & 4 deletions eng/versioning/pom_file_version_scanner.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ $StartTime = $(get-date)

# This is the for the bannedDependencies include exceptions. All <include> entries need to be of the
# form <include>groupId:artifactId:[version]</include> which locks to a specific version. The exception
# to this is the blanket, wildcard include for com.azure libraries.
$ComAzureWhitelistInclude = "com.azure:*"
# to this is the blanket, wildcard include for com.azure and com.microsoft.azure libraries.
$ComAzureWhitelistIncludes = ("com.azure:*", "com.microsoft.azure:*")

function Write-Error-With-Color([string]$msg)
{
Expand Down Expand Up @@ -561,10 +561,11 @@ Get-ChildItem -Path $Path -Filter pom*.xml -Recurse -File | ForEach-Object {
# These entries will not and should not have an update tag
elseif ($split.Count -eq 2)
{
if ($rawIncludeText -ne $ComAzureWhitelistInclude)
if ($ComAzureWhitelistIncludes -notcontains $rawIncludeText)
{
$script:FoundError = $true
Write-Error-With-Color "Error: $($rawIncludeText) is not a valid <include> entry. With the exception of the $($ComAzureWhitelistInclude), every <include> entry must be of the form <include>groupId:artifactId:[version]<include>"
$WhiteListIncludeForError = $ComAzureWhitelistIncludes -join " and "
Write-Error-With-Color "Error: $($rawIncludeText) is not a valid <include> entry. With the exception of the $($WhiteListIncludeForError), every <include> entry must be of the form <include>groupId:artifactId:[version]<include>"
}
}
else
Expand Down
3 changes: 3 additions & 0 deletions eng/versioning/version_data.txt
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,6 @@ com.microsoft.azure.msi_auth_token_provider:azure-authentication-msi-token-provi
com.microsoft.azure:azure-eventgrid;1.4.0-beta.1;1.4.0-beta.1
com.microsoft.azure:azure-loganalytics;1.0.0-beta-2;1.0.0-beta.2
com.microsoft.azure:azure-media;1.0.0-beta.1;1.0.0-beta.1
com.microsoft.azure:azure-spring-boot;2.2.4;2.2.5-beta.1
com.microsoft.azure:azure-spring-boot-starter;2.2.4;2.2.5-beta.1
com.microsoft.azure:azure-active-directory-spring-boot-starter;2.2.4;2.2.5-beta.1
1 change: 1 addition & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,6 @@
<module>sdk/storage</module>
<module>sdk/template</module>
<module>sdk/textanalytics</module>
<module>sdk/spring</module>
</modules>
</project>
2 changes: 1 addition & 1 deletion sdk/eventhubs/microsoft-azure-eventhubs/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
<dependency>
<groupId>com.nimbusds</groupId>
<artifactId>nimbus-jose-jwt</artifactId>
<version>6.0.1</version> <!-- {x-version-update;com.nimbusds:nimbus-jose-jwt;external_dependency} -->
<version>6.0.1</version> <!-- {x-version-update;eventhubs_com.nimbusds:nimbus-jose-jwt;external_dependency} -->
</dependency>

<dependency>
Expand Down
83 changes: 83 additions & 0 deletions sdk/spring/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
# Azure Spring Boot client library for Java

## Getting started
### Introduction

This repo is for Spring Boot Starters of Azure services. It helps Spring Boot developers to adopt Azure services.

### Support Spring Boot
This repository supports both Spring Boot 2.1.x and 2.2.x. Please read [Spring Boot Dependency Mapping](https://github.com/Azure/azure-sdk-for-java/wiki/Spring-Boot-Dependency-Mapping) for dependency mapping.

### Prerequisites
- JDK 1.8 and above
- [Maven](http://maven.apache.org/) 3.0 and above

## Key concepts
### Usage

Below starters are available with latest release version. We recommend users to leverage latest version for bug fix and new features.
You can find them in [Maven Central Repository](https://search.maven.org/).
The first three starters are also available in [Spring Initializr](http://start.spring.io/).

Starter Name | Version for Spring Boot 2.2.x | Version for Spring Boot 2.1.x | Version for Spring Boot 2.0.x
---|:---:|:---:|:---:
[azure-active-directory-spring-boot-starter](azure-spring-boot-starter-active-directory/README.md) | [![Maven Central](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-active-directory-spring-boot-starter.svg)](http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22com.microsoft.azure%22%20AND%20a%3A%22azure-active-directory-spring-boot-starter%22) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-active-directory-spring-boot-starter/2.1.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-active-directory-spring-boot-starter%20AND%20v:2.1.*) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-active-directory-spring-boot-starter/2.0.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-active-directory-spring-boot-starter%20AND%20v:2.0.*)
[azure-storage-spring-boot-starter](azure-spring-boot-starter-storage/README.md) | [![Maven Central](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-storage-spring-boot-starter.svg)](http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22com.microsoft.azure%22%20AND%20a%3A%22azure-storage-spring-boot-starter%22) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-storage-spring-boot-starter/2.1.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-storage-spring-boot-starter%20AND%20v:2.1.*) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-storage-spring-boot-starter/2.0.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-storage-spring-boot-starter%20AND%20v:2.0.*)
[azure-keyvault-secrets-spring-boot-starter](azure-spring-boot-starter-keyvault-secrets/README.md) | [![Maven Central](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-keyvault-secrets-spring-boot-starter.svg)](http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22com.microsoft.azure%22%20AND%20a%3A%22azure-keyvault-secrets-spring-boot-starter%22) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-keyvault-secrets-spring-boot-starter/2.1.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-keyvault-secrets-spring-boot-starter%20AND%20v:2.1.*) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-keyvault-secrets-spring-boot-starter/2.0.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-keyvault-secrets-spring-boot-starter%20AND%20v:2.0.*)
[azure-active-directory-b2c-spring-boot-starter](azure-spring-boot-starter-active-directory-b2c/README.md) | [![Maven Central](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-active-directory-b2c-spring-boot-starter.svg)](http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22com.microsoft.azure%22%20AND%20a%3A%22azure-active-directory-b2c-spring-boot-starter%22) | [![Maven Central](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-active-directory-b2c-spring-boot-starter/2.1.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-active-directory-b2c-spring-boot-starter%20AND%20v:2.1.*) | N/A
[azure-cosmosdb-spring-boot-starter](azure-spring-boot-starter-cosmosdb/README.md) | [![Maven Central](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-cosmosdb-spring-boot-starter.svg)](http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22com.microsoft.azure%22%20AND%20a%3A%22azure-cosmosdb-spring-boot-starter%22) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-cosmosdb-spring-boot-starter/2.1.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-cosmosdb-spring-boot-starter%20AND%20v:2.1.*) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-cosmosdb-spring-boot-starter/2.0.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-cosmosdb-spring-boot-starter%20AND%20v:2.0.*)
[azure-mediaservices-spring-boot-starter](azure-spring-boot-starter-mediaservices/README.md) | [![Maven Central](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-mediaservices-spring-boot-starter.svg)](http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22com.microsoft.azure%22%20AND%20a%3A%22azure-mediaservices-spring-boot-starter%22) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-mediaservices-spring-boot-starter/2.1.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-mediaservices-spring-boot-starter%20AND%20v:2.1.*) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-mediaservices-spring-boot-starter/2.0.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-mediaservices-spring-boot-starter%20AND%20v:2.0.*)
[azure-servicebus-spring-boot-starter](azure-spring-boot-starter-servicebus/README.md) | [![Maven Central](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-servicebus-spring-boot-starter.svg)](http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22com.microsoft.azure%22%20AND%20a%3A%22azure-servicebus-spring-boot-starter%22) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-servicebus-spring-boot-starter/2.1.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-servicebus-spring-boot-starter%20AND%20v:2.1.*) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-servicebus-spring-boot-starter/2.0.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-servicebus-spring-boot-starter%20AND%20v:2.0.*)
[spring-data-gremlin-boot-starter](azure-spring-boot-starter-data-gremlin/README.md) | [![Maven Central](https://img.shields.io/maven-central/v/com.microsoft.azure/spring-data-gremlin-boot-starter.svg)](http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22com.microsoft.azure%22%20AND%20a%3A%22spring-data-gremlin-boot-starter%22) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/spring-data-gremlin-boot-starter/2.1.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:spring-data-gremlin-boot-starter%20AND%20v:2.1.*) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/spring-data-gremlin-boot-starter/2.0.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:spring-data-gremlin-boot-starter%20AND%20v:2.0.*)
[azure-spring-boot-metrics-starter](azure-spring-boot-starter-metrics) | [![Maven Central](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-spring-boot-metrics-starter.svg)](http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22com.microsoft.azure%22%20AND%20a%3A%22azure-spring-boot-metrics-starter%22) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-spring-boot-metrics-starter/2.1.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-spring-boot-metrics-starter%20AND%20v:2.1.*) | [![](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-spring-boot-metrics-starter/2.0.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-spring-boot-metrics-starter%20AND%20v:2.0.*)
[azure-servicebus-jms-spring-boot-starter](azure-spring-boot-starter-servicebus-jms/README.md) | [![Maven Central](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-servicebus-jms-spring-boot-starter.svg)](http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22com.microsoft.azure%22%20AND%20a%3A%22azure-servicebus-jms-spring-boot-starter%22) | [![Maven Central](https://img.shields.io/maven-central/v/com.microsoft.azure/azure-servicebus-jms-spring-boot-starter/2.1.svg)](https://search.maven.org/search?q=g:com.microsoft.azure%20AND%20a:azure-servicebus-jms-spring-boot-starter%20AND%20v:2.1.*) | N/A

### Snapshots
[![Nexus OSS](https://img.shields.io/nexus/snapshots/https/oss.sonatype.org/com.microsoft.azure/azure-spring-boot.svg)](https://oss.sonatype.org/content/repositories/snapshots/com/microsoft/azure/azure-spring-boot/)

Snapshots built from `master` branch are available, add [maven repositories](https://maven.apache.org/settings.html#Repositories) configuration to your pom file as below.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any reason for recommending using SNAPSHOT versions instead of release versions?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Snapshots are the daily built versions, it could let users try our new features without waiting for a release.

```xml
<repositories>
<repository>
<id>nexus-snapshots</id>
<url>https://oss.sonatype.org/content/repositories/snapshots/</url>
<snapshots>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
</snapshots>
</repository>
</repositories>
```
## Examples
You could check below articles to learn more on usage of specific starters.

[How to use the Spring Boot Starter with Azure Cosmos DB API](https://docs.microsoft.com/java/azure/spring-framework/configure-spring-boot-starter-java-app-with-cosmos-db).

## Troubleshooting
## Next steps

## Contributing
This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.

Please follow [instructions here](https://github.com/Azure/azure-sdk-for-java/blob/master/CONTRIBUTING.md) to build from source or contribute.

### Filing Issues

If you encounter any bug, please file an issue [here](https://github.com/Azure/azure-sdk-for-java/issues).

To suggest a new feature or changes that could be made, file an issue the same way you would for a bug.

You can participate community driven [![Gitter](https://badges.gitter.im/Microsoft/spring-on-azure.svg)](https://gitter.im/Microsoft/spring-on-azure)

### Pull Requests

Pull requests are welcome. To open your own pull request, click [here](https://github.com/Microsoft/azure-spring-boot/compare). When creating a pull request, make sure you are pointing to the fork and branch that your changes were made in.

### Code of Conduct

This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.

### Data/Telemetry

This project collects usage data and sends it to Microsoft to help improve our products and services. Read our [privacy](https://privacy.microsoft.com/privacystatement) statement to learn more.

Loading