BIND 10 #2210: support "reconfigure" command in the configurator thread

BIND 10 Development do-not-reply at isc.org
Wed Oct 17 03:43:05 UTC 2012


#2210: support "reconfigure" command in the configurator thread
-------------------------------------+-------------------------------------
                   Reporter:         |                 Owner:
  jinmei                             |                Status:  new
                       Type:  task   |             Milestone:
                   Priority:         |  Sprint-20121023
  medium                             |            Resolution:
                  Component:         |             Sensitive:  0
  b10-auth                           |           Sub-Project:  DNS
                   Keywords:         |  Estimated Difficulty:  5
            Defect Severity:  N/A    |           Total Hours:  0
Feature Depending on Ticket:         |
  background zone loading            |
        Add Hours to Ticket:  0      |
                  Internal?:  0      |
-------------------------------------+-------------------------------------
Description changed by jinmei:

Old description:

> A subtask of #2201, depend on #2202, #2204, #2205.
>
> This task extends the newly introduced "data source configurator"
> thread in #2205 to support full data source reconfiguration in
> background (allowing the main thread to keep using the old
> configuration until new config is fully loaded).
>
> It does the following:
> - call `DataSourceConfiguratorGeneric::reconfigure()` (revised in #2204)
> - acquire the lock (introduced in #2202)
> - call `AuthSrv::setDataSourceClientLists()` (introduced in #2204) with
>   the reconfigure() result
> - release the lock
> - let the returned old map from setDataSourceClientLists() be
>   destroyed.

New description:

 A subtask of #2201, depend on #2202, #2204, #2205.

 This task extends the newly introduced "data source configurator"
 thread in #2205 to support full data source reconfiguration in
 background (allowing the main thread to keep using the old
 configuration until new config is fully loaded).

 UPDATED based the (pre-review) result of #2205:

 It does the following:
 - extend the `DataSrcClientsMgrBase` class so it will have
   `shared_ptr<map<RRClass, shared_ptr<ConfigurableClientList> > >` and
   a mutex for it (as hinted in a 'ifdef notyet' block of
   `DataSrcClientsMgrBase`).
   (Eventually we'll move this from auth_srv.)
 - introduce a new command `RECONFIGURE`.  It takes `ConstElementPtr`
   that would be currently passed to configureDataSourceGeneric().
 - extend `DataSrcClientsBuilderBase::handleCommand()` so it can handle
   the `RECONFIGURE` command.  It calls configureDataSourceGeneric()
   with the given command arg, acquire the mutex lock (introduced in
   the first step) then swap the content of the shared pointer
   (introduced in the first step), release the mutex.

--

-- 
Ticket URL: <http://bind10.isc.org/ticket/2210#comment:5>
BIND 10 Development <http://bind10.isc.org>
BIND 10 Development


More information about the bind10-tickets mailing list