anilmaddala

anilmaddala

Elixir for process intensive tasks

I am a newbie to Elixir, FP and trying to evaluate Elixir/Phoenix backend for a Machine Learning based application. My original idea was to use Elixir<->Rust<->Tensorflow on the backend server.

On doing some initial search, I found references claiming that Elixir is not suitable for process intensive tasks.

So my question would be, what/why is the limitation present? Where to draw the line for elixir in terms of which task is process intensive?

Thanks

Most Liked

LostKobrakai

LostKobrakai

Afaik one of the downsides in computationally expensive tasks is because of immutable data. For certain problems there simply are more performant algorithms around for mutable data then you have for immutable data. Sometimes you can mimic those by using ets, which is an in memory database within the beam (so mutable), but I’m not sure what the determining factors are for when this works or not.

hauleth

hauleth

CPU intensive tasks in Elixir will have the problems @LostKobrakai mentioned, however if you will use NIF or any other interoperability approach offered by BEAM then this will not be much of the problem (your example with Elixir ↔ Rust is great example of that). So if you want that approach then go for it, just shift CPU-intensive work to the Rust (or any other language) and keep Elixir as a frontend for IO-intensive work.

Where Next?

Popular in Discussions Top

Nvim
Elixir appears to be a superior language to Python. I don’t see any advantage of Python over Elixir. Are there any?
New
pillaiindu
In django there is a cache framework backed by memcached. Rails also puts a lot of emphasis on caching, and even the idea of russian-doll...
New
MarioFlach
Hello, I want to share a project I’ve been working on for a while: https://github.com/almightycouch/gitgud Background Some time ago I ...
New
praveenperera
How We Replaced React with Phoenix By: Thought Bot
New
pillaiindu
I want to convert a Phoenix LiveView CRUD website to a CRUD mobile app. What do you think is the easiest way to do so?
New
AstonJ
If a newbie asked you about Phoenix Contexts, how would you explain the basics to them? Feel free to be as concise or in-depth as you li...
New
CharlesO
Erlang :list.nth simple, but 1 - based nth(1, [H|_]) -&gt; H; nth(N, [_|T]) when N &gt; 1 -&gt; nth(N - 1, T). Elixir Enum.at … coo...
New
saif
Hello everyone, Long time lurker first time poster here. I’ve recently begun working on Elixir full-time again! :raised_hands: It’s been...
New
Markusxmr
Since Drab has been developed for a while in the open, introducing the Liveview functionality in a way it happend appears to undermine th...
New
slashdotdash
Phoenix Live View is now publicly available on GitHub. Here’s Chris McCord’s tweet announcing making it public.
New

Other popular topics Top

Harrisonl
We have an ECS cluster with 4 services, where each task joins a single cluster, via discovery ECS discovery service. Currently when I de...
New
fireproofsocks
Forgive me if this is obvious, but how does one delete a database record WITHOUT selecting it first? Ecto.Repo — Ecto v3.14.0 has exampl...
New
msaraiva
Surface is an experimental library built on top of Phoenix LiveView and its new LiveComponent API that aims to provide a more declarative...
564 43622 214
New
josevalim
Hi everyone, One of the features added to Elixir early on to help integration with Erlang code was the idea of overridable function defi...
New
vonH
When I run the Plug and I recompile I wind up having to use Ctrl C to quit iex and start again. Witht the help of rlwrap I can use the cu...
New
RisingFromAshes
I’ve read in another post that it may be possible with a router helper - but I couldn’t find an appropriate one, and tbh, I’m still just ...
New
fayddelight
I tried installing elixir 1.11.2 erlang 23.3.4 via asdf in my zsh shell. Enabled the versions locally and globally. When I list them ...
New
Qqwy
Original source of discussion: This topic on the Pragmatic Programmers’ Functional Web Development with Elixir, OTP, and Phoenix forum. ...
New
rms.mrcs
Hi, I need to transform a list of numbers into a map where the keys are the indexes and the values are the original values of the list. ...
New
klo
Got a question about when to concat vs. prepending items to list then reversing to achieve appending. So i know lists boil down to [1 | ...
New

We're in Beta

About us Mission Statement