tools/mesh-cfgclient: Add timeout for expected response
authorInga Stotland <inga.stotland@intel.com>
Fri, 1 Nov 2019 18:57:26 +0000 (11:57 -0700)
committerAnupam Roy <anupam.r@samsung.com>
Tue, 17 Dec 2019 20:31:49 +0000 (02:01 +0530)
commite089c1de9a18cf58e73d349406e4e994400bf7df
tree0ba194b642f0e4783fb58283420e2c07f40be7f6
parentec996519a3b455ec144cf2467a5c2fe69a3fed85
tools/mesh-cfgclient: Add timeout for expected response

This adds a pending request queue for the issued commands awaiting
response from a remote config server. The tool forces "single-issue"
of a config command, i.e. only one command that has a specified return
type is allowed to be outstanding per a remote node address.
That is, if AppKeyAdd command to a node is pending response, the tool
disallows sending another AppKeyAdd, AppKeyUpdate or AppKeyDelete to
the same address until response timeout expires (notification will
be displayed).
The default response timeout is set to 2 seconds and is configurable
by "timeout" command.

Change-Id: I4611df3e02faf1a5310faec16cd714f7cde5d013
Signed-off-by: Anupam Roy <anupam.r@samsung.com>
tools/mesh-cfgclient.c
tools/mesh/cfgcli.c
tools/mesh/cfgcli.h