BIND 10 #1329: Extend DatabaseAccessor to support adding diffs

BIND 10 Development do-not-reply at isc.org
Fri Nov 4 04:09:40 UTC 2011


#1329: Extend DatabaseAccessor to support adding diffs
-------------------------------------+-------------------------------------
                   Reporter:         |                 Owner:  jinmei
  jinmei                             |                Status:  accepted
                       Type:  task   |             Milestone:
                   Priority:  major  |  Sprint-20111108
                  Component:  data   |            Resolution:
  source                             |             Sensitive:  0
                   Keywords:         |           Sub-Project:  DNS
            Defect Severity:  N/A    |  Estimated Difficulty:  5
Feature Depending on Ticket:         |           Total Hours:  0
        Add Hours to Ticket:         |
                  Internal?:  0      |
-------------------------------------+-------------------------------------

Comment (by jinmei):

 trac1329 is ready for review.

 This is basically a straightforward implementation of the
 `addRecordDiff` method as described in
 http://bind10.isc.org/wiki/DifferenceDesign
 with detailed tests and considerations for minor/error cases, so I
 believe it's easy to review.

 One possible point that would require an attention (and perhaps
 discussion) is commit 3d59d6a.  In this commit I changed the way we
 prepare SQLite3 statements: they are now prepared first time they
 are needed rather than at the time of open().  The primary motivation
 is compatibility: since this task introduces a new table, an attempt
 of preparing the statement for adding diffs on an older version of
 database will fail, even if diff handling is not required in that
 environment.  I could bump the schema version and automatically
 update the schema at the initialization time, but I didn't want to
 tweak the accessor class in this direction further.  IMO we should
 eventually (soon) introduce a separate framework to manage data
 sources at a higher level, and this issue should be solved there.

 This change has other advantage: in many cases a single accessor
 object will only need a subset of the entire statements, so delaying
 the setup will help improve performance (although probably
 marginally).

 The size of this commit is not small, but I believe this is basically
 straightforward.

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


More information about the bind10-tickets mailing list