[erlang-questions] Shared ETS Access

Zoltan Lajos Kis kiszl@REDACTED
Mon Jan 11 12:25:35 CET 2010


> # Zoltan Lajos Kis 2010-01-11:
>> Is there any advantage in writing to the table through a server process,
>> instead of directly writing to the table (perhaps using the
>> write-concurrency switch) ?
>
> [Answering the general question, didn't track the thread closely.]
>
> Depends on the problem at hand. Writing through owner process implies
> table
> modifications are serialized in time, this is useful in cases where table
> holds data complex beyond a simple key-value store or when table contents
> need to stay in sync with some bits of surrounding world. So "consistency"
> or at least illusion thereof is the answer.
>
> Of course, one remembers to think twice before using ETS acrobatically
> ;-).
>
> Regards,
> 	-- Jachym
>

This will only become consistent if reads are also done through the
server. But then the table could be set to private as well (if an ets
table is needed at all then).



More information about the erlang-questions mailing list