MihailPertsev

MihailPertsev

Elixir or Phoenix integration with Node JS

Hi! I am new to elixir and I am realy love it, this language is simply amazing. My question is this
I have existing Electron app, that contains a bunch of node js scripts. Basically, what I am doing is browser automation via playwright (filling forms with data => save result => display report to user) and what I want is parallel execution of those scripts. How can I create kind of “control” elixir app for my node scripts?And how can I connect it to my existing electron interface.
The flow that I want to achieve: User clicks on button => electron app somehow communicate with elixir app => elixir app starts node js instance 1; User clicks again => electron communicate with elixir => elixir starts node js instance 2… etc

Marked As Solved

Also Liked

harmon25

harmon25

Could also try this for calling node from elixir.

MihailPertsev

MihailPertsev

This is the picturse that should clarify what I want



Do not misunderstand me, right now everything works without elixir and it works fine, but what I want is to test and kind of play with elixir’s parallelism ability. Any simple way is ok for me, I am not an expert after all.
hubertlepicki

hubertlepicki

So @MihailPertsev have you ended up using Playwright? If so, which approach did you choose and how did it go?

MihailPertsev

MihailPertsev

I ended up with pure NodeJS solution via generic-pool - npm for concurrency. Yes, I am using Playwright because I need to execute some code inside browsers… So, no Elixir here at all.

Where Next?

Popular in Questions Top

pmjoe
I have a relationship of love and hate with Elixir. Lots of things are just absolutely right, but there are some things that are kind of ...
New
gshaw
What is the idiomatic way of matching for not nil in Elixir? E.g., First way: defp halt_if_not_signed_in(conn, signed_in_account) when...
New
LegitStack
I’m hoping you guys can give me some general advice and perhaps code examples if you’re feeling up to it. I’m very interested in Elixir,...
New
Werner
Hi, I’m using Ubuntu 18.04 and after updating to OTP-24.0 yesterday i have this warning when I run “mix local.hex”: 14:57:30.512 [warn] ...
New
aadeshere1
I have a another noob question about loop. Since elixir is immutable, while loop is not directly possible. total = 10 while total != 0 ...
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
ashish173
I am using Ecto timestamps with postgres, I can see the timestamps() use the :naive_dateime but for my use case I wanted to store the ti...
New
WestKeys
Currently suffering from paralysis by [HTTP client] analysis. This is rather unusual in Elixirland as there tends to be consensus on the ...
New
Patoshizzle
After calling mix ecto.create I get this error: 17:00:32.162 [error] GenServer #PID<0.412.0> terminating ** (Postgrex.Error) FATAL...
New
skosch
To my knowledge, put_in, Map.update etc. all have the one limitation of not automatically creating intermediate keys when needed (for exa...
New

Other popular topics Top

vonH
In asking this question I am more interested about the expressiveness of the language itself and less concerned about the availability of...
New
albydarned
Hello all! I am typing this post from my new MacBook Pro with the M1 chip. I’m loving it so far, and will probably use it as my daily dr...
New
aalberti333
As the title describes, I’m trying to run Enum.map() over a list of key/value pairs, where the value is a map. My data looks like this: ...
New
ycv005
I have followed this StackOverflow post to install the specific version of Erlang. And When I am running mix ecto.setup then getting fol...
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
shahryarjb
Hello, I have map which I want to convert it to string like this: the map: %{last_name: "tavakkoli", name: "shahryar"} the string I ne...
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
skosch
To my knowledge, put_in, Map.update etc. all have the one limitation of not automatically creating intermediate keys when needed (for exa...
New
TunkShif
This post is an instruction guide to help you setup your Neovim for Elixir development from scratch. It includes general information on h...
273 38985 115
New
magnetic
Hey :wave:t3: Elixir community, I’ve been learning Elixir, and working on some side projects. My editor of choice is VSCode, and althoug...
New

We're in Beta

About us Mission Statement