summaryrefslogtreecommitdiff
path: root/vendor/github.com/minio/minio-go/v7/api-putobject-snowball.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/minio/minio-go/v7/api-putobject-snowball.go')
-rw-r--r--vendor/github.com/minio/minio-go/v7/api-putobject-snowball.go10
1 files changed, 10 insertions, 0 deletions
diff --git a/vendor/github.com/minio/minio-go/v7/api-putobject-snowball.go b/vendor/github.com/minio/minio-go/v7/api-putobject-snowball.go
index 849471e33..983ed6744 100644
--- a/vendor/github.com/minio/minio-go/v7/api-putobject-snowball.go
+++ b/vendor/github.com/minio/minio-go/v7/api-putobject-snowball.go
@@ -48,6 +48,10 @@ type SnowballOptions struct {
// Compression will typically reduce memory and network usage,
// Compression can safely be enabled with MinIO hosts.
Compress bool
+
+ // SkipErrs if enabled will skip any errors while reading the
+ // object content while creating the snowball archive
+ SkipErrs bool
}
// SnowballObject contains information about a single object to be added to the snowball.
@@ -184,10 +188,16 @@ objectLoop:
n, err := io.Copy(t, obj.Content)
if err != nil {
closeObj()
+ if opts.SkipErrs {
+ continue
+ }
return err
}
if n != obj.Size {
closeObj()
+ if opts.SkipErrs {
+ continue
+ }
return io.ErrUnexpectedEOF
}
closeObj()