Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 227 for Unlock (0.22 sec)

  1. cmd/background-newdisks-heal-ops.go

    	h.mu.RLock()
    	defer h.mu.RUnlock()
    
    	return h.Object
    }
    
    func (h *healingTracker) setObject(object string) {
    	h.mu.Lock()
    	defer h.mu.Unlock()
    
    	h.Object = object
    }
    
    func (h *healingTracker) updateProgress(success, skipped bool, bytes uint64) {
    	h.mu.Lock()
    	defer h.mu.Unlock()
    
    	switch {
    	case success:
    		h.ItemsHealed++
    		h.BytesDone += bytes
    	case skipped:
    		h.ItemsSkipped++
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 14.7K bytes
    - Viewed (0)
  2. internal/store/queuestore.go

    func (store *QueueStore[_]) Del(key string) error {
    	store.Lock()
    	defer store.Unlock()
    	return store.del(key)
    }
    
    // DelList - Deletes a list of entries from the store.
    // Returns an error even if one key fails to be deleted.
    func (store *QueueStore[_]) DelList(keys []string) error {
    	store.Lock()
    	defer store.Unlock()
    
    	for _, key := range keys {
    		if err := store.del(key); err != nil {
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Mar 25 16:44:20 GMT 2024
    - 7.1K bytes
    - Viewed (0)
  3. cmd/erasure-server-pool-rebalance.go

    			ok = true
    		}
    	}
    	if ok {
    		lock := z.serverPools[0].NewNSLock(minioMetaBucket, rebalMetaName)
    		lkCtx, err := lock.GetLock(ctx, globalOperationTimeout)
    		if err != nil {
    			rebalanceLogIf(ctx, fmt.Errorf("failed to acquire write lock on %s/%s: %w", minioMetaBucket, rebalMetaName, err))
    			return err
    		}
    		defer lock.Unlock(lkCtx)
    
    		ctx = lkCtx.Context()
    
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Apr 26 19:29:28 GMT 2024
    - 27.2K bytes
    - Viewed (0)
  4. internal/store/batch.go

    func (b *Batch[K, T]) GetByKey(key K) (T, bool) {
    	b.Lock()
    	defer b.Unlock()
    
    	item, ok := b.items[key]
    	return item, ok
    }
    
    // Len returns the no of items in the batch
    func (b *Batch[K, T]) Len() int {
    	b.Lock()
    	defer b.Unlock()
    
    	return len(b.keys)
    }
    
    // IsFull checks if the batch is full or not
    func (b *Batch[K, T]) IsFull() bool {
    	b.Lock()
    	defer b.Unlock()
    
    	return b.isFull()
    }
    
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Sat Oct 07 15:07:38 GMT 2023
    - 2.5K bytes
    - Viewed (0)
  5. internal/grid/muxclient.go

    	if responses == nil {
    		return nil, errors.New("RequestStream: responses channel is nil")
    	}
    	m.init = true
    	m.respMu.Lock()
    	if m.closed {
    		m.respMu.Unlock()
    		return nil, ErrDisconnected
    	}
    	m.respWait = responses // Route directly to output.
    	m.respMu.Unlock()
    
    	// Try to grab an initial block.
    	m.singleResp = false
    	m.RecvSeq = m.SendSeq // Sync
    	if cap(requests) > 0 {
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 14.2K bytes
    - Viewed (0)
  6. cmd/site-replication-utils.go

    						}()
    					}
    				}
    				wg.Wait()
    				sm.Unlock()
    			}
    			sTimer.Reset(siteResyncSaveInterval)
    		case <-ctx.Done():
    			return
    		}
    	}
    }
    
    // update overall site resync state
    func (sm *siteResyncMetrics) updateState(s SiteResyncStatus) error {
    	if !globalSiteReplicationSys.isEnabled() {
    		return nil
    	}
    	sm.Lock()
    	defer sm.Unlock()
    	switch s.Status {
    	case ResyncStarted:
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Jan 18 07:03:17 GMT 2024
    - 8.9K bytes
    - Viewed (1)
  7. cmd/iam-store.go

    type IAMStorageAPI interface {
    	// The role of the read-write lock is to prevent go routines from
    	// concurrently reading and writing the IAM storage. The (r)lock()
    	// functions return the iamCache. The cache can be safely written to
    	// only when returned by `lock()`.
    	lock() *iamCache
    	unlock()
    	rlock() *iamCache
    	runlock()
    	getUsersSysType() UsersSysType
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sat Apr 27 10:04:10 GMT 2024
    - 75.2K bytes
    - Viewed (2)
  8. cmd/erasure-server-pool-decom.go

    	}
    
    	// if no update is needed return right away.
    	if !update {
    		z.poolMetaMutex.Lock()
    		z.poolMeta = meta
    		z.poolMetaMutex.Unlock()
    	} else {
    		newMeta := newPoolMeta(z, meta)
    		if err = newMeta.save(ctx, z.serverPools); err != nil {
    			return err
    		}
    		z.poolMetaMutex.Lock()
    		z.poolMeta = newMeta
    		z.poolMetaMutex.Unlock()
    	}
    
    	pools := meta.returnResumablePools()
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Apr 22 17:49:30 GMT 2024
    - 41.3K bytes
    - Viewed (1)
  9. cmd/bucket-replication-stats.go

    	if r == nil {
    		return
    	}
    
    	r.Lock()
    	defer r.Unlock()
    	delete(r.Cache, bucket)
    }
    
    // UpdateReplicaStat updates in-memory replica statistics with new values.
    func (r *ReplicationStats) UpdateReplicaStat(bucket string, n int64) {
    	if r == nil {
    		return
    	}
    
    	r.Lock()
    	defer r.Unlock()
    	bs, ok := r.Cache[bucket]
    	if !ok {
    		bs = newBucketReplicationStats()
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Feb 22 06:26:06 GMT 2024
    - 13.4K bytes
    - Viewed (0)
  10. cmd/lock-rest-client_test.go

    	// Attempt all calls.
    	_, err = lkClient.RLock(context.Background(), dsync.LockArgs{})
    	if err == nil {
    		t.Fatal("Expected for Rlock to fail")
    	}
    
    	_, err = lkClient.Lock(context.Background(), dsync.LockArgs{})
    	if err == nil {
    		t.Fatal("Expected for Lock to fail")
    	}
    
    	_, err = lkClient.RUnlock(context.Background(), dsync.LockArgs{})
    	if err == nil {
    		t.Fatal("Expected for RUnlock to fail")
    	}
    
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Tue Nov 21 01:09:35 GMT 2023
    - 2K bytes
    - Viewed (0)
Back to top