If you’re not familiar with start.spring.io, it hosts the Spring Engineering team’s opinionated version of Spring Initializr, which allows developers to generate Spring Boot projects pre-populated with the dependencies they need to get started quickly.
Spring Developer Advocate Josh Long calls start.spring.io the “second-best place on the internet,” and it just got better! Why do I say that? Because Solace PubSub+ is now available on start.spring.io, enabling developers to create event-driven microservices.
As a developer who has been creating event-driven applications with a combination of the Spring Framework and Solace PubSub+ for about eight years, I love how the developer experience keeps improving. This is the next step.
When selected as a dependency on Initializr at start.spring.io, the `Solace PubSub+’ option informs Initializr to add the Solace JMS Spring Boot Starter to the maven pom or build.gradle file as a dependency. This enables autoconfiguration of a ConnectionFactory or JndiTemplate, allowing developers to use Spring Boot to easily create event-driven microservices with PubSub+ and the JMS API. Using PubSub+ to create event-driven microservices empowers developers to use the best message exchange patterns for their use case, such as publish/subscribe, queuing, request/reply and it even provides the ability to store & replay. The use of PubSub+ also allows developers to take advantage of all the benefits of having events flow over the Event Mesh, such as being able to communicate with applications using other APIs and protocols and built-in high availability and disaster recovery.
<dependency> <groupId>com.solace.spring.boot</groupId> <artifactId>solace-jms-spring-boot-starter</artifactId> <version>3.2.0</version> </dependency>
Want to give it a shot? Spring Initializr offers several ways to generate your Spring Boot project. You can do it using the Web UI, from your favorite IDE or even from the command-line.
curl https://start.spring.io/starter.zip -d dependencies=solace -d javaVersion=11 -o demo.zip
Now that you’ve used Spring Initializr to generate your Spring Boot project with Solace’s Spring Boot JMS Starter as a dependency, it’s time to code your event-driven microservice. You can learn more about using our Spring Boot JMS Starter using the following resources:
If you have any questions, feel free to ask them in the Solace Developer Community with the `Spring` tag.
And if you love start.spring.io so much that you want to learn more about how it works, watch Stéphane Nicoll’s talk from SpringOne Platform 2019: Creating “The Second Best Place on the Internet” with Spring Initializr
The Spring + Solace developer experience has come a long way in the last eight years and I’m excited to see it continuously improve. Check out solace.com/spring to see all the ways you can use Spring with Solace and stay tuned for more upcoming Spring + Solace news. Hint: Solace Spring & Solace AsyncAPI.
Until next time, Happy Eventing!