I have an issue with how mix tasks work within umbrella applications.

Our umbrella application has a large number of sub applications and a large 
number of dependencies. These dependencies connect to AMQP, our databases, 
elasticsearch, and other services. This has caused a large initialization 
time.

When running mix tasks, it seems all of these external services are needed 
and the full application needs to be initialized before any of the tasks 
can run.

This has caused the mix tasks defined to slow down immensely. 

What is the idiomatic way in elixir to do mix tasks? How can we make sure 
that a mix task doesn't require the whole application to completely 
initialize before being run? 

I have looked at the phoenix library and it seems to only initialize the 
phoenix application when `phx.server` is explicitly run. If this is the 
idiomatic way to accomplish this, how do we make sure that all of our 
dependencies don't also start as well?


I am looking for a proper way to do this in elixir that is supported by the 
community. 

-- 
Want to get insights, recommendations and answers from top consultants for 
free? Head to Discussions <https://expert360.com/community> to ask 
questions and find answers.

———————————————————————————————————————————————
This email is intended for the sole use of the intended recipient(s) and 
may contain information that is confidential and/or privileged.  Any review 
or distribution by any other person is prohibited.  If you are not an 
intended recipient, please immediately contact the sender and delete all 
copies of this email message

-- 
You received this message because you are subscribed to the Google Groups 
"elixir-lang-core" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elixir-lang-core/0f7c982a-8267-430c-8d5a-41fedcc97d3e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to