Closed dmfenton closed 8 years ago
So a different implementation of getting data into the database? It looks to me like that process is one that silently hums along unless an error occurs. Is that a correct assessment?
It's actually for getting data out. It will emit features one by one in a stream unless an error occurs.
Ah, I see. This isn't the ultimate consumer of the data, it just throws JSON out to somewhere else. I'll have to read up on highland more carefully at some point.
Yep. JSON or strings, depending on how you want to consume the data.
The first use case for me is creating a geojson feature collection -> gzipping -> uploading to S3 all in a stream.
This PR adds new functionality to create a stream of features (as JSON or strings) that come directly from the DB. Under the hood it uses
psql
to execute acopy
command and Highland.js to prepare each feature for consumption.