awslabs / aws-c-mqtt

C99 implementation of the MQTT 3.1.1 specification.
Apache License 2.0
93 stars 30 forks source link

Adapter lifecycle take2 #296

Closed bretambrose closed 1 year ago

bretambrose commented 1 year ago

Mqtt3 to 5 adapter lifecycle implementation

Maps the MQTT5 lifecycle event set as best it can to the MQTT311 implementation's event set. Given that the two interfaces can undermine one another, this is a best effort implementation; there are multiple situations where we have to make a judgement call.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

codecov-commenter commented 1 year ago

Codecov Report

Patch coverage: 84.25% and project coverage change: +0.91 :tada:

Comparison is base (59a1e89) 80.18% compared to head (515d324) 81.09%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #296 +/- ## ========================================== + Coverage 80.18% 81.09% +0.91% ========================================== Files 18 18 Lines 7641 7841 +200 ========================================== + Hits 6127 6359 +232 + Misses 1514 1482 -32 ``` | [Impacted Files](https://app.codecov.io/gh/awslabs/aws-c-mqtt/pull/296?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=awslabs) | Coverage Δ | | |---|---|---| | [source/mqtt3\_to\_mqtt5\_adapter.c](https://app.codecov.io/gh/awslabs/aws-c-mqtt/pull/296?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=awslabs#diff-c291cmNlL21xdHQzX3RvX21xdHQ1X2FkYXB0ZXIuYw==) | `67.16% <83.33%> (+21.89%)` | :arrow_up: | | [source/v5/mqtt5\_client.c](https://app.codecov.io/gh/awslabs/aws-c-mqtt/pull/296?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=awslabs#diff-c291cmNlL3Y1L21xdHQ1X2NsaWVudC5j) | `88.08% <90.00%> (+0.45%)` | :arrow_up: | | [source/v5/mqtt5\_options\_storage.c](https://app.codecov.io/gh/awslabs/aws-c-mqtt/pull/296?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=awslabs#diff-c291cmNlL3Y1L21xdHQ1X29wdGlvbnNfc3RvcmFnZS5j) | `90.21% <92.85%> (+0.02%)` | :arrow_up: | ... and [1 file with indirect coverage changes](https://app.codecov.io/gh/awslabs/aws-c-mqtt/pull/296/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=awslabs)

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.