1

I would like to know if it is possible to consult older data using orion Context Broker.

EG: I have a temperature attribute and the value is constantly changing (4,5,9,10,30,2). In the examples and specification i had the impression it is only possible to consult the latest value (in this case 2).

Is this accurate? if so is the older data deleted?

fgalan
  • 11,732
  • 9
  • 46
  • 89
Mauro Cruz
  • 105
  • 1
  • 1
  • 8

1 Answers1

1

It's correct. That's the way in which Orion works, and makes sense for the most of the use cases. Orion is a context broker, so whenever the context changes (and an attribute value is part of that context) then Orion returns the new value.

However, if you want to have historical context there are FIWARE solutions for that. In particular, Cygnus can be used to persist such historical context in several storage backends (HDFS, MySQL, CKAN, etc.). Among these backends, the Short Term Historic could be particularly interesting in your case, given that its provides a NGSI-like REST API interface for getting secuences of values, as the one you are showing.

Please have a look to the documentation on these componentes for further details.

fgalan
  • 11,732
  • 9
  • 46
  • 89
  • 1
    I took a look at the documentation and installed Fiware STH. The problem is that when i subscribe to an orion context then consult, the values are null. In the STH log it says: ERROR when collecting the raw data collection for retrieval (the collection may not exist). I will create another post for this specific issue. Thank you very much. The post can be found here: https://stackoverflow.com/questions/45867677/sth-getting-historical-raw-context – Mauro Cruz Aug 24 '17 at 17:29
  • Great! That's the way... using new question post for new problems. I hope STH experts could have a look and answer. – fgalan Aug 25 '17 at 07:38