Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for ToRetention (0.19 sec)

  1. internal/bucket/object/lock/lock.go

    		return fmt.Errorf("only 'Enabled' value is allowed to ObjectLockEnabled element")
    	}
    
    	*config = Config(parsedConfig)
    	return nil
    }
    
    // ToRetention - convert to Retention type.
    func (config *Config) ToRetention() Retention {
    	r := Retention{
    		LockEnabled: config.ObjectLockEnabled == Enabled,
    	}
    	if config.Rule != nil {
    		r.Mode = config.Rule.DefaultRetention.Mode
    
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 17.1K bytes
    - Viewed (0)
  2. cmd/bucket-object-lock.go

    			return r, nil
    		}
    		if errors.Is(err, errInvalidArgument) {
    			return r, err
    		}
    		logger.CriticalIf(context.Background(), err)
    		return r, err
    	}
    	return config.ToRetention(), nil
    }
    
    // enforceRetentionForDeletion checks if it is appropriate to remove an
    // object according to locking configuration when this is lifecycle/ bucket quota asking.
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 13.3K bytes
    - Viewed (0)
Back to top