Stephen Gallagher wrote:
On 09/08/2010 08:26 AM, Jakub Hrozek wrote:
> On 09/08/2010 02:12 AM, Stephen Gallagher wrote:
>> I have written up a problem statement and a brief overview of my plans
>> regarding netgroup support in the SSSD.
>> Please read through and comment as needed:
>>
https://fedorahosted.org/sssd/wiki/DesignDocs/Netgroups
>> My goal is to have this work completed before the end of September.
> I asked my question as another bullet point to the wiki, but Stephen
> reminded me there's probably a wider audience on this list.
> This was the question and answer:
> Q: Maybe this is too low-level at this time, but is a cleanup task
planned?
> A: Netgroups should be handled in the same way that users and groups are
> handled, so I will probably have to extend the existing cleanup task to
> also address the netgroups entries in the cache
I've also been thinking about how we're going to handle processing the
nested groups, and I think what I'm going to do is take advantage of
some of the nicer features of libcollection.
Internal processing of setnetgrent_send() will recursively call out a
subrequest to setnetgrent_send() again for each of the named nested
groups. The setnetgrent_recv() function will return a libcollection
object containing all of the results from that request (as well as any
additional subrequests called). When the results come back up, they can
be added together trivially using the col_add_collection_to_collection()
interface with the col_add_mode_clone mode.
I think this would work.
I started thinking that potentially there should be a way to not clone
the subcollections but rather use references to nested groups.
I was thinking that if you keep a hash table of the names of netgroups
as keys and pointers (or structures with one member being pointer) as
values you would be able to construct collections from cache without
copying data but rather by reference.
However this seems to be an optimization that might not be worth it at
least in the first implementation. So let us start with what you propose
and see if it scales. If not we will see how it can be improved.
_______________________________________________
sssd-devel mailing list
sssd-devel(a)lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/sssd-devel
--
Thank you,
Dmitri Pal
Engineering Manager IPA project,
Red Hat Inc.
-------------------------------
Looking to carve out IT costs?
www.redhat.com/carveoutcosts/