Re: sa-learn using event notifications

2018-03-12 Thread Arnaldo Viegas de Lima
That will depend on the retraining process complexity as well as the size of 
the messages. 
My guess is that without some real world testing it will be difficult to have a 
definitive answer. 

Arnaldo.

> On Mar 12, 2018, at 2:49 PM, Luca Olivetti  wrote:
> 
> El 12/03/18 a les 18:43, Arnaldo Viegas de Lima ha escrit:
> 
>> I see a 2 ways to handle it:
>> - Enqueue for later processing
>> - Make notifyd pass the job to another process (like a daemon)
> Yes, I thought about those two options (well, only the first one actually, 
> since notifyd can only spawn an external program) and I asked about it in my 
> original message.
> The question is, is it really necessary (with ~100 sessions and not everybody 
> constantly moving messages in/out of the spam folder)?
> 
> Bye
> -- 
> Luca Olivetti
> Wetron Automation Technology http://www.wetron.es/
> Tel. +34 93 5883004 (Ext.3010)  Fax +34 93 5883007
> 


Cyrus Home Page: http://www.cyrusimap.org/
List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/
To Unsubscribe:
https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus


Re: sa-learn using event notifications

2018-03-12 Thread Luca Olivetti

El 12/03/18 a les 18:43, Arnaldo Viegas de Lima ha escrit:


I see a 2 ways to handle it:

- Enqueue for later processing
- Make notifyd pass the job to another process (like a daemon)
Yes, I thought about those two options (well, only the first one 
actually, since notifyd can only spawn an external program) and I asked 
about it in my original message.
The question is, is it really necessary (with ~100 sessions and not 
everybody constantly moving messages in/out of the spam folder)?


Bye
--
Luca Olivetti
Wetron Automation Technology http://www.wetron.es/
Tel. +34 93 5883004 (Ext.3010)  Fax +34 93 5883007

Cyrus Home Page: http://www.cyrusimap.org/
List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/
To Unsubscribe:
https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus


Re: sa-learn using event notifications

2018-03-12 Thread Arnaldo Viegas de Lima
Ah… we use different meaning for the “SPAM” folder! For me it’s where I place 
mail that was wrongly classified as HAM. Mail classified as SPAM go to the 
“quarantine” folder (that get’s purged by Cyrus after X days).

You are talking about moving files out of “quarantine” and using a notification 
to trigger the retraining. That’s indeed a nice idea! 

I see a 2 ways to handle it:

- Enqueue for later processing
- Make notifyd pass the job to another process (like a daemon)

The problem with any of this methods (really with any solution based on 
notifications that is not completely handled in the notification processing) is 
that the use may further move the message.

One option is to make a copy of the message to another (reserved) folder. I may 
be wrong, but my guess is that Cyrus will just link the messages, so it can be 
quick. If not I guess it can be linked during the notification processing. Need 
to check.

Arnaldo.


 
> On Mar 12, 2018, at 2:20 PM, Luca Olivetti  wrote:
> 
> El 12/03/18 a les 18:07, Arnaldo Viegas de Lima ha escrit:
>> I run a separate daemon that periodically checks the spam folder, perform 
>> the necessary “training” actions and then remove the message.
> 
> That's what I've been doing for many years (using a couple of shared folder 
> where users have to move messages that have been wrongly classified)  but I 
> wanted to make it simpler, like the dovecot antispam plugin, where it is 
> enough to move a message in/out of the personal spam folder to trigger a 
> retrain.
> 
> Bye
> -- 
> Luca Olivetti
> Wetron Automation Technology http://www.wetron.es/
> Tel. +34 93 5883004 (Ext.3010)  Fax +34 93 5883007
> 


Cyrus Home Page: http://www.cyrusimap.org/
List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/
To Unsubscribe:
https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus

Re: sa-learn using event notifications

2018-03-12 Thread Luca Olivetti

El 12/03/18 a les 18:07, Arnaldo Viegas de Lima ha escrit:

I run a separate daemon that periodically checks the spam folder, perform the 
necessary “training” actions and then remove the message.


That's what I've been doing for many years (using a couple of shared 
folder where users have to move messages that have been wrongly 
classified)  but I wanted to make it simpler, like the dovecot antispam 
plugin, where it is enough to move a message in/out of the personal spam 
folder to trigger a retrain.


Bye
--
Luca Olivetti
Wetron Automation Technology http://www.wetron.es/
Tel. +34 93 5883004 (Ext.3010)  Fax +34 93 5883007

Cyrus Home Page: http://www.cyrusimap.org/
List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/
To Unsubscribe:
https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus

Re: sa-learn using event notifications

2018-03-12 Thread Arnaldo Viegas de Lima
I run a separate daemon that periodically checks the spam folder, perform the 
necessary “training” actions and then remove the message.

> On Mar 12, 2018, at 1:44 PM, Luca Olivetti  wrote:
> 
> I wrote a simple program that manages the vnd.cmu.MessageMove event to run 
> sa-learn when a message is moved into or out of the spam folder.
> I'm processing it synchronously (i.e., the program starts spawned by notifyd 
> and doesn't terminate until sa-learn exits).
> Given that sa-learn takes a few seconds to run, could it lead to problems? 
> Should I devise a different strategy (i.e. queue sa-learn to run 
> later/asynchronously)?
> I don't have many users (around 100 active sessions).
> 
> Bye
> -- 
> Luca Olivetti
> Wetron Automation Technology http://www.wetron.es/
> Tel. +34 93 5883004 (Ext.3010)  Fax +34 93 5883007
> 
> Cyrus Home Page: http://www.cyrusimap.org/
> List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/
> To Unsubscribe:
> https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus
> 


Cyrus Home Page: http://www.cyrusimap.org/
List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/
To Unsubscribe:
https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus

sa-learn using event notifications

2018-03-12 Thread Luca Olivetti
I wrote a simple program that manages the vnd.cmu.MessageMove event to 
run sa-learn when a message is moved into or out of the spam folder.
I'm processing it synchronously (i.e., the program starts spawned by 
notifyd and doesn't terminate until sa-learn exits).
Given that sa-learn takes a few seconds to run, could it lead to 
problems? Should I devise a different strategy (i.e. queue sa-learn to 
run later/asynchronously)?

I don't have many users (around 100 active sessions).

Bye
--
Luca Olivetti
Wetron Automation Technology http://www.wetron.es/
Tel. +34 93 5883004 (Ext.3010)  Fax +34 93 5883007

Cyrus Home Page: http://www.cyrusimap.org/
List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/
To Unsubscribe:
https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus