cups-browsed: how to treat rejecting queues?
When cups-browsed creates local queues to forward jobs to remote queues, I wonder how it should treat queues that are not accepting jobs? The way cupsd used to behave was to copy the remote printer's state to the local implicit queue, but cups-browsed is not structured in that way: it doesn't update the queues it creates.
The problem with the current behaviour is that the GTK+ print dialog will allow a queue rejecting jobs to be selected.
See also discussion of this for Fedora:
https://bugzilla.redhat.com/show_bug.cgi?id=1025263
Tim.
*/
Tim, one can solve the problem, cups-browsed updates queues on changes in the Bonjour record from the server (but not sure whether on all changes). Rejecting jobs is encoded in the printer-type TXT field, by the 0x80000 bit. See /usr/include/cups/cups.h, CUPS_PRINTER_REJECTING constant.
So it should be possible to implement that the cups-browsed queue follows the accepting bit of its remote queue.
Till
Quoted 15 lines · Tim Waugh
When cups-browsed creates local queues to forward jobs to remote queues, I wonder how it should treat queues that are not accepting jobs? The way cupsd used to behave was to copy the remote printer's state to the local implicit queue, but cups-browsed is not structured in that way: it doesn't update the queues it creates.
The problem with the current behaviour is that the GTK+ print dialog will allow a queue rejecting jobs to be selected.
See also discussion of this for Fedora:
https://bugzilla.redhat.com/show_bug.cgi?id=1025263Tim.
*/
Quoted 6 lines · Tim Waugh
When cups-browsed creates local queues to forward jobs to remote queues, I wonder how it should treat queues that are not accepting jobs? The way cupsd used to behave was to copy the remote printer's state to the local implicit queue, but cups-browsed is not structured in that way: it doesn't update the queues it creates.
Quoted 9 lines
The problem with the current behaviour is that the GTK+ print dialog will allow a queue rejecting jobs to be selected.
See also discussion of this for Fedora:
https://bugzilla.redhat.com/show_bug.cgi?id=1025263Tim.
*/
I have checked further, cups-browsed indeed does not update queues on Bonjour record changes, the update to https is triggered by a completely new Bonjour broadcast.
I have also tried to switch a printer on my server between accepting and rejecting state, and this does not make CUPS/Avahi generating an update of the Bonjour record (= sending a broadcast), avahi-discover on a client did not show any evidence of a signal broadcasted because of this change. Can this be a bug in CUPS which we should report?
Till
Till,
Quoted 6 lines · Till Kamppeter
...
I have also tried to switch a printer on my server between accepting and rejecting state, and this does not make CUPS/Avahi generating an update of the Bonjour record (= sending a broadcast), avahi-discover on a client did not show any evidence of a signal broadcasted because of this change. Can this be a bug in CUPS which we should report?
This is a conscious design decision for cupsd - we do not re-register the TXT records on simple state changes.
Conceptually we might want to stop sharing a printer that is not accepting jobs. Something to think about…
____________________________________________________________
Michael Sweet, Senior Printing System Engineer, PWG Chair
Quoted 10 lines · Michael Sweet
Till,
Quoted 6 lines · Till Kamppeter
...
I have also tried to switch a printer on my server between accepting and rejecting state, and this does not make CUPS/Avahi generating an update of the Bonjour record (= sending a broadcast), avahi-discover on a client did not show any evidence of a signal broadcasted because of this change. Can this be a bug in CUPS which we should report?
Quoted 3 lines
This is a conscious design decision for cupsd - we do not re-register the TXT records on simple state changes.
Conceptually we might want to stop sharing a printer that is not accepting jobs. Something to think about…
Yes, I think this would be a good idea.
Till
Quoted 5 lines · Till Kamppeter
Tim, one can solve the problem, cups-browsed updates queues on changes in the Bonjour record from the server (but not sure whether on all changes). Rejecting jobs is encoded in the printer-type TXT field, by the
0x80000bit. See/usr/include/cups/cups.h,CUPS_PRINTER_REJECTINGconstant.
OK. It should also update the existing queue states when using BrowsePoll as well. I can look at that if you like.
Tim.
*/