mirror of
https://github.com/minio/minio.git
synced 2026-02-05 02:10:14 -05:00
reduce all major allocations in replication path (#18032)
- remove targetClient for passing around via replicationObjectInfo{}
- remove cloing to object info unnecessarily
- remove objectInfo from replicationObjectInfo{} (only require necessary fields)
This commit is contained in:
@@ -507,7 +507,10 @@ func (o *ObjectInfo) IsCompressedOK() (bool, error) {
|
||||
}
|
||||
|
||||
// GetActualSize - returns the actual size of the stored object
|
||||
func (o *ObjectInfo) GetActualSize() (int64, error) {
|
||||
func (o ObjectInfo) GetActualSize() (int64, error) {
|
||||
if o.ActualSize != nil {
|
||||
return *o.ActualSize, nil
|
||||
}
|
||||
if o.IsCompressed() {
|
||||
sizeStr, ok := o.UserDefined[ReservedMetadataPrefix+"actual-size"]
|
||||
if !ok {
|
||||
|
||||
Reference in New Issue
Block a user