2
0
mirror of https://gitlab.isc.org/isc-projects/kea synced 2025-09-05 08:25:16 +00:00

[master] Finished merge of trac5035 (migrate lease expiration config)

This commit is contained in:
Francis Dupont
2017-01-10 23:24:39 +01:00
25 changed files with 5257 additions and 4392 deletions

View File

@@ -40,7 +40,7 @@
#ifndef YY_PARSER4_DHCP4_PARSER_H_INCLUDED
# define YY_PARSER4_DHCP4_PARSER_H_INCLUDED
// // "%code requires" blocks.
#line 17 "dhcp4_parser.yy" // lalr1.cc:377
#line 17 "dhcp4_parser.yy" // lalr1.cc:392
#include <string>
#include <cc/data.h>
@@ -52,7 +52,7 @@ using namespace isc::dhcp;
using namespace isc::data;
using namespace std;
#line 56 "dhcp4_parser.h" // lalr1.cc:377
#line 56 "dhcp4_parser.h" // lalr1.cc:392
# include <cassert>
# include <cstdlib> // std::abort
@@ -135,9 +135,9 @@ using namespace std;
# endif /* ! defined YYDEBUG */
#endif /* ! defined PARSER4_DEBUG */
#line 14 "dhcp4_parser.yy" // lalr1.cc:377
#line 14 "dhcp4_parser.yy" // lalr1.cc:392
namespace isc { namespace dhcp {
#line 141 "dhcp4_parser.h" // lalr1.cc:377
#line 141 "dhcp4_parser.h" // lalr1.cc:392
@@ -411,38 +411,44 @@ namespace isc { namespace dhcp {
TOKEN_LIBRARY = 324,
TOKEN_PARAMETERS = 325,
TOKEN_EXPIRED_LEASES_PROCESSING = 326,
TOKEN_SERVER_ID = 327,
TOKEN_IDENTIFIER = 328,
TOKEN_HTYPE = 329,
TOKEN_TIME = 330,
TOKEN_ENTERPRISE_ID = 331,
TOKEN_DHCP4O6_PORT = 332,
TOKEN_CONTROL_SOCKET = 333,
TOKEN_SOCKET_TYPE = 334,
TOKEN_SOCKET_NAME = 335,
TOKEN_DHCP_DDNS = 336,
TOKEN_LOGGING = 337,
TOKEN_LOGGERS = 338,
TOKEN_OUTPUT_OPTIONS = 339,
TOKEN_OUTPUT = 340,
TOKEN_DEBUGLEVEL = 341,
TOKEN_SEVERITY = 342,
TOKEN_DHCP6 = 343,
TOKEN_DHCPDDNS = 344,
TOKEN_TOPLEVEL_JSON = 345,
TOKEN_TOPLEVEL_DHCP4 = 346,
TOKEN_SUB_DHCP4 = 347,
TOKEN_SUB_INTERFACES4 = 348,
TOKEN_SUB_SUBNET4 = 349,
TOKEN_SUB_POOL4 = 350,
TOKEN_SUB_RESERVATION = 351,
TOKEN_SUB_OPTION_DEF = 352,
TOKEN_SUB_OPTION_DATA = 353,
TOKEN_SUB_HOOKS_LIBRARY = 354,
TOKEN_STRING = 355,
TOKEN_INTEGER = 356,
TOKEN_FLOAT = 357,
TOKEN_BOOLEAN = 358
TOKEN_RECLAIM_TIMER_WAIT_TIME = 327,
TOKEN_FLUSH_RECLAIMED_TIMER_WAIT_TIME = 328,
TOKEN_HOLD_RECLAIMED_TIME = 329,
TOKEN_MAX_RECLAIM_LEASES = 330,
TOKEN_MAX_RECLAIM_TIME = 331,
TOKEN_UNWARNED_RECLAIM_CYCLES = 332,
TOKEN_SERVER_ID = 333,
TOKEN_IDENTIFIER = 334,
TOKEN_HTYPE = 335,
TOKEN_TIME = 336,
TOKEN_ENTERPRISE_ID = 337,
TOKEN_DHCP4O6_PORT = 338,
TOKEN_CONTROL_SOCKET = 339,
TOKEN_SOCKET_TYPE = 340,
TOKEN_SOCKET_NAME = 341,
TOKEN_DHCP_DDNS = 342,
TOKEN_LOGGING = 343,
TOKEN_LOGGERS = 344,
TOKEN_OUTPUT_OPTIONS = 345,
TOKEN_OUTPUT = 346,
TOKEN_DEBUGLEVEL = 347,
TOKEN_SEVERITY = 348,
TOKEN_DHCP6 = 349,
TOKEN_DHCPDDNS = 350,
TOKEN_TOPLEVEL_JSON = 351,
TOKEN_TOPLEVEL_DHCP4 = 352,
TOKEN_SUB_DHCP4 = 353,
TOKEN_SUB_INTERFACES4 = 354,
TOKEN_SUB_SUBNET4 = 355,
TOKEN_SUB_POOL4 = 356,
TOKEN_SUB_RESERVATION = 357,
TOKEN_SUB_OPTION_DEF = 358,
TOKEN_SUB_OPTION_DATA = 359,
TOKEN_SUB_HOOKS_LIBRARY = 360,
TOKEN_STRING = 361,
TOKEN_INTEGER = 362,
TOKEN_FLOAT = 363,
TOKEN_BOOLEAN = 364
};
};
@@ -837,6 +843,30 @@ namespace isc { namespace dhcp {
symbol_type
make_EXPIRED_LEASES_PROCESSING (const location_type& l);
static inline
symbol_type
make_RECLAIM_TIMER_WAIT_TIME (const location_type& l);
static inline
symbol_type
make_FLUSH_RECLAIMED_TIMER_WAIT_TIME (const location_type& l);
static inline
symbol_type
make_HOLD_RECLAIMED_TIME (const location_type& l);
static inline
symbol_type
make_MAX_RECLAIM_LEASES (const location_type& l);
static inline
symbol_type
make_MAX_RECLAIM_TIME (const location_type& l);
static inline
symbol_type
make_UNWARNED_RECLAIM_CYCLES (const location_type& l);
static inline
symbol_type
make_SERVER_ID (const location_type& l);
@@ -1170,12 +1200,12 @@ namespace isc { namespace dhcp {
enum
{
yyeof_ = 0,
yylast_ = 626, ///< Last index in yytable_.
yynnts_ = 268, ///< Number of nonterminal symbols.
yylast_ = 647, ///< Last index in yytable_.
yynnts_ = 274, ///< Number of nonterminal symbols.
yyfinal_ = 22, ///< Termination state number.
yyterror_ = 1,
yyerrcode_ = 256,
yyntokens_ = 104 ///< Number of tokens.
yyntokens_ = 110 ///< Number of tokens.
};
@@ -1227,9 +1257,10 @@ namespace isc { namespace dhcp {
65, 66, 67, 68, 69, 70, 71, 72, 73, 74,
75, 76, 77, 78, 79, 80, 81, 82, 83, 84,
85, 86, 87, 88, 89, 90, 91, 92, 93, 94,
95, 96, 97, 98, 99, 100, 101, 102, 103
95, 96, 97, 98, 99, 100, 101, 102, 103, 104,
105, 106, 107, 108, 109
};
const unsigned int user_token_number_max_ = 358;
const unsigned int user_token_number_max_ = 364;
const token_number_type undef_token_ = 2;
if (static_cast<int>(t) <= yyeof_)
@@ -1262,24 +1293,24 @@ namespace isc { namespace dhcp {
{
switch (other.type_get ())
{
case 116: // value
case 155: // socket_type
case 122: // value
case 161: // socket_type
value.copy< ElementPtr > (other.value);
break;
case 103: // "boolean"
case 109: // "boolean"
value.copy< bool > (other.value);
break;
case 102: // "floating point"
case 108: // "floating point"
value.copy< double > (other.value);
break;
case 101: // "integer"
case 107: // "integer"
value.copy< int64_t > (other.value);
break;
case 100: // "constant string"
case 106: // "constant string"
value.copy< std::string > (other.value);
break;
@@ -1300,24 +1331,24 @@ namespace isc { namespace dhcp {
(void) v;
switch (this->type_get ())
{
case 116: // value
case 155: // socket_type
case 122: // value
case 161: // socket_type
value.copy< ElementPtr > (v);
break;
case 103: // "boolean"
case 109: // "boolean"
value.copy< bool > (v);
break;
case 102: // "floating point"
case 108: // "floating point"
value.copy< double > (v);
break;
case 101: // "integer"
case 107: // "integer"
value.copy< int64_t > (v);
break;
case 100: // "constant string"
case 106: // "constant string"
value.copy< std::string > (v);
break;
@@ -1397,24 +1428,24 @@ namespace isc { namespace dhcp {
// Type destructor.
switch (yytype)
{
case 116: // value
case 155: // socket_type
case 122: // value
case 161: // socket_type
value.template destroy< ElementPtr > ();
break;
case 103: // "boolean"
case 109: // "boolean"
value.template destroy< bool > ();
break;
case 102: // "floating point"
case 108: // "floating point"
value.template destroy< double > ();
break;
case 101: // "integer"
case 107: // "integer"
value.template destroy< int64_t > ();
break;
case 100: // "constant string"
case 106: // "constant string"
value.template destroy< std::string > ();
break;
@@ -1441,24 +1472,24 @@ namespace isc { namespace dhcp {
super_type::move(s);
switch (this->type_get ())
{
case 116: // value
case 155: // socket_type
case 122: // value
case 161: // socket_type
value.move< ElementPtr > (s.value);
break;
case 103: // "boolean"
case 109: // "boolean"
value.move< bool > (s.value);
break;
case 102: // "floating point"
case 108: // "floating point"
value.move< double > (s.value);
break;
case 101: // "integer"
case 107: // "integer"
value.move< int64_t > (s.value);
break;
case 100: // "constant string"
case 106: // "constant string"
value.move< std::string > (s.value);
break;
@@ -1527,7 +1558,7 @@ namespace isc { namespace dhcp {
325, 326, 327, 328, 329, 330, 331, 332, 333, 334,
335, 336, 337, 338, 339, 340, 341, 342, 343, 344,
345, 346, 347, 348, 349, 350, 351, 352, 353, 354,
355, 356, 357, 358
355, 356, 357, 358, 359, 360, 361, 362, 363, 364
};
return static_cast<token_type> (yytoken_number_[type]);
}
@@ -1952,6 +1983,42 @@ namespace isc { namespace dhcp {
return symbol_type (token::TOKEN_EXPIRED_LEASES_PROCESSING, l);
}
Dhcp4Parser::symbol_type
Dhcp4Parser::make_RECLAIM_TIMER_WAIT_TIME (const location_type& l)
{
return symbol_type (token::TOKEN_RECLAIM_TIMER_WAIT_TIME, l);
}
Dhcp4Parser::symbol_type
Dhcp4Parser::make_FLUSH_RECLAIMED_TIMER_WAIT_TIME (const location_type& l)
{
return symbol_type (token::TOKEN_FLUSH_RECLAIMED_TIMER_WAIT_TIME, l);
}
Dhcp4Parser::symbol_type
Dhcp4Parser::make_HOLD_RECLAIMED_TIME (const location_type& l)
{
return symbol_type (token::TOKEN_HOLD_RECLAIMED_TIME, l);
}
Dhcp4Parser::symbol_type
Dhcp4Parser::make_MAX_RECLAIM_LEASES (const location_type& l)
{
return symbol_type (token::TOKEN_MAX_RECLAIM_LEASES, l);
}
Dhcp4Parser::symbol_type
Dhcp4Parser::make_MAX_RECLAIM_TIME (const location_type& l)
{
return symbol_type (token::TOKEN_MAX_RECLAIM_TIME, l);
}
Dhcp4Parser::symbol_type
Dhcp4Parser::make_UNWARNED_RECLAIM_CYCLES (const location_type& l)
{
return symbol_type (token::TOKEN_UNWARNED_RECLAIM_CYCLES, l);
}
Dhcp4Parser::symbol_type
Dhcp4Parser::make_SERVER_ID (const location_type& l)
{
@@ -2145,9 +2212,9 @@ namespace isc { namespace dhcp {
}
#line 14 "dhcp4_parser.yy" // lalr1.cc:377
#line 14 "dhcp4_parser.yy" // lalr1.cc:392
} } // isc::dhcp
#line 2151 "dhcp4_parser.h" // lalr1.cc:377
#line 2218 "dhcp4_parser.h" // lalr1.cc:392