iotagent-node-lib 2.19.0 → 2.22.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (67) hide show
  1. package/.nyc_output/33364de2-1199-4ec2-b33c-cae063ef8cc4.json +1 -0
  2. package/.nyc_output/processinfo/33364de2-1199-4ec2-b33c-cae063ef8cc4.json +1 -0
  3. package/.nyc_output/processinfo/index.json +1 -0
  4. package/.readthedocs.yml +3 -1
  5. package/CHANGES_NEXT_RELEASE +1 -0
  6. package/README.md +5 -56
  7. package/doc/Contribution.md +3 -3
  8. package/doc/advanced-topics.md +8 -41
  9. package/doc/api.md +14 -3
  10. package/doc/expressionLanguage.md +17 -0
  11. package/doc/northboundinteractions.md +40 -33
  12. package/doc/operations.md +8 -5
  13. package/doc/requirements.txt +4 -0
  14. package/{docs → doc}/roadmap.md +21 -6
  15. package/doc/usermanual.md +4 -4
  16. package/docker/Mosquitto/Dockerfile +28 -12
  17. package/docker/Mosquitto/README.md +8 -7
  18. package/docker/Mosquitto/startMosquitto.sh +8 -0
  19. package/lib/fiware-iotagent-lib.js +1 -2
  20. package/lib/jexlTranformsMap.js +3 -1
  21. package/lib/model/Group.js +2 -1
  22. package/lib/model/dbConn.js +4 -0
  23. package/lib/plugins/expressionPlugin.js +56 -21
  24. package/lib/plugins/multiEntity.js +43 -49
  25. package/lib/plugins/pluginUtils.js +16 -0
  26. package/lib/services/commands/commandService.js +29 -2
  27. package/lib/services/common/domain.js +6 -2
  28. package/lib/services/common/iotManagerService.js +2 -1
  29. package/lib/services/devices/deviceRegistryMemory.js +13 -2
  30. package/lib/services/devices/deviceRegistryMongoDB.js +15 -7
  31. package/lib/services/devices/deviceService.js +52 -16
  32. package/lib/services/groups/groupRegistryMongoDB.js +13 -12
  33. package/lib/services/ngsi/entities-NGSI-LD.js +13 -4
  34. package/lib/services/ngsi/entities-NGSI-v2.js +8 -6
  35. package/lib/services/ngsi/ngsiService.js +3 -3
  36. package/lib/services/northBound/contextServer-NGSI-LD.js +20 -1
  37. package/lib/services/northBound/contextServer-NGSI-v2.js +39 -30
  38. package/lib/services/northBound/contextServerUtils.js +10 -10
  39. package/lib/services/northBound/deviceProvisioningServer.js +4 -1
  40. package/lib/templates/createDevice.json +13 -2
  41. package/lib/templates/createDeviceLax.json +2 -3
  42. package/lib/templates/updateDevice.json +13 -2
  43. package/package.json +27 -33
  44. package/test/unit/examples/deviceProvisioningRequests/provisionMinimumDevice4.json +14 -0
  45. package/test/unit/mongodb/mongoDBUtils.js +2 -2
  46. package/test/unit/mongodb/mongodb-group-registry-test.js +1 -1
  47. package/test/unit/mongodb/mongodb-registry-test.js +2 -3
  48. package/test/unit/ngsi-ld/examples/contextAvailabilityRequests/registerIoTAgentCommands.json +2 -1
  49. package/test/unit/ngsi-ld/examples/contextRequests/updateContextLanguageProperties1.json +15 -0
  50. package/test/unit/ngsi-ld/lazyAndCommands/command-test.js +315 -1
  51. package/test/unit/ngsi-ld/ngsiService/languageProperties-test.js +112 -0
  52. package/test/unit/ngsi-mixed/provisioning/ngsi-versioning-test.js +1 -1
  53. package/test/unit/ngsiv2/examples/contextRequests/createMinimumProvisionedDevice4.json +8 -0
  54. package/test/unit/ngsiv2/examples/contextRequests/updateContextCommandStatus2.json +6 -0
  55. package/test/unit/ngsiv2/examples/contextRequests/updateContextExpressionPlugin35.json +2 -0
  56. package/test/unit/ngsiv2/examples/contextRequests/updateContextExpressionPlugin36.json +1 -0
  57. package/test/unit/ngsiv2/examples/contextRequests/updateContextMultientityPlugin17.json +27 -0
  58. package/test/unit/ngsiv2/expressions/jexlBasedTransformations-test.js +63 -2
  59. package/test/unit/ngsiv2/lazyAndCommands/polling-commands-test.js +151 -0
  60. package/test/unit/ngsiv2/plugins/multientity-plugin_test.js +63 -0
  61. package/test/unit/ngsiv2/provisioning/device-provisioning-api_test.js +60 -0
  62. package/test/unit/ngsiv2/provisioning/updateProvisionedDevices-test.js +2 -1
  63. package/bin/agentConsole.js +0 -257
  64. package/bin/iotAgentTester.js +0 -44
  65. package/lib/command/commandLine.js +0 -918
  66. package/lib/command/migration.js +0 -176
  67. package/test/unit/general/migration-test.js +0 -257
