Mongo DB是否具有内存中模式? [英] Does Mongo DB have an In-Memory mode?
问题描述
可能重复:
嵌入式MongoDB在运行集成测试时
Possible Duplicate:
Embedded MongoDB when running integration tests
我想使用内存模式进行单元测试,是否有像RavenDB这样的内存模式?
I want to use In-Memory mode for unit test, is there an in In-Memory mode like RavenDB?
推荐答案
MongoDB没有内存模式.根据此链接,直到至少MongoDB 2.8才包含此功能.
There is no in-memory mode for MongoDB. As per this link, this feature won't be included until at least MongoDB 2.8.
尽管由于它使用的是内存映射的IO,所以它在实际处理过程中的速度应与内存中的速度一样快.不过不是初创公司.
Though since it's using Memory-mapped IO, it should be as speedy as in-memory during the actual processing. Not the startup though.
此外,还有一种使用RAM磁盘驱动器并将您的mongo db放在其中的黑客.这样,它将完全在内存中.
Also, there's a hack to use RAM disk drive and put your mongo db there. That way it would be entirely in memory.
这篇关于Mongo DB是否具有内存中模式?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!