Skip to content
This repository has been archived by the owner on Apr 4, 2023. It is now read-only.

Querying multiple data streams: Fix the sorting #72

Closed
dschowta opened this issue Jul 2, 2020 · 0 comments
Closed

Querying multiple data streams: Fix the sorting #72

dschowta opened this issue Jul 2, 2020 · 0 comments

Comments

@dschowta
Copy link
Member

dschowta commented Jul 2, 2020

Currently the when HDS is queried for multiple data streams, the sorting is not time based, rather it is SenML name based. e.g:

[
    {
      "n": "kitchen/lamp",
      "t": 1583860227.532632,
      "vb": true
    },
    {
      "n": "kitchen/lamp",
      "t": 1583860222.5328066,
      "vb": false
    },
    {
      "n": "terrace/temperature",
      "u": "Cel",
      "t": 1583860227.5185332,
      "v": 19.115799670689995
    },
    {
      "n": "terrace/temperature",
      "u": "Cel",
      "t": 1583860222.5185845,
      "v": 20.56714613731785
    }
]

In the above example, different records with same SenML names are ordered together, which should be ordered in the time based as follows:

[
    {
      "n": "kitchen/lamp",
      "t": 1583860227.532632,
      "vb": true
    },
    {
      "n": "terrace/temperature",
      "u": "Cel",
      "t": 1583860227.5185332,
      "v": 19.115799670689995
    },
    {
      "n": "kitchen/lamp",
      "t": 1583860222.5328066,
      "vb": false
    },
    {
      "n": "terrace/temperature",
      "u": "Cel",
      "t": 1583860222.5185845,
      "v": 20.56714613731785
    }
]

This would be useful especially when the query spans over multiple pages. Then it would be difficult for the clients to wait until the entire package has arrived.

dschowta added a commit that referenced this issue Jul 7, 2020
Grpcsync :
closes issue #72 #70 #62 (partially)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant