How we’ve remade sys threads in Manticore Search

Recently we’ve remade our system threads. Since we’ve forked from Sphinx and earlier searchd had all system tasks made in an often-rise-up style. Each service worked in a dedicated thread which wakes up every 50ms and checks whether it has something to do or not. That means that even an idle daemon wakes 200 times a sec ‘just to check’ a task. Having 6 such tasks will make 1200 wakes a sec, and it became noticeable especially by clients on Amazon AWS which counts CPU usage. Those internal tasks were: […]