Skip to content

Query results as multi-line JSON Objects instead of JSON Array #53

@fgalan

Description

@fgalan

Currently API.md specifies that the response to a query or doQuery operation is a JSON array with the result, like this:

[
    {
        "timeinstant": "2020-08-17 18:25:28.332+01",
        "activity": 12,
        "animalbreed": "Merina",
        "animalname": "TUNA",
        "animalspecies": "Ovino",
        ...
    },
    ...
]

Instead of that, it would be better to return a list of JSON Object (an object per line). That way it would be easier to process in a stream way (with the current approach, the client needs to wait until the whole response is receive, an this can be a lot if the response has thousands of results)

I think that's the way other tools works (like mongoexport)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions