You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When creating the DeviceClient using DeviceClient.createFromSecurityProvider we are unable to receive C2D messages (sent either via azure portal or using service sdk). When created using the connection string and certificate files or strings [ "new DeviceClient( ... )" ] then c2d messages work fine. Further, using the connection string method one time will cause c2d messages to work even when connecting using createFromSecurityProvider.
For production our device has high security requirements and we use a custom security provider and therefore we require the use of createFromSecurityProvider.
Code sample exhibiting the issue:
If you only ever connect to iot hub like this, cannot receive c2d message... deviceClient = DeviceClient.createFromSecurityProvider(iotHubUri, deviceId, securityProviderX509, IotHubClientProtocol.MQTT);
If you connect like this then c2d messages can be received AND after connecting like this once it seems that subsequent connections using createFromSecurityProvider work as well. deviceClient = new DeviceClient(connStringX509, IotHubClientProtocol.MQTT, this.getCertPath(), true, this.getKeyPath(), true);
Console log of the issue:
Need Support?
Have a feature request for SDKs? Please post it on User Voice to help us prioritize.
Have a technical question? Ask on Stack Overflow with tag “azure-iot-hub”
Need Support? Every customer with an active Azure subscription has access to support with guaranteed response time. Consider submitting a ticket and get assistance from Microsoft support team
Found a bug? Please help us fix it by thoroughly documenting it and filing an issue on GitHub (C, Java, .NET, Node.js, Python).
The text was updated successfully, but these errors were encountered:
I've taken a look into this issue, and it is a bug on our side. Currently, only MQTT/MQTT_WS have this issue though. If you would switch to AMQPS/AMQPS_WS or HTTPS you would be good to receive messages.
@larrype, thank you for your contribution to our open-sourced project! Please help us improve by filling out this 2-minute customer satisfaction survey
Observed issue on Windows 10 and Android API 29
JDK 1.8 for Windows and Android
iot-device-client 1.17.2
security-provider 1.3.0
x509-provider 1.1.3
provisioning-device-client 1.7.0
iot-deps 0.8.3
Description of the issue:
When creating the DeviceClient using DeviceClient.createFromSecurityProvider we are unable to receive C2D messages (sent either via azure portal or using service sdk). When created using the connection string and certificate files or strings [ "new DeviceClient( ... )" ] then c2d messages work fine. Further, using the connection string method one time will cause c2d messages to work even when connecting using createFromSecurityProvider.
For production our device has high security requirements and we use a custom security provider and therefore we require the use of createFromSecurityProvider.
Code sample exhibiting the issue:
If you only ever connect to iot hub like this, cannot receive c2d message...
deviceClient = DeviceClient.createFromSecurityProvider(iotHubUri, deviceId, securityProviderX509, IotHubClientProtocol.MQTT);
If you connect like this then c2d messages can be received AND after connecting like this once it seems that subsequent connections using createFromSecurityProvider work as well.
deviceClient = new DeviceClient(connStringX509, IotHubClientProtocol.MQTT, this.getCertPath(), true, this.getKeyPath(), true);
Console log of the issue:
Need Support?
The text was updated successfully, but these errors were encountered: