dwyl / dwyl/learn-phoenix

POOL_SIZE config var

Open
#117 0 comments 2 reactions 1 assignee Claimed by @RobStallion View on GitHub
discuss help wanted technical
Dominant language
No language data
Stars
664
Forks
41
PR merge metrics
No merged PRs in 30d

Description

`POOL_SIZE` is a variable that is set in the config files. Phoenix seems to give it a default value of 10 always.

However I was working on an application that had been deployed to heroku and the `POOL_SIZE` variable was set to 18. Everything seemed to work as expected until we tried to run a seed file.

When we were running the seed file we were getting the following error
```
Postgrex.Protocol (#PID<0.259.0>) failed to connect: ** (Postgrex.Error) FATAL 53300 (too_many_connections): too many connections for role.
```

I noticed that the phoenix default was 10 so updated that value on heroku and and ran the seed file again, but this time it worked.

Opening this issue so that I can document anything I learn about how `POOL_SIZE` works (in general and on heroku) here but if anyone has an knowledge please comment.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.