Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
lwm2mclient: improve overall stability upon connectivity issues
This patch adds a few simple mechanisms to improve management of flaky connectivity conditions: - Add timeout to the socket "connect" function. Each client will timeout after the value passed to the "lwm2m_client_service" function for all clients (e.g. if 1000 ms timeout is passed to the "service" function with X clients, each of the X client will use 1000 ms as the timeout value when calling "connect") - Remove call to the "service" function in the "start" function. It makes the "start" function non-blocking, connection to th server is now initiated during first call of the "service" function - Remove dynamic allocation of handles array in the service function, using static allocation instead. This brings a limitation that the "service" function can not be called for servicing more than a limited number of 128 clients - Add detection of connection failure in new places, returning an error for the concerned client to the calling application Change-Id: I0af9f60780ba6c0c59c2f08f005a1ae5b9f405b7 Signed-off-by: Gregory Lemercier <g.lemercier@samsung.com>
- Loading branch information
Gregory Lemercier
committed
Dec 19, 2017
1 parent
8977467
commit cc74496
Showing
8 changed files
with
86 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters