[PATCHES] winbindd: Remove indirection through domain->methods

Jeremy Allison jra at samba.org
Mon Oct 10 21:27:58 UTC 2016


On Fri, Oct 07, 2016 at 04:52:43PM -0700, Christof Schmitt wrote:
> Is there a reason for the domain->methods indirection? I assume that
> this is historical, but in the current code domain->methods is always
> set to cache_methods. Unless there are plans to change this, i would
> propose to remove this indirection to make the code a bit easier to
> understand. See attached patches.

So as I recall (from a long time ago) this idea was that
using this indirection allowed the possibility of bypassing
the cache and going directly to the backend in case we
wanted to enforce freshness.

Turns out we always go through the cache anyway, and if we
want to special case to go direct we can always force removal of any
cache entry before attempting the cache lookup.

So given that:

Reviewed-by: Jeremy Allison <jra at samba.org>

as this does significantly clean up this code and make it
easier to understand.

I'll wait a day or so before pushing in case Volker, Guenther
or any other winbindd 'old-hands' want to weigh in with something
I might have missed here :-).

Cheers,

	Jeremy.



More information about the samba-technical mailing list