Returning row data from PostgreSQL functions w/ Ecto

Continuing our exploration of all things Elixir, we’re going to convert our search query into a PostgreSQL function that returns rows and try put that row data into an Ecto schema.

http://www.brightball.com/articles/postgresql-functions-with-elixir-ecto

Introducing Tesla — the flexible HTTP client for Elixir

tl;dr for rubyists - faraday is here!

In this article I will show you how and why you might be interested in this new HTTP library.

https://medium.com/@teamon/introducing-tesla-the-flexible-http-client-for-elixir-95b699656d88

Function currying in Elixir

Kare lets you curry (partially apply) functions in Elixir.

iex> curried = Kare.curry(fn x, y, z -> x + y * z end)
iex> curried.(1).(2).(3)
7

Re-design with Elixir/OTP and Pattern Matching

Elixir is a fast growing elegant functional language on top of Erlang VM. One of the most important feature of Elixir is able use OpenTelecomPlatform(OTP) which allows to run concurrent supervised supervisor/workers on the same node and also across multiple machines. And secondly, use the pattern matching to keep code clear and more readable.

https://medium.com/@mustafaturan/re-architecting-with-elixir-otp-and-pattern-matching-b452213c7947

Keep your ETS tables alive forever (v1.1)!

ETS tables are ephemeral by nature, but sometimes you want to make sure that they hang around so you can recover from crashes or unexpected circumstances. Sadly, if the ETS owner process dies, your ETS table also falls over.

Eternal stops this from happening, and has been revamped to a (backwards compatible) v1.1 which now supports OTP Supervision trees instead of the clumsy functions allowed previously.

Check it out! https://github.com/zackehh/eternal

Asynchronous Tasks with Elixir

In this article, I’ll show you how easy is to convert a sequential program written in Elixir into a concurrent one using the Task module.

Asynchronous Tasks with Elixir

#TIL: `handle_info(_, state), do: {:noreply, state}` is a Pokemon clause

Today I learned, that handle_info(_, state), do: {:noreply, state} is a Pokemon clause, because:

Gotta catch em all.

Gravity - Elixir client for the Gravatar API

gravity is an Elixir client for the Gravatar API.

iex> Gravity.image("yosriady@gmail.com")
 "https://www.gravatar.com/avatar/1b0ab2500efc1b91424fb49045312929"

IntelliJ Elixir v4.3.0

README changes

Completion

Aliases and Modules

When you start typing an Alias, completion will look in three locations:

  1. alias aliased names in the current file a. Suffix for alias Prefix.Suffix b. MultipleAliasA or MultipleAliasB for alias Prefix.{MultipleAliasA, MultipleAliasB} c. As for alias Prefix.Suffix, as: As
  2. Indexed module names (as available from Go To Symbol) a. Prefix.Suffix from defmodule Prefix.Suffix b. MyProtocol from defprotocol MyProtocol c. MyProtocol.MyStruct i. defimpl MyProtocol, for: MyStruct ii. defimpl MyProtocol nested under defmodule MyStruct
  3. Nested modules under aliased names a. Suffix.Nested for alias Prefix.Suffix where Prefix.Suffix.Nested is an indexed module, implementation or protocol name. b. MultipleAliasA.Nested for alias Prefix.{MultipleAliasA, MultipleAliasB} where Prefix.MultipleAliasA.Nested alias Prefix.{MultipleAliasA, MultipleAliasB} is an indexed module, implementation or protocol name. c. As.Nested for alias Prefix.Suffix, as: As where Prefix.Suffix.Nested is an indexed module, implementation, or protocol name.

Go To Declaration

Go To Declaration is a feature of JetBrains IDEs that allows you to jump from the usage of a symbol, such as a Module Alias, to its declaration, such as the defmodule call.

Alias

  1. Place the cursor over an Alias with an aliased name setup by alias a. Suffix if alias Prefix.Suffix called b. MultipleAliasA if alias Prefix.{MultipleAliasA, MultipleAliasB} called c. As if alias Prefix.Suffix, as: As
  2. Activate the Go To Declaration action with one of the following: a. Cmd+B b. Select Navigate > Declaration from the menu. c. Cmd+Click
  3. A Go To Declaration lookup menu will appear, allowing you to jump either the alias that setup the aliased name or jumping directly to defmodule of the unaliased name. Select which declaration you want a. Use arrow keys to select and hit Enter b. Click

Elixir Hunt - Find your next Elixir Job

alt

What ?

I hunt for Elixir Jobs so you don’t have to!

Why ?

I got bored to go every day around internet (angel.co, indeed, elixir-jobs, workwithelixir, …) to find my next job. I think it should be easy to see the available Elixir positions … so I made it !

Where ?

Website:http://www.elixirhunt.com/

Twitter:https://twitter.com/elixirhunt

Hope it helps :)

Deploying Elixir to AWS Elastic Beanstalk

I’m trying to find some tutorial or resource that helps me deploy a Phoenix app to AWS Elastic Beanstalk, without using Docker.

Anyone would like to share something?

How Elixir helped us scale our Video User Profile Service for the Olympics

In this article, I did a quick look at our rewrite of a Ruby on Rails Service to an Elixir version, to met 2016 Olympics throughput increase.

https://medium.com/software-sandwich/how-elixir-helped-us-to-scale-our-video-user-profile-service-for-the-olympics-dd7fbba1ad4e#.lb8dwp35y

Feedbacks are welcome.

Paasaa: natural language detection

Paasaa is a simple library for natural (human) language detection:

iex> Paasaa.detect "Detect this!"
"eng"

https://github.com/minibikini/paasaa

Impressions From My First ElixirConf

This week I attended the Elixir & Phoenix Conference with about 540 other people. It was the first time that I ever attended Elixir Conf. I wrote up some thoughts & impressions from an older and sometimes grouchy developer who has a lot of experience in .Net and almost no experience in Ruby.

http://taylonr.com/impressions-from-my-first-elixirconf/

River, an HTTP/2 Client for Elixir

River is an HTTP/2 client for Elixir. It’s very much a beta and under active development, but I intend to have full HTTP/2 & HTTP/1.x support. In short, River should eventually be the HTTP client you can use for any http use case, even if you’re not calling an HTTP/2 server.

Give it a look, and let me know what you think!

https://github.com/peburrows/river

Documented example of using Cowboy in Elixir

Cowboy Elixir Example

When I was new to Elixir, I found the docs for NineNines’ Cowboy web server totally incomprehensible - even with experience they’re still obtuse. So I made this heavily documented example of using Cowboy to serve static assets, dynamic requests, and websockets in Elixir. Updated today for Elixir 1.3 with fixed links and more docco. Hopefully it’ll save you the day I wasted puzzling it out!

exfacebook

Few months ago I did the migration from Ruby to Elixir in one of my home project musicfeed. Elixir app is working as aggregator of facebook music feeds. As result of the migration I did the library for Facebook API that’s supporting pagination, batch requests, image and video uploads. I hope it could be helpful for someone as well.

exfacebook

Load your aliases when starting IEx

When working on a phoenix project, you often need to load add aliases once you fire up your IEx shell.

You can set them on IEx startup usingn a .iex.exs file:

https://niallburkley.com/blog/preloading-aliases-in-iex/

Develop from anywhere in a browser with the intellij IDE

Applications are dockerized, docker-compose used to link containers. No client install needed. https://github.com/StefanHoutzager/elixir-dev-anywhere-docker Enjoy.

Generate Your Phoenix Project Documentation with ex_doc

ExDoc generates web documentation for any elixir project and that includes your phoenix applications! See how it works, what comes out, and pick up some tips.

Previous page Next page