BIND 10 trac761, updated. 1efa5d9d7f699cc3ee636d4e1b50b3fb3a863180 [trac761] address stephen's comments

BIND 10 source code commits bind10-changes at lists.isc.org
Thu Jun 23 07:58:49 UTC 2011


The branch, trac761 has been updated
       via  1efa5d9d7f699cc3ee636d4e1b50b3fb3a863180 (commit)
       via  aaad42c52aed2c3890378511ecb2f97a3731d23a (commit)
       via  4beebf47805d0c3f80872e8f690f09c1658ae4e2 (commit)
       via  61b01087195d5d1f875f01c5fd2eac5dc61d012d (commit)
      from  189f58f73fe02cf2729ab26d6ce8ab6469e82a1c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 1efa5d9d7f699cc3ee636d4e1b50b3fb3a863180
Author: Jelte Jansen <jelte at isc.org>
Date:   Wed Jun 22 21:31:31 2011 +0200

    [trac761] address stephen's comments

commit aaad42c52aed2c3890378511ecb2f97a3731d23a
Author: Jelte Jansen <jelte at isc.org>
Date:   Wed Jun 22 21:08:08 2011 +0200

    [trac761] message file cleanups
    
    - alphabetized the messages
    - removed redundant whitespace
    - removed $PREFIX
    - fixed initial no namespace comment

commit 4beebf47805d0c3f80872e8f690f09c1658ae4e2
Author: Jelte Jansen <jelte at isc.org>
Date:   Wed Jun 22 21:03:39 2011 +0200

    [trac761] rename xfrindef.mes to xfrin_messages.mes

commit 61b01087195d5d1f875f01c5fd2eac5dc61d012d
Author: Jelte Jansen <jelte at isc.org>
Date:   Tue Jun 21 18:20:33 2011 +0200

    [trac761] message text should start with lowercase

-----------------------------------------------------------------------

Summary of changes:
 src/bin/xfrin/Makefile.am                          |   12 ++--
 src/bin/xfrin/xfrin.py.in                          |    9 +--
 src/bin/xfrin/{xfrindef.mes => xfrin_messages.mes} |   95 ++++++++++----------
 3 files changed, 56 insertions(+), 60 deletions(-)
 rename src/bin/xfrin/{xfrindef.mes => xfrin_messages.mes} (64%)

-----------------------------------------------------------------------
diff --git a/src/bin/xfrin/Makefile.am b/src/bin/xfrin/Makefile.am
index e6c9a2f..0af9be6 100644
--- a/src/bin/xfrin/Makefile.am
+++ b/src/bin/xfrin/Makefile.am
@@ -6,13 +6,13 @@ pkglibexec_SCRIPTS = b10-xfrin
 
 b10_xfrindir = $(pkgdatadir)
 b10_xfrin_DATA = xfrin.spec
-pyexec_DATA = xfrindef.py
+pyexec_DATA = xfrin_messages.py
 
-CLEANFILES = b10-xfrin xfrin.pyc xfrinlog.py xfrindef.py xfrindef.pyc
+CLEANFILES = b10-xfrin xfrin.pyc xfrinlog.py xfrin_messages.py xfrin_messages.pyc
 
 man_MANS = b10-xfrin.8
 EXTRA_DIST = $(man_MANS) b10-xfrin.xml
-EXTRA_DIST += xfrin.spec xfrindef.mes
+EXTRA_DIST += xfrin.spec xfrin_messages.mes
 
 if ENABLE_MAN
 
@@ -22,11 +22,11 @@ b10-xfrin.8: b10-xfrin.xml
 endif
 
 # Define rule to build logging source files from message file
-xfrindef.py: xfrindef.mes
-	$(top_builddir)/src/lib/log/compiler/message -p $(top_srcdir)/src/bin/xfrin/xfrindef.mes
+xfrin_messages.py: xfrin_messages.mes
+	$(top_builddir)/src/lib/log/compiler/message -p $(top_srcdir)/src/bin/xfrin/xfrin_messages.mes
 
 # this is done here since configure.ac AC_OUTPUT doesn't expand exec_prefix
-b10-xfrin: xfrin.py xfrindef.py
+b10-xfrin: xfrin.py xfrin_messages.py
 	$(SED) -e "s|@@PYTHONPATH@@|@pyexecdir@|" \
 	       -e "s|@@LOCALSTATEDIR@@|$(localstatedir)|" xfrin.py >$@
 	chmod a+x $@
diff --git a/src/bin/xfrin/xfrin.py.in b/src/bin/xfrin/xfrin.py.in
index f61301b..64e3563 100755
--- a/src/bin/xfrin/xfrin.py.in
+++ b/src/bin/xfrin/xfrin.py.in
@@ -29,10 +29,10 @@ from isc.config.ccsession import *
 from isc.notify import notify_out
 import isc.util.process
 import isc.net.parse
