Performance

I have the following scenario:

A webhook listens for events and registers leads in a postgres database. After creating the lead in the database, you need to send an email or SMS after 3 and 5 days if you don’t make a deposit (webhook event). What is the best strategy in terms of performance:

  1. as soon as you create a lead, put one on wait to be triggered after the set time
  2. Use a cron to check (go through the database) and check by date if there is an email to be sent. In this case, would it be better to bring the leads in batches and send emails or to bring them all at once and send emails through a loop?

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

Hey @Andresd_jf,

Welcome to the community :tada:

If it was me I would take the second option that way you know what time your messages are going out but really the best option would be to try both and see what works for you and the environment.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.