Skip to content

Design doc

Warren Zhu edited this page Sep 5, 2018 · 4 revisions

Design goal and decision

  1. Seamless Spring Cloud integration with Azure. Users can easily adopt Azure services without having to modify existing code. Only dependencies and a few configuration settings are needed.
  2. Least configuration. This is done by taking advantage of Spring boot auto config to preconfigure default properties values based on Azure Resource Management API. Users can override these properties with their own.
  3. Provision resource automatically. If resources are not existed, our modules will create them under user specified subscription and resource group.
  4. No cloud vendor lock in. With our modules, users can easily consume Azure services as well as benefit from conveniences provided by Spring Cloud, without getting locked in with one specific cloud vendor.

Spring Cloud Azure Starter vs Spring Azure Starter vs Spring Boot Starter

Simply, these starters are ordered in decreasing level of abstraction, from high to low. But even if you choose the high level, you still have freedom to manipulate in low level.

  1. Spring Cloud Azure Starter has prefix spring-cloud-azure-starter. These starters rely on high level abstraction provided by Spring Cloud. They use azure credential to do auto config and hide low level details of Azure SDK. They also provide automatic resource provision. For example, to use spring-cloud-azure-starter-servicebus, you just need to provide service bus namespace in property and use spring cloud stream abstraction to produce and consume message.
  2. Spring Azure Starter has prefix spring-azure-starter. These starters rely on abstraction provided by Spring. They use azure credential to do auto config and hide low level details of Azure SDK. They also provide automatic resource provision. For example, to use spring-azure-starter-storage, you just need to provide storage account name in property and rely on Resource abstraction provided by Spring.
  3. Spring Boot Starter has suffix spring-boot-starter. These starters rely on low level details of Azure SDK and some azure service specific property. For example, to use azure-storage-spring-boot-starter, you need to understand connection string in property and rely on CloudStorageAccount.

Our suggestion is try to use Spring Cloud Azure Starter or Spring Azure Starter unless your project already rely on low level Azure SDK.

Planned feature

Feature Azure Service Description Status
Spring cloud Cache Starter Redis Auto config of redis properties
Spring cloud Resource Storage account Mapping storage as Spring resource
Spring cloud JDBC starter Sql Database
Mysql
PostgreSql
Auto config of sql database
Spring cloud messaging Event Hub
Service Bus
Queue Storage
Notification Hub
Inbound and outbound adapter for consuming and producing message
Spring cloud stream binder Event Hub Event hub binder to provide as many function as Kafka
Spring cloud stream starter Kafka-HDInsight
Event Hub with Kafka API
Auto config of Kafka properties
Spring cloud CosmosDB starter Cosmos DB Auto config of connection properties and Spring Data CosmosDB
Spring cloud logging starter Application Insight Auto config of logger
Spring cloud trace Applcation Insight Auto config of sending trace
Spring Hadoop starter Hadoop(HDInisght) Auto config of hadoop
Spring mail SendGrid Auto config of mail service Blocked on no Azure management API
Spring cloud Function Azure Function Auto config of Azure Function