mqtt_cpp
mqtt_cpp copied to clipboard
Future improvement: Compile time option to completely remove MQTTv3 code.
E.g., in my situation, I'm not interested in MQTTv3 compatibility. As a result, it would be convenient for me to be able to turn off v3 compatibility at compile time. This would improve build times, and reduce attack surface for security issues.
I'm sure there are MQTT applications that will remain MQTTv3 for a long time. For those applications, disabling MQTTv5 would be nice to have as well.
My broker supports both v3.1.1 and v5. This means the one accept mixed clients.
If we have 3 choices, it is nice.
- Both v3.1.1 and v5 support.
- Only v5 support
- Only v3.1.1 support
Right, that's what I meant.
I imagine the way it would be implemented is with #ifdef style macros.
Either way, something for the far future. No reason to make this change now.