explicitAttrs: "true" is not true
explicitAttrs: true behaves as expected
but
explicitAttrs:"true" or explicitAttrs:"m0==null?[]:true" doesn't.
Hi @mrutid and @fgalan , could you please provide me the detailed description regarding the issue? also, could you attach the specific link or data to reproduce this issue. Thank you.
Hi @MayankSingh-NEC, thanks for your willingness to contribute to the IoT Agent. Somehow this is a corner case, so this is nor urgent. It would be addressed later when refactoring the code related in the iotagent-node-lib.
Hi @mrutid and @fgalan , I'm not able to reproduce this issue. As, it is completely working fine in my system, using the default configs. PFA.
- Group Provisioning
curl -iX POST \
'http://localhost:4041/iot/services' \
-H 'Content-Type: application/json' \
-H 'fiware-service: myHome' \
-H 'fiware-servicepath: /environment' \
-d '{
"services": [
{
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"cbHost": "http://orion:1026",
"entity_type": "Device",
"resource": "/iot/d",
"explicitAttrs": "m0==null?[]:true" or "true"
}
]
}'
Note: Response can be seen in the iotagent-json logs. Attached in the file.
Thank @MayankSingh-NEC for testing the issue. You are just checking the group provision. This was working well.
The problem behind this is how the agent is working when sending the measures. You should test If sending a measure m0, then the measures should not be propagated to the CB. Everything else should be persisted.
Having said that, this problem was already analysed and identified. The challenge here is the logic is distributed across the codebase, so it is not a simple fix. We are waiting until refactoring the code related with explicitAttrs, that would simplify the fix.
This issue is fixed by https://github.com/telefonicaid/iotagent-node-lib/pull/1314
@MayankSingh-NEC could you check again (using master branch) and provide feedback, please? Thanks!
@MayankSingh-NEC could you check again (using master branch) and provide feedback, please? Thanks!
Hi @fgalan , I've tested and verified that now, it's working fine. Thanks :))
@MayankSingh-NEC thanks for the report!
We close the issue, based on your positive feedback.