Proxy: Ignore idle timeout if observe subscription on session

Ignore the idle_timeout_secs parameter for a server if there is one
or more active observe subscriptions for the server session.
This commit is contained in:
Jon Shallow authored and Jon Shallow committed 2025-03-24 16:17:14 +00:00
1 parent b2cbc7057a
commit df95d5bcc3
4 files changed
+36 -10

No files matched your search

+3 -1
View File
@@ -60,7 +60,9 @@ typedef struct coap_proxy_server_list_t {
server, else 0 for all clients to share the same
ongoing session */
unsigned int idle_timeout_secs; /**< Proxy upstream session idle timeout
(0 is no timeout) */
(0 is no timeout). Timeout is ignored
if there are any active upstream Observe
requests */
} coap_proxy_server_list_t;
/**
+5 -1
View File
@@ -41,8 +41,12 @@ struct coap_proxy_list_t {
size_t req_count; /**< Count of incoming request info */
coap_uri_t uri; /**< URI info for connection */
uint8_t *uri_host_keep; /**< memory for uri.host */
coap_tick_t idle_timeout_ticks; /**< Idle timeout (0 == no timeout) */
coap_tick_t idle_timeout_ticks; /**< Idle timeout (0 == no timeout). Timeout
is ignored if there are any active
upstream Observe requests */
coap_tick_t last_used; /**< Last time entry was used */
uint64_t res_tx_token; /**< Copy of ongoing session tx_token for restart */
coap_lg_crcv_t *res_lg_crcv; /**< Copy of ongoing session lg_crcv for restart */
};
/**