@@ -0,0 +1 @@
1
+ {"parent":null,"pid":78202,"argv":["/home/fermin/.nvm/versions/node/v16.15.0/bin/node","/home/fermin/src/iotagent-node-lib/node_modules/.bin/mocha","--recursive","test/**/*.js","--reporter","spec","--timeout","8000","--ui","bdd","--exit","--color","true"],"execArgv":[],"cwd":"/home/fermin/src/iotagent-node-lib","time":1655738400548,"ppid":78191,"coverageFilename":"/home/fermin/src/iotagent-node-lib/.nyc_output/33364de2-1199-4ec2-b33c-cae063ef8cc4.json","externalId":"","uuid":"33364de2-1199-4ec2-b33c-cae063ef8cc4","files":["/home/fermin/src/iotagent-node-lib/lib/fiware-iotagent-lib.js","/home/fermin/src/iotagent-node-lib/lib/services/ngsi/ngsiService.js","/home/fermin/src/iotagent-node-lib/lib/services/common/domain.js","/home/fermin/src/iotagent-node-lib/lib/constants.js","/home/fermin/src/iotagent-node-lib/lib/errors.js","/home/fermin/src/iotagent-node-lib/lib/commonConfig.js","/home/fermin/src/iotagent-node-lib/lib/services/ngsi/ngsiUtils.js","/home/fermin/src/iotagent-node-lib/lib/services/common/genericMiddleware.js","/home/fermin/src/iotagent-node-lib/lib/model/dbConn.js","/home/fermin/src/iotagent-node-lib/lib/services/common/alarmManagement.js","/home/fermin/src/iotagent-node-lib/lib/services/ngsi/subscriptionService.js","/home/fermin/src/iotagent-node-lib/lib/services/stats/statsRegistry.js","/home/fermin/src/iotagent-node-lib/lib/services/devices/deviceService.js","/home/fermin/src/iotagent-node-lib/lib/services/groups/groupService.js","/home/fermin/src/iotagent-node-lib/lib/services/common/iotManagerService.js","/home/fermin/src/iotagent-node-lib/lib/request-shim.js","/home/fermin/src/iotagent-node-lib/lib/services/devices/registrationUtils.js","/home/fermin/src/iotagent-node-lib/lib/services/northBound/restUtils.js","/home/fermin/src/iotagent-node-lib/lib/services/commands/commandService.js","/home/fermin/src/iotagent-node-lib/lib/services/northBound/northboundServer.js","/home/fermin/src/iotagent-node-lib/lib/services/northBound/contextServer.js","/home/fermin/src/iotagent-node-lib/lib/services/northBound/contextServerUtils.js","/home/fermin/src/iotagent-node-lib/lib/services/northBound/deviceProvisioningServer.js","/home/fermin/src/iotagent-node-lib/lib/services/northBound/deviceGroupAdministrationServer.js","/home/fermin/src/iotagent-node-lib/lib/plugins/compressTimestamp.js","/home/fermin/src/iotagent-node-lib/lib/plugins/pluginUtils.js","/home/fermin/src/iotagent-node-lib/lib/plugins/attributeAlias.js","/home/fermin/src/iotagent-node-lib/lib/plugins/addEvent.js","/home/fermin/src/iotagent-node-lib/lib/plugins/timestampProcessPlugin.js","/home/fermin/src/iotagent-node-lib/lib/plugins/expressionPlugin.js","/home/fermin/src/iotagent-node-lib/lib/plugins/expressionParser.js","/home/fermin/src/iotagent-node-lib/lib/plugins/jexlParser.js","/home/fermin/src/iotagent-node-lib/lib/jexlTranformsMap.js","/home/fermin/src/iotagent-node-lib/lib/plugins/multiEntity.js","/home/fermin/src/iotagent-node-lib/lib/plugins/bidirectionalData.js","/home/fermin/src/iotagent-node-lib/lib/services/groups/groupRegistryMemory.js","/home/fermin/src/iotagent-node-lib/lib/services/common/securityServiceKeystone.js","/home/fermin/src/iotagent-node-lib/lib/services/devices/deviceRegistryMemory.js","/home/fermin/src/iotagent-node-lib/lib/services/commands/commandRegistryMemory.js","/home/fermin/src/iotagent-node-lib/lib/services/devices/devices-NGSI-v2.js","/home/fermin/src/iotagent-node-lib/lib/services/ngsi/entities-NGSI-v2.js","/home/fermin/src/iotagent-node-lib/lib/services/ngsi/subscription-NGSI-v2.js","/home/fermin/src/iotagent-node-lib/lib/services/northBound/contextServer-NGSI-v2.js","/home/fermin/src/iotagent-node-lib/lib/model/Device.js","/home/fermin/src/iotagent-node-lib/lib/model/Group.js","/home/fermin/src/iotagent-node-lib/lib/model/Command.js","/home/fermin/src/iotagent-node-lib/lib/services/devices/deviceRegistryMongoDB.js","/home/fermin/src/iotagent-node-lib/lib/services/groups/groupRegistryMongoDB.js","/home/fermin/src/iotagent-node-lib/lib/services/commands/commandRegistryMongoDB.js","/home/fermin/src/iotagent-node-lib/lib/services/devices/devices-NGSI-LD.js","/home/fermin/src/iotagent-node-lib/lib/services/ngsi/entities-NGSI-LD.js","/home/fermin/src/iotagent-node-lib/lib/services/ngsi/subscription-NGSI-LD.js","/home/fermin/src/iotagent-node-lib/lib/services/northBound/contextServer-NGSI-LD.js","/home/fermin/src/iotagent-node-lib/lib/services/common/securityServiceOAuth2.js","/home/fermin/src/iotagent-node-lib/lib/services/devices/devices-NGSI-mixed.js","/home/fermin/src/iotagent-node-lib/lib/services/ngsi/subscription-NGSI-mixed.js","/home/fermin/src/iotagent-node-lib/lib/services/northBound/contextServer-NGSI-mixed.js","/home/fermin/src/iotagent-node-lib/lib/services/ngsi/entities-NGSI-mixed.js"]}
@@ -0,0 +1 @@
1
+ {"processes":{"33364de2-1199-4ec2-b33c-cae063ef8cc4":{"parent":null,"children":[]}},"files":{"/home/fermin/src/iotagent-node-lib/lib/fiware-iotagent-lib.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/ngsi/ngsiService.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/common/domain.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/constants.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/errors.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/commonConfig.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/ngsi/ngsiUtils.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/common/genericMiddleware.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/model/dbConn.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/common/alarmManagement.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/ngsi/subscriptionService.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/stats/statsRegistry.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/devices/deviceService.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/groups/groupService.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/common/iotManagerService.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/request-shim.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/devices/registrationUtils.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/northBound/restUtils.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/commands/commandService.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/northBound/northboundServer.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/northBound/contextServer.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/northBound/contextServerUtils.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/northBound/deviceProvisioningServer.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/northBound/deviceGroupAdministrationServer.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/plugins/compressTimestamp.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/plugins/pluginUtils.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/plugins/attributeAlias.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/plugins/addEvent.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/plugins/timestampProcessPlugin.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/plugins/expressionPlugin.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/plugins/expressionParser.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/plugins/jexlParser.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/jexlTranformsMap.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/plugins/multiEntity.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/plugins/bidirectionalData.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/groups/groupRegistryMemory.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/common/securityServiceKeystone.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/devices/deviceRegistryMemory.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/commands/commandRegistryMemory.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/devices/devices-NGSI-v2.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/ngsi/entities-NGSI-v2.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/ngsi/subscription-NGSI-v2.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/northBound/contextServer-NGSI-v2.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/model/Device.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/model/Group.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/model/Command.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/devices/deviceRegistryMongoDB.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/groups/groupRegistryMongoDB.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/commands/commandRegistryMongoDB.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/devices/devices-NGSI-LD.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/ngsi/entities-NGSI-LD.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/ngsi/subscription-NGSI-LD.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/northBound/contextServer-NGSI-LD.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/common/securityServiceOAuth2.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/devices/devices-NGSI-mixed.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/ngsi/subscription-NGSI-mixed.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/northBound/contextServer-NGSI-mixed.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"],"/home/fermin/src/iotagent-node-lib/lib/services/ngsi/entities-NGSI-mixed.js":["33364de2-1199-4ec2-b33c-cae063ef8cc4"]},"externalIds":{}}
package/.readthedocs.yml CHANGED
@@ -4,4 +4,6 @@ mkdocs:
4
4
  configuration: mkdocs.yml
