[erlang-questions] ets+dets

Leonard B leonard.boyce@REDACTED
Thu May 11 23:12:49 CEST 2017

On Thu, May 11, 2017 at 4:32 PM, Adam Rutkowski <hq@REDACTED> wrote:
> On Tue, May 9, 2017, at 22:00, Vlad Dumitrescu wrote:
> I was thinking of an ets+dets combo, but it may be tricky to get the details
> right. Is there something like this out there? Would it be better to just
> use mnesia?
> Hi Vlad,
> Apologies if this sounds blunt, but isn't mnesia in fact an ETS+DETS combo
> with lots of tricky details?
> With DETS alone I often get the tables corrupted, erlang-history is the
> prime example -- `rm ~/.erlang-hist.nonode@REDACTED` is my weekly operation.
> What other properties are you looking for? Why _not_ mnesia in your case?
> Cheers
> /A.

Hi Adam,

It seems to be a common misconception that mnesia disc_copies behaves like this.
I used to think so myself. In fact it keeps all data in memory and
flushes to disc,
so it does not meet Vlad's requirements for minimal in-memory cache, with disk

As was pointed out to me when I asked about it in '15, from the docs:
"If a table is of type disc_copies at a certain node, the entire table
is resident in RAM memory and on disc."


> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions

More information about the erlang-questions mailing list