Uploaded image for project: 'Help-Desk'
  1. Help-Desk
  2. HELP-15323

[fiware-stackoverflow] Orion subscriptions do not detect the removal of entities

    Details

      Description

      Created question in FIWARE Q/A platform on 16-01-2019 at 16:01
      Please, ANSWER this question AT https://stackoverflow.com/questions/54220061/orion-subscriptions-do-not-detect-the-removal-of-entities

      Question:
      Orion subscriptions do not detect the removal of entities

      Description:
      Subscriptions detect the creation and update of entities but do not detect the removal of entities.

      Subscription creation:

      POST http://myhost:orion_port/v2/subscriptions

      {
      "description": "Send a notification to detect any change",
      "subject": {
      "entities": [

      { "idPattern": ".*" }

      ]
      },
      "notification": {
      "http":

      { "url": "http://myhost:myport/myendpoint" }

      }
      }

      Entity creation:

      POST http://myhost:iot_aget_json_port/iot/devices

      {
      "devices": [{
      "device_id": "entity_test_agent",
      "entity_name": "entity_test_orion",
      "entity_type": "test",
      "transport": "HTTP",
      "protocol": "IoTA-JSON",
      "attributes": [

      { "object_id": "status", "name": "status", "type": "Text" }

      ],
      "static_attributes": [

      { "name": "name", "type": "Text", "value": "Test" }

      ]
      }]

      }

      Entity update:

      PUT http://myhost:orion_port/v2/entities/entity_test_orion/attrs/name

      { "value": true }

      Delete entity:

      DELETE http://myhost:orion_port/v2/entities/entity_test_orion

      DELETE http://myhost:iot_aget_json_port/iot/devices/entity_test_agent

      First, I send the subscription creation to detect changes in entities.

      Later, I create an entity and the subscription is executed without problems. Then I update the entity name and I receive the subscription again perfectly, but if I delete the entity I do not receive any event.

      There are any way to receive subscription events to detect when an entity is deleted?

        Activity

        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open In Progress In Progress
        15h 47m 1 Jose Manuel Cantera 17/Jan/19 9:53 AM
        In Progress In Progress Answered Answered
        6s 1 Jose Manuel Cantera 17/Jan/19 9:53 AM
        Answered Answered Closed Closed
        11h 12m 1 Backlog Manager 17/Jan/19 9:05 PM
        fla Fernando Lopez made changes -
        Fix Version/s 2021 [ 12600 ]
        Hide
        backlogmanager Backlog Manager added a comment -

        2019-01-17 21:05|UPDATED status: transition Finish| # answers= 1, accepted answer= True

        Show
        backlogmanager Backlog Manager added a comment - 2019-01-17 21:05|UPDATED status: transition Finish| # answers= 1, accepted answer= True
        backlogmanager Backlog Manager made changes -
        Resolution Done [ 10000 ]
        Status Answered [ 10104 ] Closed [ 6 ]
        jmcantera Jose Manuel Cantera made changes -
        Status In Progress [ 3 ] Answered [ 10104 ]
        jmcantera Jose Manuel Cantera made changes -
        Status Open [ 1 ] In Progress [ 3 ]
        fla Fernando Lopez made changes -
        Assignee Jose Manuel Cantera [ jmcantera ]
        fla Fernando Lopez made changes -
        HD-Enabler Orion [ 10875 ]
        Description
        Created question in FIWARE Q/A platform on 16-01-2019 at 16:01
        {color: red}Please, ANSWER this question AT{color} https://stackoverflow.com/questions/54220061/orion-subscriptions-do-not-detect-the-removal-of-entities


        +Question:+
        Orion subscriptions do not detect the removal of entities

        +Description:+
        Subscriptions detect the creation and update of entities but do not detect the removal of entities.


        Subscription creation:


        POST http://myhost:orion_port/v2/subscriptions

        {
            "description": "Send a notification to detect any change",
            "subject": {
                "entities": [{
                    "idPattern": ".*"
                }]
            },
            "notification": {
                "http": {
                    "url": "http://myhost:myport/myendpoint"
                }
            }
        }



        Entity creation:


        POST http://myhost:iot_aget_json_port/iot/devices

        {
            "devices": [{
                "device_id": "entity_test_agent",
                "entity_name": "entity_test_orion",
                "entity_type": "test",
                "transport": "HTTP",
                "protocol": "IoTA-JSON",
                "attributes": [{
                     "object_id": "status",
                     "name": "status",
                     "type": "Text"
                }],
                "static_attributes": [{
                     "name": "name",
                     "type": "Text",
                     "value": "Test"
                }]
            }]


        }


        Entity update:


        PUT http://myhost:orion_port/v2/entities/entity_test_orion/attrs/name

        {
             "value": true
        }



        Delete entity:


        DELETE http://myhost:orion_port/v2/entities/entity_test_orion

        DELETE http://myhost:iot_aget_json_port/iot/devices/entity_test_agent

        First, I send the subscription creation to detect changes in entities.

        Later, I create an entity and the subscription is executed without problems. Then I update the entity name and I receive the subscription again perfectly, but if I delete the entity I do not receive any event.

        There are any way to receive subscription events to detect when an entity is deleted?
        Created question in FIWARE Q/A platform on 16-01-2019 at 16:01
        {color: red}Please, ANSWER this question AT{color} https://stackoverflow.com/questions/54220061/orion-subscriptions-do-not-detect-the-removal-of-entities


        +Question:+
        Orion subscriptions do not detect the removal of entities

        +Description:+
        Subscriptions detect the creation and update of entities but do not detect the removal of entities.


        Subscription creation:


        POST http://myhost:orion_port/v2/subscriptions

        {
            "description": "Send a notification to detect any change",
            "subject": {
                "entities": [{
                    "idPattern": ".*"
                }]
            },
            "notification": {
                "http": {
                    "url": "http://myhost:myport/myendpoint"
                }
            }
        }



        Entity creation:


        POST http://myhost:iot_aget_json_port/iot/devices

        {
            "devices": [{
                "device_id": "entity_test_agent",
                "entity_name": "entity_test_orion",
                "entity_type": "test",
                "transport": "HTTP",
                "protocol": "IoTA-JSON",
                "attributes": [{
                     "object_id": "status",
                     "name": "status",
                     "type": "Text"
                }],
                "static_attributes": [{
                     "name": "name",
                     "type": "Text",
                     "value": "Test"
                }]
            }]


        }


        Entity update:


        PUT http://myhost:orion_port/v2/entities/entity_test_orion/attrs/name

        {
             "value": true
        }



        Delete entity:


        DELETE http://myhost:orion_port/v2/entities/entity_test_orion

        DELETE http://myhost:iot_aget_json_port/iot/devices/entity_test_agent

        First, I send the subscription creation to detect changes in entities.

        Later, I create an entity and the subscription is executed without problems. Then I update the entity name and I receive the subscription again perfectly, but if I delete the entity I do not receive any event.

        There are any way to receive subscription events to detect when an entity is deleted?
        backlogmanager Backlog Manager made changes -
        Field Original Value New Value
        Component/s FIWARE-TECH-HELP [ 10278 ]
        Hide
        backlogmanager Backlog Manager added a comment -

        2019-01-16 18:05|CREATED monitor | # answers= 0, accepted answer= False

        Show
        backlogmanager Backlog Manager added a comment - 2019-01-16 18:05|CREATED monitor | # answers= 0, accepted answer= False
        backlogmanager Backlog Manager created issue -

          People

          • Assignee:
            jmcantera Jose Manuel Cantera
            Reporter:
            backlogmanager Backlog Manager
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: