You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@spamassassin.apache.org by bu...@bugzilla.spamassassin.org on 2014/02/03 23:52:59 UTC

[Bug 6997] [FR] merge bayes database(s)

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6997

RW <rw...@googlemail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |rwmaillists@googlemail.com

--- Comment #1 from RW <rw...@googlemail.com> ---
It should be trivial to merge two backup files with a bit of scripting. There
are three kind of lines: metadata (v), token (t), and  signature (s) e.g.

v       3       db_version # this must be the first line!!!
v       11092   num_spam
v       3968    num_nonspam
...
t       3       0       1259670431      295b15d4b5
t       0       1       1260035824      dabf5b0ede
...
s       s       300feabea1f24e00434235260d05b2d0a5cd143a@sa_generated
s       h       d04d35c817646450e194c13cc3fac9f2f1b82aef@sa_generated


all you have to do is merge the metadata and merge token lines with the same
token hash into a single line with aggregate counts and the newest time-stamp. 

The signatures should just be passed through or discarded if you don't want
them. 

It's not possible to deal correctly with any messages that have been trained in
both files, but that shouldn't be major problem.

-- 
You are receiving this mail because:
You are the assignee for the bug.