Commit Graph

15 Commits (0dd0a0e50cf08519ef842f23ad6108552adc31c5)

Author SHA1 Message Date
Klaus Post 0dd0a0e50c Fix error grammar
Fixes #56
2017-07-16 17:00:58 +02:00
Klaus Post 5abf0ee302 Add options (#46)
* Add options

Make constants changeable as options.

The API remains backwards compatible.

* Update documentation.

* Fix line endings

* fmt

* fmt

* Use functions for parameters.

Much neater.
2017-02-19 11:13:22 +01:00
Harshavardhana df175d2921 ErrShortData shouldn't be returned for data less than dataShards.
The reasoning behind this is that if we have a data block number
of 10, and parity of 10.  Restricting input such that files of
size < 10Bytes should be errored out doesn't seem like the right
approach.

Most erasure subsystems will have static data and parity blocks,
in such case erroring out is not correct since reedsolomon itself
doesn't provide this limitation (please correct me here if i am
wrong :-)).

So removing the check itself is not a problem since most of the
data after the split would be padded with zeros, which is okay
and should be left as application optimization if they wish to
pack small files in this range.

ErrShortData will be still returned in case if the size of data
is empty, or in case of streaming if the size == 0.
2016-04-29 20:38:45 -07:00
klauspost e125c8bc8c Fix comment. 2015-11-03 12:36:28 +01:00
klauspost 94aef4a146 Add stream order information. 2015-11-03 12:10:37 +01:00
klauspost 5dedbfc3ff Update streaming documentation. 2015-10-27 15:59:47 +01:00
Klaus Post 4c33f7e599 Remove duplicated package documentation. 2015-10-27 15:39:19 +01:00
klauspost 64a2a9b848 Add performance note. 2015-10-27 14:54:40 +01:00
klauspost 7d91d8d953 Create separate read/write errors. 2015-10-27 11:11:50 +01:00
klauspost ff9a5aff03 Remove StreamError for shard size mismatches
Since the result is pretty random (especially on concurrent reads),
we just return the plan ErrShardSize.
2015-10-27 10:54:08 +01:00
klauspost e78a382960 Add specific error for streams, to help identify the faulty stream. 2015-10-27 10:36:29 +01:00
klauspost 0500314cc5 Add concurrent reads/writes to streaming interface. 2015-10-26 15:59:02 +01:00
klauspost 8940ce33cc Return ErrShardNoData if there is no data in stream. 2015-10-26 14:31:10 +01:00
Klaus Post 32af654e33 Trim output shards to be equal size to input shards on last read. 2015-10-24 12:42:04 +02:00
klauspost 3fada41987 Add streaming API 2015-10-23 16:14:55 +02:00