当前位置:网站首页>Change Servlet project to SSM project
Change Servlet project to SSM project
2022-08-01 09:24:00 【Ultimate Chiba】
目录
将Servlet项目改为SSM(Spring Boot+Spring MVC+MyBATIS)项目.
1.先创建SSM项目.



2.Set up profiles for different platforms
2.1.Create profiles for different platforms
要求:The configuration file format for different platforms must conform to the specification.
2.2.在主配置文件中(application.yml)The runtime platform of the configuration project in
spring:
profiles:
active: dev
This can be done.
3.Configure the connected database and MyBatis 存储 xml 的路径
#开发环境的配置文件
spring:
datasource:
url: jdbc:mysql://127.0.0.1:3306/myblog2022?characterEncoding=utf8&useSSL=true
username: root
password: 12345678
driver-class-name: com.mysql.cj.jdbc.Driver
#生产环境的配置文件
spring:
datasource:
url: jdbc:mysql://121.5.240.34:3306/myblog2022?characterEncoding=utf8&useSSL=true
username: root
password: 12345678
driver-class-name: com.mysql.cj.jdbc.Driver
主配置文件:
#配置mybatis xml保存路径
mybatis:
mapper-locations: classpath:mybatis/**Mapper.xml 4.将servletAll front-end pages in ssm项目中的static目录中
5.Retrofit to implement business interface
重点操作MyBatis,
Manipulate two files:xxxMapper.java 的接口声明、xxxMapper.xml 实现SQL操作
边栏推荐
- sqlserver怎么查询一张表中同人员的交叉日期
- 消息队列面试题(2022最新整理)
- rpm和yum
- network basic learning
- VoLTE Basic Learning Series | Enterprise Voice Network Brief
- pytest interface automation testing framework | parametrize source code analysis
- HoloView--Customization
- A problem with writing to the database after PHP gets the timestamp
- 网络基础学习
- net stop/start mysql80 拒绝访问
猜你喜欢

Data Analysis 5

ACmix 论文精读,并解析其模型结构
![[Dataset] Dataset summary of various insulators, bird's nests and anti-vibration hammers](/img/02/927f4e228eb3abbd76cade5be00352.png)
[Dataset] Dataset summary of various insulators, bird's nests and anti-vibration hammers

How to ensure the consistency of database and cache data?

Custom IP used in PCIE

Microsoft Azure & NVIDIA IoT developers season I | Azure IoT & NVIDIA Jetson development foundation

scrapy爬虫框架的使用
![ASP.NET Core 6框架揭秘实例演示[30]:利用路由开发REST API](/img/b3/0167c22f14b97eb0206696495af7b5.png)
ASP.NET Core 6框架揭秘实例演示[30]:利用路由开发REST API

自定义IP在PCIE中使用

VoLTE Basic Learning Series | Enterprise Voice Network Brief
随机推荐
sqlserver 对比两张表的差异
ASP.NET Core 6框架揭秘实例演示[30]:利用路由开发REST API
堆内存的介绍及应用(含例子)
Case practice --- Resnet classic convolutional neural network (Mindspore)
Delphi MDI appliction documents maximize display, remove buttons such as maximize and minimize
将aof文件转换为命令waoffle安装和使用
SaaS安全认证综合指南
pytest interface automation testing framework | pass in parameter values in the form of function return values
UXDB如何返回当前数据库所有表的记录数?
Centos install php7.4, build hyperf, forward RDS
云原生FAQ
PerViT: 神经网络也能像人类利用外围视觉一样观察图像!
STM32个人笔记-嵌入式C语言优化
优炫数据库支持Oracle哪几种时间及日期类型
leetcode-6133:分组的最大数量
【数据集】各类绝缘子、鸟巢及防震锤数据集汇总
笔记。。。。
Idea common plugins
The soul asks: How does MySQL solve phantom reads?
静态Pod、Pod创建流程、容器资源限制