openaustralia / yinyo

A wonderfully simple API driven service to reliably execute many long running scrapers in a super scaleable way
https://yinyo.io
Apache License 2.0
6 stars 1 forks source link

Bundle events that happen close together in time into a single http request #44

Open mlandauer opened 5 years ago

mlandauer commented 5 years ago

This is a performance optimisation only. If a scraper sends out multiple events in a short period of time it will generate many http requests to the clay server which in turn will generate many requests to the external callback url. It would be sensible to only send out the http requests at most at a certain interval. Say, for arguments sake, that interval is 0.1s. Then, any events that happen in a 0.1s interval we bundle together and send in a single http request.