As your Elixir project grew, how did you deal with the pain of compilation?

and what did you do to improve the compilation?

Personally I created DepViz to visualize compilation dependencies and track them down for elimination :grinning_face_with_smiling_eyes:

11 Likes

So far haven’t. With the written permission of several older customers I’ve kept their source code and would love to exercise more on it when I get the time. There are ways, but they are non-trivial for the moment.

If your concern is growing compilation times in CI environments, you can cache the _build and deps folders.

Done that and it works fine.

No, my concern are projects where touching one file causes recompilation of 100+ others, for no obvious reasons.

1 Like

I think that the compiler got smarter on the last elixir version and the idea was to keep improving on that front.
This need to be checked though.

Yes, see #060 Compile Faster with Marc-André Lafortune - Thinking Elixir

4 Likes

yes exactly this. And when i try to create a migration, the project starts compiling. I am at v1.9 and upgrading to latest version is out of question for couple of mnths bcoz of the work load and small team.

and after u run the migration and go back to starting the server, it will again recompile