acdh-oeaw / arche-core

MIT License
0 stars 1 forks source link

Avoid buffering the whole response in memory for read-only requests #31

Closed zozlak closed 1 year ago

zozlak commented 1 year ago

To be able to report an error using HTTP response code we must wait with sending the output after the error handling code. But as the error handling code may want to rollback the transaction which would delete all cursors which haven't been read yet. Anyway, at least for the read-only requests, it should be possible to find a way to avoid buffering them in the memory.

zozlak commented 1 year ago

Resolved on the v3.8 branch (f9e59e2bb12a97b845ccfb76e3e3edfa4603288a).

Confirmed by the tests conducted as a part of the arche-docs api performance measures