内存数据库的数据持久性和数据安全性是相对而言的特性,
如果数据安全就无所谓持久性。
例如你的MysqL如果一年不崩溃,硬件不断电,服务器不重起。
那么在内存的持久和在硬盘的持久就是没有区别。
同样的道理,如果你的数据有三处以上的备份。
每处备份可以保证一致性和时效性。
那么这也是数据的持久性。
所以数据的持久性不单单指硬盘的数据保存。
而从用户角度说,数据的持久性可能只是针对一个小的数据集合。
或者数据的持久只针对一小部分的对象。
而对于大部分数据是不需要保存到硬盘的。
例如游戏中的npc,大数据计算过程中的常量,网页的系统数据等等。
对于整个库的硬盘持久化那就又退缩到了硬盘数据库的程度。
要更清楚地意识到内存数据库不单单是保存数据,
他更重要的工作内容是处理数据,单单把数据从硬盘拿到内存并不是内存数据库的目的。
The data persistence and data security of the memory database are relatively character,If data security does not matter the persistence of. For example,your MysqL if a year does not collapse,the hardware is constantly power,the server is not dump. So in the memory of the persistent and persistent in the hard disk is no difference between. The same token,if you have more than three data backup. Each backup can ensure consistency and timeliness. So this is the persistence of data. So data persistence does not simply refer to the hard disk data storage. From a user perspective,the persistence of the data may be just a small collection of data. Or the persistence of the data only for a small part of the object. And for most of the data is not required to save to the hard disk. For example,in the game of NPC,big data computing process constants,web system data,etc.. For the entire hard disk persistence of the library,and then back to the extent of the hard disk database. To be more aware of the memory database is not just to save the data,His more important work is process to data,the data from the hard drive to get memory is not the purpose of the memory database.
原文链接:https://www.f2er.com/nosql/203648.html