patchlwIP - A Lightweight TCP/IP stack - Patches: patch #9889, Support for memory pools in MQTT...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

patch #9889: Support for memory pools in MQTT app

Submitter:  Anton Gerasimov <oytis>
Submitted:  Mon 10 Feb 2020 12:57:21 PM UTC
   
 
Category:  None Priority:  5 - Normal
Status:  None Privacy:  Public
Assigned to:  None Open/Closed:  Open
Planned Release:  None

Tue 11 Feb 2020 02:19:26 PM UTC, comment #2: 

Well, the API is kind of there, one can include 'lwip/apps/mqtt_priv.h', and do what documentation suggested, allocate the client handler statically that is. But the name 'mqtt_priv.h' implies that it's private, and shouldn't be included directly. Maybe it could then be merged with mqtt.h or renamed to something like 'mqtt_static.h'?

Or as the most lightweight solution 'doc/mqtt_client.txt' could mention that mqtt_priv.h should be included for the static allocation.

Or did you have a different kind of API in mind?

Anton Gerasimov <oytis>
Tue 11 Feb 2020 08:25:13 AM UTC, comment #1: 

Hmm, maybe it would be easier to expose an API where the caller can provide the memory instead of adding the memp allocation scheme into mqtt.c?

Simon Goldschmidt <goldsimon>
Group administrator
Mon 10 Feb 2020 12:57:21 PM UTC, original submission:  

The definition of mqtt_client_t is not a part of public API any more, so it can't be instantiated statically without including private headers. An alternative is a configuration option to make MQTT use pool allocator. It changes the API slightly as the pool should be initialized first.

Anton Gerasimov <oytis>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by goldsimon (Posted a comment)
  • -email is unavailable- added by oytis (Submitted the item)
  • -email is unavailable- added by oytis
  • -email is unavailable- added by oytis
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2020-02-10 oytis Attached File- Added 0001-mqtt-add-support-for-memory-pools.patch, #48390
        Attached File- Added 0002-doc-update-MQTT-documentation-with-memory-pools.patch, #48391
        Carbon-Copy- Added -email is unavailable-
        Carbon-Copy- Added -email is unavailable-

    Back to the top

    Powered by Savane 3.13-3230.
    Corresponding source code