]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[2203] renamed datasrc_configurator to datasrc_config; it represents it better.
authorJINMEI Tatuya <jinmei@isc.org>
Fri, 5 Oct 2012 17:12:42 +0000 (10:12 -0700)
committerJINMEI Tatuya <jinmei@isc.org>
Thu, 11 Oct 2012 17:04:30 +0000 (10:04 -0700)
src/bin/auth/Makefile.am
src/bin/auth/benchmarks/Makefile.am
src/bin/auth/benchmarks/query_bench.cc
src/bin/auth/datasrc_config.cc [moved from src/bin/auth/datasrc_configurator.cc with 97% similarity]
src/bin/auth/datasrc_config.h [moved from src/bin/auth/datasrc_configurator.h with 97% similarity]
src/bin/auth/main.cc
src/bin/auth/tests/Makefile.am
src/bin/auth/tests/auth_srv_unittest.cc
src/bin/auth/tests/command_unittest.cc
src/bin/auth/tests/datasrc_config_unittest.cc [moved from src/bin/auth/tests/datasrc_configurator_unittest.cc with 92% similarity]

index df30a428db996d05e6d24105b5edae4d25f41254..9eee9d4d54af5fcfb79743762da1ea5453418971 100644 (file)
@@ -55,7 +55,7 @@ b10_auth_SOURCES += auth_config.cc auth_config.h
 b10_auth_SOURCES += command.cc command.h
 b10_auth_SOURCES += common.h common.cc
 b10_auth_SOURCES += statistics.cc statistics.h
-b10_auth_SOURCES += datasrc_configurator.h datasrc_configurator.cc
+b10_auth_SOURCES += datasrc_config.h datasrc_config.cc
 b10_auth_SOURCES += main.cc
 
 nodist_b10_auth_SOURCES = auth_messages.h auth_messages.cc
index fcfcb8add4df699d5828e4eebe236b22070289a9..c525b665d330d361aa49fcd1ebd5ac14aa3e0ccf 100644 (file)
@@ -17,7 +17,7 @@ query_bench_SOURCES += ../auth_srv.h ../auth_srv.cc
 query_bench_SOURCES += ../auth_config.h ../auth_config.cc
 query_bench_SOURCES += ../statistics.h ../statistics.cc
 query_bench_SOURCES += ../auth_log.h ../auth_log.cc
-query_bench_SOURCES += ../datasrc_configurator.h ../datasrc_configurator.cc
+query_bench_SOURCES += ../datasrc_config.h ../datasrc_config.cc
 
 nodist_query_bench_SOURCES = ../auth_messages.h ../auth_messages.cc
 
index 07111a56d41f72b513997c2697ee6f2d6802c18b..73f702baff11f135ae2876714f5daac66baf463e 100644 (file)
@@ -30,7 +30,7 @@
 
 #include <auth/auth_srv.h>
 #include <auth/auth_config.h>
-#include <auth/datasrc_configurator.h>
+#include <auth/datasrc_config.h>
 #include <auth/query.h>
 
 #include <asiodns/asiodns.h>
similarity index 97%
rename from src/bin/auth/datasrc_configurator.cc
rename to src/bin/auth/datasrc_config.cc
index 5469389a0e63df0cbbb2d88ca7974abfabd04aae..73fb5190c6b885e2270659fe2f547c7598365612 100644 (file)
@@ -14,7 +14,7 @@
 
 #include <cc/data.h>
 #include "auth_srv.h"
-#include "datasrc_configurator.h"
+#include "datasrc_config.h"
 
 // This is a trivial specialization for the commonly used version.
 // Defined in .cc to avoid accidental creation of multiple copies.
similarity index 97%
rename from src/bin/auth/datasrc_configurator.h
rename to src/bin/auth/datasrc_config.h
index b8d21f3e989fe18a2539903aca9d2f853b562952..79ace2811a79ed103cd17501d6ba19527577cfbb 100644 (file)
@@ -12,8 +12,8 @@
 // OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
 // PERFORMANCE OF THIS SOFTWARE.
 
-#ifndef DATASRC_CONFIGURATOR_H
-#define DATASRC_CONFIGURATOR_H
+#ifndef DATASRC_CONFIG_H
+#define DATASRC_CONFIG_H
 
 #include "auth_srv.h"
 
@@ -108,12 +108,12 @@ configureDataSourceGeneric(Server& server,
     }
 }
 
