D
D
Dmitry2015-09-08 12:14:23
Gearman
Dmitry, 2015-09-08 12:14:23

How to implement continuous execution of a dynamically changing number of tasks on gearman?

Good time of the day!
There is a chain of tasks. For clarity, I will describe.

  • The parser searches and compares names (for example, goods) on several sites (3 for now, but there will be more)
  • According to the list of matching names, pages with product characteristics are parsed
  • Then the characteristics are compared and the discrepancies are added to the database

At the moment, the client sends tasks to the worker, and the function is deliberately looped for constant processing (once every 5 seconds).
How to properly organize continuous and parallel (because there are several such chains, depending on the number of product categories) execution of these chains?
And also, there can be a lot of goods (more than 40) and you have to wait a long time for a response from the site, so they also need to be broken down somehow (for example, 20 pieces).
Is gearman the right choice?
Please, does anyone have any experience with this? If possible, a few normal examples (documentation on gearman is not enough).
Thank you!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dimonchik, 2015-09-08
@dimonchik2013

the correct choice is the one you know
Gearman is quite well described, which means that the correct one
can be swung at RabbitMQ, but for "40 goods" it's over
organized: put data/step readiness labels, depending on the label, send the next step to work

Similar questions

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question