News for hackers. Stuff that matters.
Re:Rustler is a library for writing Erlang NIFs in safe Rust... by heavenlyblue on Monday September 16, 2019 @07:20PM (#20989534)
How does Elixir handle OOMs, in such a case?

Do they fail the entire VM, too?

Re:Rustler is a library for writing Erlang NIFs in safe Rust... by toast0 on Monday September 16, 2019 @07:51PM (#20989702)
Yes mostly; when you get a failed allocation, for the most part there is nothing reasonable to do other than make a nice crash dump. Especially from the point of view of a language/toolkit.

As a operator/user, you can certainly write some code to scan for large processes, and kill them; with a fair bit of success, but that's not a great thing for the toolkit to do, it doesn't have a good way to tell what's too big or what's intended.

Re:Rustler is a library for writing Erlang NIFs in safe Rust... by ramchip on Tuesday September 17, 2019 @05:32AM (#20993242)
Nowadays in Erlang you can set a memory limit per process[1], ensuring they get killed if they try to allocate more. Of course you still have to estimate how much is reasonable which isn’t always obvious...

[1] See max_heap_size under http://erlang.org/documentation/doc-9.0/erts-9.0/doc/html/er...

Re:Rustler is a library for writing Erlang NIFs in safe Rust... by puzza007 on Monday September 16, 2019 @08:00PM (#20989766)
Yes