-/// \brief Concrete version of DataSourceConfiguratorGeneric for the
+/// \brief Concrete version of configureDataSource() for the
 ///     use with authoritative server implementation.
 void
 configureDataSource(AuthSrv& server, const isc::data::ConstElementPtr& config);
 
-#endif
+#endif  // DATASRC_CONFIG_H
 
 // Local Variables:
 // mode: c++
index 8431a488a2e5ecf214c5ba10ef5f6b05092e6f32..b425813006fe36c81efb1657b4b44d166388621d 100644 (file)
@@ -34,7 +34,7 @@
 #include <auth/command.h>
 #include <auth/auth_srv.h>
 #include <auth/auth_log.h>
-#include <auth/datasrc_configurator.h>
+#include <auth/datasrc_config.h>
 #include <asiodns/asiodns.h>
 #include <asiolink/asiolink.h>
 #include <log/logger_support.h>
index 3b1873678c52fa7dc5ba07365bb5fc415d856b86..6b9d385298d34651a8d62c12875e7f3febf593e7 100644 (file)
@@ -42,7 +42,7 @@ run_unittests_SOURCES += ../auth_config.h ../auth_config.cc
 run_unittests_SOURCES += ../command.h ../command.cc
 run_unittests_SOURCES += ../common.h ../common.cc
 run_unittests_SOURCES += ../statistics.h ../statistics.cc
-run_unittests_SOURCES += ../datasrc_configurator.h ../datasrc_configurator.cc
+run_unittests_SOURCES += ../datasrc_config.h ../datasrc_config.cc
 run_unittests_SOURCES += datasrc_util.h datasrc_util.cc
 run_unittests_SOURCES += auth_srv_unittest.cc
 run_unittests_SOURCES += config_unittest.cc
@@ -51,7 +51,7 @@ run_unittests_SOURCES += command_unittest.cc
 run_unittests_SOURCES += common_unittest.cc
 run_unittests_SOURCES += query_unittest.cc
 run_unittests_SOURCES += statistics_unittest.cc
-run_unittests_SOURCES += datasrc_configurator_unittest.cc
+run_unittests_SOURCES += datasrc_config_unittest.cc
 run_unittests_SOURCES += run_unittests.cc
 
 nodist_run_unittests_SOURCES = ../auth_messages.h ../auth_messages.cc
index d462a3fd769543f695ba6b2a5ec8dc4edbca6d38..60a9a2ac382337be14b9d4c837ebf752cbbbeb30 100644 (file)
@@ -36,7 +36,7 @@
 #include <auth/command.h>
 #include <auth/common.h>
 #include <auth/statistics.h>
-#include <auth/datasrc_configurator.h>
+#include <auth/datasrc_config.h>
 
 #include <util/unittests/mock_socketsession.h>
 #include <util/threads/lock.h>
index c7465263eafd8321491d4c9bccedd2fb80f36074..c7994831a5f5e8c5f8ea4e2cba647f49a2757007 100644 (file)
@@ -19,7 +19,7 @@
 #include <auth/auth_srv.h>
 #include <auth/auth_config.h>
 #include <auth/command.h>
-#include <auth/datasrc_configurator.h>
+#include <auth/datasrc_config.h>
 
 #include <dns/name.h>
 #include <dns/rrclass.h>
similarity index 92%
rename from src/bin/auth/tests/datasrc_configurator_unittest.cc
rename to src/bin/auth/tests/datasrc_config_unittest.cc
index f2945364754d47c1eaf94df457bef92ea0520a3a..3d3aa58b910e0077534565fd25fff5459f5a0230 100644 (file)
@@ -12,7 +12,7 @@
 // OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
 // PERFORMANCE OF THIS SOFTWARE.
 
-#include <auth/datasrc_configurator.h>
+#include <auth/datasrc_config.h>
 
 #include <config/tests/fake_session.h>
 #include <config/ccsession.h>
