summaryrefslogtreecommitdiff
path: root/doc/misc/gnus.texi
diff options
context:
space:
mode:
authorEric Abrahamsen <eric@ericabrahamsen.net>2014-12-18 11:22:02 +0000
committerKatsumi Yamaoka <yamaoka@jpl.org>2014-12-18 11:22:02 +0000
commitd20acfe06340953dce443795d28ac224a2223414 (patch)
tree1bc3a7ea61c8f9d07b0b38efee915530d0617329 /doc/misc/gnus.texi
parent18d4bdf135524f33173caa2ef2164345bd09017d (diff)
downloademacs-d20acfe06340953dce443795d28ac224a2223414.tar.gz
Fix Gnus registry pruning and sorting, and rename file
* lisp/gnus/gnus-registry.el (gnus-registry-prune-factor): Add new variable. (gnus-registry-max-pruned-entries): Remove obsolete variable. (gnus-registry-cache-file): Change default filename extension to "eieio". (gnus-registry-read): Add new function, split out from `gnus-registry-load', that does the actual object reading. (gnus-registry-load): Use it. Add condition case handler to check for old filename extension and rename to the new one. (gnus-registry-default-sort-function): New variable to specify a sort function to use when pruning. (gnus-registry-save, gnus-registry-insert): Use it. (gnus-registry-sort-by-creation-time): Define a default sort function. * lisp/gnus/registry.el (registry-db): Consolidate the :max-hard and :max-soft slots into a :max-size slot. (registry-db-version): Add new variable for database version number. (registry-prune): Use :max-size slot. Accept and use a sort-function argument. (registry-collect-prune-candidates): Add new function for finding non-precious pruning candidates. (registry-prune-hard-candidates, registry-prune-soft-candidates): Remove obsolete functions. (initialize-instance): Upgrade registry version when starting. * doc/misc/gnus.texi (Gnus Registry Setup): Explain pruning changes. Mention gnus-registry-prune-factor. Explain sorting changes and gnus-registry-default-sort-function. Correct file extension.
Diffstat (limited to 'doc/misc/gnus.texi')
-rw-r--r--doc/misc/gnus.texi27
1 files changed, 22 insertions, 5 deletions
diff --git a/doc/misc/gnus.texi b/doc/misc/gnus.texi
index 57aee27e2b1..6e3dced25d4 100644
--- a/doc/misc/gnus.texi
+++ b/doc/misc/gnus.texi
@@ -25953,17 +25953,34 @@ the word ``archive'' is not followed.
@defvar gnus-registry-max-entries
The number (an integer or @code{nil} for unlimited) of entries the
-registry will keep.
+registry will keep. If the registry has reached or exceeded this
+size, it will reject insertion of new entries.
@end defvar
-@defvar gnus-registry-max-pruned-entries
-The maximum number (an integer or @code{nil} for unlimited) of entries
-the registry will keep after pruning.
+@defvar gnus-registry-prune-factor
+This option (a float between 0 and 1) controls how much the registry
+is cut back during pruning. In order to prevent constant pruning, the
+registry will be pruned back to less than
+@code{gnus-registry-max-entries}. This option controls exactly how
+much less: the target is calculated as the maximum number of entries
+minus the maximum number times this factor. The default is 0.1:
+i.e. if your registry is limited to 50000 entries, pruning will try to
+cut back to 45000 entries. Entries with keys marked as precious will
+not be pruned.
+@end defvar
+
+@defvar gnus-registry-default-sort-function
+This option specifies how registry entries are sorted during pruning.
+If a function is given, it should sort least valuable entries first,
+as pruning starts from the beginning of the list. The default value
+is @code{gnus-registry-sort-by-creation-time}, which proposes the
+oldest entries for pruning. Set to nil to perform no sorting, which
+will speed up the pruning process.
@end defvar
@defvar gnus-registry-cache-file
The file where the registry will be stored between Gnus sessions. By
-default the file name is @code{.gnus.registry.eioio} in the same
+default the file name is @code{.gnus.registry.eieio} in the same
directory as your @code{.newsrc.eld}.
@end defvar