I have been experimenting with Spring Boot the last couple days and I made a very small extension to my first test of the framework. After reading a getting started guide I discovered something else amazing about this project. I added the following class to my test from the previous post:
I then added the following to my pom.xml:
With those minimal changes I now see a list of beans provided by on the console:
And found that with almost zero work I can now make calls like http://localhost:8080/health
which responds:
ok
Or http://localhost:8080/metrics
to learn:
Or http://localhost:8080/trace
for details like:
I almost went without the super verbose Application class, but I think it's important to illustrate the huge amount of functionality added just by adding a few lines to our pom.xml (it's even shorter if you use Gradle). If building a real application goes as smoothly as my initial tests, I think Spring Boot is going to be a framework I spend a lot of time developing in.