Commit 5d1e1994 authored by Mukund Sivaraman's avatar Mukund Sivaraman
Browse files

Merge branch 'master' into trac2165_2

parents 79f1c5b6 73270385
469. [bug] jelte
libdatasrc: the data source client list class now ignores zone
content problems (such as out-of-zone data) in MasterFiles type
zones, instead of aborting the entire configuration. It only logs
an error, and all other zones and datasources are still loaded. The
error log message has been improved to include the zone origin and
source file name. As a result of this change, b10-auth no longer
exits upon encountering such errors during startup.
(Trac #2178, git a75ed413e8a1c8e3702beea4811a46a1bf519bbd)
468. [func]* naokikambe, fujiwara
b10-stats polls the bind10 and b10-auth with new 'getstats' command
to retrieve statistics data. The "poll-interval" parameter in
b10-stats is for configuring the polling interval. All statistics
data collected once are preserved while b10-stats is running.
The "sendstats" command was removed from bind10 and b10-auth. The
"statistics-interval" configuration item was removed from b10-auth.
(Trac #2136, git dcb5ce50b4b4e50d28247d5f8b5cb8d90bda942a)
(Trac #2137, git d53bb65a43f6027b15a6edc08c137951e3ce5e0e)
(Trac #2138, git b34e3313460eebc9c272ca8c1beb27297c195150)
bind10-devel-20120816 released on August 16, 2012
467. [bug] jelte
For configurations, allow named sets to contain lists of items.
(Trac #2114, git 712637513505f7afb8434292ca2a98c3517dffd3)
466. [func] jelte
Allow bindctl to add and remove items to and from lists
and dicts for items of type "any". This is for easier
configurations.
(Trac #2184, git ad2d728d1496a9ff59d622077850eed0638b54eb)
465. [doc] vorner
Improved documentation about ACLs in the Guide.
(Trac #2066, git 76f733925b3f3560cfc2ee96d2a19905b623bfc3)
464. [func] jelte, muks
libdns++: The LabelSequence class has been extended with some new
methods. These are mainly intended for internal development, but
the class is public, so interested users may want to look into the
extensions.
(Trac #2052, git 57c61f2^..dbef0e2)
(Trac #2053, git 1fc2b06b57a008ec602daa2dac79939b3cc6b65d)
(Trac #2086, git 3fac7d5579c5f51b8e952b50db510b45bfa986f3)
(Trac #2087, git 49ad6346f574d00cfbd1d12905915fd0dd6a0bac)
(Trac #2148, git 285c2845ca96e7ef89f9158f1dea8cda147b6566)
463. [func] jinmei
Python isc.dns: the Name, RRType and RRClass classes are now
hashable. So, for example, objects of these classes can be used
as a dictionary key.
(Trac #1883, git 93ec40dd0a1df963c676037cc60c066c748b3030)
462. [build] jreed
BIND 10 now compiles against googletest-1.6.0 versions that are
installed on the system as source code. For such versions, use the
--with-gtest-source configure switch.
(Trac #1999, git 6a26d459a40d7eed8ebcff01835377b3394a78de)
461. [bug] muks
We now set g+w and g+s permissions (mode 02770) during
installation for the BIND 10 local state directory
($prefix/var/bind10-devel/) so that permissions to files
and sub-directories created in that directory are inherited.
(Trac #2171, git ab4d20907abdb3ce972172463dcc73405b3dee79)
460. [bug] muks
SSHFP's algorithm and fingerprint type checks have been relaxed
such that they will accept any values in [0,255]. This is so that
future algorithm and fingerprint types are accomodated.
(Trac #2124, git 49e6644811a7ad09e1326f20dd73ab43116dfd21)
459. [func] tomek
b10-dhcp6: DHCPv6 server component is now integrated into
BIND10 framework. It can be started from BIND10 (using bindctl)
BIND 10 framework. It can be started from BIND 10 (using bindctl)
and can receive commands. The only supported command for now
is 'Dhcp6 shutdown'.
b10-dhcp4: Command line-switch '-s' to disable msgq was added.
b10-dhcp6: Command line-switch '-s' to disable msgq was added.
(Trac #1708, git e0d7c52a71414f4de1361b09d3c70431c96daa3f)
458. [build]* jinmei
458. [build]* jinmei
>>>>>>> master
BIND 10 now relies on Boost offset_ptr, which caused some new
portability issues. Such issues are detected at ./configure time.
If ./configure stops due to this, try the following workaround:
......@@ -20,12 +94,12 @@
(which would be the case if Boost is installed via pkgsrc)
(Trac #2147, git 30061d1139aad8716e97d6b620c259752fd0a3cd)
457. [build]* muks
457. [build]* muks
BIND 10 library names now have a "b10-" prefix. This is to avoid
clashes with other similarly named libraries on the system.
(Trac #2071, git ac20a00c28069804edc0a36050995df52f601efb)
456. [build]* muks
456. [build] muks
BIND 10 now compiles against log4cplus-1.1.0 (RC releases)
also. Note: some older versions of log4cplus don't work any more;
known oldest workable version is 1.0.4. Thanks to John Lumby for
......@@ -36,7 +110,8 @@
The server now uses newer API for data sources. This would be an
internal change, however, the data sources are now configured
differently. Please, migrate your configuration to the top-level
"data_sources" module.
"data_sources" module. Also the bind10 -n and --no-cache
and b10-auth -n options are removed.
(Trac #1976, git 0d4685b3e7603585afde1b587cbfefdfaf6a1bb3)
454. [bug] jelte
......@@ -53,11 +128,14 @@
NOTIMP instead of SERVFAIL.
(Trac #1986, git bd6b0a5ed3481f78fb4e5cb0b18c7b6e5920f9f8)
452. [func]* muks
isc-sysinfo: An initial implementation of the isc-sysinfo tool
is now available. It gathers and outputs system information which
can be used by future tech support staff.
(Trac #2062, git 144e80212746f8d55e6a59edcf689fec9f32ae95)
452. [func] muks, jelte
isc-sysinfo: An initial implementation of the isc-sysinfo
tool is now available for Linux, OpenBSD, FreeBSD, and Mac
OS X. It gathers and outputs system information which can
be used by future tech support staff. This includes a
generic Python "sysinfo" module.
(Trac #2062, #2121, #2122, #2172,
git 144e80212746f8d55e6a59edcf689fec9f32ae95)
451. [bug] muks, jinmei
libdatasrc: the database-based data source now correctly returns
......@@ -67,14 +145,14 @@
"glue"; it's the caller's responsibility.)
(Trac #1771, git 483f1075942965f0340291e7ff7dae7806df22af)
450. [func]* tomek
450. [func] tomek
b10-dhcp4: DHCPv4 server component is now integrated into
BIND10 framework. It can be started from BIND10 (using bindctl)
BIND 10 framework. It can be started from BIND 10 (using bindctl)
and can receive commands. The only supported command for now
is 'Dhcp4 shutdown'.
(Trac #1651, git 7e16a5a50d3311e63d10a224ec6ebcab5f25f62c)
bind10-devel-20120621 released on June 21. 2012
bind10-devel-20120621 released on June 21, 2012
449. [bug] muks
b10-xfin: fixed a bug where xfrin sent the wrong notification
......@@ -135,7 +213,7 @@ bind10-devel-20120621 released on June 21. 2012
file) was removed.
(Trac #1281, git 900fc8b420789a8c636bcf20fdaffc60bc1041e0)
bind10-devel-20120517 released on May 17. 2012
bind10-devel-20120517 released on May 17, 2012
440. [func] muks
bindctl: improved some error messages so they will be more
......@@ -714,7 +792,7 @@ bind10-devel-20120119 released on January 19, 2012
(Trac #1430, git b35797ba1a49c78246abc8f2387901f9690b328d)
356. [doc] tomek
BIND10 Guide updated. It now describes DHCPv4 and DHCPv6
BIND 10 Guide updated. It now describes DHCPv4 and DHCPv6
components, including their overview, usage, supported standard
and limitations. libdhcp++ is also described.
(Trac #1367, git 3758ab360efe1cdf616636b76f2e0fb41f2a62a0)
......@@ -1530,7 +1608,7 @@ bind10-devel-20110519 released on May 19, 2011
(Trac #719, git a234b20dc6617392deb8a1e00eb0eed0ff353c0a)
236. [func] jelte
C++ client side of configuration now uses BIND10 logging system.
C++ client side of configuration now uses BIND 10 logging system.
It also has improved error handling when communicating with the
rest of the system.
(Trac #743, git 86632c12308c3ed099d75eb828f740c526dd7ec0)
......@@ -2480,8 +2558,8 @@ bind10-devel-20100917 released on September 17, 2010
86. [func] jerry
bin/zonemgr: Added zone manager module. The zone manager is one
of the co-operating processes of BIND10, which keeps track of
timers and other information necessary for BIND10 to act as a
of the co-operating processes of BIND 10, which keeps track of
timers and other information necessary for BIND 10 to act as a
slave. (Trac #215, svn r2737)
85. [build]* jinmei
......
......@@ -2,7 +2,7 @@
# Process this file with autoconf to produce a configure script.
AC_PREREQ([2.59])
AC_INIT(bind10-devel, 20120712, bind10-dev@isc.org)
AC_INIT(bind10-devel, 20120817, bind10-dev@isc.org)
AC_CONFIG_SRCDIR(README)
AM_INIT_AUTOMAKE
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])dnl be backward compatible
......@@ -1101,6 +1101,7 @@ AC_CONFIG_FILES([Makefile
src/bin/zonemgr/tests/Makefile
src/bin/stats/Makefile
src/bin/stats/tests/Makefile
src/bin/stats/tests/testdata/Makefile
src/bin/usermgr/Makefile
src/bin/tests/Makefile
src/lib/Makefile
......@@ -1165,6 +1166,7 @@ AC_CONFIG_FILES([Makefile
src/lib/datasrc/Makefile
src/lib/datasrc/memory/Makefile
src/lib/datasrc/memory/tests/Makefile
src/lib/datasrc/memory/benchmarks/Makefile
src/lib/datasrc/tests/Makefile
src/lib/datasrc/tests/testdata/Makefile
src/lib/xfr/Makefile
......
......@@ -1621,9 +1621,8 @@ const std::string HARDCODED_DNS_SERVER = "2001:db8:1::1";</pre><p>
</p><p>
This stats daemon provides commands to identify if it is
running, show specified or all statistics data, show specified
or all statistics data schema, and set specified statistics
data.
running, show specified or all statistics data, and show specified
or all statistics data schema.
For example, using <span class="command"><strong>bindctl</strong></span>:
......
......@@ -1790,8 +1790,8 @@ Chapter 16. Statistics
statistics data from various modules and aggregates it.
This stats daemon provides commands to identify if it is running, show
specified or all statistics data, show specified or all statistics data
schema, and set specified statistics data. For example, using bindctl:
specified or all statistics data, and show specified or all statistics data
schema. For example, using bindctl:
> Stats show
{
......
......@@ -1347,7 +1347,7 @@ TODO
<para>
This is encoded in form of JSON. Semi-formal description could look
something like this. It is described in more details below.
<!-- FIXME: Is <screen> really the correct one?-->
<!-- FIXME: Is <screen> really the correct one?-->
<screen>ACL := [ RULE, RULE, ... ]
RULE := { "action": "ACCEPT"|"REJECT"|"DROP", MATCH, MATCH, ... }
RULE_RAW := { MATCH, MATCH, ... }
......@@ -1376,8 +1376,8 @@ AND_MATCH := "ALL": [ RULE_RAW, RULE_RAW, ... ]
The other is TSIG key by which the message was signed. The ACL
contains only the name (under the name "key"), the key itself
must be stored in the global keyring. This property is applicable only
to the DNS context. <!-- TODO: Section for the keyring and link to
it.-->
to the DNS context.
<!-- TODO: Section for the keyring and link to it.-->
</para>
<para>
......@@ -1633,21 +1633,6 @@ can use various data source backends.
</simpara>
</listitem>
</varlistentry>
<varlistentry>
<term>statistics-interval</term>
<listitem>
<simpara>
<varname>statistics-interval</varname> is the timer interval
in seconds for <command>b10-auth</command> to share its
statistics information to
<citerefentry><refentrytitle>b10-stats</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
Statistics updates can be disabled by setting this to 0.
The default is 60.
</simpara>
</listitem>
</varlistentry>
</variablelist>
</para>
......@@ -1680,13 +1665,14 @@ can use various data source backends.
</varlistentry>
<varlistentry>
<term>sendstats</term>
<term>getstats</term>
<listitem>
<simpara>
<command>sendstats</command> tells <command>b10-auth</command>
<command>getstats</command> requests <command>b10-auth</command>
to send its statistics data to
<citerefentry><refentrytitle>b10-stats</refentrytitle><manvolnum>8</manvolnum></citerefentry>
immediately.
<citerefentry><refentrytitle>b10-stats</refentrytitle>
<manvolnum>8</manvolnum></citerefentry>
as a response of the command.
</simpara>
</listitem>
</varlistentry>
......@@ -2162,7 +2148,7 @@ Xfrout/transfer_acl[0] {"action": "ACCEPT"} any (default)</screen>
TSIGs in the incoming messages and to sign responses.</para>
<para>
For further details on ACL configuration, see
For further details on ACL configuration, see
<xref linkend="common-acl" />.
</para>
......@@ -3027,9 +3013,8 @@ const std::string HARDCODED_DNS_SERVER = "2001:db8:1::1";</screen>
<para>
This stats daemon provides commands to identify if it is
running, show specified or all statistics data, show specified
or all statistics data schema, and set specified statistics
data.
running, show specified or all statistics data, and show specified
or all statistics data schema.
For example, using <command>bindctl</command>:
......
<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>BIND 10 Messages Manual</title><link rel="stylesheet" href="./bind10-guide.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.75.2"><meta name="description" content="BIND 10 is a Domain Name System (DNS) suite managed by Internet Systems Consortium (ISC). It includes DNS libraries and modular components for controlling authoritative and recursive DNS servers. This is the messages manual for BIND 10 version 20120712. The most up-to-date version of this document, along with other documents for BIND 10, can be found at ."></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="book" title="BIND 10 Messages Manual"><div class="titlepage"><div><div><h1 class="title"><a name="idp74800"></a>BIND 10 Messages Manual</h1></div><div><p class="releaseinfo">This is the messages manual for BIND 10 version
<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>BIND 10 Messages Manual</title><link rel="stylesheet" href="./bind10-guide.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.75.2"><meta name="description" content="BIND 10 is a Domain Name System (DNS) suite managed by Internet Systems Consortium (ISC). It includes DNS libraries and modular components for controlling authoritative and recursive DNS servers. This is the messages manual for BIND 10 version 20120712. The most up-to-date version of this document, along with other documents for BIND 10, can be found at ."></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="book" title="BIND 10 Messages Manual"><div class="titlepage"><div><div><h1 class="title"><a name="id1168229451102"></a>BIND 10 Messages Manual</h1></div><div><p class="releaseinfo">This is the messages manual for BIND 10 version
20120712.</p></div><div><p class="copyright">Copyright © 2011-2012 Internet Systems Consortium, Inc.</p></div><div><div class="abstract" title="Abstract"><p class="title"><b>Abstract</b></p><p>BIND 10 is a Domain Name System (DNS) suite managed by
Internet Systems Consortium (ISC). It includes DNS libraries
and modular components for controlling authoritative and
......
......@@ -420,16 +420,6 @@ This is a debug message reporting that an incoming NOTIFY was received.
</para></listitem>
</varlistentry>
<varlistentry id="AUTH_RECEIVED_SENDSTATS">
<term>AUTH_RECEIVED_SENDSTATS command 'sendstats' received</term>
<listitem><para>
This is a debug message issued when the authoritative server has received
a command from the statistics module to send it data. The 'sendstats'
command is handled differently to other commands, which is why the debug
message associated with it has its own code.
</para></listitem>
</varlistentry>
<varlistentry id="AUTH_RESPONSE_FAILURE">
<term>AUTH_RESPONSE_FAILURE exception while building response to query: %1</term>
<listitem><para>
......
......@@ -56,11 +56,6 @@
}]
}
},
{ "item_name": "statistics-interval",
"item_type": "integer",
"item_optional": true,
"item_default": 60
},
{
"item_name": "listen_on",
"item_type": "list",
......@@ -110,8 +105,8 @@
]
},
{
"command_name": "sendstats",
"command_description": "Send data to a statistics module at once",
"command_name": "getstats",
"command_description": "Retrieve statistics data",
"command_args": []
},
{
......
......@@ -53,37 +53,6 @@ public:
virtual void commit() {};
};
/// A derived \c AuthConfigParser class for the "statistics-internal"
/// configuration identifier.
class StatisticsIntervalConfig : public AuthConfigParser {
public:
StatisticsIntervalConfig(AuthSrv& server) :
server_(server), interval_(0)
{}
virtual void build(ConstElementPtr config_value) {
const int32_t config_interval = config_value->intValue();
if (config_interval < 0) {
isc_throw(AuthConfigError, "Negative statistics interval value: "
<< config_interval);
}
if (config_interval > 86400) {
isc_throw(AuthConfigError, "Statistics interval value "
<< config_interval
<< " must be equal to or shorter than 86400");
}
interval_ = config_interval;
}
virtual void commit() {
// setStatisticsTimerInterval() is not 100% exception free. But
// exceptions should happen only in a very rare situation, so we
// let them be thrown and subsequently regard them as a fatal error.
server_.setStatisticsTimerInterval(interval_);
}
private:
AuthSrv& server_;
uint32_t interval_;
};
/// A special parser for testing: it throws from commit() despite the
/// suggested convention of the class interface.
class ThrowerCommitConfig : public AuthConfigParser {
......@@ -155,9 +124,7 @@ createAuthConfigParser(AuthSrv& server, const std::string& config_id) {
// simplicity. In future we'll probably generalize it using map-like
// data structure, and may even provide external register interface so
// that it can be dynamically customized.
if (config_id == "statistics-interval") {
return (new StatisticsIntervalConfig(server));
} else if (config_id == "listen_on") {
if (config_id == "listen_on") {
return (new ListenAddressConfig(server));
} else if (config_id == "_commit_throw") {
// This is for testing purpose only and should not appear in the
......
......@@ -122,11 +122,6 @@ a NOTIFY packet that an RR type of something other than SOA in the
question section. (The RR type received is included in the message.) The
server will return a FORMERR error to the sender.
% AUTH_NO_STATS_SESSION session interface for statistics is not available
The authoritative server had no session with the statistics module at the
time it attempted to send it data: the attempt has been abandoned. This
could be an error in configuration.
% AUTH_NO_XFRIN received NOTIFY but XFRIN session is not running
This is a debug message produced by the authoritative server when it receives
a NOTIFY packet but the XFRIN process is not running. The packet will be
......@@ -169,12 +164,6 @@ a command on the command channel.
% AUTH_RECEIVED_NOTIFY received incoming NOTIFY for zone name %1, zone class %2
This is a debug message reporting that an incoming NOTIFY was received.
% AUTH_RECEIVED_SENDSTATS command 'sendstats' received
This is a debug message issued when the authoritative server has received
a command from the statistics module to send it data. The 'sendstats'
command is handled differently to other commands, which is why the debug
message associated with it has its own code.
% AUTH_RESPONSE_FAILURE exception while building response to query: %1
This is a debug message, generated by the authoritative server when an
attempt to create a response to a received DNS packet has failed. The
......@@ -203,7 +192,7 @@ multiple lines of text. For this reason, it is suggested that this log message
not be routed to the syslog file, where the multiple lines could confuse
programs that expect a format of one message per line.
% AUTH_SEND_NORMAL_RESPONSE sending an error response (%1 bytes):\n%2
% AUTH_SEND_NORMAL_RESPONSE sending a normal response (%1 bytes):\n%2
This is a debug message recording that the authoritative server is sending
a response to the originator of a query.
......@@ -242,37 +231,6 @@ is not running, b10-auth will respond to UPDATE requests with rcode NOTIMP.
When b10-ddns is running, b10-ddns will handle and respond to the UPDATE
message.
% AUTH_STATS_CHANNEL_CREATED STATS session channel created
This is a debug message indicating that the authoritative server has
created a channel to the statistics process. It is issued during server
startup is an indication that the initialization is proceeding normally.
% AUTH_STATS_CHANNEL_ESTABLISHED STATS session channel established
This is a debug message indicating that the authoritative server
has established communication over the previously created statistics
channel. It is issued during server startup is an indication that the
initialization is proceeding normally.
% AUTH_STATS_COMMS communication error in sending statistics data: %1
An error was encountered when the authoritative server tried to send data
to the statistics daemon. The message includes additional information
describing the reason for the failure.
% AUTH_STATS_TIMEOUT timeout while sending statistics data: %1
The authoritative server sent data to the statistics daemon but received
no acknowledgement within the specified time. The message includes
additional information describing the reason for the failure.
% AUTH_STATS_TIMER_DISABLED statistics timer has been disabled
This is a debug message indicating that the statistics timer has been
disabled in the authoritative server and no statistics information is
being produced.
% AUTH_STATS_TIMER_SET statistics timer set to %1 second(s)
This is a debug message indicating that the statistics timer has been
enabled and that the authoritative server will produce statistics data
at the specified interval.
% AUTH_STOP_DDNS_FORWARDER DDNS UPDATE handling stopped
This is a debug message indicating that b10-auth has received a message
that it should stop internally forwarding UPDATE message to b10-ddns.
......
......@@ -247,9 +247,6 @@ public:
ModuleCCSession* config_session_;
AbstractSession* xfrin_session_;
/// Interval timer for periodic submission of statistics counters.
IntervalTimer statistics_timer_;
/// Query counters for statistics
AuthCounters counters_;
......@@ -320,7 +317,6 @@ AuthSrvImpl::AuthSrvImpl(AbstractXfroutClient& xfrout_client,
BaseSocketSessionForwarder& ddns_forwarder) :
config_session_(NULL),
xfrin_session_(NULL),
statistics_timer_(io_service_),
counters_(),
keyring_(NULL),
ddns_base_forwarder_(ddns_forwarder),
......@@ -479,43 +475,11 @@ AuthSrv::setConfigSession(ModuleCCSession* config_session) {
impl_->registerStatisticsValidator();
}
void
AuthSrv::setStatisticsSession(AbstractSession* statistics_session) {
impl_->counters_.setStatisticsSession(statistics_session);
}
ModuleCCSession*
AuthSrv::getConfigSession() const {
return (impl_->config_session_);
}
uint32_t
AuthSrv::getStatisticsTimerInterval() const {
return (impl_->statistics_timer_.getInterval() / 1000);
}
void
AuthSrv::setStatisticsTimerInterval(uint32_t interval) {
if (interval == impl_->statistics_timer_.getInterval()) {
return;
}
if (interval > 86400) {
// It can't occur since the value is checked in
// statisticsIntervalConfig::build().
isc_throw(InvalidParameter, "Too long interval: " << interval);
}
if (interval == 0) {
impl_->statistics_timer_.cancel();
LOG_DEBUG(auth_logger, DBG_AUTH_OPS, AUTH_STATS_TIMER_DISABLED);
} else {
impl_->statistics_timer_.setup(boost::bind(&AuthSrv::submitStatistics,
this),
interval * 1000);
LOG_DEBUG(auth_logger, DBG_AUTH_OPS, AUTH_STATS_TIMER_SET)
.arg(interval);
}
}
void
AuthSrv::processMessage(const IOMessage& io_message, Message& message,
OutputBuffer& buffer, DNSServer* server)
......@@ -882,8 +846,8 @@ AuthSrv::updateConfig(ConstElementPtr new_config) {
}
}
bool AuthSrv::submitStatistics() const {
return (impl_->counters_.submitStatistics());
ConstElementPtr AuthSrv::getStatistics() const {
return (impl_->counters_.getStatistics());
}
uint64_t
......
......@@ -17,7 +17,6 @@
#include <string>
#include <cc/data.h>
#include <config/ccsession.h>
#include <datasrc/factory.h>
#include <dns/message.h>
......@@ -203,64 +202,21 @@ public:
///
void setXfrinSession(isc::cc::AbstractSession* xfrin_session);
/// \brief Set the communication session with Statistics.
///
/// This function never throws an exception as far as
/// AuthCounters::setStatisticsSession() doesn't throw.
///
/// Note: this interface is tentative. We'll revisit the ASIO and
/// session frameworks, at which point the session will probably
/// be passed on construction of the server.
///
/// \param statistics_session A Session object over which statistics
/// information is exchanged with statistics module.
/// The session must be established before setting in the server
/// object.
/// Ownership isn't transferred: the caller is responsible for keeping
/// this object to be valid while the server object is working and for
/// disconnecting the session and destroying the object when the server
/// is shutdown.
void setStatisticsSession(isc::cc::AbstractSession* statistics_session);
/// Return the interval of periodic submission of statistics in seconds.
///
/// If the statistics submission is disabled, it returns 0.
///
/// This method never throws an exception.
uint32_t getStatisticsTimerInterval() const;
/// Set the interval of periodic submission of statistics.
///
/// If the specified value is non 0, the \c AuthSrv object will submit
/// its statistics to the statistics module every \c interval seconds.
/// If it's 0, and \c AuthSrv currently submits statistics, the submission
/// will be disabled. \c interval must be equal to or shorter than 86400
/// seconds (1 day).
///
/// This method should normally not throw an exception; however, its
/// underlying library routines may involve resource allocation, and
/// when it fails it would result in a corresponding standard exception.
///
/// \param interval The submission interval in seconds if non 0;
/// or a value of 0 to disable the submission.
void setStatisticsTimerInterval(uint32_t interval);
/// \brief Submit statistics counters to statistics module.
/// \brief Returns statistics data
///
/// This function can throw an exception from
/// AuthCounters::submitStatistics().
/// AuthCounters::getStatistics().
///
/// \return true on success, false on failure (e.g. session timeout,
/// session error).
bool submitStatistics() const;
/// \return JSON format statistics data.
isc::data::ConstElementPtr getStatistics() const;
/// \brief Get the value of counter in the AuthCounters.
///
/// This function calls AuthCounters::getCounter() and
/// This function calls AuthCounters::getStatistics() and
/// returns its return value.
///
/// This function never throws an exception as far as
/// AuthCounters::getCounter() doesn't throw.
/// AuthCounters::getStatistics() doesn't throw.
///
/// Note: Currently this function is for testing purpose only.
///
......
......@@ -14,13 +14,6 @@
#include <config.h>
#include <stdlib.h>