When creating a new Spring Boot project using Spring Initializr
and adding Azure Support
, it adds a dependency to com.microsoft.azure:azure-spring-boot-starter
.
implementation 'com.microsoft.azure:azure-spring-boot-starter'
The spring cloud documentation says:
The Azure Support entry contains auto-configuration support for Azure
managed services [...]
Now I'd like to send and receive messages from Azure Service Bus
and the documentation wants me to add a dependency to azure-servicebus
.
implementation 'com.microsoft.azure:azure-spring-boot-starter'
implementation 'com.microsoft.azure:azure-servicebus'
Okay fine. When I now switch over to Microsoft and read the documentation about Service Bus there, it mentions two libraries, where Microsoft states the second one is dated and legacy.
- azure-messaging-servicebus (latest)
implementation 'com.azure:azure-messaging-servicebus:7.0.0'
- azure-servicebus (legacy)
'com.microsoft.azure:azure-servicebus'
Question
- Is the Spring Boot documentation just outdated?
- I have read somewhere that libraries in
com.microsoft.com
are for managing the resource itself, while libraries in com.azure
are for managing the data. Is this true?
- What is meant by auto-configuration support?
As you can see I am very confused which dependencies I need to add. Also I don't get the difference between packages from com.azure
and com.microsoft.azure
.
Can someone please shed some light on this?
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…