[cups.development] [RFE] STR #3048: Option to check for changes in client.conf

karl runge runge at karlrunge.com
Tue Dec 30 08:58:29 PST 2008


DO NOT REPLY TO THIS MESSAGE.  INSTEAD, POST ANY RESPONSES TO THE LINK BELOW.

[STR New]

Although /etc/cups/client.conf and ~/.cups/client.conf are not
often used by administrators or users, it would be nice to have
a mechanism where libcups will reload these files once it detects
they have changed.

That way, running applications (e.g. web browser) would not need
to be restarted to pick up the changes in those files.

A usage mode that could take advantage of this would be to
temporarily redirect print requests to a different CUPS server
by means of the ServerName parameter (e.g. a remote desktop
access app.)  This would also be of use if one's main cups server
(non-localhost) was down and he needed to use a different one.

One possible way to implement this would be to have a "Reload"
setting in client.conf itself.  If present, libcups interfaces
(e.g. cupsServer() and ippPort()) will check if client.conf
has been modified since the last time and if it has then induce
reloading the parameters from scratch using its startup algorithm.

Under normal circumstances I suspect this would have minimal
performance impact; since the file are so small and easy to
parse the subsequent interaction with the CUPS server is likely
much longer.  If there was concern about extreme usage modes
where this would induce too many stat(2)'s per second, one could
use a timestamp to cache the results for, say, 5 seconds before
re-stating.  Most users would not notice or object to a short
delay like that.

Link: http://www.cups.org/str.php?L3048
Version:  -feature





More information about the cups mailing list