I need to create a workflow that has a counter to delivery the following soluction:
There are an application that has a wait status, and I need to send a message showing how long the people are waiting. On workflow has two timers (sleep command) that wait 5 and 10 minutes. After second timer (10min), there is a loop that sends message every 10 minutes, in other words, a first time, the message has 15 minutes, every loop, this will be add 10 minutes and the Teams message sending 25, 35, 45 minutesâŚ
I made this using Set node, but while it is manually, Is there a way to increase this cout automatically?
Hey @harshil1712, could you help about this workflow?
We are using the Function node to generate the the counter and the dynamic Teams message.
The first time, it works, and send â15 minutesâ on Teams, but in the loop, this value donât change, itâ always 15 minutes.
We are trying to use a variable to keep the last value after the Function node, but this variable donât works.
Where is wrong?
Thanks.
I would set the initial value out of the loop using the Set node and manipulate this value inside the loop. Currently, youâre setting the initial value in the loop. Every time the loop runs, this initial value is set. The following image might give you a better idea
Hey @harshil1712, we made the workflow following your exemple and it worked, it create a variable and change this value acording the loop.
As we are not using a Database to store the variable (I think that the flow uses an internal buffer from our n8n instance), some times our workflow stop working, like the variable was lost, for exemple, after 20 minutes, it stops sending the message. Iâm rigth? Can this internal buffer causing the problem?
Hey @harshil1712, I changed the workflow timeout, and make that it has up to 30 minutes, it working, but occours often âUnknown Statusâ and the workflow stop working.
How can I discovery the error?
Hey @harshil1712, clicking on the folder icon is not showing nothing, but I noticed that n8n container is rebooting some times during the day, Iâll oberve it.
If the container restarts it is a sign that n8n crashed. That happens normally if it runs out of memory. That would then also explain the âUnknownâ status.
Hey @jan, this afternoon the container didnât crash and the workflow works fine all time.
Is there a log that I can see the out of memory?
How can I fix it? Do I increasing RAM memory can help?
From what has been shared in the above link, it is possible that the API errors out and doesnât send a response back to n8n, causing the above error.
About " Did you change the mode from main to own ?" I read the n8n documentation but I didnât understantd how to do that. I mean, How to use the âexport EXECUTIONS_PROCESS=ownâ command? Do I need to send it on docker-compose or on n8n container shell? Could you help me about this?