![]() It obviously gives wicked-fast reads on each node, but writes will be very expensive. From a redundancy standpoint, this is fairly ridiculous and costly, and Mnesia by no means forces you to do so. In the link above where Mnesia and MySQL are compared for speed, one needs to remember that it's in eJabberd, which runs against a single server if it's MySQL and runs a fully replicated database if it's Mnesia - and large eJabberd clusters can have as much as 10 or more erlang nodes (and thus, 10 or more Mnesia replicas). Mnesia is what it is, and is likely to stay that way. Some work has been done to extend the suitability of Mnesia for other domains, but it is not a priority for the Erlang/OTP development team. OTOH, these applications have practically no need for ad-hoc query support, and do not use very large data sets. This essentially meant that you could read from the database only if the data was in shared memory, but would avoid writing to persistent storage on a per-call-setup basis. As it says in the docs (above), Mnesia's target applications were telecom switching applications, where response time requirements for e.g. You need to decide which one is most important to you. ![]() Overall, SQL databases tend to favor throughput over latency, and when it comes to latency, Mnesia+Erlang are generally outstanding. The reason why Mnesia can do this and still be robust, is that Erlang implements memory 'protection' at the language level. This is not possible in MySQL, since your application and the database will be separated in memory. If your application is written in Erlang, Mnesia allows you to store the data in the same memory space as your application, which means you can fetch a single data object as quickly as a few microseconds. Mnesia and MySQL are indeed different beasts, and which one is the best depends very much on how you intend to use it. Here's my answer, based on having used Mnesia since 1996 and various other database technologies since 1988.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |