T
T
TAnonim2018-08-03 23:06:35
Laravel
TAnonim, 2018-08-03 23:06:35

What is the best way to implement a daemon process in Laravel?

In addition to the main functions, my Laravel application also needs a separate "background" process that will always be running and will receive data from a third-party service every n seconds in order to perform some actions with them. The question is, what is the correct way to do this in terms of framework architecture? What category will this process belong to (controllers or not)?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
J
JhaoDa, 2018-08-03
@TAnonim

It is correct to do it in a queue. The task completed, returned back to the queue with a delay of n seconds, completed, returned ... well, you understand. It's not very clear why "a process that will always be running", but the queue listener can be run in daemon mode.
Or it can be done by the scheduler. Correctness is subjective...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question