路在脚下,心向远方

自定义注解

[TOC] 注解定义 转载地址:https://www.cnblogs.com/longshiyVip/p/4707519.html 注解相当于一种标记,

异常

[TOC] 转载地址:https://blog.csdn.net/weixin_41987553/article/details/82500591 异常

泛型

[TOC] 转载地址:https://www.imooc.com/article/details/id/22747 转载地址:http://www.so

Lombok

[TOC] 转载地址:https://www.cnblogs.com/heyonggang/p/8638374.html 作用 Lombok能通过注解的方

springboot系列-多数据源

[TOC] 实现多数据源的配置。 配置数据源 @Configuration @MapperScan(basePackages = "com.example.moredatademo.mysqlmapper", sqlSessionTemplateRef = "mysqlSqlSessionTemplate") public class MysqlDataSourceConfig { @Bean(name = "mySqlDataSource") @ConfigurationProperties(prefix = "spring.datasource.mysqlone") @Primary public DataSource mySqlDataSource() { DataSource dataSource = DruidDataSourceBuilder.create().build(); return dataSource; } @Bean(name = "mysqlSqlSessionFactory") @Primary /*此处必须在主数据库的数据源配置上加上@