obuspa: config option for E2ESession mode

This commit is contained in:
Vivek Kumar Dutta 2023-04-20 17:37:02 +05:30
parent 6062346802
commit 5bef6dfff6
2 changed files with 10 additions and 4 deletions

View file

@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=obuspa
PKG_VERSION:=7.0.2.5
PKG_VERSION:=7.0.2.6
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/bbf/obuspa.git
PKG_SOURCE_VERSION:=5c2fa02032b6d93940cd3d271a807adb47e90fb4
PKG_SOURCE_VERSION:=1905f6372eb14ae02df7c359595657591d6e9743
PKG_MAINTAINER:=Vivek Dutta <vivek.dutta@iopsys.eu>
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip

View file

@ -234,7 +234,8 @@ validate_controller_section()
'Host:string' \
'Port:port' \
'Path:string' \
'EnableEncryption:bool'
'EnableEncryption:bool' \
'SessionMode:string'
}
validate_subscription_section()
@ -327,7 +328,7 @@ configure_controller()
local EndpointID Enable
local Protocol Destination
local Topic mqtt stomp assigned_role_name AssignedRole ParameterName
local Host Port Path EnableEncryption Reference
local Host Port Path EnableEncryption Reference SessionMode
local dm_ref sec
sec="${1}"
@ -364,6 +365,11 @@ configure_controller()
db_set "${BASEPATH}.Alias" "${sec}"
db_set "${BASEPATH}.Enable" "${Enable}"
db_set "${BASEPATH}.EndpointID" "${EndpointID}"
if [ -n "${SessionMode}" ]; then
db_set "${BASEPATH}.E2ESession.SessionMode" "${SessionMode}"
fi
if [ -n "${assigned_role_name}" ]; then
AssignedRole=$(get_role_index "${assigned_role_name}")
fi