[bind10-dev] writable datasources 3/3; API proposal
zhanglikun
zlkzhy at gmail.com
Mon May 17 08:09:28 UTC 2010
Some minor suggestions.
> /**
> * Add an RRset to a zone. If the RRset already exists, the
> * RRs in this set are added to it.
> virtual Result addRRset(isc::dns::Name* zonename, isc::dns::RRset&
> rrset) = 0;
Divide the API AddRRset() into AddRRset() and AddRR() to avoid unnecessary
duplication check, It's useful when we replace the old rrset with the new
one.
AddRRset(): Don't check duplicated records, add rrset directly.
AddRR(): Do record duplication check.
Or it can be done by adding a parameter
addRRset(isc::dns::Name* zonename, isc::dns::RRset&, rrset, bool
duplication_check) = 0;
>
> /**
> * Delete an RRset from a zone. If the RRset in the zone contains
> * more RRs than the given one here, keep those.
> */
> virtual Result deleteRRset(isc::dns::Name* zonename,
> isc::dns::RRset& rrset) = 0;
Change to two interfaces(there maybe a better solution):
virtual Result deleteRRset(isc::dns::Name* zonename, rrname, rrtype,
rr_class) = 0;
virtual Result deleteRR(isc::dns::Name* zonename, isc::dns::RRset& rrset) =
0;
> * Full handler for IXFR message.
> */
> virtual Result doIXFR(isc::dns::Message *msg);
>
> /**
> * Full handler for dynamic update message
> */
> virtual Result doUpdate(isc::dns::Message *msg);
>
Should these two APIs provided by datasource? I think it should be down by
update and XFR module.
Thanks
Zhang Likun
More information about the bind10-dev
mailing list