@@ -35,7 +35,7 @@ using namespace boost;
 
 namespace {
 
-class DatasrcConfiguratorTest;
+class DatasrcConfigTest;
 
 class FakeList {
 public:
@@ -61,17 +61,16 @@ private:
 typedef shared_ptr<FakeList> ListPtr;
 
 void
-testConfigureDataSource(DatasrcConfiguratorTest& test,
+testConfigureDataSource(DatasrcConfigTest& test,
                         const isc::data::ConstElementPtr& config)
 {
     // We use the test fixture for the Server type.  This makes it possible
     // to easily fake all needed methods and look that they were called.
-    configureDataSourceGeneric<DatasrcConfiguratorTest, FakeList>(test,
-                                                                  config);
+    configureDataSourceGeneric<DatasrcConfigTest, FakeList>(test, config);
 }
 
 void
-datasrcConfigHandler(DatasrcConfiguratorTest* fake_server, const std::string&,
+datasrcConfigHandler(DatasrcConfigTest* fake_server, const std::string&,
                      isc::data::ConstElementPtr config,
                      const isc::config::ConfigData&)
 {
@@ -80,7 +79,7 @@ datasrcConfigHandler(DatasrcConfiguratorTest* fake_server, const std::string&,
     }
 }
 
-class DatasrcConfiguratorTest : public ::testing::Test {
+class DatasrcConfigTest : public ::testing::Test {
 public:
     // These pretend to be the server
     ListPtr getClientList(const RRClass& rrclass) {
@@ -104,7 +103,7 @@ public:
         return (mutex_);
     }
 protected:
-    DatasrcConfiguratorTest() :
+    DatasrcConfigTest() :
         session(ElementPtr(new ListElement), ElementPtr(new ListElement),
                 ElementPtr(new ListElement)),
         specfile(string(TEST_OWN_DATA_DIR) + "/spec.spec")
@@ -162,11 +161,11 @@ protected:
 };
 
 // Push there a configuration with a single list.
-TEST_F(DatasrcConfiguratorTest, createList) {
+TEST_F(DatasrcConfigTest, createList) {
     initializeINList();
 }
 
-TEST_F(DatasrcConfiguratorTest, modifyList) {
+TEST_F(DatasrcConfigTest, modifyList) {
     // First, initialize the list
     initializeINList();
     // And now change the configuration of the list
@@ -184,7 +183,7 @@ TEST_F(DatasrcConfiguratorTest, modifyList) {
 }
 
 // Check we can have multiple lists at once
-TEST_F(DatasrcConfiguratorTest, multiple) {
+TEST_F(DatasrcConfigTest, multiple) {
     const ElementPtr
         config(buildConfig("{\"IN\": [{\"type\": \"yyy\"}], "
                                  "\"CH\": [{\"type\": \"xxx\"}]}"));
@@ -204,7 +203,7 @@ TEST_F(DatasrcConfiguratorTest, multiple) {
 //
 // It's almost like above, but we initialize first with single-list
 // config.
-TEST_F(DatasrcConfiguratorTest, updateAdd) {
+TEST_F(DatasrcConfigTest, updateAdd) {
     initializeINList();
     const ElementPtr
         config(buildConfig("{\"IN\": [{\"type\": \"yyy\"}], "
@@ -222,7 +221,7 @@ TEST_F(DatasrcConfiguratorTest, updateAdd) {
 }
 
 // We delete a class list in this test.
-TEST_F(DatasrcConfiguratorTest, updateDelete) {
+TEST_F(DatasrcConfigTest, updateDelete) {
     initializeINList();
     const ElementPtr
         config(buildConfig("{}"));
@@ -239,7 +238,7 @@ TEST_F(DatasrcConfiguratorTest, updateDelete) {
 }
 
 // Check that we can rollback an addition if something else fails
-TEST_F(DatasrcConfiguratorTest, rollbackAddition) {
+TEST_F(DatasrcConfigTest, rollbackAddition) {
     initializeINList();
     // The configuration is wrong. However, the CH one will get done first.
     const ElementPtr
@@ -258,7 +257,7 @@ TEST_F(DatasrcConfiguratorTest, rollbackAddition) {
 }
 
 // Check that we can rollback a deletion if something else fails
-TEST_F(DatasrcConfiguratorTest, rollbackDeletion) {
+TEST_F(DatasrcConfigTest, rollbackDeletion) {
     initializeINList();
     // Put the CH there
     const ElementPtr
@@ -279,7 +278,7 @@ TEST_F(DatasrcConfiguratorTest, rollbackDeletion) {
 
 // Check that we can roll back configuration change if something
 // fails later on.
-TEST_F(DatasrcConfiguratorTest, rollbackConfiguration) {
+TEST_F(DatasrcConfigTest, rollbackConfiguration) {
     initializeINList();
     // Put the CH there
     const ElementPtr