mirror of
https://github.com/minio/minio.git
synced 2025-02-03 01:46:00 -05:00
batch:repl fix copy from source -> remote (#20382)
completes fix started by #20365
This commit is contained in:
parent
6224849fd1
commit
060276932d
@ -1208,7 +1208,11 @@ func (r *BatchJobReplicateV1) Start(ctx context.Context, api ObjectLayer, job Ba
|
|||||||
s3Type := r.Target.Type == BatchJobReplicateResourceS3 || r.Source.Type == BatchJobReplicateResourceS3
|
s3Type := r.Target.Type == BatchJobReplicateResourceS3 || r.Source.Type == BatchJobReplicateResourceS3
|
||||||
|
|
||||||
go func() {
|
go func() {
|
||||||
for _, prefix := range r.Source.Prefix.F() {
|
prefixes := r.Source.Prefix.F()
|
||||||
|
if len(prefixes) == 0 {
|
||||||
|
prefixes = []string{""}
|
||||||
|
}
|
||||||
|
for _, prefix := range prefixes {
|
||||||
prefixWalkCh := make(chan itemOrErr[ObjectInfo], 100)
|
prefixWalkCh := make(chan itemOrErr[ObjectInfo], 100)
|
||||||
if err := api.Walk(ctx, r.Source.Bucket, strings.TrimSpace(prefix), prefixWalkCh, WalkOptions{
|
if err := api.Walk(ctx, r.Source.Bucket, strings.TrimSpace(prefix), prefixWalkCh, WalkOptions{
|
||||||
Marker: lastObject,
|
Marker: lastObject,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user