Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 25 for houcine (0.21 sec)

  1. internal/lsync/lrwmutex.go

    }
    
    // NewLRWMutex - initializes a new lsync RW mutex.
    func NewLRWMutex() *LRWMutex {
    	return &LRWMutex{}
    }
    
    // Lock holds a write lock on lm.
    //
    // If the lock is already in use, the calling go routine
    // blocks until the mutex is available.
    func (lm *LRWMutex) Lock() {
    	const isWriteLock = true
    	lm.lockLoop(context.Background(), lm.id, lm.source, math.MaxInt64, isWriteLock)
    }
    
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Sun Jan 02 17:15:06 GMT 2022
    - 4.8K bytes
    - Viewed (0)
  2. internal/logger/target/kafka/kafka.go

    	if logCh != nil {
    		// We are not allowed to add when logCh is nil
    		h.wg.Add(1)
    		defer h.wg.Done()
    
    	}
    	h.logChMu.RUnlock()
    
    	if logCh == nil {
    		return
    	}
    
    	// Create a routine which sends json logs received
    	// from an internal channel.
    	for entry := range logCh {
    		h.logEntry(entry)
    	}
    }
    
    func (h *Target) logEntry(entry interface{}) {
    	atomic.AddInt64(&h.totalMessages, 1)
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Feb 22 06:26:06 GMT 2024
    - 10.1K bytes
    - Viewed (1)
  3. internal/lock/lock_test.go

    	case <-locked:
    		t.Error("unexpected unblocking")
    	case <-time.After(100 * time.Millisecond):
    	}
    
    	// unlock
    	if err = dupl.Close(); err != nil {
    		t.Fatal(err)
    	}
    
    	// the previously blocked routine should be unblocked
    	select {
    	case <-locked:
    	case <-time.After(1 * time.Second):
    		t.Error("unexpected blocking")
    	}
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Sep 19 18:05:16 GMT 2022
    - 3.6K bytes
    - Viewed (0)
  4. internal/logger/logger.go

    	sendLog(ctx, entry)
    }
    
    // ErrCritical is the value panic'd whenever CriticalIf is called.
    var ErrCritical struct{}
    
    // CriticalIf logs the provided error on the console. It fails the
    // current go-routine by causing a `panic(ErrCritical)`.
    func CriticalIf(ctx context.Context, err error, errKind ...interface{}) {
    	if err != nil {
    		LogIf(ctx, "", err, errKind...)
    		panic(ErrCritical)
    	}
    }
    
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 12.2K bytes
    - Viewed (0)
  5. cmd/erasure-sets.go

    				nsMutex:            mutex,
    			}
    		}(i)
    	}
    
    	wg.Wait()
    
    	// start cleanup stale uploads go-routine.
    	go s.cleanupStaleUploads(ctx)
    
    	// start cleanup of deleted objects.
    	go s.cleanupDeletedObjects(ctx)
    
    	// Start the disk monitoring and connect routine.
    	if !globalIsTesting {
    		go s.monitorAndConnectEndpoints(ctx, defaultMonitorConnectEndpointInterval)
    	}
    
    	return s, nil
    }
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Apr 15 08:25:46 GMT 2024
    - 37.5K bytes
    - Viewed (5)
  6. cmd/storage-rest-client.go

    	return client.endpoint.PoolIdx, client.endpoint.SetIdx, client.endpoint.DiskIdx
    }
    
    // Wrapper to restClient.Call to handle network errors, in case of network error the connection is disconnected
    // and a healthcheck routine gets invoked that would reconnect.
    func (client *storageRESTClient) call(ctx context.Context, method string, values url.Values, body io.Reader, length int64) (io.ReadCloser, error) {
    	if values == nil {
    		values = make(url.Values)
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Apr 15 08:25:46 GMT 2024
    - 26K bytes
    - Viewed (0)
  7. internal/dsync/drwmutex.go

    		refreshInterval:      drwMutexRefreshInterval,
    		lockRetryMinInterval: lockRetryMinInterval,
    	}
    }
    
    // Lock holds a write lock on dm.
    //
    // If the lock is already in use, the calling go routine
    // blocks until the mutex is available.
    func (dm *DRWMutex) Lock(id, source string) {
    	isReadLock := false
    	dm.lockBlocking(context.Background(), nil, id, source, isReadLock, Options{
    		Timeout: drwMutexInfinite,
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Feb 22 06:26:06 GMT 2024
    - 19.7K bytes
    - Viewed (0)
  8. cmd/erasure-server-pool-decom.go

    	// Load rebalance metadata if present
    	err := z.loadRebalanceMeta(ctx)
    	if err != nil {
    		return fmt.Errorf("failed to load rebalance data: %w", err)
    	}
    
    	// Start rebalance routine
    	z.StartRebalance()
    
    	meta := poolMeta{}
    	if err := meta.load(ctx, z.serverPools[0], z.serverPools); err != nil {
    		return err
    	}
    
    	update, err := meta.validate(z.serverPools)
    	if err != nil {
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 40.4K bytes
    - Viewed (1)
  9. cmd/admin-handlers_test.go

    		return madmin.ServiceActionRestart
    	case stopCmd:
    		return madmin.ServiceActionStop
    	}
    	return madmin.ServiceActionRestart
    }
    
    // testServiceSignalReceiver - Helper function that simulates a
    // go-routine waiting on service signal.
    func testServiceSignalReceiver(cmd cmdType, t *testing.T) {
    	expectedCmd := cmd.toServiceSignal()
    	serviceCmd := <-globalServiceSignalCh
    	if serviceCmd != expectedCmd {
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Feb 22 06:26:06 GMT 2024
    - 13.8K bytes
    - Viewed (0)
  10. cmd/data-scanner.go

    		return true, 0
    	}
    
    	// For instance, an applied lifecycle means we remove/transitioned an object
    	// from the current deployment, which means we don't have to call healing
    	// routine even if we are asked to do via heal flag.
    	if action == lifecycle.NoneAction {
    		if i.heal.enabled {
    			done := globalScannerMetrics.time(scannerMetricHealCheck)
    			size = i.applyHealing(ctx, o, oi)
    			done()
    
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Apr 15 09:40:19 GMT 2024
    - 46.9K bytes
    - Viewed (0)
Back to top