icwmpd: schedule inform and session handling

This commit is contained in:
Suvendhu Hansa 2023-09-28 08:38:23 +00:00 committed by Vivek Kumar Dutta
parent ea3b3aec05
commit eebe898c37
2 changed files with 3 additions and 10 deletions

View file

@ -8,11 +8,11 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=icwmp
PKG_VERSION:=9.5.7
PKG_VERSION:=9.5.8
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/bbf/icwmp.git
PKG_SOURCE_VERSION:=1e2ffebf659631a7126dc4df8c4daa0fb3671946
PKG_SOURCE_VERSION:=79871c5365cf89ce718b922b0863c8a68c09a771
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip

View file

@ -18,14 +18,7 @@ handle_icwmp_update() {
sleep 10
ret=$(ubus call service list '{"name":"icwmpd"}' | jsonfilter -qe '@.icwmpd.instances.icwmp.running')
if [ "$ret" = "true" ]; then
# read status from var/state/icwmp
status=$(uci -q -c /var/state get icwmp.sess_status.current_status)
if [ "$status" == "failure" ]; then
log "Trigger out of bound inform, since last inform status was failure"
ubus -t 10 call tr069 inform >/dev/null 2>&1
fi
else
if [ "$ret" != "true" ]; then
log "Restarting icwmp tr069 object"
/etc/init.d/icwmpd restart
fi