BlackLab icon indicating copy to clipboard operation
BlackLab copied to clipboard

Reimplement/replace DataStream with Jackson Stream API

Open jan-niestadt opened this issue 3 years ago • 1 comments

Jackson Streaming API does most of what DataStream does now. Exceptions are contextList (lists of values for annotations that get a different structure in XML and JSON) and all-in-one status/error responses.

We could start by reimplementing DataStream using Jackson, which would get rid of the DataStream* subclasses. Eventually we might want to eliminate DataStream altogether and just call Jackson directly.

Apart from getting rid of some code, this will give an error message if you try to construct invalid JSON/XML, which DataStream does not.

This is a bit of work but not difficult.

jan-niestadt avatar Feb 10 '22 09:02 jan-niestadt

(we should look into how Solr writes it XML/JSON responses, and consider using that instead of Jackson)

jan-niestadt avatar Jul 04 '22 10:07 jan-niestadt