espressif / esp-aws-iot

AWS IoT SDK for ESP32 based chipsets
Apache License 2.0
256 stars 153 forks source link

Enable non-blocking socket mode in coreMQTT transport (CA-329) #214

Open paulbartell opened 5 months ago

paulbartell commented 5 months ago

Improve mqtt performance by using a non-blocking socket to connect coreMQTT to the MQTT broker.

txf- commented 4 months ago

I should point out that building this I'm getting:

error: 'lBytesRead' may be used uninitialized [-Werror=maybe-uninitialized]

in espTlsTransportRecv

txf- commented 4 months ago

I'll put this in a separate comment. I tried this solution and was updating a shadow document. However sometimes it would sends empty messages. I tried increasing xTimeout value to 10000 and that reduces the number of empty updates.

edit: never mind, my previous solution also demonstrates this problem.