Submitted by heartin on Sat, 09/10/2016 - 22:34
Spring Boot can help us create Spring applications much faster than otherwise. Spring Boot is based on "conventions over configuration" and you have to do very little in configuring an application. For example, you can create a web application with an embedded server in few minutes and you can "just run" them like a desktop application.
Spring boot home page @ https://projects.spring.io/spring-boot/ describe itself as follows:
Submitted by heartin on Fri, 09/09/2016 - 06:04
Here I will list out upcoming notes or notes sections (books) on Spring.
-
Aspect Oriented Programming
-
Testing with Spring
-
Transactions with Spring
-
Spring and Data
-
Spring Boot Essentials (In progress)
-
Spring MVC Essentials (In progress)
Note:
Submitted by heartin on Fri, 09/09/2016 - 05:56
There are different ways to executing some code during initialization and destruction of a bean. We could do that using InitializingBean interface, but there are better approaches using annotations.
We will see two of such approaches here:
-
Using initMethod and destroyMethod attributes of the @Bean annotation
Submitted by heartin on Fri, 09/09/2016 - 04:37
Beans in Spring can be either singletons or prototypes. Singleton means that only one instance of the bean will be maintained by the Spring and will be returned every time you call the getBean() method. If you set the scope to prototype, then a new bean will be created every time you call the getBean() method.
The default is singleton. In Java configuration, you can specify that a bean scope is prototype by specifying @Scope("prototype") over the bean definition.
Submitted by heartin on Fri, 09/09/2016 - 01:13
These are additional exercises you can try out once after learning and practicing all the previous exercises in this section. There will be also hints to make things easier.
-
Provide examples for autowire for type and autowire by constructor.
-
Rewrite the following programming using annotations and java configuration: http://javajee.com/autowiring-in-spring-through-xml-configuration-example.
Pages