Browse Source

[master] revert

Francis Dupont 8 years ago
parent
commit
a6d16a9dec

File diff suppressed because it is too large
+ 592 - 597
doc/guide/ddns.xml


+ 1 - 12
src/bin/agent/kea-ctrl-agent.xml

@@ -52,8 +52,7 @@
       <arg><option>-V</option></arg>
       <arg><option>-V</option></arg>
       <arg><option>-W</option></arg>
       <arg><option>-W</option></arg>
       <arg><option>-d</option></arg>
       <arg><option>-d</option></arg>
-      <arg><option>-c<replaceable class="parameter">config-file</replaceable></option></arg>
-      <arg><option>-t<replaceable class="parameter">config-file</replaceable></option></arg>
+      <arg><option>-s</option></arg>
     </cmdsynopsis>
     </cmdsynopsis>
   </refsynopsisdiv>
   </refsynopsisdiv>
 
 
@@ -116,16 +115,6 @@
         </para></listitem>
         </para></listitem>
       </varlistentry>
       </varlistentry>
 
 
-      <varlistentry>
-        <term><option>-t</option></term>
-        <listitem><para>
-          Check the syntax of the configuration file and report the
-          first error if any. Note that not all parameters are
-          completely checked, in particular, service and client
-          sockets are not opened, and hook libraries are not loaded.
-        </para></listitem>
-      </varlistentry>
-
     </variablelist>
     </variablelist>
   </refsect1>
   </refsect1>
 
 

+ 11 - 11
src/bin/d2/kea-dhcp-ddns.xml

@@ -2,7 +2,7 @@
                "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"
                "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"
                [<!ENTITY mdash "&#8212;">]>
                [<!ENTITY mdash "&#8212;">]>
 <!--
 <!--
- - Copyright (C) 2013-2017 Internet Systems Consortium, Inc. ("ISC")
+ - Copyright (C) 2013-2016 Internet Systems Consortium, Inc. ("ISC")
  -
  -
  - This Source Code Form is subject to the terms of the Mozilla Public
  - This Source Code Form is subject to the terms of the Mozilla Public
  - License, v. 2.0. If a copy of the MPL was not distributed with this
  - License, v. 2.0. If a copy of the MPL was not distributed with this
@@ -52,8 +52,8 @@
       <arg><option>-V</option></arg>
       <arg><option>-V</option></arg>
       <arg><option>-W</option></arg>
       <arg><option>-W</option></arg>
       <arg><option>-d</option></arg>
       <arg><option>-d</option></arg>
-      <arg><option>-c<replaceable class="parameter">config-file</replaceable></option></arg>
-      <arg><option>-t<replaceable class="parameter">config-file</replaceable></option></arg>
+      <!-- not yet <arg><option>-t</option></arg> -->
+      <arg><option>-c</option></arg>
     </cmdsynopsis>
     </cmdsynopsis>
   </refsynopsisdiv>
   </refsynopsisdiv>
 
 
@@ -105,21 +105,21 @@
         </para></listitem>
         </para></listitem>
       </varlistentry>
       </varlistentry>
 
 
+<!-- not yet
       <varlistentry>
       <varlistentry>
-        <term><option>-c</option></term>
+        <term><option>-t</option></term>
         <listitem><para>
         <listitem><para>
-          Configuration file including the configuration for DHCP-DDNS server.
-          It may also contain configuration entries for other Kea services.
+          Check the syntax of the configuration file and report the first
+          error if any.
         </para></listitem>
         </para></listitem>
       </varlistentry>
       </varlistentry>
+-->
 
 
       <varlistentry>
       <varlistentry>
-        <term><option>-t</option></term>
+        <term><option>-c</option></term>
         <listitem><para>
         <listitem><para>
-          Check the syntax of the configuration file and report the
-          first error if any. Note that not all parameters are
-          completely checked, in particular, service socket is
-          not opened.
+          Configuration file including the configuration for DHCP-DDNS server.
+          It may also contain configuration entries for other Kea services.
         </para></listitem>
         </para></listitem>
       </varlistentry>
       </varlistentry>
 
 

+ 1 - 1
src/bin/d2/main.cc

