Decide on Which HTTP Client to Use
HTTP clients in Elixir have a long history. Even before Elixir, there were Erlang clients that are still used to this day in Elixir apps. Knowing the whole history doesn’t provide you with much benefit, but it will be helpful to understand the different abstraction levels that clients can sit on top of.
Once you understand that, we can take a look at the major players and where they sit. There isn’t a single right answer in the end, but you’ll have a solid grasp of why we pick Req as our preferred client.
The Various Levels of Abstraction
Let’s walk through the different levels of abstraction from the lowest to the highest.
- Sockets
-
At the lowest level, HTTP requests are made over sockets. These sockets usually ...
Get From Ruby to Elixir now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.