mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-01-19 02:48:24 +00:00
remote.mount: print out metadata sync errors
This commit is contained in:
parent
330d1fde7f
commit
04663c3611
|
@ -83,6 +83,7 @@ func (s *s3RemoteStorageClient) Traverse(remote *remote_pb.RemoteStorageLocation
|
||||||
}
|
}
|
||||||
isLastPage := false
|
isLastPage := false
|
||||||
for !isLastPage && err == nil {
|
for !isLastPage && err == nil {
|
||||||
|
var localErr error
|
||||||
listErr := s.conn.ListObjectsV2Pages(listInput, func(page *s3.ListObjectsV2Output, lastPage bool) bool {
|
listErr := s.conn.ListObjectsV2Pages(listInput, func(page *s3.ListObjectsV2Output, lastPage bool) bool {
|
||||||
for _, content := range page.Contents {
|
for _, content := range page.Contents {
|
||||||
key := *content.Key
|
key := *content.Key
|
||||||
|
@ -94,6 +95,7 @@ func (s *s3RemoteStorageClient) Traverse(remote *remote_pb.RemoteStorageLocation
|
||||||
RemoteETag: *content.ETag,
|
RemoteETag: *content.ETag,
|
||||||
StorageName: s.conf.Name,
|
StorageName: s.conf.Name,
|
||||||
}); err != nil {
|
}); err != nil {
|
||||||
|
localErr = err
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -104,6 +106,9 @@ func (s *s3RemoteStorageClient) Traverse(remote *remote_pb.RemoteStorageLocation
|
||||||
if listErr != nil {
|
if listErr != nil {
|
||||||
err = fmt.Errorf("list %v: %v", remote, listErr)
|
err = fmt.Errorf("list %v: %v", remote, listErr)
|
||||||
}
|
}
|
||||||
|
if localErr != nil {
|
||||||
|
err = fmt.Errorf("process %v: %v", remote, localErr)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue