Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 7 of 7 for ExpectedExpiryTime (0.28 sec)

  1. internal/bucket/lifecycle/lifecycle.go

    				// Specifying the Days tag will automatically perform all versions cleanup
    				// once the latest object is old enough to satisfy the age criteria.
    				// This is a MinIO only extension.
    				if expectedExpiry := ExpectedExpiryTime(obj.ModTime, int(rule.Expiration.Days)); now.IsZero() || now.After(expectedExpiry) {
    					events = append(events, Event{
    						Action: DeleteAllVersionsAction,
    						RuleID: rule.ID,
    						Due:    expectedExpiry,
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sat Mar 09 06:41:22 GMT 2024
    - 17K bytes
    - Viewed (0)
  2. internal/bucket/lifecycle/transition.go

    		return t.Date.Time, true
    	}
    
    	// Days == 0 indicates immediate tiering, i.e object is eligible for tiering since its creation.
    	if t.Days == 0 {
    		return obj.ModTime, true
    	}
    	return ExpectedExpiryTime(obj.ModTime, int(t.Days)), true
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Jan 10 17:07:49 GMT 2022
    - 5.1K bytes
    - Viewed (0)
  3. internal/bucket/lifecycle/noncurrentversion.go

    	}
    	// Days == 0 indicates immediate tiering, i.e object is eligible for tiering since it became noncurrent.
    	if n.NoncurrentDays == 0 {
    		return obj.SuccessorModTime, true
    	}
    	return ExpectedExpiryTime(obj.SuccessorModTime, int(n.NoncurrentDays)), true
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Tue Dec 14 17:41:44 GMT 2021
    - 5.3K bytes
    - Viewed (1)
  4. cmd/bucket-lifecycle.go

    	for k, v := range objInfo.UserDefined {
    		meta[k] = v
    	}
    	if len(objInfo.UserTags) != 0 {
    		meta[xhttp.AmzObjectTagging] = objInfo.UserTags
    	}
    	// Set restore object status
    	restoreExpiry := lifecycle.ExpectedExpiryTime(time.Now().UTC(), rreq.Days)
    	meta[xhttp.AmzRestore] = completedRestoreObj(restoreExpiry).String()
    	return ObjectOptions{
    		Versioned:        globalBucketVersioningSys.PrefixEnabled(bucket, object),
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Wed Apr 17 05:09:58 GMT 2024
    - 33.1K bytes
    - Viewed (0)
  5. cmd/data-scanner.go

    			// subsequent lifecycle policy applications
    			objectInfos = append(objectInfos, obj)
    			continue
    		}
    
    		// NoncurrentDays not passed yet.
    		if time.Now().UTC().Before(lifecycle.ExpectedExpiryTime(obj.SuccessorModTime, event.NoncurrentDays)) {
    			// add this version back to remaining versions for
    			// subsequent lifecycle policy applications
    			objectInfos = append(objectInfos, obj)
    			continue
    		}
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Apr 22 17:49:30 GMT 2024
    - 47.4K bytes
    - Viewed (0)
  6. internal/bucket/lifecycle/lifecycle_test.go

    			1,
    			time.Date(2020, time.March, 17, 0, 0, 0, 0, time.UTC),
    		},
    	}
    
    	for i, tc := range testCases {
    		t.Run(fmt.Sprintf("Test %d", i+1), func(t *testing.T) {
    			got := ExpectedExpiryTime(tc.modTime, int(tc.days))
    			if !got.Equal(tc.expected) {
    				t.Fatalf("Expected %v to be equal to %v", got, tc.expected)
    			}
    		})
    	}
    }
    
    func TestEval(t *testing.T) {
    	testCases := []struct {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sat Mar 09 06:41:22 GMT 2024
    - 45.6K bytes
    - Viewed (0)
  7. cmd/object-handlers.go

    		if !objInfo.RestoreOngoing && !objInfo.RestoreExpires.IsZero() {
    			statusCode = http.StatusAccepted
    			alreadyRestored = true
    		}
    	}
    	// set or upgrade restore expiry
    	restoreExpiry := lifecycle.ExpectedExpiryTime(time.Now().UTC(), rreq.Days)
    	metadata := cloneMSS(objInfo.UserDefined)
    
    	// update self with restore metadata
    	if rreq.Type != SelectRestoreRequest {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Apr 22 17:49:30 GMT 2024
    - 125K bytes
    - Viewed (0)
Back to top