How to show an entity from OrionContextBroker in the MapViewer widget

283 views Asked by At

I am trying to show an entity stored in my OrionContextBroker instance in the Wirecloud MapViewer widget. I create the context using this JSON POST REST request to miOrionInstance:1026/v1/updateContext like this:

{
    "contextElements": [
        {
            "type": "Room",
            "isPattern": "false",
            "id": "Room1",
            "attributes": [
            {
                "name": "position",
                "type": "string",
                "value": "43.47258, -3.8026643"
            }
            ]
        }
    ],
    "updateAction": "APPEND"
}

I am able to recover this information through the NGSIUpdater Widget with no problem, but I am unable to show this entity in the MapViewer widget. I have tried to wire the NGSISource Operator to the NGSIEntityToPol Operator and finally to the MapViewer Widget (in Insert/Update centered Pol). The configuration of the NGSISource operator is:

NGSI server URL: http://miOrionInstanceIP:1026
NGSI proxy URL: http://ngsiproxy.lab.fi-ware.org
NGSI entity types: Room
Id Pattern:
Monitored NGSI Attribures: position

And the configuration of the NGSIEntityToPol Operator is the following:

Coordinates attribute: position

But nothing appears in the map.

Thanks,

1

There are 1 answers

2
Álvaro Arranz On BEST ANSWER

The "NGSI entity types" value is incorrect, it should contain the entity type of the entities you are interested in (e.g. Room). The rest of your configuration seems correct, so if changing this setting doesn't solve your problems, you may be facing the same problems described at this question.