s3:printing: Do not clear the printer-list.tdb
commitcce25171f7e24ce39693677c9edcdc584f8d9db4
authorAndreas Schneider <asn@samba.org>
Wed, 22 Jun 2022 16:56:26 +0000 (22 18:56 +0200)
committerJule Anger <janger@samba.org>
Mon, 11 Jul 2022 10:27:17 +0000 (11 10:27 +0000)
tree6db2ae9c06007aa54feaac1d108d1e42349be903
parentbecccbae321afe9b4223781512a682100bd88e31
s3:printing: Do not clear the printer-list.tdb

With the new dcerpc architecture we need to keep printer-list.tdb
around. A spoolss dcerpc call will start rpc-spoolssd which will then
start the background queue process. However in order to enum the
printers we need have a printer-list.tdb. Depending on the number of
printers this task can take several seconds. It is unlinkly that
the printer-list will change all the time, so we might provide outdated
data till it gets refreshed, but this is better than providing no
printer list at all.

If there are a lot of printers, the idle_seconds for the rpc-spoolssd
should be increased so that the background task can finish.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=15082

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit 9080cd30d517cb50954e440bb4475c2eeb678906)
source3/printing/printer_list.c
source3/printing/printer_list.h
source3/printing/printing.c