BIND 10 #2575: implement DataSourceClient::deleteZone and its SQLite3 implementation

BIND 10 Development do-not-reply at isc.org
Thu Jan 10 16:36:44 UTC 2013


#2575: implement DataSourceClient::deleteZone and its SQLite3 implementation
-------------------------------------+-------------------------------------
            Reporter:  jinmei        |                        Owner:
                Type:  task          |  jinmei
            Priority:  medium        |                       Status:
           Component:  data source   |  reviewing
            Keywords:                |                    Milestone:
           Sensitive:  0             |  Sprint-20130122
         Sub-Project:  DNS           |                   Resolution:
Estimated Difficulty:  3             |                 CVSS Scoring:
         Total Hours:  0             |              Defect Severity:  N/A
                                     |  Feature Depending on Ticket:
                                     |  loadzone-ng
                                     |          Add Hours to Ticket:  0
                                     |                    Internal?:  0
-------------------------------------+-------------------------------------
Changes (by vorner):

 * owner:  vorner => jinmei


Comment:

 Hello

 I think these comments are little bit confused. The first one says it
 should return `false`, but then there's `EXPECT_TRUE` after it. The second
 one says it should return `false`, but because it exists, however, if I
 understand it correctly, the zone actually doesn't exist at the time.
 {{{#!c++
     // Deleting an existing zone; it should work and return false (not
     // previously existent)
     EXPECT_TRUE(this->client_->deleteZone(this->zname_));

     // Now it's not found by findZone
     EXPECT_EQ(result::NOTFOUND,
 this->client_->findZone(this->zname_).code);

     // And the second call should return false since it now exists
     this->allowMoreTransaction(true);
     EXPECT_FALSE(this->client_->deleteZone(this->zname_));
 }}}

 This comment seems to be a copy-paste. I don't see anything failing in
 here.
 {{{#!c++
 TYPED_TEST(DatabaseClientTest, deleteZoneRollbackOnNotFind) {
     // attempt of deleting non-existent zone.  result in false
     const Name new_name("example.com");
     EXPECT_FALSE(this->client_->deleteZone(new_name));

     // deleteZone started a transaction, but since it failed,
     // it should have been rolled back, and the next attempt should
 succeed
     this->allowMoreTransaction(true);
     EXPECT_TRUE(this->client_->deleteZone(this->zname_));
 }
 }}}

 Also, what is the ticket to actually use it? Should there be python
 interface?

-- 
Ticket URL: <https://bind10.isc.org/ticket/2575#comment:9>
BIND 10 Development <http://bind10.isc.org>
BIND 10 Development


More information about the bind10-tickets mailing list