There is a large number of visits to web, whether the session is stored in mongodb or redis?.

for example, redis? is recommended in many documents. What are the advantages and disadvantages of the two?

Mar.30,2021

largely depends on whether the operation and maintenance staff and developers have a high level of redis or mongo .


redis is based on memory, so it is fast enough, because the amount of data in session is small and the access is quite frequent, so it is recommended to use redis,. On the contrary, if the amount of data is very large, you can consider mongodb


I think there is no special difference, both are fine. Note that when memory is large enough, MongoDB also uses memory to buffer all data. Just consider it in terms of the team's ability and complexity of operation and maintenance.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b3ba78-e7fe.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b3ba78-e7fe.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?