i tried stored meta data entity seems cygnus storing entity data no meta data stored in data base.
here how update entity using ngsi v1 updatecontext
{ "contextelements": [ { "type": "dummymeta", "ispattern": "false", "id": "dummymeta", "attributes": [ { "name": "dummy", "type": "float", "value": "26.5", "metadatas": [ { "name": "accuracy", "type": "float", "value": "1" } ] } ] } ], "updateaction": "append" }
here payload subscription:
{ "entities": [ { "id": "dummymeta", "type": "dummymeta", "ispattern": "false" } ], "attributes": [ "dummy" ] , "reference": "http://cygnusserver.ddns.net:5050/notify", "duration":"p1m", "notifyconditions": [ { "type": "onchange", "condvalues": [ "dummy" ] } ], "throttling": "pt5s" }
here how stored in data base
> db['kura_/egmmqtt_dummymeta_dummymeta'].find().sort({$natural:-1}) { "_id" : objectid("57c929d8902531258a3c6ed0"), "recvtime" : isodate("2016-09-02t07:27:18.331z"), "attrname" : "dummy", "attrtype" : "float", "attrvalue" : "26.5" } { "_id" : objectid("57c92990902531258a3c6ecc"), "recvtime" : isodate("2016-09-02t07:26:04.148z"), "attrname" : "dummy", "attrtype" : "float", "attrvalue" : "26.5" }
what missing able store whole information (data , metadata) attribute? in advance help!
mongodb sink not save metadata design. requirement our internal products using cygnus.
being said that, think should not difficult modify code side in order save metadata.
alternatively, can create issue optionally save metadata when configured through configuration parameter. nevertheless, cannot commit implementation date.
Comments
Post a Comment