热部署插件配置和mybatis热部署插件配置和破解(Jrebel MybatisPlus Extension和JRebel and XRebel)


前言

Jrebel MybatisPlus Extension,顾名思义就是热部署中mybatis的扩展,他的功能就是配合 Jrebel 一起使用,修改 mybatis 的 mapper.xml 文件不用重启项目,听起来是不是很爽,安装下赶紧去试试吧。


热部署:JRebel and XRebel,指在修改项目BUG的时候对JSP或JAVA类进行了修改(除了配置文件外)在不重启WEB服务器前提下能让修改生效。

idea中好用的热部署插件——JRebel and XRebel
提示:以下是本篇文章正文内容,下面案例可供参考

一、JRebel and XRebel

https://blog.csdn.net/weixin_43185154/article/details/124315521

二、Jrebel MybatisPlus Extension

https://blog.csdn.net/weixin_47088026/article/details/116735679

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
在Spring中配置MyBatisMyBatis Plus需要进行如下步骤: 1. 添加相关依赖:在pom.xml文件中添加MyBatisMyBatis Plus的依赖。 ``` <!-- MyBatis --> <dependency> <groupId>org.mybatis.spring.boot</groupId> <artifactId>mybatis-spring-boot-starter</artifactId> <version>2.1.3</version> </dependency> <!-- MyBatis Plus --> <dependency> <groupId>com.baomidou</groupId> <artifactId>mybatis-plus-boot-starter</artifactId> <version>3.4.1</version> </dependency> ``` 2. 配置数据源:在application.yml文件中配置数据源。 ``` spring: datasource: driver-class-name: com.mysql.cj.jdbc.Driver url: jdbc:mysql://localhost:3306/mybatisplus?useUnicode=true&characterEncoding=utf-8&useSSL=false&serverTimezone=UTC username: root password: 123456 ``` 3. 配置MyBatis:在application.yml文件中配置MyBatis相关属性。 ``` mybatis: mapper-locations: classpath:/mapper/*.xml configuration: map-underscore-to-camel-case: true ``` 4. 配置MyBatis Plus:在application.yml文件中配置MyBatis Plus相关属性。 ``` mybatis-plus: mapper-locations: classpath:/mapper/*.xml configuration: map-underscore-to-camel-case: true ``` 5. 编写Mapper接口:在Mapper接口中实现对数据库的操作。 ``` @Mapper public interface UserMapper extends BaseMapper<User> { } ``` 6. 使用Mapper:在Service中注入Mapper并调用Mapper中的方法。 ``` @Service public class UserServiceImpl implements UserService { @Autowired private UserMapper userMapper; @Override public List<User> list() { return userMapper.selectList(null); } } ``` 以上就是在Spring中配置MyBatisMyBatis Plus的步骤。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值