Skip to content

Commit 7250a07

Browse files
change qos in connection check
Signed-off-by: Pradeep Kumar K J <pkj@softwareag.com>
1 parent 5726ff2 commit 7250a07

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

crates/core/tedge/src/cli/connect/command.rs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,12 @@ fn check_device_status_c8y(tedge_config: &TEdgeConfig) -> Result<DeviceStatus, C
259259
match event {
260260
Ok(Event::Incoming(Packet::SubAck(_))) => {
261261
// We are ready to get the response, hence send the request
262-
client.publish(C8Y_TOPIC_BUILTIN_JWT_TOKEN_UPSTREAM, AtLeastOnce, false, "")?;
262+
client.publish(
263+
C8Y_TOPIC_BUILTIN_JWT_TOKEN_UPSTREAM,
264+
rumqttc::QoS::AtMostOnce,
265+
false,
266+
"",
267+
)?;
263268
}
264269
Ok(Event::Incoming(Packet::PubAck(_))) => {
265270
// The request has been sent

crates/core/tedge/src/cli/connect/jwt_token.rs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,12 @@ pub(crate) fn get_connected_c8y_url(tedge_config: &TEdgeConfig) -> Result<String
3333
match event {
3434
Ok(Event::Incoming(Packet::SubAck(_))) => {
3535
// We are ready to get the response, hence send the request
36-
client.publish(C8Y_TOPIC_BUILTIN_JWT_TOKEN_UPSTREAM, AtLeastOnce, false, "")?;
36+
client.publish(
37+
C8Y_TOPIC_BUILTIN_JWT_TOKEN_UPSTREAM,
38+
rumqttc::QoS::AtMostOnce,
39+
false,
40+
"",
41+
)?;
3742
}
3843
Ok(Event::Incoming(Packet::PubAck(_))) => {
3944
// The request has been sent

0 commit comments

Comments
 (0)