Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 9 of 9 for assumeCache (0.17 sec)

  1. pkg/scheduler/framework/plugins/volumebinding/assume_cache.go

    	"fmt"
    
    	"k8s.io/klog/v2"
    
    	v1 "k8s.io/api/core/v1"
    	storagehelpers "k8s.io/component-helpers/storage/volume"
    	"k8s.io/kubernetes/pkg/scheduler/util/assumecache"
    )
    
    // PVAssumeCache is a AssumeCache for PersistentVolume objects
    type PVAssumeCache struct {
    	*assumecache.AssumeCache
    	logger klog.Logger
    }
    
    func pvStorageClassIndexFunc(obj interface{}) ([]string, error) {
    	if pv, ok := obj.(*v1.PersistentVolume); ok {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Apr 25 09:46:58 UTC 2024
    - 3.7K bytes
    - Viewed (0)
  2. pkg/scheduler/util/assumecache/assume_cache.go

    	} else {
    		c.logger.V(10).Info("Adding object to assume cache", "description", c.description, "cacheKey", name, "assumeCache", obj)
    	}
    }
    
    func (c *AssumeCache) update(oldObj interface{}, newObj interface{}) {
    	c.add(newObj)
    }
    
    func (c *AssumeCache) delete(obj interface{}) {
    	if obj == nil {
    		return
    	}
    
    	name, err := cache.DeletionHandlingMetaNamespaceKeyFunc(obj)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Apr 25 09:46:58 UTC 2024
    - 10.6K bytes
    - Viewed (0)
  3. pkg/scheduler/framework/plugins/volumebinding/assume_cache_test.go

    		pvs[pv.Name] = pv
    		assumecache.AddTestObject(cache.AssumeCache, pv)
    	}
    
    	// List them
    	verifyListPVs(t, cache, pvs, "")
    
    	// Update a PV
    	updatedPV := makePV("test-pv3", "").withVersion("2").PersistentVolume
    	pvs[updatedPV.Name] = updatedPV
    	assumecache.UpdateTestObject(cache.AssumeCache, updatedPV)
    
    	// List them
    	verifyListPVs(t, cache, pvs, "")
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Apr 25 09:46:58 UTC 2024
    - 12.8K bytes
    - Viewed (0)
  4. pkg/scheduler/util/assumecache/assume_cache_test.go

    		tCtx.Fatalf("GetAPIObject() returned %v, expected %v", actualAPIObject, expectedAPIObject)
    	}
    }
    
    func verifyList(tCtx ktesting.TContext, assumeCache *AssumeCache, expectedObjs []interface{}, indexObj interface{}) {
    	actualObjs := assumeCache.List(indexObj)
    	diff := cmp.Diff(expectedObjs, actualObjs, cmpopts.SortSlices(func(x, y interface{}) bool {
    		xKey, err := cache.MetaNamespaceKeyFunc(x)
    		if err != nil {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Apr 25 09:46:58 UTC 2024
    - 9.5K bytes
    - Viewed (0)
  5. pkg/scheduler/framework/plugins/volumebinding/binder_test.go

    func (env *testEnv) deleteVolumes(pvs []*v1.PersistentVolume) {
    	for _, pv := range pvs {
    		assumecache.DeleteTestObject(env.internalBinder.pvCache.AssumeCache, pv)
    	}
    }
    
    func (env *testEnv) deleteClaims(pvcs []*v1.PersistentVolumeClaim) {
    	for _, pvc := range pvcs {
    		assumecache.DeleteTestObject(env.internalBinder.pvcCache.AssumeCache, pvc)
    	}
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Apr 25 09:46:58 UTC 2024
    - 82.8K bytes
    - Viewed (0)
  6. pkg/scheduler/framework/plugins/dynamicresources/structuredparameters.go

    // newResourceModel.
    type resourceSliceLister interface {
    	List(selector labels.Selector) (ret []*resourcev1alpha2.ResourceSlice, err error)
    }
    
    // assumeCacheLister is the subset of volumebinding.AssumeCache needed by newResourceModel.
    type assumeCacheLister interface {
    	List(indexObj interface{}) []interface{}
    }
    
    // newResourceModel parses the available information about resources. Objects
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Mar 22 09:03:22 UTC 2024
    - 8.7K bytes
    - Viewed (0)
  7. pkg/scheduler/framework/plugins/volumebinding/binder.go

    	"k8s.io/klog/v2"
    	v1helper "k8s.io/kubernetes/pkg/apis/core/v1/helper"
    	"k8s.io/kubernetes/pkg/features"
    	"k8s.io/kubernetes/pkg/scheduler/framework/plugins/volumebinding/metrics"
    	"k8s.io/kubernetes/pkg/scheduler/util/assumecache"
    	"k8s.io/kubernetes/pkg/volume/util"
    )
    
    // ConflictReason is used for the special strings which explain why
    // volume binding is impossible for a node.
    type ConflictReason string
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu May 09 14:55:34 UTC 2024
    - 42.6K bytes
    - Viewed (0)
  8. pkg/scheduler/framework/plugins/dynamicresources/dynamicresources.go

    	// something like it (see https://github.com/kubernetes/kubernetes/pull/112202)
    	// might have to be managed by the cluster autoscaler.
    	claimAssumeCache *assumecache.AssumeCache
    
    	// inFlightAllocations is map from claim UUIDs to claim objects for those claims
    	// for which allocation was triggered during a scheduling cycle and the
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu May 30 15:22:37 UTC 2024
    - 75.9K bytes
    - Viewed (0)
  9. CHANGELOG/CHANGELOG-1.23.md

    - Migrated `pkg/proxy` to structured logging ([#104891](https://github.com/kubernetes/kubernetes/pull/104891), [@shivanshu1333](https://github.com/shivanshu1333))
    - Migrated `pkg/scheduler/framework/plugins/volumebinding/assume_cache.go` to structured logging. ([#105904](https://github.com/kubernetes/kubernetes/pull/105904), [@mengjiao-liu](https://github.com/mengjiao-liu)) [SIG Instrumentation, Scheduling and Storage]
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Feb 28 21:06:52 UTC 2023
    - 424.5K bytes
    - Viewed (0)
Back to top