mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2025-09-19 18:47:57 +08:00
s3: print out time in UTC format
fix https://github.com/chrislusf/seaweedfs/issues/1297
This commit is contained in:
@@ -207,7 +207,7 @@ func (s3a *S3ApiServer) listObjectParts(input *s3.ListPartsInput) (output *ListP
|
|||||||
}
|
}
|
||||||
output.Parts = append(output.Parts, &s3.Part{
|
output.Parts = append(output.Parts, &s3.Part{
|
||||||
PartNumber: aws.Int64(int64(partNumber)),
|
PartNumber: aws.Int64(int64(partNumber)),
|
||||||
LastModified: aws.Time(time.Unix(entry.Attributes.Mtime, 0)),
|
LastModified: aws.Time(time.Unix(entry.Attributes.Mtime, 0).UTC()),
|
||||||
Size: aws.Int64(int64(filer2.TotalSize(entry.Chunks))),
|
Size: aws.Int64(int64(filer2.TotalSize(entry.Chunks))),
|
||||||
ETag: aws.String("\"" + filer2.ETag(entry) + "\""),
|
ETag: aws.String("\"" + filer2.ETag(entry) + "\""),
|
||||||
})
|
})
|
||||||
|
@@ -38,7 +38,7 @@ func (s3a *S3ApiServer) ListBucketsHandler(w http.ResponseWriter, r *http.Reques
|
|||||||
if entry.IsDirectory {
|
if entry.IsDirectory {
|
||||||
buckets = append(buckets, &s3.Bucket{
|
buckets = append(buckets, &s3.Bucket{
|
||||||
Name: aws.String(entry.Name),
|
Name: aws.String(entry.Name),
|
||||||
CreationDate: aws.Time(time.Unix(entry.Attributes.Crtime, 0)),
|
CreationDate: aws.Time(time.Unix(entry.Attributes.Crtime, 0).UTC()),
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user