WeChat Public Number: An Outstanding Disabled Person. If you have any questions, please leave a message backstage. I won’t listen anyway. Preface Recently, I had the idea of changing jobs, so I deliberately reviewed the relevant knowledge of SpringBoot and reviewed it in detail. Some of them, I feel, were previously neglected, such as the ..
Category : spring
WeChat Public Number: An Outstanding Disabled Person. If you have any questions, please leave a message backstage. I won’t listen anyway. Preface It’s been two days since this month, and this article only met with you. I’m tired recently. I’m sorry. After work, I watched the automatic configuration in SpringBoot and told everyone my understanding. ..
1. Add dependencies. In addition to the packages required by SSM, the packages to be added are mybatis-ehcache.jar, ehcache-spring-annotations.jar; Maven coordinates are as follows: <!–Mybatis-ehcache–> <dependency> <groupId>org.mybatis.caches</groupId> <artifactId>mybatis-ehcache</artifactId> <version>1.0.3</version> </dependency> <!–ehcache-spring-annotations–> <dependency> <groupId>com.googlecode.ehcache-spring-annotations</groupId> <artifactId>ehcache-spring-annotations</artifactId> <version>1.2.0</version> </dependency> 2.echache profile, as follows: ehcache.xml <?xml version=”1.0″ encoding=”UTF-8″?> <ehcache xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance” xsi:noNamespaceSchemaLocation=”http://ehcache.org/ehcache.xsd”> <diskStore path=”java.io.tmpdir”/> <defaultCache maxElementsInMemory=”3000″ eternal=”false” timeToIdleSeconds=”3600″ timeToLiveSeconds=”3600″ overflowToDisk=”true” ..
(i) Spring IoC Important concept 1. Control inversion: Control inversion is a way to generate or obtain a specific object through description (xml or annotation in java) and through a third party. Control inversion IoC(Inversion of Control) means that the control right of creating objects is transferred. in the past, the initiative and timing of ..
Problem Business scenario There are often some edge operations on business requirements, such as main process operation A: users sign up for courses for warehousing, and edge operation B: sending emails or short message notifications. Business requirements After operation A fails to operate the database and the transaction rolls back, operation B cannot be executed. ..
Order Traditional spring is generally configured based on xml, but many comments of JavaConfig were added later. Springboot, in particular, is basically all java config. if you don’t understand it, you really don’t adapt. Note here. @RestController Spring4 has added RestController’s comments in order to more conveniently support the development of restfull applications. More functions ..
SpringBoot configuration property series MVC for SpringBoot configuration attributes Server for SpringBoot configuration properties DataSource for SpringBoot configuration properties SpringBoot configuration property NOSQL MQ for SpringBoot configuration properties Security for SpringBoot configuration properties Migration of SpringBoot configuration properties SpringBoot configuration properties other In addition, I attach some personal articles about springboot. SpringBoot past lives SpringBoot ..
SpringBoot configuration property series MVC for SpringBoot configuration attributes Server for SpringBoot configuration properties DataSource for SpringBoot configuration properties SpringBoot configuration property NOSQL MQ for SpringBoot configuration properties Security for SpringBoot configuration properties Migration of SpringBoot configuration properties SpringBoot configuration properties other In addition, I attach some personal articles about springboot. SpringBoot past lives SpringBoot ..
SpringBoot configuration property series MVC for SpringBoot configuration attributes Server for SpringBoot configuration properties DataSource for SpringBoot configuration properties SpringBoot configuration property NOSQL MQ for SpringBoot configuration properties Security for SpringBoot configuration properties Migration of SpringBoot configuration properties SpringBoot configuration properties other In addition, I attach some personal articles about springboot. SpringBoot past lives SpringBoot ..
Order SpringBoot’s starter is mainly used to simplify dependencies. This article is mainly divided into two parts, one is to list some starter’s dependencies, the other is to teach you to write a starter yourself. Part of starters’ Dependence Starter(Group ID: org.springframework.boot) Delivery depends on spring-boot-starter-log4j2 ■ org.apache.logging.log4j:log4j-slf4j-impl■ org.apache.logging.log4j:log4j-api■ org.apache.logging.log4j:log4j-core■ org.slf4j:jcl-over-slf4j■ org.slf4j:jul-to-slf4j spring-boot-starter-logging ■ ch.qos.logback:logback-classic■ ..
Order When using netty to develop rpc, one of the problems facing the client side is how the client can easily call remote services. Rmi in java gives a good example through proxy mode. Through proxy, calling remote service is as simple as calling local service for users. For published services, interfaces using java are ..
@Profile This annotation can be used in conjunction with @Configuration to specify the configuration of different profile using java code. It can be annotated on classes or methods of @ beans. Comments on Class dev @Configuration @Profile(“dev”) public class CacheConfigDev { private static final Logger log = LoggerFactory.getLogger(CacheConfigDev.class); @Bean public CacheManager concurrentMapCacheManager() { log.debug(“Cache manager ..