astarte-platform / astarte-device-sdk-rust

Apache License 2.0
6 stars 12 forks source link

fix(disconnect): rework the disconnect for gRPC #374

Closed joshuachp closed 2 months ago

joshuachp commented 2 months ago

Make the disconnect usable with the gRPC connection, before the trait was implemented for the wrong struct and the error was not returned. Now the call to disconnect can fail but it only takes a reference, so you can retry it multiple times.

codecov[bot] commented 2 months ago

Codecov Report

Attention: Patch coverage is 75.00000% with 3 lines in your changes missing coverage. Please review.

Project coverage is 68.6%. Comparing base (9cbc2b0) to head (c7f6d16). Report is 2 commits behind head on master.

Files with missing lines Patch % Lines
src/client.rs 0.0% 2 Missing :warning:
src/transport/mqtt/mod.rs 0.0% 1 Missing :warning:
Additional details and impacted files | [Files with missing lines](https://app.codecov.io/gh/astarte-platform/astarte-device-sdk-rust/pull/374?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=astarte-platform) | Coverage Δ | | |---|---|---| | [src/transport/grpc/mod.rs](https://app.codecov.io/gh/astarte-platform/astarte-device-sdk-rust/pull/374?src=pr&el=tree&filepath=src%2Ftransport%2Fgrpc%2Fmod.rs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=astarte-platform#diff-c3JjL3RyYW5zcG9ydC9ncnBjL21vZC5ycw==) | `54.6% <100.0%> (-0.5%)` | :arrow_down: | | [src/transport/mqtt/mod.rs](https://app.codecov.io/gh/astarte-platform/astarte-device-sdk-rust/pull/374?src=pr&el=tree&filepath=src%2Ftransport%2Fmqtt%2Fmod.rs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=astarte-platform#diff-c3JjL3RyYW5zcG9ydC9tcXR0L21vZC5ycw==) | `62.9% <0.0%> (ø)` | | | [src/client.rs](https://app.codecov.io/gh/astarte-platform/astarte-device-sdk-rust/pull/374?src=pr&el=tree&filepath=src%2Fclient.rs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=astarte-platform#diff-c3JjL2NsaWVudC5ycw==) | `63.0% <0.0%> (+0.4%)` | :arrow_up: |