当前位置:网站首页>Differences between redis and MySQL
Differences between redis and MySQL
2022-04-23 04:52:00 【xmh-sxh-1314】
One 、.redis and mysql Summary of the differences
(1) On type
In terms of type ,mysql Is a relational database ,redis Is the cache database
(2) In effect
mysql For persistent storage of data to the hard disk , Powerful , But it's slower
redis It is used to store frequently used data into the cache , Fast reading speed
(3) On demand
mysql and redis Because of the different needs , It is usually used in combination with .
Two 、 Detailed instructions
1.mysql and redis Database type of
mysql Is a relational database , It is mainly used to store persistent data , Store data on a hard disk , Slow read speed .
redis yes NOSQL, This is a non relational database , It is also a cache database , Store data in cache , Cache read speed is fast , Can greatly improve the operation efficiency , But the storage time is limited
2.mysql Operation mechanism of
mysql Relational databases as persistent storage , The relative weakness is that every time you request access to the database , They all exist I/O operation , If the database is accessed repeatedly and frequently . First of all : You spend a lot of time chaining databases , As a result, the operating efficiency is too slow ; second : Repeated database access can also lead to overloading of the database , Then the concept of caching is derived .
3. cache
A cache is a buffer for data exchange (cache), When the browser executes the request , First of all, search in the cache , If there is , Just get ; Otherwise, access the database .
The advantage of caching is fast reading speed
4.redis database
redis Database is a cache database , Used to store frequently used data , This reduces the number of times you access the database , Improve operational efficiency .
版权声明
本文为[xmh-sxh-1314]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204230446013496.html
边栏推荐
- redis数据类型有哪些
- KVM error: Failed to connect socket to ‘/var/run/libvirt/libvirt-sock‘
- Innovation training (V) configuration information
- Learning Android V from scratch - UI
- Introduction to raspberry pie 3B - system installation
- New terminal play method: script guidance independent of technology stack
- Sword finger offer: the path with a certain value in the binary tree (backtracking)
- Innovation training (XI) airline ticket crawling company information
- Wine (COM) - basic concept
- The last day of 2021 is the year of harvest.
猜你喜欢

DIY 一个 Excel 版的子网计算器

PIP3 installation requests Library - the most complete pit sorting
![解决ValueError: Argument must be a dense tensor: 0 - got shape [198602], but wanted [198602, 16].](/img/99/095063b72390adea6250f7b760d78c.png)
解决ValueError: Argument must be a dense tensor: 0 - got shape [198602], but wanted [198602, 16].

View analysis of scenic spots in ArcGIS

Excel uses the functions of replacement, sorting and filling to comprehensively sort out financial data

Painless upgrade of pixel series

【数据库】表的查看、修改和删除

使用model.load_state_dict()时,出现AttributeError: ‘str‘ object has no attribute ‘copy‘

Eight misunderstandings that should be avoided in data visualization

泰克示波器DPO3054自校准SPC失败维修
随机推荐
C language: Advanced pointer
Open the past and let's start over.
leetcode001--返回和为target的数组元素的下标
L2-011 玩转二叉树(建树+BFS)
POI export message list (including pictures)
【数据库】MySQL基本操作(基操~)
[2021] Spatio-Temporal Graph Contrastive Learning
C# List字段排序含有数字和字符
Informatics Olympiad 1955: [11noip popularization group] Swiss round | openjudge 4.1 4363: Swiss round | Luogu p1309 [noip2011 popularization group] Swiss round
Wine (COM) - basic concept
Opencv + clion face recognition + face model training
Druid -- JDBC tool class case
Progress of innovation training (IV)
Unity camera rotation with sliding effect (rotation)
Learning Android II from scratch - activity
解决ValueError: Argument must be a dense tensor: 0 - got shape [198602], but wanted [198602, 16].
洛谷P2731骑马修栅栏
Better way to read configuration files than properties
Sword finger offer: the median in the data stream (priority queue large top heap small top heap leetcode 295)
Customize the navigation bar at the top of wechat applet (adaptive wechat capsule button, flex layout)