tagomoris / presto-client-node

Distributed query engine Presto client library for node.js
MIT License
126 stars 57 forks source link

Clarification needed on response #16

Closed Santhoshas closed 7 years ago

Santhoshas commented 7 years ago

DATA callback method: data [function(error, data, columns, stats) :optional] - called per fetch of query results (may be called 2 or more)

  1. Is it possible to get results in a single callback?
  2. Is it possible to get result data in SUCCESS callback method? - how to differentiate 201 and 204?
tagomoris commented 7 years ago

No for both, for now. It's not difficult to add a callback function to get data at once at the end of query result. But Presto query results are sometimes very large, and containing such data on memory makes node.js process very unstable. So I don't prefer such approach.

Santhoshas commented 7 years ago

Thank you