Processes in Iex

The Elixir iex shell is a very powerful tool in itself.

I have recently found a trick that makes it much easier to use. If you get stuck in a line that you just can’t complete just type :break + return and it will cancel that line.

This is an investigation of what you get out of the box.

Lets start with the processes that exist in an empty iex session:

iex > Process.list |> Enum.count
56 
Process.registered |> Enum.count
33

That means that there are 33 named processes started with iex and 23 anonymous ones.

Here are the named ones:

Elixir.IEx.Broker - GenServer, communicates with other components.
Elixir.IEx.Config - Agent, handles .iex.config file
Elixir.IEx.Pry - GenServer, Handles Pry debugging
Elixir.IEx.Supervisor - Supervisor for the above three Services.
Elixir.Logger, Service for logging, works with logger.
Elixir.Logger.BackendSupervisor, Supervises the backend for the logger
Elixir.Logger.Supervisor - Supervisor for the logger components
application_controller - GenServer, handles loaded applications
code_server - Erlang code server
elixir_code_server - GenServer that manages loaded code in ets
elixir_config - GenServer that stores config in ets
elixir_sup - Supervisor for the above two GenServers
erl_prim_loader
erl_signal_server
erts_code_purger
file_server_2
global_group
global_name_server
inet_db
init
kernel_refc
kernel_safe_sup
kernel_sup
logger - Erlang logger service, used by Elixir.Logger
logger_handler_watcher
logger_proxy
logger_sup
rex
socket_registry
standard_error
standard_error_sup
user
user_drv

We have the following applications loaded:

iex > :application_controller.loaded_applications
[
  {:logger, 'logger', '1.10.4'},
  {:iex, 'iex', '1.10.4'},
  {:compiler, 'ERTS  CXC 138 10', '7.6.2'},
  {:elixir, 'elixir', '1.10.4'},
  {:stdlib, 'ERTS  CXC 138 10', '3.13'},
  {:kernel, 'ERTS  CXC 138 10', '7.0'}
]

You can find out more using :observer.start
This is the Elixir Application Tree
Here is the IEx Application Tree
This is the Elixir Logger Supervisor tree
Here is the Erlang Kernel supervisor tree

These cover 43 of the Processes

I have 13 to track down.

Nodes 2020 Extended

I was the first speaker at Nodes 2020 Extended.

My Talk at Nodes 2020 Extended

This is the first time I have done an event that was live streamed. It was a bit odd having two different streams being shared at the same time (video + audio on one) and the screen on the other.

Thanks to @ElLazal and @nsmith_piano for hosting.

I almost got caught out by the demo gods: I had installed Neo4j 4 at the conference a couple of weeks ago and found that my utility will need some updates before it will work with that version. Thankfully I was able to quickly debug this using a docker image. It’s possible to create a Neo4j 3.5 db in Neoj4j which saved the day.