You need to write a site using Spring and Hibernate.
What is better to choose for the first time: Spring Framework or Spring Boot?
Answer 1, Authority 100%
Not sure how well you present the difference between the Spring Boot and Spring MVC, so I will try to explain.
Spring MVC is a framework to develop Web applications. Inside, he uses the Spring Core (i.e., all components like your and the framework itself are bins in a container that controls both their life cycle and their dependencies).
And here, Spring Boot? In order to deploy a typical application on the Spring MVC and, say, Hibernate from you, as from a programmer, you will need to write a certain amount of code. Moreover, as a rule, in standard projects, this configuration code is the same. In order to simplify the life of developers and beginners who cannot make a project, the Spring Boot project appeared. It has in advance prepared pieces of configurations that are activated depending on the various conditions. For example, if you have Hibernate in CLASSPATH, then the Bines for work Spring and Hibernate are automatically configured. If you have a JAR file to work with the H2 database, it automatically unfolds and hibernate is configured to work with it. Etc. For various components.
Total. It is possible that you should try Spring-Boot, because In it, most likely, you will have to write less code to configure all this economy. But, if you need a little non-standard configuration, and the knowledge of the Spring Framework is insufficient, then problems may arise, with how to configure.
decide, of course, you.
Answer 2, Authority 18%
Spring Boot was created not to write on XML. Here is the config 2 bins.
It’s easier to write, more pleasant. He himself started learning Spring from MVC.
Sexas At the sight of XML there is blood from the eye :-).
All configuration on Java. Many things go out of the box. For example, you have connected the database dependence, for example MySQL, and you can only specify the URL, User, Password in Application.Properties – all, database is configured. Without any additional. Settings.
spring.datasource.url = jdbc: mysql: // Localhost: 3306 /
Spring Boot is the following step Spring to make it easier to configure and develop applications. With Spring Boot Configuration Spring Minimizes Maximum.
Answer 3, Authority 13%
I would solve this: if you need a working code as quickly as possible, then definitely boot, but if you have time and desire to read a little (there is enough of the day with your head), it is better to start with the old good Spring Framework – there will be more understanding “as It works everything. ”
You can still consider so:
- Spring Core itself launches bines, perfectly, it is clear, just
Dofig configs in XML. - Spring + schemes create default bines that can be found in schemes
and override as needed – for understanding sometimes you need
Climb into the scheme, but to write much less in XML. - Spring Boot – Dofiga Magic, creating bines to the right and left, and
track which one were created … well, too, probably somehow you can
But another layer of automation.