The device service (C sdk)fails to boot (device creation unsuccessful) in the Main 3.2 branch when utilizing the message bus configured as MQTT. #304
Unanswered
sagargaikwad-eaton
asked this question in
Q&A
Replies: 1 comment
-
|
There is something wrong when the C SDK is handling the device validation request from the edgex/device-template/validate/device topic |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Dear Team,
I am referencing the documentation found at https://docs.edgexfoundry.org/3.2/microservices/device/sdk/devicesdk-getting-started/GettingStartedSDK-C/ to establish a device service and initiate it within the EdgeX Compose environment. I have adhered to the outlined procedures in the document and successfully executed the device-template for a random number generator device. The device service has started, successfully created the device, and is capable of receiving events with message bus set to redis.
I am encountering difficulties while attempting to create a device service using the MQTT message bus logs mentioned as below ,
level=INFO ts=2024-08-14T17:47:32Z app=device-template msg="Starting HTTP server on interface localhost, port 59999" level=DEBUG ts=2024-08-14T17:47:32Z app=device-template msg="Resolved interface is ::1" level=DEBUG ts=2024-08-14T17:47:32Z app=device-template msg="mqtt: subscribing to edgex/system-events/core-metadata/device/add/device-template/#" level=DEBUG ts=2024-08-14T17:47:32Z app=device-template msg="mqtt: subscribing to edgex/device-template/validate/device" level=INFO ts=2024-08-14T17:47:32Z app=device-template msg="Processing Devices from ./res/devices" level=DEBUG ts=2024-08-14T17:47:37Z app=device-template msg="HTTP response: 503" level=TRACE ts=2024-08-14T17:47:37Z app=device-template msg="POST [{"apiVersion":"v3","Device":{"name":"RandNum-Device01","profileName":"RandNum-Device","description":"Random Number Generator Device","labels":["test","random"],"protocols":{"Other":{"Address":"random","Port":300}},"autoEvents":[{"interval":"10s","sourceName":"RandomNumber","onChange":false}],"serviceName":"device-template","adminState":"UNLOCKED","operatingState":"UP","apiVersion":"v3"}}] to http://localhost:59881/api/v3/device returns 503" **level=INFO ts=2024-08-14T17:47:37Z app=device-template msg="Device RandNum-Device01 create failed: HTTP request failed: <html><head><title>Timeout</title></head><body><h1>Timeout</h1></body></html>"** level=ERROR ts=2024-08-14T17:47:37Z app=device-template msg="Error processing file ./res/devices/random-generator-devices.json" Error: 21: HTTP request failed level=TRACE ts=2024-08-14T17:47:37Z app=device-template msg="iot_scheduler_free"In this instance, while utilizing the MQTT message bus, it is evident that the device is not being created, nor is there a callback for device creation. I am employing the same device and profile as previously used with the Redis message bus; however, it is not functioning with the MQTT message bus.
The detailed logs for both the operational Redis message bus and the non-operational MQTT message bus are provided below.
Not_working_mqtt_log.txt
working_redis_log.txt
Kindly look in this matter and suggest is anything missing from my side or its valid issue provide solution for it
CC : @iain-anderson @cloudxxx8
Beta Was this translation helpful? Give feedback.
All reactions