Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 114 for Cancel (0.23 sec)

  1. internal/dsync/drwmutex.go

    			}
    		}
    	}
    }
    
    func (dm *DRWMutex) startContinuousLockRefresh(lockLossCallback func(), id, source string, quorum int) {
    	ctx, cancel := context.WithCancel(context.Background())
    
    	dm.m.Lock()
    	dm.cancelRefresh = cancel
    	dm.m.Unlock()
    
    	go func() {
    		defer cancel()
    
    		refreshTimer := time.NewTimer(dm.refreshInterval)
    		defer refreshTimer.Stop()
    
    		for {
    			select {
    			case <-ctx.Done():
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Feb 22 06:26:06 GMT 2024
    - 19.7K bytes
    - Viewed (0)
  2. cmd/admin-handlers-users_test.go

    	}
    	return testCases
    }()
    
    const (
    	EnvTestEtcdBackend = "_MINIO_ETCD_TEST_SERVER"
    )
    
    func (s *TestSuiteIAM) setUpEtcd(c *check, etcdServer string) {
    	ctx, cancel := context.WithTimeout(context.Background(), testDefaultTimeout)
    	defer cancel()
    
    	configCmds := []string{
    		"etcd",
    		"endpoints=" + etcdServer,
    		"path_prefix=" + mustGetUUID(),
    	}
    	_, err := s.adm.SetConfigKV(ctx, strings.Join(configCmds, " "))
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Feb 12 16:36:16 GMT 2024
    - 45.7K bytes
    - Viewed (0)
  3. cmd/admin-handlers_test.go

    	ctx, cancel := context.WithCancel(ctx)
    
    	// reset global variables to start afresh.
    	resetTestGlobals()
    
    	// Set globalIsErasure to indicate that the setup uses an erasure
    	// code backend.
    	globalIsErasure = true
    
    	// Initializing objectLayer for HealFormatHandler.
    	objLayer, erasureDirs, xlErr := initTestErasureObjLayer(ctx)
    	if xlErr != nil {
    		cancel()
    		return nil, xlErr
    	}
    
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Feb 22 06:26:06 GMT 2024
    - 13.8K bytes
    - Viewed (0)
  4. cmd/metacache-set.go

    	metaMu := &mc.mu
    	rpc := mc.rpc
    	cancel := mc.cancel
    	defer func() {
    		o.debugln(color.Green("saveMetaCacheStream:")+"err:", err)
    		if err != nil && !errors.Is(err, io.EOF) {
    			go mc.setErr(err.Error())
    			cancel()
    		}
    	}()
    
    	defer cancel()
    	// Save continuous updates
    	go func() {
    		var err error
    		ticker := time.NewTicker(10 * time.Second)
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Apr 26 19:52:52 GMT 2024
    - 30.4K bytes
    - Viewed (0)
  5. cmd/batch-handlers.go

    	}
    	return nil
    }
    
    // delete canceler from the map, cancel job if requested
    func (j *BatchJobPool) canceler(jobID string, cancel bool) error {
    	if j == nil {
    		return errInvalidArgument
    	}
    	j.jmu.Lock()
    	defer j.jmu.Unlock()
    	if canceler, ok := j.jobCancelers[jobID]; ok {
    		if cancel {
    			canceler()
    		}
    	}
    	delete(j.jobCancelers, jobID)
    	return nil
    }
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Apr 08 14:11:38 GMT 2024
    - 55.2K bytes
    - Viewed (0)
  6. internal/grid/muxserver.go

    		ctx, cancel = context.WithTimeout(ctx, time.Duration(msg.DeadlineMS)*time.Millisecond)
    	} else {
    		ctx, cancel = context.WithCancel(ctx)
    	}
    	m := muxServer{
    		ID:        msg.MuxID,
    		RecvSeq:   msg.Seq + 1,
    		SendSeq:   msg.Seq,
    		ctx:       ctx,
    		cancel:    cancel,
    		parent:    c,
    		LastPing:  time.Now().Unix(),
    		BaseFlags: c.baseFlags,
    	}
    	go func() {
    		// TODO: Handle
    	}()
    
    	return &m
    }
    
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 9.1K bytes
    - Viewed (0)
  7. cmd/admin-handlers-users-race_test.go

    			func(t *testing.T) {
    				runAllIAMConcurrencyTests(testCase, &check{t, testCase.serverType})
    			},
    		)
    	}
    }
    
    func (s *TestSuiteIAM) TestDeleteUserRace(c *check) {
    	ctx, cancel := context.WithTimeout(context.Background(), 90*time.Second)
    	defer cancel()
    
    	bucket := getRandomBucketName()
    	err := s.client.MakeBucket(ctx, bucket, minio.MakeBucketOptions{})
    	if err != nil {
    		c.Fatalf("bucket creat error: %v", err)
    	}
    
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Sep 04 19:57:37 GMT 2023
    - 3.9K bytes
    - Viewed (0)
  8. internal/config/dns/etcd_dns.go

    			key = key + etcdPathSeparator + ip
    			ctx, cancel := context.WithTimeout(context.Background(), defaultContextTimeout)
    			_, err = c.etcdClient.Put(ctx, key, string(bucketMsg))
    			cancel()
    			if err != nil {
    				ctx, cancel = context.WithTimeout(context.Background(), defaultContextTimeout)
    				c.etcdClient.Delete(ctx, key)
    				cancel()
    				return err
    			}
    		}
    	}
    	return nil
    }
    
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sun Jan 02 17:15:06 GMT 2022
    - 8.3K bytes
    - Viewed (0)
  9. cmd/shared-lock.go

    }
    
    func mergeContext(ctx1, ctx2 context.Context) (context.Context, context.CancelFunc) {
    	ctx, cancel := context.WithCancel(context.Background())
    	go func() {
    		select {
    		case <-ctx1.Done():
    		case <-ctx2.Done():
    		// The lock acquirer decides to cancel, exit this goroutine
    		case <-ctx.Done():
    		}
    
    		cancel()
    	}()
    	return ctx, cancel
    }
    
    func (ld sharedLock) GetLock(ctx context.Context) (context.Context, context.CancelFunc) {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Feb 13 09:26:38 GMT 2023
    - 2.3K bytes
    - Viewed (0)
  10. cmd/healthcheck-handler.go

    	if objLayer == nil {
    		w.Header().Set(xhttp.MinIOServerStatus, unavailable)
    		writeResponse(w, http.StatusServiceUnavailable, nil, mimeNone)
    		return
    	}
    
    	ctx, cancel := context.WithTimeout(ctx, globalAPIConfig.getClusterDeadline())
    	defer cancel()
    
    	opts := HealthOptions{
    		Maintenance:    r.Form.Get("maintenance") == "true",
    		DeploymentType: r.Form.Get("deployment-type"),
    	}
    	result := objLayer.Health(ctx, opts)
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Wed Apr 03 21:13:20 GMT 2024
    - 6.5K bytes
    - Viewed (0)
Back to top