当前位置:网站首页>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
边栏推荐
- Informatics Aosai yibentong 1212: letters | openjudge 2.5 156: Letters
- Wine (COM) - basic concept
- Teach you how to build the ruoyi system by Tencent cloud
- Download PDF from HowNet (I don't want to use CAJViewer anymore!!!)
- C language: Advanced pointer
- 【数据库】MySQL基本操作(基操~)
- leetcode001--返回和为target的数组元素的下标
- 跨境电商 | Facebook 和 Instagram:哪个社交媒体更适合你?
- DIY 一个 Excel 版的子网计算器
- Leetcode009 -- search the target value in the array with binary search
猜你喜欢
![[winui3] write an imitation Explorer file manager](/img/3e/62794f1939da7f36f7a4e9dbf0aa7a.png)
[winui3] write an imitation Explorer file manager

Recommended scheme of national manufactured electronic components

AQS源码阅读

Shanghai Hangxin technology sharing 𞓜 overview of safety characteristics of acm32 MCU

Repair of self calibration SPC failure of Tektronix oscilloscope dpo3054

Sword finger offer: the path with a certain value in the binary tree (backtracking)

MySQL - index

Learning Android V from scratch - UI

Recommended scheme for national production of electronic components of wireless keyboard

Details related to fingerprint payment
随机推荐
Spark small case - RDD, broadcast
Better way to read configuration files than properties
leetcode——启发式搜索
Flink's important basics
General enumeration constant class
Small volume Schottky diode compatible with nsr20f30nxt5g
The object needs to add additional attributes. There is no need to add attributes in the entity. The required information is returned
Learning Android from scratch -- Introduction
/etc/bash_ completion. D directory function (the user logs in and executes the script under the directory immediately)
PHP 统计指定文件夹下文件的数量
Painless upgrade of pixel series
DIY 一个 Excel 版的子网计算器
Case of using stream load to write data to Doris
[winui3] Écrivez une copie du gestionnaire de fichiers Explorer
使用model.load_state_dict()时,出现AttributeError: ‘str‘ object has no attribute ‘copy‘
L2-011 play binary tree (build tree + BFS)
Unity RawImage背景无缝连接移动
Gets all dates between two times
Innovation training (VI) routing
Introduction to raspberry pie 3B - system installation