I have a message route query on iotHub like below:-
IS_OBJECT($twin.properties.reported.deviceOperations) OR $twin.properties.reported.deviceOperations = null
Expected result:-
Message should be delivered to the endpoint having twin like below:-
"properties": {
"reported": {
"deviceOperations": {
"6a8e9bb0-631b-42ad-a3ec-7c8fe4a67c6c": {
"requestType": "fileDownload",
"metadata": {
"key": "value"
},
"blobName": "<Some_BLob_Name>",
"progressUpdate": false,
"de88a4ed-6eb0-483b-a929-cf0ae544e0df": {
"wipe": true
}
}
},
}
This is getting delivered and is working fine due to the IS_OBJECT query in message routing
The problem/issue arises in the second query for json below
"properties": {
"reported": {
"deviceOperations": null
}
}
this is not getting delivered to the endpoint but it should due to this condition $twin.properties.reported.deviceOperations = null.
And the reported property deviceOperations is getting cleared in twin but somehow not delivered to the endpoint.
Also when i put the message routing query as true I get the message in my endpoint as below
[EventHubMonitor] [9:21:31 AM] Message received:
{
"version": 6,
"properties": {
"reported": {
"deviceOperations": null,
"$metadata": {
"$lastUpdated": "2024-11-26T03:51:31.5199729Z",
"deviceOperations": null
},
"$version": 3
}
}
}
So only the condition $twin.properties.reported.deviceOperations = null in message routing doesn't work
Am I missing anything?
Note:- The test works in the Azure UI portal for above JSON.
I have a message route query on iotHub like below:-
IS_OBJECT($twin.properties.reported.deviceOperations) OR $twin.properties.reported.deviceOperations = null
Expected result:-
Message should be delivered to the endpoint having twin like below:-
This is getting delivered and is working fine due to the
IS_OBJECTquery in message routingThe problem/issue arises in the second query for json below
this is not getting delivered to the endpoint but it should due to this condition
$twin.properties.reported.deviceOperations = null.And the reported property deviceOperations is getting cleared in twin but somehow not delivered to the endpoint.
Also when i put the message routing query as
trueI get the message in my endpoint as below[EventHubMonitor] [9:21:31 AM] Message received:
So only the condition
$twin.properties.reported.deviceOperations = nullin message routing doesn't workAm I missing anything?
Note:- The test works in the Azure UI portal for above JSON.