In current configuration the service can:
- check 6000 emails per hour (that is about 140000 per day or 4 millions per month)
- send the same number of emails per hour
- the load is evenly distributed over time
Set CHECK_THREAD_MAX=100
and SEND_THREAD_MAX=20
environment variable for php
docker container to manage service capabilities (maximum sum of threads is 300).
- Install Docker
- Clone the repo to the project directory
- Run
docker-compose up
in the project directory
- Open dashboard on localhost
- Cron job is planned automatically
- Once an hour worker plan a batch of emails to be processed within next hour to evenly distribute the load
- Another worker checks for emails in the queue (every minute by cron) and process them in parallel threads
Check
andsend
workers and queues are separated and do not conflict with each other
- Dashboard displays general statistics, check and mailing progress
- MySQL server is available on IP 127.0.0.1 and port 3306
- You can adjust servers IPs and ports in
docker-compose.yml
if it conflicts with your local environment - Random data is automatically generated (1 million users), set
USER_RANDOM_MAX=1000000
environment variable forphp
docker container to change number of users - To speed up testing, set
USER_SAMPLE_DATA=true
environment variable forphp
docker container (set by default)