-from xfrindef import *
+from xfrin_messages import *
 
 isc.log.init("b10-xfrin")
-logger = isc.log.Logger("b10-xfrin")
+logger = isc.log.Logger("xfrin")
 
 try:
     from pydnspp import *
@@ -74,9 +74,6 @@ __version__ = 'BIND10'
 XFRIN_OK = 0
 XFRIN_FAIL = 1
 
-def log_error(msg):
-    raise DONOTCALLMEEVER
-
 class XfrinException(Exception):
     pass
 
@@ -281,7 +278,7 @@ class XfrinConnection(asyncore.dispatcher):
             ret = XFRIN_FAIL
             #TODO, recover data source.
         except isc.datasrc.sqlite3_ds.Sqlite3DSError as e:
-            logger.error(XFRIN_AXFR_DB_FAILURE, self._zone_name, str(e))
+            logger.error(XFRIN_AXFR_DATABASE_FAILURE, self._zone_name, str(e))
             ret = XFRIN_FAIL
         except UserWarning as e:
             # XXX: this is an exception from our C++ library via the
diff --git a/src/bin/xfrin/xfrin_messages.mes b/src/bin/xfrin/xfrin_messages.mes
new file mode 100644
index 0000000..80a0be3
--- /dev/null
+++ b/src/bin/xfrin/xfrin_messages.mes
@@ -0,0 +1,91 @@
+# Copyright (C) 2011  Internet Systems Consortium, Inc. ("ISC")
+#
+# Permission to use, copy, modify, and/or distribute this software for any
+# purpose with or without fee is hereby granted, provided that the above
+# copyright notice and this permission notice appear in all copies.
+#
+# THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
+# REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
+# AND FITNESS.  IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
+# INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+# LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
+# OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+# PERFORMANCE OF THIS SOFTWARE.
+
+# No namespace declaration - these constants go in the global namespace
+# of the xfrin messages python module.
+
+% XFRIN_AXFR_INTERNAL_FAILURE AXFR transfer of zone %1 failed: %2
+The AXFR transfer for the given zone has failed due to an internal
+problem in the bind10 python wrapper library.
+The error is shown in the log message.
+
+% XFRIN_AXFR_DATABASE_FAILURE AXFR transfer of zone %1 failed: %2
+The AXFR transfer for the given zone has failed due to a database problem.
+The error is shown in the log message.
+
+% XFRIN_AXFR_TRANSFER_FAILURE AXFR transfer of zone %1 failed: %2
+The AXFR transfer for the given zone has failed due to a protocol error.
+The error is shown in the log message.
+
+% XFRIN_AXFR_TRANSFER_STARTED AXFR transfer of zone %1 started
+A connection to the master server has been made, the serial value in
+the SOA record has been checked, and a zone transfer has been started.
+
+% XFRIN_AXFR_TRANSFER_SUCCESS AXFR transfer of zone %1 succeeded
+The AXFR transfer of the given zone was successfully completed.
+
+% XFRIN_BAD_MASTER_ADDR_FORMAT bad format for master address: %1
+The given master address is not a valid IP address.
+
+% XFRIN_BAD_MASTER_PORT_FORMAT bad format for master port: %1
+The master port as read from the configuration is not a valid port number.
+
+% XFRIN_BAD_TSIG_KEY_STRING bad TSIG key string: %1
+The TSIG key string as read from the configuration does not represent
+a valid TSIG key.
+
+% XFRIN_BAD_ZONE_CLASS Invalid zone class: %1
+The zone class as read from the configuration is not a valid DNS class.
+
+% XFRIN_CC_SESSION_ERROR error reading from cc channel: %1
+There was a problem reading from the command and control channel. The
+most likely cause is that xfrin the msgq daemon is not running.
+
+% XFRIN_COMMAND_ERROR error while executing command '%1': %2
+There was an error while the given command was being processed. The
+error is given in the log message.
+
+% XFRIN_CONNECT_MASTER error connecting to master at %1: %2
+There was an error opening a connection to the master. The error is
+shown in the log message.
+
+% XFRIN_MSGQ_SEND_ERROR error while contacting %1 and %2
+There was a problem sending a message to the xfrout module or the
+zone manager. This most likely means that the msgq daemon has quit or
+was killed.
+
+% XFRIN_MSGQ_SEND_ERROR_ZONE_MANAGER error while contacting %1
+There was a problem sending a message to the zone manager. This most
+likely means that the msgq daemon has quit or was killed.
+
+% XFRIN_IMPORT_DNS error importing python DNS module: %1
+There was an error importing the python DNS module pydnspp. The most
+likely cause is a PYTHONPATH problem.
+
+% XFRIN_RETRANSFER_UNKNOWN_ZONE got notification to retransfer unknown zone %1
+There was an internal command to retransfer the given zone, but the
+zone is not known to the system. This may indicate that the configuration
+for xfrin is incomplete, or there was a typographical error in the
+zone name in the configuration.
+
+% XFRIN_STARTING starting resolver with command line '%1'
+An informational message, this is output when the resolver starts up.
+
+% XFRIN_STOPPED_BY_KEYBOARD keyboard interrupt, shutting down
+There was a keyboard interrupt signal to stop the xfrin daemon. The
+daemon will now shut down.
+
+% XFRIN_UNKNOWN_ERROR unknown error: %1
+An uncaught exception was raised while running the xfrin daemon. The
+exception message is printed in the log message.
diff --git a/src/bin/xfrin/xfrindef.mes b/src/bin/xfrin/xfrindef.mes
deleted file mode 100644
index 8c6b3f0..0000000
--- a/src/bin/xfrin/xfrindef.mes
+++ /dev/null
@@ -1,92 +0,0 @@
-# Copyright (C) 2011  Internet Systems Consortium, Inc. ("ISC")
-#
-# Permission to use, copy, modify, and/or distribute this software for any
-# purpose with or without fee is hereby granted, provided that the above
-# copyright notice and this permission notice appear in all copies.
-#
-# THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
-# REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
-# AND FITNESS.  IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
-# INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
-# LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
-# OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
-# PERFORMANCE OF THIS SOFTWARE.
-
-$PREFIX XFRIN_
-# No namespace declaration - these constants go in the global namespace
-# along with the resolver methods.
-
-% STARTING      starting resolver with command line '%1'
-An informational message, this is output when the resolver starts up.
-
-% IMPORT_DNS    Error importing python DNS module: %1
-There was an error importing the python DNS module pydnspp. The most
-likely cause is a PYTHONPATH problem.
-
-% CONNECT_MASTER Error connecting to master at %1: %2
-There was an error opening a connection to the master. The error is
-shown in the log message.
-
-% AXFR_TRANSFER_STARTED AXFR Transfer of zone %1 started
-A connection to the master server has been made, the serial value in
-the SOA record has been checked, and a zone transfer has been started.
-
-% AXFR_TRANSFER_SUCCESS AXFR Transfer of zone %1 succeeded
-The AXFR transfer of the given zone was successfully completed.
-
-% AXFR_TRANSFER_FAILURE AXFR Transfer of zone %1 failed: %2
-The AXFR transfer for the given zone has failed due to a protocol error.
-The error is shown in the log message.
-
-% AXFR_DB_FAILURE AXFR Transfer of zone %1 failed: %2
-The AXFR transfer for the given zone has failed due to a database problem.
-The error is shown in the log message.
-
-% AXFR_INTERNAL_FAILURE AXFR Transfer of zone %1 failed: %2
-The AXFR transfer for the given zone has failed due to an internal
-problem in the bind10 python wrapper library.
-The error is shown in the log message.
-
-% BAD_MASTER_ADDR_FORMAT Bad format for master address: %1
-The given master address is not a valid IP address
-
-% BAD_MASTER_PORT_FORMAT Bad format for master port: %1
-The given master port is not a valid port number
-
-% BAD_ZONE_CLASS Invalid zone class: %1
-The given zone class is not a valid DNS class.
-
-% BAD_TSIG_KEY_STRING Bad TSIG key string: %1
-The given string does not represent a valid TSIG key.
-
-% RETRANSFER_UNKNOWN_ZONE Got notification to retransfer unknown zone %1
-There was an internal command to retransfer the given zone, but the
-zone is not known to the system. This may indicate that the configuration
-for xfrin is incomplete, or there was a typographical error in the
-zone name in the configuration.
-
-% COMMAND_ERROR Error while executing command '%1': %2
-There was an error while the given command was being processed. The
-error is given in the log message.
-
-% MSGQ_SEND_ERROR Error while contacting %1 and %2
-There was a problem sending a message to the xfrout module or the
-zone manager. This most likely means that the msgq daemon has quit or
-was killed.
-
-% MSGQ_SEND_ERROR_ZONE_MANAGER Error while contacting %1
-There was a problem sending a message to the zone manager. This most
-likely means that the msgq daemon has quit or was killed.
-
-% STOPPED_BY_KEYBOARD Keyboard interrupt, shutting down
-There was a keyboard interrupt signal to stop the xfrin daemon. The
-daemon will now shut down.
-
-% CC_SESSION_ERROR Error reading from cc channel: %1
-There was a problem reading from the command and control channel. The
-most likely cause is that xfrin the msgq daemon is not running.
-
-% UNKNOWN_ERROR Unknown error: %1
-An uncaught exception was raised while running the xfrin daemon. The
-exception message is printed in the log message.
-




More information about the bind10-changes mailing list