@@ -1,4 +1,4 @@
-// Copyright (C) 2013-2017 Internet Systems Consortium, Inc. ("ISC")
+// Copyright (C) 2013-2016 Internet Systems Consortium, Inc. ("ISC")
 //
 //
 // This Source Code Form is subject to the terms of the Mozilla Public
 // This Source Code Form is subject to the terms of the Mozilla Public
 // License, v. 2.0. If a copy of the MPL was not distributed with this
 // License, v. 2.0. If a copy of the MPL was not distributed with this

+ 2 - 7
src/lib/process/d_controller.cc

@@ -150,12 +150,12 @@ void
 DControllerBase::parseArgs(int argc, char* argv[])
 DControllerBase::parseArgs(int argc, char* argv[])
 {
 {
     // Iterate over the given command line options. If its a stock option
     // Iterate over the given command line options. If its a stock option
-    // ("c" or "d") handle it here.  If its a valid custom option, then
+    // ("s" or "v") handle it here.  If its a valid custom option, then
     // invoke customOption.
     // invoke customOption.
     int ch;
     int ch;
     opterr = 0;
     opterr = 0;
     optind = 1;
     optind = 1;
-    std::string opts("dvVWc:t:" + getCustomOpts());
+    std::string opts("dvVWc:" + getCustomOpts());
     while ((ch = getopt(argc, argv, opts.c_str())) != -1) {
     while ((ch = getopt(argc, argv, opts.c_str())) != -1) {
         switch (ch) {
         switch (ch) {
         case 'd':
         case 'd':
@@ -182,17 +182,12 @@ DControllerBase::parseArgs(int argc, char* argv[])
             break;
             break;
 
 
         case 'c':
         case 'c':
-        case 't':
             // config file name
             // config file name
             if (optarg == NULL) {
             if (optarg == NULL) {
                 isc_throw(InvalidUsage, "configuration file name missing");
                 isc_throw(InvalidUsage, "configuration file name missing");
             }
             }
 
 
             setConfigFile(optarg);
             setConfigFile(optarg);
-
-            if (ch == 't') {
-                check_only_ = true;
-            }
             break;
             break;
 
 
         case '?': {
         case '?': {

+ 12 - 30
src/lib/process/d_controller.h

@@ -34,7 +34,7 @@ public:
 /// Since command line argument parsing is done as part of
 /// Since command line argument parsing is done as part of
 /// DControllerBase::launch(), it uses this exception to propagate
 /// DControllerBase::launch(), it uses this exception to propagate
 /// version information up to main(), when command line argument
 /// version information up to main(), when command line argument
-/// -v, -V or -W is given.
+/// -v or -V is given.
 class VersionMessage : public isc::Exception {
 class VersionMessage : public isc::Exception {
 public:
 public:
     VersionMessage(const char* file, size_t line, const char* what) :
     VersionMessage(const char* file, size_t line, const char* what) :
@@ -128,7 +128,7 @@ public:
     /// arguments.
     /// arguments.
     ///
     ///
     /// This function can be run in "test mode". It prevents initialization
     /// This function can be run in "test mode". It prevents initialization
-    /// of module logger. This is used in unit tests which initialize logger
+    /// of D2 module logger. This is used in unit tests which initialize logger
     /// in their main function. Such a logger uses environmental variables to
     /// in their main function. Such a logger uses environmental variables to
     /// control severity, verbosity etc.
     /// control severity, verbosity etc.
     ///
     ///
@@ -223,10 +223,10 @@ public:
     /// @return an Element that contains the results of command composed
     /// @return an Element that contains the results of command composed
     /// of an integer status value and a string explanation of the outcome.
     /// of an integer status value and a string explanation of the outcome.
     /// The status value is one of the following:
     /// The status value is one of the following:
-    ///   COMMAND_SUCCESS - Command executed successfully
-    ///   COMMAND_ERROR - Command is valid but suffered an operational
+    ///   D2::COMMAND_SUCCESS - Command executed successfully
+    ///   D2::COMMAND_ERROR - Command is valid but suffered an operational
     ///   failure.
     ///   failure.
-    ///   COMMAND_INVALID - Command is not recognized as valid be either
+    ///   D2::COMMAND_INVALID - Command is not recognized as valid be either
     ///   the controller or the application process.
     ///   the controller or the application process.
     virtual isc::data::ConstElementPtr executeCommand(const std::string&
     virtual isc::data::ConstElementPtr executeCommand(const std::string&
                                                       command,
                                                       command,
@@ -283,10 +283,10 @@ protected:
     /// @return an Element that contains the results of command composed
     /// @return an Element that contains the results of command composed
     /// of an integer status value and a string explanation of the outcome.
     /// of an integer status value and a string explanation of the outcome.
     /// The status value is one of the following:
     /// The status value is one of the following:
-    ///   COMMAND_SUCCESS - Command executed successfully
-    ///   COMMAND_ERROR - Command is valid but suffered an operational
+    ///   D2::COMMAND_SUCCESS - Command executed successfully
+    ///   D2::COMMAND_ERROR - Command is valid but suffered an operational
     ///   failure.
     ///   failure.
-    ///   COMMAND_INVALID - Command is not recognized as a valid custom
+    ///   D2::COMMAND_INVALID - Command is not recognized as a valid custom
     ///   controller command.
     ///   controller command.
     virtual isc::data::ConstElementPtr customControllerCommand(
     virtual isc::data::ConstElementPtr customControllerCommand(
             const std::string& command, isc::data::ConstElementPtr args);
             const std::string& command, isc::data::ConstElementPtr args);
@@ -302,7 +302,7 @@ protected:
 
 
     /// @brief Virtual method which returns a string containing the option
     /// @brief Virtual method which returns a string containing the option
     /// letters for any custom command line options supported by the derivation.
     /// letters for any custom command line options supported by the derivation.
-    /// These are added to the stock options of "c", "d", ..., during command
+    /// These are added to the stock options of "c" and "v" during command
     /// line interpretation.
     /// line interpretation.
     ///
     ///
     /// @return returns a string containing the custom option letters.
     /// @return returns a string containing the custom option letters.
@@ -342,20 +342,6 @@ protected:
         verbose_ = value;
         verbose_ = value;
     }
     }
 
 
-    /// @brief Supplies whether or not check only mode is enabled.
-    ///
-    /// @return returns true if check only is enabled.
-    bool isCheckOnly() const {
-        return (check_only_);
-    }
-
-    /// @brief Method for enabling or disabling check only mode.
-    ///
-    /// @param value is the new value to assign the flag.
-    void setCheckOnly(bool value) {
-        check_only_ = value;
-    }
-
     /// @brief Getter for fetching the controller's IOService
     /// @brief Getter for fetching the controller's IOService
     ///
     ///
     /// @return returns a pointer reference to the IOService.
     /// @return returns a pointer reference to the IOService.
@@ -399,15 +385,14 @@ protected:
     /// list of options with those returned by getCustomOpts(), and uses
     /// list of options with those returned by getCustomOpts(), and uses
     /// cstdlib's getopt to loop through the command line.
     /// cstdlib's getopt to loop through the command line.
     /// It handles stock options directly, and passes any custom options into
     /// It handles stock options directly, and passes any custom options into
-    /// the customOption method.  Currently there are only some stock options
-    /// -c/t for specifying the configuration file, -d for verbose logging,
-    /// and -v/V/W for version reports.
+    /// the customOption method.  Currently there are only two stock options
+    /// -c for specifying the configuration file, and -v for verbose logging.
     ///
     ///
     /// @param argc  is the number of command line arguments supplied
     /// @param argc  is the number of command line arguments supplied
     /// @param argv  is the array of string (char *) command line arguments
     /// @param argv  is the array of string (char *) command line arguments
     ///
     ///
     /// @throw InvalidUsage when there are usage errors.
     /// @throw InvalidUsage when there are usage errors.
-    /// @throw VersionMessage if the -v, -V or -W arguments is given.
+    /// @throw VersionMessage if the -v or -V arguments is given.
     void parseArgs(int argc, char* argv[]);
     void parseArgs(int argc, char* argv[]);
 
 
 
 
@@ -551,9 +536,6 @@ private:
     /// @brief Indicates if the verbose logging mode is enabled.
     /// @brief Indicates if the verbose logging mode is enabled.
     bool verbose_;
     bool verbose_;
 
 
-    /// @brief Indicates if the check only mode is enabled.
-    bool check_only_;
-
     /// @brief The absolute file name of the JSON spec file.
     /// @brief The absolute file name of the JSON spec file.
     std::string spec_file_name_;
     std::string spec_file_name_;