nl_tokens: Ported from : https : // github . com / Shopify / sarama / blob / a3e2437d6d26cda6b2dc501dbdab4d3f6befa295 / snappy . go
pl_tokens: function decodeSnappy ( buffer , cb ) { if ( isChunked ( buffer ) ) { var pos = 16 ; var max = buffer . length ; var encoded = [ ] ; var size ; while ( pos < max ) { size = buffer . readUInt32BE ( pos ) ; pos += 4 ; encoded . push ( buffer . slice ( <mask> , pos + size ) ) ; pos += size ; } return async . mapSeries ( encoded , snappy . uncompress , function ( err , decodedChunks ) { if ( err ) return cb ( err ) ; return cb ( null , Buffer . concat ( decodedChunks ) ) ; } ) ; } return snappy . uncompress ( buffer , cb ) ; }