[425835] Support for "hour client expiration times.
This allows shorter values for the persistent_client_expiration option. Bug: https://bugs.eclipse.org/bugs/show_bug.cgi?id=425835
This commit is contained in:
parent
c591b06574
commit
0adb2ed217
@ -53,6 +53,8 @@ Broker:
|
||||
of UNSUBSCRIBE requests to be disabled for topics with "out" direction.
|
||||
Closes bug #456899.
|
||||
- Wildcard TLS certificates are now supported for bridges.
|
||||
- Support for "hour" client expiration lengths for the
|
||||
persistent_client_expiration option. Closes bug #425835.
|
||||
|
||||
Clients:
|
||||
- Both clients can now load default configuration options from a file.
|
||||
|
@ -454,7 +454,7 @@
|
||||
to persistent clients that will never reconnect. This
|
||||
option allows these clients to be removed.</para>
|
||||
<para>The expiration period should be an integer followed
|
||||
by one of d w m y for day, week, month and year
|
||||
by one of h d w m y for hour, day, week, month and year
|
||||
respectively. For example:</para>
|
||||
<itemizedlist mark="circle">
|
||||
<listitem><para>persistent_client_expiration 2m</para></listitem>
|
||||
|
@ -91,8 +91,8 @@
|
||||
# generated client id. This leads to persistent clients that will never
|
||||
# reconnect. This option allows these clients to be removed.
|
||||
#
|
||||
# The expiration period should be an integer followed by one of d w m y for
|
||||
# day, week, month and year respectively. For example
|
||||
# The expiration period should be an integer followed by one of h d w m y for
|
||||
# hour, day, week, month and year respectively. For example
|
||||
#
|
||||
# persistent_client_expiration 2m
|
||||
# persistent_client_expiration 14d
|
||||
|
@ -1479,6 +1479,9 @@ int _config_read_file_core(struct mqtt3_config *config, bool reload, const char
|
||||
token = strtok_r(NULL, " ", &saveptr);
|
||||
if(token){
|
||||
switch(token[strlen(token)-1]){
|
||||
case 'h':
|
||||
expiration_mult = 3600;
|
||||
break;
|
||||
case 'd':
|
||||
expiration_mult = 86400;
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user