├── src
└── main
│ ├── java
│ └── cn
│ │ └── shiyujun
│ │ ├── proxy
│ │ ├── service
│ │ │ ├── MainService.java
│ │ │ └── impl
│ │ │ │ └── MainServiceImpl.java
│ │ ├── test
│ │ │ ├── StaticTest.java
│ │ │ ├── DynamicTest.java
│ │ │ └── CglibTest.java
│ │ └── handle
│ │ │ ├── StaticProxy.java
│ │ │ ├── CglibInterceptor.java
│ │ │ └── DynamicProxy.java
│ │ ├── service
│ │ ├── IOCService.java
│ │ ├── JDBCService.java
│ │ └── impl
│ │ │ ├── IOCServiceImpl.java
│ │ │ └── JDBCServiceImpl.java
│ │ ├── demo
│ │ ├── MVCDemo.java
│ │ ├── AnnotationIOCDemo.java
│ │ ├── TransactionalDemo.java
│ │ ├── JDBCDemo.java
│ │ └── IOCDemo.java
│ │ ├── config
│ │ ├── AnnotationConfig.java
│ │ ├── AspectJTest.java
│ │ └── JDBCConfig.java
│ │ ├── entity
│ │ ├── UserRowMapper.java
│ │ └── User.java
│ │ └── controller
│ │ └── MVCDemoController.java
│ └── resources
│ ├── application.properties
│ ├── templates
│ └── test.html
│ └── application-ioc.xml
├── .gitignore
├── README.md
└── pom.xml
/src/main/java/cn/shiyujun/proxy/service/MainService.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.proxy.service;
2 |
3 | public interface MainService {
4 | void doSomeThing();
5 | }
6 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/service/IOCService.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.service;
2 |
3 | /**
4 | * @author syj
5 | * CreateTime 2019/7/18
6 | * describe:
7 | */
8 | public interface IOCService {
9 |
10 | public String hollo();
11 | }
12 |
--------------------------------------------------------------------------------
/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | spring.thymeleaf.prefix=classpath:/templates/
2 | spring.thymeleaf.suffix=.html
3 | spring.thymeleaf.mode=LEGACYHTML5
4 | spring.thymeleaf.encoding=UTF-8
5 | spring.thymeleaf.content-type=text/html
6 | spring.thymeleaf.cache=false
7 |
8 |
9 |
--------------------------------------------------------------------------------
/src/main/resources/templates/test.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/proxy/service/impl/MainServiceImpl.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.proxy.service.impl;
2 |
3 | import cn.shiyujun.proxy.service.MainService;
4 |
5 | public class MainServiceImpl implements MainService {
6 | public void doSomeThing() {
7 | System.out.println("doSomeThing......");
8 | }
9 | }
10 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/service/JDBCService.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.service;
2 |
3 | /**
4 | * @author syj
5 | * CreateTime 2019/7/18
6 | * describe:
7 | */
8 | public interface JDBCService {
9 |
10 | public void queryById(int id);
11 | public void updateNameById(int id,String name);
12 | public void testTransactional();
13 | }
14 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | /target
2 | /releases
3 | /distribution
4 | /.settings
5 | .project
6 | .classpath
7 | *.class
8 | *.tmp
9 | /tomcat.10025
10 |
11 | # Package Files #
12 | *.jar
13 | *.war
14 | *.ear
15 |
16 | # virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
17 | hs_err_pid*
18 |
19 | .idea/*
20 |
21 | *.iml
22 | .DS_Store
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/service/impl/IOCServiceImpl.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.service.impl;
2 |
3 | import cn.shiyujun.service.IOCService;
4 |
5 | /**
6 | * @author syj
7 | * CreateTime 2019/7/18
8 | * describe:
9 | */
10 | public class IOCServiceImpl implements IOCService {
11 | public String hollo() {
12 | return "Hello,IOC";
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/demo/MVCDemo.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.demo;
2 |
3 | import org.springframework.boot.SpringApplication;
4 | import org.springframework.boot.autoconfigure.SpringBootApplication;
5 |
6 | @SpringBootApplication(scanBasePackages="cn.shiyujun.controller")
7 | public class MVCDemo {
8 | public static void main (String args[]){
9 | SpringApplication.run(MVCDemo.class, args);
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/src/main/resources/application-ioc.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/proxy/test/StaticTest.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.proxy.test;
2 |
3 | import cn.shiyujun.proxy.handle.StaticProxy;
4 | import cn.shiyujun.proxy.service.MainService;
5 | import cn.shiyujun.proxy.service.impl.MainServiceImpl;
6 |
7 | public class StaticTest {
8 |
9 | public static void main (String args[]){
10 | MainService mainService=new MainServiceImpl();
11 | MainService staticProxy=new StaticProxy(mainService);
12 | staticProxy.doSomeThing();
13 | }
14 |
15 |
16 | }
17 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/proxy/test/DynamicTest.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.proxy.test;
2 |
3 | import cn.shiyujun.proxy.handle.DynamicProxy;
4 | import cn.shiyujun.proxy.service.MainService;
5 | import cn.shiyujun.proxy.service.impl.MainServiceImpl;
6 |
7 | public class DynamicTest {
8 |
9 | public static void main (String args[]){
10 | MainService mainService=new MainServiceImpl();
11 | DynamicProxy dynamicProxy=new DynamicProxy(mainService);
12 | ((MainService)dynamicProxy.getProxy()).doSomeThing();
13 | }
14 |
15 |
16 | }
17 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/config/AnnotationConfig.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.config;
2 |
3 | import cn.shiyujun.service.IOCService;
4 | import cn.shiyujun.service.impl.IOCServiceImpl;
5 | import org.springframework.context.annotation.Bean;
6 | import org.springframework.context.annotation.Configuration;
7 | import org.springframework.context.annotation.EnableAspectJAutoProxy;
8 |
9 | @EnableAspectJAutoProxy
10 | @Configuration
11 | public class AnnotationConfig {
12 | @Bean
13 | public IOCService iocService(){
14 | return new IOCServiceImpl();
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/proxy/handle/StaticProxy.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.proxy.handle;
2 |
3 | import cn.shiyujun.proxy.service.MainService;
4 |
5 | public class StaticProxy implements MainService {
6 | private MainService mainService;
7 | public StaticProxy(MainService mainService){
8 | this.mainService=mainService;
9 | }
10 | public void doSomeThing() {
11 | System.out.println("begin time:"+System.currentTimeMillis());
12 | mainService.doSomeThing();
13 | System.out.println("end time:"+System.currentTimeMillis());
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/demo/AnnotationIOCDemo.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.demo;
2 |
3 | import cn.shiyujun.service.IOCService;
4 | import org.springframework.context.ApplicationContext;
5 | import org.springframework.context.annotation.AnnotationConfigApplicationContext;
6 |
7 | public class AnnotationIOCDemo {
8 | public static void main (String args[]){
9 | ApplicationContext context = new AnnotationConfigApplicationContext("cn.shiyujun.config");
10 | IOCService iocService=context.getBean(IOCService.class);
11 | System.out.println(iocService.hollo());
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/demo/TransactionalDemo.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.demo;
2 |
3 | import cn.shiyujun.service.JDBCService;
4 | import org.springframework.context.ApplicationContext;
5 | import org.springframework.context.annotation.AnnotationConfigApplicationContext;
6 |
7 | public class TransactionalDemo {
8 | public static void main (String args[]){
9 | ApplicationContext context = new AnnotationConfigApplicationContext("cn.shiyujun.config");
10 | JDBCService jdbcService= context.getBean(JDBCService.class);
11 | jdbcService.testTransactional();
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/demo/JDBCDemo.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.demo;
2 |
3 | import cn.shiyujun.service.JDBCService;
4 | import org.springframework.context.ApplicationContext;
5 | import org.springframework.context.annotation.AnnotationConfigApplicationContext;
6 |
7 | public class JDBCDemo {
8 | public static void main (String args[]){
9 | ApplicationContext context = new AnnotationConfigApplicationContext("cn.shiyujun.config");
10 | JDBCService jdbcService= context.getBean(JDBCService.class);
11 | jdbcService.updateNameById(1,"李四");
12 | jdbcService.queryById(1);
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/demo/IOCDemo.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.demo;
2 |
3 | import cn.shiyujun.service.IOCService;
4 | import org.springframework.context.ApplicationContext;
5 | import org.springframework.context.support.ClassPathXmlApplicationContext;
6 |
7 | /**
8 | * @author syj
9 | * CreateTime 2019/7/18
10 | * describe:
11 | */
12 | public class IOCDemo {
13 | public static void main (String args[]){
14 | ApplicationContext context = new ClassPathXmlApplicationContext("classpath:application-ioc.xml");
15 | IOCService iocService=context.getBean(IOCService.class);
16 | System.out.println(iocService.hollo());
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/proxy/test/CglibTest.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.proxy.test;
2 |
3 | import cn.shiyujun.proxy.handle.CglibInterceptor;
4 | import cn.shiyujun.proxy.service.MainService;
5 | import cn.shiyujun.proxy.service.impl.MainServiceImpl;
6 | import org.springframework.cglib.proxy.Enhancer;
7 |
8 | public class CglibTest {
9 |
10 | public static void main (String args[]){
11 | Enhancer enhancer = new Enhancer();
12 | enhancer.setSuperclass(MainServiceImpl.class);
13 | enhancer.setCallback(new CglibInterceptor());
14 | MainService proxy= (MainService)enhancer.create();
15 | proxy.doSomeThing();
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/proxy/handle/CglibInterceptor.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.proxy.handle;
2 |
3 | import org.springframework.cglib.proxy.MethodInterceptor;
4 | import org.springframework.cglib.proxy.MethodProxy;
5 |
6 | import java.lang.reflect.Method;
7 |
8 | public class CglibInterceptor implements MethodInterceptor {
9 |
10 |
11 | public Object intercept(Object obj, Method method, Object[] objects, MethodProxy methodProxy) throws Throwable {
12 | System.out.println("begin time:"+System.currentTimeMillis());
13 | Object object = methodProxy.invokeSuper(obj, objects);
14 | System.out.println("end time:"+System.currentTimeMillis());
15 | return object;
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/entity/UserRowMapper.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.entity;
2 |
3 | import org.springframework.jdbc.core.RowMapper;
4 | import org.springframework.lang.Nullable;
5 |
6 | import java.sql.ResultSet;
7 | import java.sql.SQLException;
8 |
9 | /**
10 | * d
11 | *
12 | * @author syj
13 | * CreateTime 2019/08/16
14 | * describe:
15 | */
16 | public class UserRowMapper implements RowMapper {
17 | @Nullable
18 | public Object mapRow(ResultSet resultSet, int i) throws SQLException {
19 | User user=new User();
20 | user.setId(resultSet.getInt("id"));
21 | user.setName(resultSet.getString("name"));
22 | user.setAge(resultSet.getInt("age"));
23 | return user;
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/controller/MVCDemoController.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.controller;
2 |
3 | import org.springframework.stereotype.Controller;
4 | import org.springframework.ui.Model;
5 | import org.springframework.web.bind.annotation.RequestMapping;
6 | import org.springframework.web.bind.annotation.RequestMethod;
7 |
8 | /**
9 | * d
10 | *
11 | * @author syj
12 | * CreateTime 2019/08/26
13 | * describe:
14 | */
15 | @Controller
16 | public class MVCDemoController {
17 |
18 | @RequestMapping(value = "/testMVC",method = RequestMethod.GET )
19 | public String testMVC(Model model){
20 | model.addAttribute("name","张三");
21 | model.addAttribute("age","18");
22 |
23 | return "test";
24 | }
25 |
26 | }
27 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/entity/User.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.entity;
2 |
3 | /**
4 | * d
5 | *
6 | * @author syj
7 | * CreateTime 2019/08/16
8 | * describe:
9 | */
10 | public class User {
11 | private int id;
12 | private String name;
13 | private int age;
14 |
15 | public int getId() {
16 | return id;
17 | }
18 |
19 | public void setId(int id) {
20 | this.id = id;
21 | }
22 |
23 | public String getName() {
24 | return name;
25 | }
26 |
27 | public void setName(String name) {
28 | this.name = name;
29 | }
30 |
31 | public int getAge() {
32 | return age;
33 | }
34 |
35 | public void setAge(int age) {
36 | this.age = age;
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/config/AspectJTest.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.config;
2 |
3 |
4 |
5 | import org.aspectj.lang.ProceedingJoinPoint;
6 | import org.aspectj.lang.annotation.*;
7 | import org.springframework.stereotype.Component;
8 |
9 | @Aspect
10 | @Component
11 | public class AspectJTest {
12 |
13 | @Pointcut("execution(public * cn.shiyujun.service.IOCService.hollo(..))")
14 | public void testAOP(){}
15 |
16 | @Before("testAOP()")
17 | public void before(){
18 | System.out.println("before testAOP...");
19 | }
20 |
21 | @After("testAOP()")
22 | public void after(){
23 | System.out.println("after testAOP...");
24 | }
25 |
26 | @Around("testAOP()")
27 | public Object around(ProceedingJoinPoint p){
28 | System.out.println("around before testAOP...");
29 | Object o = null;
30 | try {
31 | o = p.proceed();
32 | } catch (Throwable e) {
33 | e.printStackTrace();
34 | }
35 | System.out.println("around after testAOP...");
36 | return o;
37 | }
38 |
39 |
40 | }
41 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/proxy/handle/DynamicProxy.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.proxy.handle;
2 |
3 | import cn.shiyujun.proxy.service.MainService;
4 |
5 | import java.lang.reflect.InvocationHandler;
6 | import java.lang.reflect.Method;
7 | import java.lang.reflect.Proxy;
8 |
9 | public class DynamicProxy {
10 | private MainService mainService;
11 | public DynamicProxy(MainService mainService){
12 | this.mainService=mainService;
13 | }
14 |
15 | public Object getProxy() {
16 | return Proxy.newProxyInstance(
17 | mainService.getClass().getClassLoader(),
18 | mainService.getClass().getInterfaces(),
19 | new InvocationHandler() {
20 | @Override
21 | public Object invoke(Object proxy, Method method, Object[] args) throws Throwable {
22 | System.out.println("begin time:"+System.currentTimeMillis());
23 | method.invoke(mainService, args);
24 | System.out.println("end time:"+System.currentTimeMillis());
25 | return null;
26 | }
27 | });
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/service/impl/JDBCServiceImpl.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.service.impl;
2 |
3 | import cn.shiyujun.entity.User;
4 | import cn.shiyujun.entity.UserRowMapper;
5 | import cn.shiyujun.service.JDBCService;
6 | import org.springframework.jdbc.core.JdbcTemplate;
7 | import org.springframework.transaction.annotation.Transactional;
8 |
9 | import java.util.List;
10 |
11 | /**
12 | * @author syj
13 | * CreateTime 2019/7/18
14 | * describe:
15 | */
16 | @Transactional
17 | public class JDBCServiceImpl implements JDBCService {
18 | private JdbcTemplate jdbcTemplate;
19 |
20 | public JDBCServiceImpl(JdbcTemplate jdbcTemplate) {
21 | this.jdbcTemplate = jdbcTemplate;
22 | }
23 |
24 | public void queryById(int id) {
25 | List list = jdbcTemplate.query("select id,name,age from user where id=?", new Object[]{id}, new UserRowMapper());
26 | if (list.size() > 0) {
27 | System.out.println("id 为" + id + "的用户名为:" + list.get(0).getName());
28 | }
29 | }
30 |
31 | public void updateNameById(int id, String name) {
32 | jdbcTemplate.update("update user set name=? where id=?", new Object[]{name, id});
33 | }
34 |
35 | @Override
36 | public void testTransactional() {
37 | jdbcTemplate.update("update user set name='王五' where id=1", new Object[]{});
38 | throw new RuntimeException("异常");
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/src/main/java/cn/shiyujun/config/JDBCConfig.java:
--------------------------------------------------------------------------------
1 | package cn.shiyujun.config;
2 |
3 |
4 | import cn.shiyujun.service.JDBCService;
5 | import cn.shiyujun.service.impl.JDBCServiceImpl;
6 | import com.alibaba.druid.pool.DruidDataSource;
7 | import org.springframework.context.annotation.Bean;
8 | import org.springframework.context.annotation.Configuration;
9 | import org.springframework.jdbc.core.JdbcTemplate;
10 | import org.springframework.jdbc.datasource.DataSourceTransactionManager;
11 | import org.springframework.scheduling.config.AnnotationDrivenBeanDefinitionParser;
12 | import org.springframework.transaction.annotation.EnableTransactionManagement;
13 |
14 | @EnableTransactionManagement
15 | @Configuration
16 | public class JDBCConfig {
17 | @Bean
18 | public DruidDataSource druidDataSource() {
19 | DruidDataSource druidDataSource = new DruidDataSource();
20 | druidDataSource.setUsername("root");
21 | druidDataSource.setPassword("123456");
22 | druidDataSource.setDriverClassName("com.mysql.jdbc.Driver");
23 | druidDataSource.setUrl("jdbc:mysql://172.16.40.159:3306/cfkk?characterEncoding=utf-8&useSSL=false");
24 | return druidDataSource;
25 | }
26 |
27 | @Bean
28 | public JDBCService jdbcService(DruidDataSource druidDataSource) {
29 | JdbcTemplate jdbcTemplate = new JdbcTemplate(druidDataSource);
30 | JDBCService jdbcService = new JDBCServiceImpl(jdbcTemplate);
31 | return jdbcService;
32 | }
33 |
34 | @Bean
35 | public DataSourceTransactionManager dataSourceTransactionManager(DruidDataSource druidDataSource) {
36 | return new DataSourceTransactionManager(druidDataSource);
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | **配套学习博客**
2 |
3 |
4 | 1. [为什么我建议你去阅读优秀的源码](https://mp.weixin.qq.com/s/mC7BklvQwMJrQ_V0k4n1vA)
5 | 2. [有哪些你不知道的阅读源码的技巧](https://mp.weixin.qq.com/s/Nt8ibQxdopDq5_6yRpYC1g)
6 | 3. [SpringIOC源码解析(上)](https://mp.weixin.qq.com/s/0zDCy0eQycdM8M9eHGuLEQ)
7 | 4. [SpringIOC源码解析(下)](https://mp.weixin.qq.com/s/z-DZxBWOSSaFfQXlA0TSKw)
8 | 5. [SpringIOC源码解析(基于注解)](https://mp.weixin.qq.com/s/xqDPttr53rxLBi8t8kIQDg)
9 | 6. [基于注解的SpringAOP源码解析(一)](https://mp.weixin.qq.com/s/yMw1MZIRjQ4c504SSuPFaw)
10 | 7. [基于注解的SpringAOP源码解析(二)](https://mp.weixin.qq.com/s/kxbdat_T0io6xEnD48HK-g)
11 | 8. [基于注解的SpringAOP源码解析(三)](https://mp.weixin.qq.com/s/TORZGi2AX8hV1gNf1qNZUA)
12 | 9. [SpringJDBC源码解析](https://mp.weixin.qq.com/s/cmdlQ2LUi-7IDC6rCKqWOg)
13 | 10. [Spring @Import注解源码解析](https://mp.weixin.qq.com/s/dNOBwMPHKdccmeJFWzzTOg)
14 | 11. [Spring事务源码解析(一)@EnableTransactionManagement注解](https://mp.weixin.qq.com/s/FU3hznLFspCcHYJs-x8h2Q)
15 | 12. [Spring事务源码解析(二)获取增强](https://mp.weixin.qq.com/s/5tTrdl5GuD9WAyuHNUvW8w)
16 | 13. [Spring事务源码解析(三)](https://mp.weixin.qq.com/s/H933x4Upa8Vgl1EkuTZBtQ)
17 | 14. [SpringMVC源码解析(一)](https://mp.weixin.qq.com/s/V8iwW-rpaQsISiis7hF0aw)
18 | 15. [SpringMVC源码解析(二)](https://mp.weixin.qq.com/s/d7Ne8EI-e3VyGddEh9BvMA)
19 | 16. [SpringBoot自动装配原理解析](https://mp.weixin.qq.com/s/I3-sM55JSb4BFJ-zPosZgQ)
20 | 17. [SpringBoot源码解析:创建SpringApplication对象实例](https://mp.weixin.qq.com/s/h-pvfCSsYIlVSCHd9oCrEg)
21 | 18. [SpringApplication到底run了什么(上)](https://mp.weixin.qq.com/s/TuQR1kKqHrAQOxnRCfdFOw)
22 | 19. [SpringApplication到底run了什么(下)](https://mp.weixin.qq.com/s/rtR3dOWSqG60dVJoR9tCEA)
23 | 20. [SpringBoot嵌入式Tomcat的自动配置原理](https://mp.weixin.qq.com/s/XdxQgAYqarGpiSS3n7tp4g)
24 | 21. [SpringBoot健康检查实现原理](https://mp.weixin.qq.com/s/SFc2-NZZ3Nv7bX1QRfqQ7g)
25 |
26 | 
27 |
--------------------------------------------------------------------------------
/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 | 4.0.0
6 |
7 | org.springframework.boot
8 | spring-boot-starter-parent
9 | 2.0.0.RELEASE
10 |
11 | cn.shiyujun
12 | spring-framework
13 | 1.0-SNAPSHOT
14 |
15 |
16 | org.springframework
17 | spring-context
18 | 5.0.0.RELEASE
19 |
20 |
21 |
22 | org.springframework
23 | spring-aop
24 | 5.0.0.RELEASE
25 |
26 |
27 | org.aspectj
28 | aspectjrt
29 | 1.8.11
30 |
31 |
32 | org.aspectj
33 | aspectjweaver
34 | 1.8.11
35 |
36 |
37 |
38 | org.springframework
39 | spring-jdbc
40 | 5.0.0.RELEASE
41 |
42 |
43 | mysql
44 | mysql-connector-java
45 | 5.1.45
46 |
47 |
48 | com.alibaba
49 | druid
50 | 1.1.18
51 |
52 |
53 | org.springframework.boot
54 | spring-boot-starter-web
55 |
56 |
57 | org.springframework.boot
58 | spring-boot-starter-thymeleaf
59 |
60 |
61 |
62 |
63 |
--------------------------------------------------------------------------------