Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

what does endpoint.ex file do in phoenix elixir

I am new to elixir and phoenix, and using phoenix guides. In getting started guide they just say http://puu.sh/klblD/e50082298d.png but they didn't explain what is endpoint and whats is tasks. Can somebody explain whats it does?

like image 299
Murtza Avatar asked Sep 23 '15 10:09

Murtza


1 Answers

Not to take anything away from @Gazier but I agree with @JoseValim; his response should be an answer so others who might look for this can find it easily.

The endpoint is the boundary where all requests to your web application start. It is also the interface your application provides to the underlying web servers.

Overall, an endpoint has three responsibilities:

  • to provide a wrapper for starting and stopping the endpoint as part of a supervision tree;

  • to define an initial plug pipeline where requests are sent through;

  • to host web specific configuration for your application.

The documentation is here.

like image 123
Onorio Catenacci Avatar answered Sep 24 '22 21:09

Onorio Catenacci