[RADIATOR] Reload Clients cache list ?
Heikki Vatiainen
hvn at open.com.au
Wed Oct 20 09:49:20 UTC 2021
On 14.10.2021 14.11, Patrik Forsberg wrote:
> Yes I'm aware of that but there is no way to manually force an update prior to the RefreshPeriod trigger ?
Here's one method if you don't mind needing to use internals a bit more
than usual. Theory of operation:
- There is only one ClientList of any type (if not, adjust [0] below)
- RefreshPeriod is configured
- Between refresh events, 'kill -WINCH <pid>' forces action that is
similar of periodic refresh happening
- refresh_timeout() is called by periodic event scheduler.
refresh_timeout() also sets the trigger for the next periodic timeout
In short: the above triggers additional refresh between periodic refresh
triggers.
WINCHHook sub { my $cl = $main::config->{ClientList}->[0]; \
my $handle = $cl->{_timeouthandle}; \
Radius::Select::remove_timeout($handle); \
Radius::ClientListSQL::refresh_timeout($handle, $cl); }
If you run Radiator with debug logging enabled, it will show what
happens with SIGWINCH.
Thanks,
Heikki
--
Heikki Vatiainen
OSC, makers of Radiator
Visit radiatorsoftware.com for Radiator AAA server software
More information about the radiator
mailing list