D
D
Dmitry Goncharov2020-08-12 11:39:35
Node.js
Dmitry Goncharov, 2020-08-12 11:39:35

How to automate Workflow?

Good afternoon!

There is a WorkFlow(CharFlow) constructor https://jerosoler.github.io/Drawflow/

What is the best way to automate what the user built in this constructor?

For example
, the User received a tag via api. And for this tag there is an automation:

  1. Wait 30 minutes
  2. Send an email
  3. Wait 30 minutes
  4. Send another email
  5. Send message to chat


The question is, how can we check these tags and move the user through our funnel with the completion of tasks?

Thank you very much!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
I
Ivan Shumov, 2020-08-12
@inoise

You need to choose a Workflow Manager for yourself and integrate microservices with ready-made functionality into it. For example, you can look at Zeebe

D
Daria Motorina, 2020-08-12
@glaphire

Your question draws on a full-fledged TOR, you need to decompose tasks, clarify everything, and only then decide how to do it.
This particular part

The user received a tag via api. And for this tag there is an automation:
Wait 30 minutes
Send an email to the mail
Wait 30 minutes
Send another email to the mail
Send a message to the chat

It is solved by the fact that on the event "A tag came to the user via api" in the task table, records are created with a "schedule" - a field when it should work. Cron polls the table every minute (or a little less often), sees if it's time to pick up the record and processes it. Processing can be moved to the message queue so as not to suffer with the fact that the old tasks have not yet been processed by the script, but you need to take new ones.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question