Our application entry point will be named BookStoreApplication and will be BookstoreApplication.java:
package pl.finsys.example; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; @SpringBootApplication public class BookstoreApplication { public static void main(final String[] args) { SpringApplication.run(BookstoreApplication.class, args); } }
That's it. The whole nine lines of code, not counting blank lines. It could not be more concise. The @SpringBootApplication is a kind of shortcut annotation, which is very convenient. It replaces all of the following annotations:
- @Configuration: A class marked with this annotation becomes a source of bean ...