Skip to content

Commit

Permalink
Yevster/storage telemetry isolation (microsoft#715)
Browse files Browse the repository at this point in the history
* Separating out telemetry and decoupling storage from auto-config

* Making azure credentials optional to prevent regression

* Fixing dependencies and tests

* Fixing autoconfiguration interdependency issues (that occur when running storage queue sample)

* storage queue starts up

* Update pom.xml

* Update spring.provides

* Fixing POM XML header

* Fixing superfluous dependencies; adding default telemetry config to telemetry library
  • Loading branch information
yevster authored Jul 12, 2020
1 parent 602e8ef commit 66ef7af
Show file tree
Hide file tree
Showing 44 changed files with 433 additions and 306 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ bin/
/config
.idea/
/out
.vscode/

# Do not ignore them
!.idea/copyright
Expand Down
18 changes: 11 additions & 7 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://maven.apache.org/POM/4.0.0"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>com.microsoft.azure</groupId>
Expand Down Expand Up @@ -48,12 +49,12 @@
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-build</artifactId>
<version>2.2.0.RELEASE</version>
<relativePath/>
<relativePath />
</parent>

<modules>
<module>spring-cloud-azure-appconfiguration-config</module>
<module>spring-cloud-azure-appconfiguration-config-web</module>
<module>spring-cloud-azure-appconfiguration-config-web</module>
<module>spring-cloud-azure-autoconfigure</module>
<module>spring-cloud-azure-context</module>
<module>spring-cloud-azure-dependencies</module>
Expand All @@ -66,6 +67,7 @@
<module>spring-cloud-azure-storage</module>
<module>spring-cloud-azure-stream-binder</module>
<module>spring-integration-azure</module>
<module>spring-cloud-azure-telemetry</module>
</modules>

<properties>
Expand Down Expand Up @@ -136,12 +138,14 @@
<compilerArgs>
<!-- Enable all warnings -->
<compilerArg>-Xlint:all</compilerArg>
<!-- Disable options warning because we will have differences between the compiler and source code level-->
<!-- Disable options warning because we will
have differences between the compiler and source code level -->
<compilerArg>-Xlint:-options</compilerArg>
<!-- Disable serialversionuid warnings -->
<compilerArg>-Xlint:-serial</compilerArg>
<!--compilerArg>-Werror</compilerArg-->
<!-- Workaround errorprone with lombok log result in IndexOutOfRange Exception -->
<!--compilerArg>-Werror</compilerArg -->
<!-- Workaround errorprone with lombok log result
in IndexOutOfRange Exception -->
<compilerArg>-Xep:ParameterName:OFF</compilerArg>
</compilerArgs>
</configuration>
Expand Down
327 changes: 154 additions & 173 deletions spring-cloud-azure-autoconfigure/pom.xml
Original file line number Diff line number Diff line change
@@ -1,177 +1,158 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://maven.apache.org/POM/4.0.0"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<groupId>com.microsoft.azure</groupId>
<artifactId>spring-cloud-azure</artifactId>
<version>1.2.7-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>spring-cloud-azure-autoconfigure</artifactId>
<name>Spring Cloud Azure Autoconfigure</name>

<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-autoconfigure</artifactId>
</dependency>

<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>spring-cloud-azure-context</artifactId>
</dependency>

<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-web</artifactId>
</dependency>

<!-- Storage -->
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>spring-cloud-azure-storage</artifactId>
<optional>true</optional>
</dependency>

<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-storage-queue</artifactId>
<optional>true</optional>
</dependency>

<!-- Cloud SQL -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-jdbc</artifactId>
<optional>true</optional>
</dependency>

<dependency>
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP</artifactId>
<scope>test</scope>
</dependency>

<!-- PostgreSQL -->
<dependency>
<groupId>org.postgresql</groupId>
<artifactId>postgresql</artifactId>
<optional>true</optional>
</dependency>

<!-- MySQL -->
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<optional>true</optional>
</dependency>

<!-- SQL Server -->
<dependency>
<groupId>com.microsoft.sqlserver</groupId>
<artifactId>mssql-jdbc</artifactId>
<optional>true</optional>
</dependency>

<!-- Event Hub -->
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>spring-integration-eventhubs</artifactId>
<optional>true</optional>
</dependency>

<!-- Storage Queue -->
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>spring-integration-storage-queue</artifactId>
<optional>true</optional>
</dependency>

<!-- Service Bus -->
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>spring-integration-servicebus</artifactId>
<optional>true</optional>
</dependency>

<!-- Redis -->
<dependency>
<groupId>org.springframework.data</groupId>
<artifactId>spring-data-redis</artifactId>
<optional>true</optional>
</dependency>

<!-- Kafka -->
<dependency>
<groupId>org.springframework.kafka</groupId>
<artifactId>spring-kafka</artifactId>
<optional>true</optional>
</dependency>

<!-- MongoDB -->
<dependency>
<groupId>org.springframework.data</groupId>
<artifactId>spring-data-mongodb</artifactId>
<optional>true</optional>
</dependency>

<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context-support</artifactId>
<optional>true</optional>
</dependency>

<!--Spring JMS-->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-jms</artifactId>
<optional>true</optional>
</dependency>

<!--Qpid-->
<dependency>
<groupId>org.apache.qpid</groupId>
<artifactId>qpid-jms-client</artifactId>
<optional>true</optional>
</dependency>

</dependencies>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>3.0.2</version>
<configuration>
<archive>
<manifest>
<addDefaultImplementationEntries>true</addDefaultImplementationEntries>
<addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
</manifest>
</archive>
</configuration>
</plugin>
</plugins>
<resources>
<!-- Raw Resource -->
<resource>
<directory>src/main/resources</directory>
<includes>
<include>META-INF/spring.factories</include>
</includes>
</resource>
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
<includes>
<include>telemetry.config</include>
</includes>
</resource>
</resources>
</build>
xmlns="http://maven.apache.org/POM/4.0.0"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<groupId>com.microsoft.azure</groupId>
<artifactId>spring-cloud-azure</artifactId>
<version>1.2.7-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>spring-cloud-azure-autoconfigure</artifactId>
<name>Spring Cloud Azure Autoconfigure</name>

<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-autoconfigure</artifactId>
</dependency>

<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-web</artifactId>
</dependency>

<!-- Telemetry -->
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>spring-cloud-azure-telemetry</artifactId>
</dependency>

<!-- Cloud SQL -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-jdbc</artifactId>
<optional>true</optional>
</dependency>

<dependency>
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP</artifactId>
<scope>test</scope>
</dependency>

<!-- PostgreSQL -->
<dependency>
<groupId>org.postgresql</groupId>
<artifactId>postgresql</artifactId>
<optional>true</optional>
</dependency>

<!-- MySQL -->
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<optional>true</optional>
</dependency>

<!-- SQL Server -->
<dependency>
<groupId>com.microsoft.sqlserver</groupId>
<artifactId>mssql-jdbc</artifactId>
<optional>true</optional>
</dependency>

<!-- Event Hub -->
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>spring-integration-eventhubs</artifactId>
<optional>true</optional>
</dependency>

<!-- Service Bus -->
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>spring-integration-servicebus</artifactId>
<optional>true</optional>
</dependency>

<!-- Redis -->
<dependency>
<groupId>org.springframework.data</groupId>
<artifactId>spring-data-redis</artifactId>
<optional>true</optional>
</dependency>

<!-- Kafka -->
<dependency>
<groupId>org.springframework.kafka</groupId>
<artifactId>spring-kafka</artifactId>
<optional>true</optional>
</dependency>

<!-- MongoDB -->
<dependency>
<groupId>org.springframework.data</groupId>
<artifactId>spring-data-mongodb</artifactId>
<optional>true</optional>
</dependency>

<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context-support</artifactId>
<optional>true</optional>
</dependency>

<!--Spring JMS -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-jms</artifactId>
<optional>true</optional>
</dependency>

<!--Qpid -->
<dependency>
<groupId>org.apache.qpid</groupId>
<artifactId>qpid-jms-client</artifactId>
<optional>true</optional>
</dependency>

<!-- Dependencies on other modules for AutoConfiguration tests -->
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>spring-cloud-azure-storage</artifactId>
<scope>test</scope>
</dependency>

</dependencies>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>3.0.2</version>
<configuration>
<archive>
<manifest>
<addDefaultImplementationEntries>true</addDefaultImplementationEntries>
<addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
</manifest>
</archive>
</configuration>
</plugin>
</plugins>
<resources>
<!-- Raw Resource -->
<resource>
<directory>src/main/resources</directory>
<includes>
<include>META-INF/spring.factories</include>
</includes>
</resource>
</resources>
</build>

</project>
Loading

0 comments on commit 66ef7af

Please sign in to comment.