abstract-blob-store icon indicating copy to clipboard operation
abstract-blob-store copied to clipboard

Confirming: No API Guarantee for Filter or Append

Open kemitchell opened this issue 9 years ago • 1 comments
trafficstars

Would really appreciate confirmation that createReadStream and createWriteStream make no guarantees relevant for:

  1. Appending data to a blob. To append a blob, users have to stream the existing data to a buffer, then stream it back to the store, with whatever's to be appended tacked on at the end.
  2. Filtering data in a blob. This requires buffering, too.

Many thanks!

kemitchell avatar Oct 28 '16 21:10 kemitchell

That's correct, the interface only guarantees that you'll get a readable or writable stream corresponding to a key. Implementations can use options to extend this though, for example by passing {append: true} to createWriteStream

jnordberg avatar Oct 07 '17 08:10 jnordberg