Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 208 for lockF2 (0.06 sec)

  1. android/guava-tests/test/com/google/common/util/concurrent/CycleDetectingLockFactoryTest.java

        checkMessage(expected, "LockC -> LockA", "LockB -> LockC", "LockA -> LockB");
      }
    
      public void testReentrancy_noDeadlock() {
        lockA.lock();
        lockB.lock();
        lockA.lock(); // Should not assert on lockB -> reentrant(lockA)
      }
    
      public void testExplicitOrdering_noViolations() {
        lock1.lock();
        lock3.lock();
        lock3.unlock();
        lock2.lock();
        lock3.lock();
      }
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 22:10:29 UTC 2024
    - 16.1K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/util/concurrent/CycleDetectingLockFactoryTest.java

        checkMessage(expected, "LockC -> LockA", "LockB -> LockC", "LockA -> LockB");
      }
    
      public void testReentrancy_noDeadlock() {
        lockA.lock();
        lockB.lock();
        lockA.lock(); // Should not assert on lockB -> reentrant(lockA)
      }
    
      public void testExplicitOrdering_noViolations() {
        lock1.lock();
        lock3.lock();
        lock3.unlock();
        lock2.lock();
        lock3.lock();
      }
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 22:10:29 UTC 2024
    - 16.1K bytes
    - Viewed (0)
  3. guava/src/com/google/common/util/concurrent/CycleDetectingLockFactory.java

       *
       * Lock lockA = factory1.newReentrantLock(MyLockOrder.FIRST);
       * Lock lockB = factory1.newReentrantLock(MyLockOrder.FIRST);
       * Lock lockC = factory2.newReentrantLock(MyLockOrder.FIRST);
       *
       * lockA.lock();
       *
       * lockB.lock();  // will throw an IllegalStateException
       * lockC.lock();  // will throw an IllegalStateException
       *
       * lockA.lock();  // reentrant acquisition is okay
       * }</pre>
       *
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Dec 15 19:31:54 UTC 2023
    - 35.9K bytes
    - Viewed (0)
  4. internal/dsync/drwmutex.go

    }
    
    // releaseAll releases all locks that are marked as locked
    func releaseAll(ctx context.Context, ds *Dsync, tolerance int, owner string, locks *[]string, isReadLock bool, restClnts []NetLocker, names ...string) bool {
    	var wg sync.WaitGroup
    	for lockID := range restClnts {
    		wg.Add(1)
    		go func(lockID int) {
    			defer wg.Done()
    			if sendRelease(ctx, ds, restClnts[lockID], owner, (*locks)[lockID], isReadLock, names...) {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Sep 09 15:49:49 UTC 2024
    - 20.4K bytes
    - Viewed (0)
  5. cmd/local-locker.go

    	Source          string // Contains line, function and filename requesting the lock.
    	Group           bool   // indicates if it was a group lock.
    	Owner           string // Owner represents the UUID of the owner who originally requested the lock.
    	Quorum          int    // Quorum represents the quorum required for this lock to be active.
    	idx             int    `msg:"-"` // index of the lock in the lockMap.
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Wed Jul 24 10:24:01 UTC 2024
    - 10.7K bytes
    - Viewed (0)
  6. cmd/namespace-lock.go

    	} else {
    		locked = nsLk.GetLock(ctx, opsID, lockSource, timeout)
    	}
    
    	if !locked { // We failed to get the lock
    		// Decrement ref count since we failed to get the lock
    		n.lockMapMutex.Lock()
    		n.lockMap[resource].ref--
    		if n.lockMap[resource].ref < 0 {
    			logger.CriticalIf(GlobalContext, errors.New("resource reference count was lower than 0"))
    		}
    		if n.lockMap[resource].ref == 0 {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sun Sep 29 22:40:36 UTC 2024
    - 9.2K bytes
    - Viewed (0)
  7. internal/dsync/lock-args.go

    // LockArgs is minimal required values for any dsync compatible lock operation.
    type LockArgs struct {
    	// Unique ID of lock/unlock request.
    	UID string
    
    	// Resources contains single or multiple entries to be locked/unlocked.
    	Resources []string
    
    	// Owner represents unique ID for this instance, an owner who originally requested
    	// the locked resource, useful primarily in figuring out stale locks.
    	Owner string
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Wed Jul 24 10:24:01 UTC 2024
    - 1.8K bytes
    - Viewed (0)
  8. cmd/shared-lock.go

    	for {
    		locker := objAPI.NewNSLock(minioMetaBucket, lockName)
    		lkctx, err := locker.GetLock(ctx, sharedLockTimeout)
    		if err != nil {
    			continue
    		}
    
    	keepLock:
    		for {
    			select {
    			case <-ctx.Done():
    				return
    			case <-lkctx.Context().Done():
    				// The context of the lock is canceled, this can happen
    				// if one lock lost quorum due to cluster instability
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Feb 13 09:26:38 UTC 2023
    - 2.3K bytes
    - Viewed (0)
  9. cmd/lock-rest-server-common_test.go

    		TimeLastRefresh: UTCNow().UnixNano(),
    	}
    
    	locker.ll.lockMap["name"] = []lockRequesterInfo{
    		lockRequesterInfo1,
    		lockRequesterInfo2,
    	}
    
    	lri := locker.ll.lockMap["name"]
    
    	// test unknown uid
    	if locker.ll.removeEntry("name", dsync.LockArgs{
    		Owner: "owner",
    		UID:   "unknown-uid",
    	}, &lri) {
    		t.Errorf("Expected %#v, got %#v", false, true)
    	}
    
    	if !locker.ll.removeEntry("name", dsync.LockArgs{
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Wed Jul 24 10:24:01 UTC 2024
    - 3.2K bytes
    - Viewed (0)
  10. internal/lsync/lrwmutex_test.go

    		lrwm.RUnlock()
    		// fmt.Println("1st read lock released, waiting...")
    	}()
    
    	go func() {
    		time.Sleep(3 * time.Second)
    		lrwm.RUnlock()
    		// fmt.Println("2nd read lock released, waiting...")
    	}()
    
    	// fmt.Println("Trying to acquire write lock, waiting...")
    	locked = lrwm.GetLock(ctx, "", "", duration)
    	if locked {
    		// fmt.Println("Write lock acquired, waiting...")
    		time.Sleep(1 * time.Second)
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sun Mar 05 04:57:35 UTC 2023
    - 7.9K bytes
    - Viewed (0)
Back to top