5
5
 
6
6
  python:
7
- version: 3.6
7
+ version: 3.8
8
+ install:
9
+ - requirements: doc/requirements.txt
@@ -0,0 +1 @@
1
+
package/README.md CHANGED
@@ -20,7 +20,7 @@ platform (authentication and authorization of the channel) and provide other com
20
20
  This project is part of [FIWARE](https://www.fiware.org/). For more information check the FIWARE Catalogue entry for the
21
21
  [IoT Agents](https://github.com/Fiware/catalogue/tree/master/iot-agents).
22
22
 
23
- | :books: [Documentation](https://iotagent-node-lib.rtfd.io) | :mortar_board: [Academy](https://fiware-academy.readthedocs.io/en/latest/iot-agents/idas) | :dart: [Roadmap](https://github.com/telefonicaid/iotagent-node-lib/blob/master/docs/roadmap.md) |
23
+ | :books: [Documentation](https://iotagent-node-lib.rtfd.io) | :mortar_board: [Academy](https://fiware-academy.readthedocs.io/en/latest/iot-agents/idas) | :dart: [Roadmap](https://github.com/telefonicaid/iotagent-node-lib/blob/master/doc/roadmap.md) |
24
24
  | ---------------------------------------------------------- | ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- |
25
25
 
26
26
 
@@ -72,7 +72,7 @@ IoT Agent
72
72
  In order to use the library within your own IoT Agent, you must first you require it before use:
73
73
 
74
74
  ```javascript
75
- const iotagentLib = require("iotagent-node-lib");
75
+ const iotagentLib = require('iotagent-node-lib');
76
76
  ```
77
77
 
78
78
  Information about how to configure the Library can be found at the corresponding section of the
@@ -298,64 +298,13 @@ configuration is independent, and can be checked with the `showConfigCb` and `sh
298
298
  Their values can be changed with the `configCb` and `configIot` commands respectively. The new configurations will be
299
299
  deleted upon startup.
300
300
 
301
- #### Creating specialized testers
302
-
303
- The command-line testing tools make use of the
304
- [command-node Node.js library](https://github.com/telefonicaid/command-shell-lib) for command-line utils. In order to
305
- help creating testing tools for IoTAgents of specific protocols, all the commands of the library tester are offered as a
306
- array that can be directly imported into other Command-Line tools, using the following steps:
307
-
308
- - Require the `iotagent-node-lib` command-line module in your command-line tool:
309
-
310
- ```javascript
311
- var iotaCommands = require("iotagent-node-lib").commandLine;
312
- ```
313
-
314
- - Initialize the command-line utils (the initialization function takes two arguments, that will be explained in detail
315
- below:
316
-
317
- ```javascript
318
- iotaCommands.init(configCb, configIot);
319
- ```
320
-
321
- - Add the IOTA Lib commands to your array of commands
322
-
323
- ```javascript
324
- commands = commands.concat(commands, iotaCommands.commands);
325
- ```
326
-
327
- - Execute the command-line interpreter as usual:
328
-
329
- ```javascript
330
- clUtils.initialize(commandLine.commands, "IoT Agent tester> ");
331
- ```
332
-
333
- The command-line module makes use of two configuration objects. Both can be shown and edited in the command-line using
334
- the provided commands, but a default value must be present.
335
-
336
- The Context Broker configuration object holds all the information about the Context Broker where the IoT Agent to be
337
- tested is connected. It MUST contain the following attributes:
338
-
339
- - **host**: host where the Context Broker instance is located.
340
- - **port**: port where the Context Broker instance is listening.
341
- - **service**: service that will be used in all the NGSI operations.
342
- - **subservice**: service that will be used in all the NGSI operations.
343
-
344
- The IoT Agent configuration object holds information about the IoT Agent that is being tested. It MUST contain the
345
- following attributes:
346
-
347
- - **host**: host where the IoT Agent instance is located.
348
- - **port**: port where the IoT Agent instance is listening.
349
- - **service**: service that will be used to group devices and device information.
350
- - **subservice**: subservice that will be used to group devices and device information.
351
-
352
301
  ---
353
302
 
354
303
  ## Licence
355
304
 
356
305
  The IoT Agent Node Library is licensed under [Affero General Public License (GPL) version 3](./LICENSE).
357
306
 
358
- © 2019 Telefonica Investigación y Desarrollo, S.A.U
307
+ © 2022 Telefonica Investigación y Desarrollo, S.A.U
359
308
 
360
309
  ### Are there any legal issues with AGPL 3.0? Is it safe for me to use?
361
310
 
@@ -364,8 +313,8 @@ related with the fact that different people assign different interpretations on
364
313
  used in these licenses. Due to this, some people believe that there is a risk in just _using_ software under GPL or AGPL
365
314
  licenses (even without _modifying_ it).
366
315
 
367
- For the avoidance of doubt, the owners of this software licensed under an AGPL-3.0 license
368
- wish to make a clarifying public statement as follows:
316
+ For the avoidance of doubt, the owners of this software licensed under an AGPL-3.0 license wish to make a clarifying
317
+ public statement as follows:
369
318
 
370
319
  > Please note that software derived as a result of modifying the source code of this software in order to fix a bug or
371
320
  > incorporate enhancements is considered a derivative work of the product. Software that merely uses or aggregates (i.e.
@@ -33,7 +33,7 @@ contributions are done using a pull request (PR). The detailed "protocol" used i
33
33
 
34
34
  * Direct commits to master branch (even single-line modifications) are not allowed. Every modification has to come as a PR
35
35
  * In case the PR is implementing/fixing a numbered issue, the issue number has to be referenced in the body of the PR at creation time
36
- * Anybody is welcome to provide comments to the PR (either direct comments or using the review feature offered by Github)
36
+ * Anybody is welcome to provide comments to the PR (either direct comments or using the review feature offered by GitHub)
37
37
  * Use *code line comments* instead of *general comments*, for traceability reasons (see comments lifecycle below)
38
38
  * Comments lifecycle
39
39
  * Comment is created, initiating a *comment thread*
@@ -142,7 +142,7 @@ point to each of the released versions of the project, they are permanent and th
142
142
 
143
143
  ## Change log
144
144
 
145
- The project contains a version changelog, called CHANGES_NEXT_RELEASE, that can be found in the root of the project.
145
+ The project contains a version change log, called CHANGES_NEXT_RELEASE, that can be found in the root of the project.
146
146
  Whenever a new feature or bug fix is going to be merged with `master`, a new entry should be added to this changelog.
147
147
  The new entry should contain the reference number of the issue it is solving (if any).
148
148
 
@@ -159,7 +159,7 @@ The process of making a release consists of the following steps:
159
159
  new target version (without any sufix), and PR into `master`. Also, in this task, the contents of the Change log are
160
160
  copied to the RPM spec.
161
161
  2. Create a tag from the last version of `master` named with the version number and push it to the repository.
162
- 3. Create the release in Github, from the created tag. In the description, add the contents of the Change log.
162
+ 3. Create the release in GitHub, from the created tag. In the description, add the contents of the Change log.
163
163
  4. Create a release branch from the last version of `master` named with the version number.
164
164
  5. Create a new task for preparing the next release, adding the sufix `-next` to the current version number (to signal
165
165
  this as the development version), and flush the contents of the CHANGES_NEXT_RELEASE file.
@@ -21,7 +21,6 @@
21
21
  - [Autoprovision configuration (autoprovision)](#autoprovision-configuration-autoprovision)
22
22
  - [Explicitly defined attributes (explicitAttrs)](#explicitly-defined-attributes-explicitattrs)
23
23
  - [Configuring operation to persist the data in Context Broker (appendMode)](#configuring-operation-to-persist-the-data-in-context-broker-appendmode)
24
- - [Old IoTAgent data migration](#old-iotagent-data-migration)
25
24
 
26
25
  ### Secured access to the Context Broker
27
26
 
@@ -198,7 +197,7 @@ e.g.:
198
197
  When provisioning devices for an NGSI-LD Context Broker, `type` values should typically correspond to one of the
199
198
  following:
200
199
 
201
- - `Property`, `Relationship`, `Geoproperty`
200
+ - `Property`, `Relationship`, `GeoProperty`, `LanguageProperty`
202
201
  - Native JSON types (e.g. `String`, `Boolean`, `Float` , `Integer` `Number`)
203
202
  - Temporal Properties (e.g. `Datetime`, `Date` , `Time`)
204
203
  - GeoJSON types (e.g `Point`, `LineString`, `Polygon`, `MultiPoint`, `MultiLineString`, `MultiPolygon`)
@@ -306,8 +305,8 @@ stored in the Context Broker by adding a new attribute to the entity with the sa
306
305
  element. By adding the field `explicitAttrs` with `true` value to device or group provision, the IoTAgent rejects the
307
306
  measure elements that are not defined in the mappings of device or group provision, persisting only the one defined in
308
307
  the mappings of the provision. If `explicitAttrs` is provided both at device and group level, the device level takes
309
- precedence. Additionally `explicitAttrs` can be used to define which meassures defined in JSON/JEXL array will be
310
- propagated to NGSI interface.
308
+ precedence. Additionally `explicitAttrs` can be used to define which meassures (identified by their attribute names, not
309
+ by their object_id) defined in JSON/JEXL array will be propagated to NGSI interface.
311
310
 
312
311
  The different possibilities are summarized below:
313
312
 
@@ -333,8 +332,8 @@ Case 3:
333
332
  "explicitAttrs": "['attr1','atrr2']"
334
333
  ```
335
334
 
336
- just measures defined in the array will be will be propagated to NGSI interface (note that in this case the value of
337
- `explicitAttrs` is not a JSON but a string that looks likes a JSON).
335
+ just measures defined in the array (identified by their attribute names, not by their object_id) will be will be
336
+ propagated to NGSI interface (note that in this case the value of `explicitAttrs` is not a JSON but a string that looks likes a JSON).
338
337
 
339
338
  Case 4:
340
339
 
@@ -347,8 +346,8 @@ depending on the JEXL expression evaluation:
347
346
  - If it evaluates to `true` every measure will be propagated to NGSI interface (as in case 1)
348
347
  - If it evaluates to `false` just measures defined in active, static (plus conditionally TimeInstant) will be
349
348
  propagated to NGSI interface (as in case 2)
350
- - If it evaluates to an array just measures defined in the array will be will be propagated to NGSI interface (as in
351
- case 3)
349
+ - If it evaluates to an array just measures defined in the array (identified by their attribute names, not by their object_id)
350
+ will be will be propagated to NGSI interface (as in case 3)
352
351
 
353
352
  ### Configuring operation to persist the data in Context Broker (appendMode)
354
353
 
@@ -441,7 +440,7 @@ events in the IoT Agent with the configured type name will be marked as events.
441
440
 
442
441
  ##### Timestamp Processing Plugin (timestampProcess)
443
442
 
444
- This plugin processes the entity attributes looking for a `TimeInstant` attribute. If one is found, for NGSIv2, the
443
+ This plugin processes the entity attributes looking for a `TimeInstant` attribute. If one is found, for NGSI v2, the
445
444
  plugin adds a `TimeInstant` attribute as metadata for every other attribute in the same request. With NGSI-LD, the
446
445
  Standard `observedAt` property-of-a-property is used instead.
447
446
 
@@ -539,35 +538,3 @@ subscription payload.
539
538
  For each attribute in the `reverse` array, an expression must be defined to calculate its value based on the
540
539
  notification attributes. This value will be passed to the underlying protocol with the `object_id` name. Details about
541
540
  how the value is then progressed to the device are protocol-specific.
542
-
543
- ### Old IoTAgent data migration
544
-
545
- In order to ease the transition from the old IoTAgent implementation (formerly known as IDAS) to the new Node.js based
546
- implementations, a data migration tool has been developed. This data migration tool has been integrated as a command in
547
- the IoTAgent command-line tester.
548
-
549
- In order to perform a full migration, follow this steps:
550
-
551
- - From the project root, start the command-line tester:
552
-
553
- ```bash
554
- bin/iotAgentTester.js
555
- ```
556
-
557
- - Configure the MongoDB host and port, and the origin Database (that holds the data to be migrated):
558
-
559
- ```bash
560
- configMigration localhost 27017 originDB
561
- ```
562
-
563
- - Launch the migration, using the special value "\*" as service and subservice
564
-
565
- ```bash
566
- migrate targetDB * *
567
- ```
568
-
569
- Some warnings may appear with the "Attribute [_id] was not found for item translation" message during the migration.
570
- They show the values existing in the original DB that had no translation for the target DB.
571
-
572
- If you want to restrict the migration for certain services and subservices, just substitute the `*` value for the
573
- particular service and subservice you want to use.
package/doc/api.md CHANGED
@@ -92,6 +92,7 @@ correspondence between the API resource fields and the same fields in the databa
92
92
  | `internal_attributes` | `internalAttributes` | optional section with free format, to allow specific IoT Agents to store information along with the devices in the Device Registry. |
93
93
  | `expressionLanguage` | `expresionLanguage` | optional boolean value, to set expression language used to compute expressions, possible values are: legacy or jexl. When not set or wrongly set, `legacy` is used as default value. |
94
94
  | `explicitAttrs` | `explicitAttrs` | optional field to support selective ignore of measures so that IOTA doesn’t progress. See details in [specific section](advanced-topics.md#explicitly-defined-attributes-explicitattrs) |
95
+ | `entityNameExp` | `entityNameExp` | optional field to allow use expressions to define entity name, instead default `id` and `type` |
95
96
  | `ngsiVersion` | `ngsiVersion` | optional string value used in mixed mode to switch between **NGSI-v2** and **NGSI-LD** payloads. Possible values are: `v2` or `ld`. The default is `v2`. When not running in mixed mode, this field is ignored. |
96
97
  | `defaultEntityNameConjunction` | `defaultEntityNameConjunction` | optional string value to set default conjunction string used to compose a default `entity_name` when is not provided at device provisioning time. |
97
98
  | `autoprovision` | `autoprovision` | optional boolean: If `false`, autoprovisioned devices (i.e. devices that are not created with an explicit provision operation but when the first measure arrives) are not allowed in this group. Default (in the case of omitting the field) is `true`. |
@@ -247,15 +248,15 @@ the API resource fields and the same fields in the database model.
247
248
 
248
249
  #### Attribute lists
249
250
 
250
- In the device model there are three list of attributes that can be declared: attributes, lazy and commands. All of them
251
- have the same syntax, an object containing the following attributes:
251
+ In the group/device model there are three list of attributes that can be declared: attributes, lazy and commands. All of
252
+ them have the same syntax, an object containing the following attributes:
252
253
 
253
254
  - **object_id** (optional): name of the attribute as coming from the device.
254
255
  - **name** (mandatory): ID of the attribute in the target entity in the Context Broker.
255
256
  - **type** (mandatory): name of the type of the attribute in the target entity.
256
257
  - **metadata** (optional): additional static metadata for the attribute in the target entity. (e.g. `unitCode`)
257
258
 
258
- Some transformation plugins also allow the use of the following optional attributes:
259
+ Some transformation plugins also allow the use of the following optional fields:
259
260
 
260
261
  - **expression**: indicates that the value of the target attribute will not be the plain value or the measurement, but
261
262
  an expression based on a combination of the reported values. See the
@@ -268,6 +269,16 @@ Some transformation plugins also allow the use of the following optional attribu
268
269
  - **reverse**: add bidirectionality expressions to the attribute. See the **bidirectionality** transformation plugin
269
270
  in the [Data Mapping Plugins section](advanced-topics.md#bidirectionality-plugin-bidirectional) for details.
270
271
 
272
+ Additionally for commands (which are attributes of type `command`) the following fields are optional:
273
+
274
+ - **expression** indicates that the value of the target command will not be the plain value or the command, but an
275
+ expression based on a combination of the returned values. See the
276
+ [Expression Language definition](expressionLanguage.md) for details
277
+ - **payloadType**: indicates how command payload will be transformed before be sent to device. Please have a look to
278
+ particular IOTAs documentation for allowed values of this field in each case.
279
+ - **contentType**: `content-type` header used when send command by HTTP transport (ignored in other kinds of
280
+ transports)
281
+
271
282
  See the transformation plugins Section for more details.
272
283
 
273
284
  #### Advice on Attribute defintions
@@ -342,6 +342,21 @@ Will now generate the following NGSI v2 payload:
342
342
  }
343
343
  ```
344
344
 
345
+ ## Available keys for all Expressions
346
+
347
+ Apart from measurement transformations (including multientity cases), expressions can be used in the following cases:
348
+
349
+ - Default EntityName defined at group level and used for provision and autoprovision of devices
350
+ - Commands (push and pull)
351
+ - Endpoint of push http commands
352
+
353
+ In all of them the following device data is available to all expressions
354
+
355
+ - `id`: device ID
356
+ - `type`: device type
357
+ - `service`: device service
358
+ - `subservice`: device subservice
359
+
345
360
  ## JEXL Based Transformations
346
361
 
347
362
  The recommended expression language for the IoTAgent Library is [JEXL](https://github.com/TomFrost/jexl). To use JEXL,
@@ -474,6 +489,8 @@ Current common transformation set:
474
489
  | slice: (arr, init, end) | `arr.slice(init,end);` |
475
490
  | addset: (arr, x) | <code>{ return Array.from((new Set(arr)).add(x)) }</code> |
476
491
  | removeset: (arr, x) | <code>{ let s = new Set(arr); s.delete(x); return Array.from(s) }</code> |
492
+ | touppercase: (val) | `String(val).toUpperCase()` |
493
+ | tolowercase: (val) | `String(val).toLowerCase()` |
477
494
 
478
495
  You have available this [JEXL interactive playground][99] with all the transformations already loaded, in which you can
479
496
  test all the functions described above.
@@ -163,16 +163,15 @@ The equivalent **NGSI-LD** payload is associated to an update operation (PATCH `
163
163
 
164
164
  ```json
165
165
  {
166
- "temperature": {
167
- "type": "Property",
168
- "value": "23"
169
- },
170
- "pressure" :{
171
- "type": "Property",
172
- "value": "720"
173
- }
166
+ "temperature": {
167
+ "type": "Property",
168
+ "value": "23"
169
+ },
170
+ "pressure": {
171
+ "type": "Property",
172
+ "value": "720"
173
+ }
174
174
  }
175
-
176
175
  ```
177
176
 
178
177
  #### R1 - UpdateContext (response)
@@ -285,7 +284,8 @@ This is an **NGSI-LD** response to `/ngsi-ld/v1/entities/<entity>`
285
284
  ```
286
285
 
287
286
  In this case, the response to the QueryContext is a list of responses, one for each requested entity, indicating whether
288
- the information has been retrieved successfully (in the HTTP Status code) and the requested Context information in the body of the response.
287
+ the information has been retrieved successfully (in the HTTP Status code) and the requested Context information in the
288
+ body of the response.
289
289
 
290
290
  Application level errors can be specified for each entity in this payload.
291
291
 
@@ -305,7 +305,7 @@ Context Element, but with the request as a whole.
305
305
 
306
306
  ### Scenario 1: active attributes
307
307
 
308
- ![General ](./img/scenario1.png "Scenario 1: active attributes")
308
+ ![General ](./img/scenario1.png 'Scenario 1: active attributes')
309
309
 
310
310
  In this scenario, the interaction is started by the device, that is going to actively send a piece of data to the
311
311
  platform. When the IoTAgent receives the data, it sends it to the Context Broker through a P1 request. The Context
@@ -319,7 +319,7 @@ updating process, and can occur at any time (they are to completely different pr
319
319
 
320
320
  ### Scenario 2: lazy attributes
321
321
 
322
- ![General ](./img/scenario2.png "Scenario 2: lazy attributes")
322
+ ![General ](./img/scenario2.png 'Scenario 2: lazy attributes')
323
323
 
324
324
  This scenario requires that the attributes that are going to be requested are marked as provided by the IoT Agent,
325
325
  through a registration process (NGSIv9). Examples of this registration process will be provided in the practical section
@@ -345,7 +345,7 @@ queries (and thus P2 and R2 payloads).
345
345
 
346
346
  ### Scenario 3: commands
347
347
 
348
- ![General ](./img/scenario3.png "Scenario 3: commands")
348
+ ![General ](./img/scenario3.png 'Scenario 3: commands')
349
349
 
350
350
  This scenario requires that the attributes that are going to be requested are marked as provided by the IoT Agent,
351
351
  through a registration process (NGSIv9). Examples of this registration process will be provided in the practical section
@@ -359,15 +359,26 @@ use three kinds of attributes:
359
359
  - An attribute will be used as the _input attribute_ (the attribute registered in the Context Provider). This input
360
360
  attribute can be thought of as a command issued to the IoTAgent (from here the name of the scenario) whose value is
361
361
  the set of arguments of the command. Only updateContext operations will be used to interact with this attributes.
362
+ Typically this attribute is of type `command`.
362
363
 
363
364
  - Another attribute will be used as the _result attribute_. This attribute will be updated from the IoTAgent, and its
364
365
  value stored in the Context Broker. This attribute will contain the result of the command (this result can be
365
366
  information in case the command was a "information retrieval" command or the result of an action if it was an
366
- "actuator command"). Typically, the name of this attribute will be the same of the input attribute, with an
367
- additional sufix (`_info`).
367
+ "actuator command"). Initially its value is empty. Typically, the name of this attribute will be the same of the
368
+ input attribute, with an additional sufix (`_info`) and the type is `commandResult`.
368
369
 
369
370
  - Another attribute with the same characteristics as the later will be used to indicate whether the command has ended
370
- successfully or whether an error has been reported.
371
+ successfully or whether an error has been reported. Typically, the name of this attribute will be the same of the
372
+ input attribute, with an additional sufix (`_status`) and the type is `commandStatus`. The possible values of this
373
+ attribute are: `ERROR`, `EXPIRED`, `PENDING`, `DELIVERED`, `UNKNOWN` with the following meanings:
374
+ - ERROR: There is a kind of error.
375
+ - EXPIRED: This meens that pull command has been expired without be delivered to device according with
376
+ `pollingExpiration` time defined by config.
377
+ - PENDING: In a PUSH command means that command has been sent to device but not device has still not respond. In a
378
+ PULL command means that command has been stored and device still has no ask for it.
379
+ - DELIVERED: The command has been delivered to phisical device.
380
+ - OK: The command has been delivered and device has respond.
381
+ - UNKNOWN: This is the initial value.
371
382
 
372
383
  In this scenario, the interaction is also initiated by the User. The user starts the scenario by sending an update
373
384
  request P1 to the Context Broker, to the input attribute (1). The Context Broker redirects this same payload to the
@@ -835,7 +846,6 @@ The IoT Agent detects the selected attribute is a command, and replies to the Co
835
846
  ```json
836
847
  [
837
848
  {
838
-
839
849
  "type": "device",
840
850
  "id": "Dev0001",
841
851
  "switch": {
@@ -854,7 +864,6 @@ The Context Broker, forwards the same response to the user, thus replying the or
854
864
  ```json
855
865
  [
856
866
  {
857
-
858
867
  "type": "device",
859
868
  "id": "Dev0001",
860
869
  "switch": {
@@ -882,11 +891,11 @@ curl -X POST -H "Content-Type: application/json" -H "Accept: application/json" -
882
891
  "isPattern": "false",
883
892
  "id": "Dev0001",
884
893
  "switch_info": {
885
- "type": "command_info",
894
+ "type": "commandResult",
886
895
  "value": "Switched successfully!"
887
896
  },
888
897
  "switch_status": {
889
- "type": "command_status",
898
+ "type": "commandStatus",
890
899
  "value": "OK"
891
900
  }
892
901
  }
@@ -906,11 +915,11 @@ The Context Broker replies to the IoT Agent with a R1 payload (200 OK):
906
915
  "type": "device",
907
916
  "id": "Dev0001",
908
917
  "switch_info": {
909
- "type": "command_info",
918
+ "type": "commandResult",
910
919
  "value": ""
911
920
  },
912
- "switch_status": {
913
- "type": "command_status",
921
+ "switch_status": {
922
+ "type": "commandStatus",
914
923
  "value": ""
915
924
  }
916
925
  }
@@ -936,8 +945,8 @@ curl -X POST -H "Content-Type: application/json" -H "Accept: application/json" -
936
945
  }
937
946
  ],
938
947
  "attributes": [
939
- "switch_info",
940
- "switch_status"
948
+ "switch_info",
949
+ "switch_status"
941
950
  ]
942
951
  }' "https://<platform-ip>:10027/v2/op/query"
943
952
  ```
@@ -947,20 +956,18 @@ The Context Broker replies with all the desired data, in R2 format (200 OK):
947
956
  ```json
948
957
  [
949
958
  {
950
-
951
959
  "type": "device",
952
960
  "id": "Dev0001",
953
961
  "switch_info": {
954
- "type": "command_info",
962
+ "type": "commandResult",
955
963
  "value": "Switched successfully!"
956
964
  },
957
965
  "switch_status": {
958
- "type": "command_status",
966
+ "type": "commandStatus",
959
967
  "value": "OK"
960
968
  }
961
969
  }
962
970
  ]
963
-
964
971
  ```
965
972
 
966
973
  ### Scenario 3: commands (error)
@@ -978,11 +985,11 @@ curl -X POST -H "Content-Type: application/json" -H "Accept: application/json" -
978
985
  "isPattern": "false",
979
986
  "id": "Dev0001",
980
987
  "switch_info":{
981
- "type": "command_info",
988
+ "type": "commandResult",
982
989
  "value": "The switch could not be switched due to the following error: switch blocked"
983
990
  },
984
991
  "switch_status":{
985
- "type": "command_status",
992
+ "type": "commandStatus",
986
993
  "value": "ERROR"
987
994
  }
988
995
  }
@@ -999,11 +1006,11 @@ In this case, the Context Broker reply with the following response (200 OK):
999
1006
  "type": "device",
1000
1007
  "id": "Dev0001",
1001
1008
  "switch_info": {
1002
- "type": "command_info",
1009
+ "type": "commandResult",
1003
1010
  "value": ""
1004
1011
  },
1005
1012
  "switch_status": {
1006
- "type": "command_status",
1013
+ "type": "commandStatus",
1007
1014
  "value": ""
1008
1015
  }
1009
1016
  }
package/doc/operations.md CHANGED
@@ -99,11 +99,11 @@ The following table shows the alarms that can be raised in the IoTAgent library.
99
99
  log starting with the prefix "Raising [%s]:" (where %s is the alarm name). All the alarms are released by an info log
100
100
  with the prefix "Releasing [%s]". These texts appear in the `msg=` field of the generic log record format.
101
101
 
102
- | Alarm name | Severity | Description |
103
- | :---------- | :----------- | :------------------------------------------------------- |
104
- | MONGO-ALARM | **Critical** | Indicates an error in the MongoDB connectivity |
105
- | ORION-ALARM | **Critical** | Indicates a persistent error accesing the Context Broker |
106
- | IOTAM-ALARM | **Critical** | Indicates a persistent error accessing the IoTAM |
102
+ | Alarm name | Severity | Description |
103
+ | :------------- | :----------- | :------------------------------------------------------- |
104
+ | MONGO-ALARM_XX | **Critical** | Indicates an error in the MongoDB connectivity |
105
+ | ORION-ALARM | **Critical** | Indicates a persistent error accesing the Context Broker |
106
+ | IOTAM-ALARM | **Critical** | Indicates a persistent error accessing the IoTAM |
107
107
 
108
108
  while the 'Severity' criterium is as follows:
109
109
 
@@ -111,6 +111,9 @@ while the 'Severity' criterium is as follows:
111
111
  - **Major** - The system has a problem that degrades the service and must be addressed
112
112
  - **Warning** - It is happening something that must be notified
113
113
 
114
+ In order to identify the internal flow which origins a mongo alarm, there is a suffix `_XX` which identifies from `01` to
115
+ `11` each flow.
116
+
114
117
  ## Error naming code
115
118
 
116
119
  Every error has a code composed of a prefix and an ID, codified with the following table:
@@ -0,0 +1,4 @@
1
+ mkdocs==1.2.3
2
+ Pygments==2.9.0
3
+ Markdown==3.3.4
4
+ jinja2==3.0.0
@@ -13,7 +13,7 @@ only, and this section may be revised to provide newer information at any time.
13
13
 
14
14
  Disclaimer:
15
15
 
16
- - This section has been last updated in March 2020. Please take into account its content could be obsolete.
16
+ - This section has been last updated in March 2022. Please take into account its content could be obsolete.
17
17
  - Note we develop this software in Agile way, so development plan is continuously under review. Thus, this roadmap has
18
18
  to be understood as rough plan of features to be done along time which is fully valid only at the time of writing
19
19
  it. This roadmap has not be understood as a commitment on features and/or dates.
@@ -25,19 +25,17 @@ Disclaimer:
25
25
  The following list of features are planned to be addressed in the short term, and incorporated in a release of the
26
26
  product:
27
27
 
28
- - Selectively ignore measure in the southbound interface (community)
29
- - JEXL support in expressions (community)
30
28
  - cgroup literal in configuration groups management API (community)
31
29
  - Metadata processing improvements
32
- - Add MongoDB authentication support
30
+ - Improve command functionalities (binary data + expression + mapping)
33
31
 
34
32
  ### Medium term
35
33
 
36
34
  The following list of features are planned to be addressed in the medium term, typically within the subsequent
37
35
  release(s) generated in the next 9 months after the next planned release:
38
36
 
39
- - Support for "delta" measures (i.e. "temperature _increased_ in 5 degress" instead of "temperature _is_ 25")
40
- - Removal support for NGSIv1 (which currently is deprecated)
37
+ - Accept JEXL Expressions for entity name in autoprovisioned devices (#1145)
38
+ - Refactor entities-NGSI-v2.js module (#1166)
41
39
 
42
40
  ### Long term
43
41
 
@@ -48,3 +46,20 @@ us if you wish to get involved in the implementation or influence the roadmap:
48
46
  - Incremental introduccion of ECMAScript6 syntax (previous analysis of which sub-set of interesting aspect we want to
49
47
  take)
50
48
  - Use the lightweight ingestion mechanism for connection oriented updates implemented in Context Broker
49
+ - Add support to other transport protocols (BacNET, Modbus, etc)
50
+
51
+ ### Features already completed
52
+
53
+ The following list contains all features that were in the roadmap and have already been implemented.
54
+
55
+ - Support for "delta" measures (i.e. "temperature _increased_ in 5 degress" instead of "temperature _is_ 25")
56
+ - Allow to handle binary messages ([iota-ul#530](https://github.com/telefonicaid/iotagent-ul/issues/530))
57
+ - Removal support for NGSIv1 (#966) ([2.18.0](https://github.com/telefonicaid/iotagent-node-lib/releases/tag/2.18.0))
58
+ - Selectively ignore measure in the southbound interface
59
+ ([iotagent-json#416](https://github.com/telefonicaid/iotagent-json/issues/416),
60
+ [iotagent-ul#372](https://github.com/telefonicaid/iotagent-ul/issues/372))
61
+ ([2.13.0](https://github.com/telefonicaid/iotagent-node-lib/releases/tag/2.13.0))
62
+ - JEXL support in expressions (#801, #687, #868)
63
+ ([2.13.0](https://github.com/telefonicaid/iotagent-node-lib/releases/tag/2.13.0))
64
+ - Add MongoDB authentication support (#844)
65
+ ([2.12.0](https://github.com/telefonicaid/iotagent-node-lib/releases/tag/2.12.0))