mosquitto-users team mailing list archive
-
mosquitto-users team
-
Mailing list archive
-
Message #00383
Mosquitto client mosquitto_start
Hi,
I am currently using the Mosquitto Client in a multi-threading mode. So I am not using mosquitto_loop but the mosquitto_loop_start / mosquitto_loop_stop functions.
I have noticed that everytime the client is running the memory consumption is increased by 8MB. This is the default space allocated by pthread_create (called by the mosquitto_loop_start function) for each new thread. It is possible to decrease this allocated space by putting an attribute (pthread_attr_t) when calling the pthread_create function. Currently this parameter is set to NULL and it does not seem possible to modify it. I have noticed there is a dummypthread.h file with "#define pthread_create(A, B, C, D)" but I am not sure if it can be used for customization.
Regards,
Remi
Follow ups