reduce extra getObjectInfo() calls during ILM transition (#13091)

* reduce extra getObjectInfo() calls during ILM transition

This PR also changes expiration logic to be non-blocking,
scanner is now free from additional costs incurred due
to slower object layer calls and hitting the drives.

* move verifying expiration inside locks
This commit is contained in:
Harshavardhana
2021-08-27 17:06:47 -07:00
committed by GitHub
parent e05886561d
commit 35f2552fc5
5 changed files with 105 additions and 67 deletions

View File

@@ -52,6 +52,7 @@ type ObjectOptions struct {
DeleteMarkerReplicationStatus string // Is only set in DELETE operations
VersionPurgeStatus VersionPurgeStatusType // Is only set in DELETE operations for delete marker version to be permanently deleted.
Transition TransitionOptions
Expiration ExpirationOptions
NoLock bool // indicates to lower layers if the caller is expecting to hold locks.
ProxyRequest bool // only set for GET/HEAD in active-active replication scenario
@@ -63,6 +64,11 @@ type ObjectOptions struct {
MaxParity bool
}
// ExpirationOptions represents object options for object expiration at objectLayer.
type ExpirationOptions struct {
Expire bool
}
// TransitionOptions represents object options for transition ObjectLayer operation
type TransitionOptions struct {
Status string