Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 7 of 7 for Hockman (0.19 sec)

  1. cmd/local-locker_test.go

    		if err != nil {
    			t.Fatal(err)
    		}
    		if !ok {
    			t.Fatal("did not get write lock")
    		}
    
    		rResources[i] = arg.Resources[0]
    	}
    	if len(l.lockMap) != len(rResources)+len(wResources) {
    		t.Fatalf("lockmap len, got %d, want %d + %d", len(l.lockMap), len(rResources), len(wResources))
    	}
    	if len(l.lockUID) != len(rResources)+len(wResources) {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sun Mar 05 04:57:35 GMT 2023
    - 11.8K bytes
    - Viewed (0)
  2. cmd/local-locker.go

    		Quorum:          args.Quorum,
    	}
    	if lri, ok := l.lockMap[resource]; ok {
    		if reply = !isWriteLock(lri); reply {
    			// Unless there is a write lock
    			l.lockMap[resource] = append(l.lockMap[resource], lrInfo)
    			l.lockUID[formatUUID(args.UID, 0)] = resource
    		}
    	} else {
    		// No locks held on the given name, so claim (first) read lock
    		l.lockMap[resource] = []lockRequesterInfo{lrInfo}
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Feb 19 22:54:46 GMT 2024
    - 10.6K bytes
    - Viewed (0)
  3. cmd/lock-rest-server-common_test.go

    		Writer:          true,
    		UID:             "89ab-cdef",
    		Timestamp:       UTCNow(),
    		TimeLastRefresh: UTCNow(),
    	}
    
    	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) {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Mar 23 17:26:21 GMT 2023
    - 3.1K bytes
    - Viewed (0)
  4. cmd/namespace-lock.go

    	defer n.lockMapMutex.Unlock()
    	if _, found := n.lockMap[resource]; !found {
    		return
    	}
    	if readLock {
    		n.lockMap[resource].RUnlock()
    	} else {
    		n.lockMap[resource].Unlock()
    	}
    	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 {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Jun 05 23:56:35 GMT 2023
    - 9.2K bytes
    - Viewed (0)
  5. cmd/namespace-lock_test.go

    		//    successfully acquiring the lock.
    		// 2) lk2 then needs to advance and remove the resource from lockMap.
    		// 3) lk3 or lk4 (whichever didn't execute in step 1) then executes and creates
    		//    a new entry in lockMap and acquires a lock for the same resource.
    
    		<-lk2ch
    		lk3ok := <-lk3ch
    		lk4ok := <-lk4ch
    
    		if lk3ok && lk4ok {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Apr 23 18:58:53 GMT 2021
    - 3.1K bytes
    - Viewed (0)
  6. cmd/peer-rest-client.go

    func (client *peerRESTClient) Close() error {
    	client.restClient.Close()
    	return nil
    }
    
    // GetLocks - fetch older locks for a remote node.
    func (client *peerRESTClient) GetLocks() (lockMap map[string][]lockRequesterInfo, err error) {
    	resp, err := getLocksRPC.Call(context.Background(), client.gridConn(), grid.NewMSS())
    	if err != nil || resp == nil {
    		return nil, err
    	}
    	return *resp, nil
    }
    
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 25.8K bytes
    - Viewed (0)
  7. internal/dsync/dsync-server_test.go

    	var locksHeld int64
    	if locksHeld, reply = l.lockMap[args.Resources[0]]; !reply {
    		l.lockMap[args.Resources[0]] = ReadLock // No locks held on the given name, so claim (first) read lock
    		reply = true
    	} else if reply = locksHeld != WriteLock; reply { // Unless there is a write lock
    		l.lockMap[args.Resources[0]] = locksHeld + ReadLock // Grant another read lock
    	}
    	return reply, nil
    }
    
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Jan 23 16:46:37 GMT 2023
    - 8.3K bytes
    - Viewed (0)
Back to top