[Rspamd-Users] avast.lua virus scanner module for Rspamd

Vsevolod Stakhov vsevolod at rspamd.com
Fri Jan 31 00:00:25 UTC 2020

On 30/01/2020 20:32, Vsevolod Stakhov wrote:
> On 30/01/2020 19:02, Ralph Seichter wrote:
>> * Vsevolod Stakhov:
>>> You literally break almost everything with unpredictable consequences
>>> by doing it as you mix non-blocking and blocking sockets IO.
>> Strong words, with which I disagree, given that avast.lua does what it
>> is meant to do on various servers (as tested by me and others).
> Even if some architectural solution works for some users in some
> conditions doesn't necessarily make it right. And this one is apparently
> NOT right. I'm sorry but I don't have enough time to explain it in more
> details. So you could either check the code or relevant textbooks (e.g
> about so called c10k problem), or just trust my opinion on that.

Just in case, my intention was not to discourage you from experiments :)
I'm just trying to explain that everything (aside of local file system)
should be done via event loop and async polling model. Apparently all
side libraries assumes plain synchronous sockets and that just doesn't work.

Well, with the only exception of the OpenResty libraries, but their API
and event loops are not compatible with Rspamd...

On the other hand, if you want to do some brave experiments then it is
not a problem at all. But I would suggest to make it in a more canonical
way. At least when you intend to include your work into the upstream

I'm sorry if my messages were seeming to be too harsh: I've not intended

More information about the Users mailing list