namecache redesign

Andrew Bartlett abartlet at samba.org
Sat Aug 31 03:01:00 GMT 2002


Rafal Szczesniak wrote:
> 
> On Sat, Aug 31, 2002 at 03:22:59PM +1000, Andrew Bartlett wrote:
> > tridge at samba.org wrote:
> > >
> > > Tim,
> > >
> > > > How about keeping basically the same API in namecache.c (i.e expiry
> > > > based on time_t) but with an appropriate key prefix as you suggest?
> > >
> > > What I'd like to see is a lib/gencache.c module that provides a string
> > > based cache. So all cache entries would have string keys and string
> > > values.
> > >
> > > key: NBT/name#1c
> > > value: 192.168.2.10 192.168.3.21
> >
> > Perhaps this (the value) should be prefixed with the current unix time,
> > in seconds since 1970?  That should get us nice cache expiration
> > properties.
> 
> Good suggestion, though it's a drop of sour flavour in purely text-oriented
> cache... or you thought about converting it  to text as well.

I figured just the base-10 number, it's sufficiently easy to parse for
computers and sane (if not easy) for humans.

Andrew,

-- 
Andrew Bartlett                                 abartlet at pcug.org.au
Manager, Authentication Subsystems, Samba Team  abartlet at samba.org
Student Network Administrator, Hawker College   abartlet at hawkerc.net
http://samba.org     http://build.samba.org     http://hawkerc.net



More information about the samba-technical mailing list