- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 19 for withTimeout (0.1 sec)
-
cmd/etcd.go
timeoutCtx, cancel := context.WithTimeout(ctx, defaultContextTimeout) defer cancel() _, err := client.Delete(timeoutCtx, key) etcdLogIf(ctx, err) return etcdErrToErr(err, client.Endpoints()) } func readKeyEtcd(ctx context.Context, client *etcd.Client, key string) ([]byte, error) { timeoutCtx, cancel := context.WithTimeout(ctx, defaultContextTimeout) defer cancel()
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Apr 04 12:04:40 UTC 2024 - 2.9K bytes - Viewed (0) -
internal/config/dns/etcd_dns.go
key := msgPath(fmt.Sprintf("%s.%s", bucket, domainName), c.prefixPath) 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 } }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Sep 26 15:03:08 UTC 2024 - 8K bytes - Viewed (0) -
cmd/healthcheck-handler.go
func ClusterCheckHandler(w http.ResponseWriter, r *http.Request) { ctx := newContext(r, w, "ClusterCheckHandler") objLayer := checkHealth(w) if objLayer == nil { return } ctx, cancel := context.WithTimeout(ctx, globalAPIConfig.getClusterDeadline()) defer cancel() opts := HealthOptions{ Maintenance: r.Form.Get("maintenance") == "true", DeploymentType: r.Form.Get("deployment-type"), }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Jun 26 07:44:34 UTC 2024 - 6.9K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/FluentFutureTest.java
assertThat(f.get()).isEqualTo(2); } @J2ktIncompatible @GwtIncompatible // withTimeout public void testWithTimeout() throws Exception { ScheduledExecutorService executor = newScheduledThreadPool(1); try { FluentFuture<?> f = FluentFuture.from(SettableFuture.create()).withTimeout(0, SECONDS, executor); ExecutionException e = assertThrows(ExecutionException.class, () -> f.get());
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Feb 13 14:28:25 UTC 2024 - 5.7K bytes - Viewed (0) -
okhttp-coroutines/src/test/kotlin/okhttp3/coroutines/ExecuteAsyncTest.kt
import kotlinx.coroutines.coroutineScope import kotlinx.coroutines.job import kotlinx.coroutines.supervisorScope import kotlinx.coroutines.test.runTest import kotlinx.coroutines.withContext import kotlinx.coroutines.withTimeout import mockwebserver3.MockResponse import mockwebserver3.MockWebServer import mockwebserver3.SocketPolicy.DisconnectAfterRequest import okhttp3.Callback import okhttp3.FailingCall
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Thu Apr 18 01:24:38 UTC 2024 - 5.4K bytes - Viewed (0) -
cmd/sftp-server_test.go
if err == nil || !errors.Is(err, errNoSuchUser) { c.Fatalf("expected err(%s) but got (%s)", errNoSuchUser, err) } } func (s *TestSuiteIAM) SFTPInvalidServiceAccountPassword(c *check) { ctx, cancel := context.WithTimeout(context.Background(), testDefaultTimeout) defer cancel() accessKey, secretKey := mustGenerateCredentials(c) err := s.adm.SetUser(ctx, accessKey, secretKey, madmin.AccountEnabled) if err != nil {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri Jun 28 09:06:25 UTC 2024 - 8.3K bytes - Viewed (0) -
internal/http/check_port_linux.go
// the specified interface if any. _ = syscall.SetsockoptString(int(fdPtr), syscall.SOL_SOCKET, syscall.SO_BINDTODEVICE, opts.Interface) } }) return nil }, } ctx, cancel := context.WithTimeout(context.Background(), time.Second) defer cancel() l, err := lc.Listen(ctx, "tcp", net.JoinHostPort(host, port)) if err != nil { return err }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed May 03 21:12:25 UTC 2023 - 1.9K bytes - Viewed (0) -
internal/grid/muxserver.go
func newMuxStateless(ctx context.Context, msg message, c *Connection, handler StatelessHandler) *muxServer { var cancel context.CancelFunc ctx = setCaller(ctx, c.remote) if msg.DeadlineMS > 0 { 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,
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri Jun 07 15:51:52 UTC 2024 - 9.7K bytes - Viewed (0) -
internal/http/check_port_others.go
// It is possible to have a disconnected client in this tiny window of time. func CheckPortAvailability(host, port string, opts TCPOptions) (err error) { lc := &net.ListenConfig{} ctx, cancel := context.WithTimeout(context.Background(), time.Second) defer cancel() l, err := lc.Listen(ctx, "tcp", net.JoinHostPort(host, port)) if err != nil { return err }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed May 03 21:12:25 UTC 2023 - 1.5K bytes - Viewed (0) -
internal/config/dns/operator_dns.go
u.RawQuery = q.Encode() return u.String(), nil } // Put - Adds DNS entries into operator webhook server func (c *OperatorDNS) Put(bucket string) error { ctx, cancel := context.WithTimeout(context.Background(), defaultOperatorContextTimeout) defer cancel() e, err := c.endpoint(bucket, false) if err != nil { return newError(bucket, err) }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Mar 06 16:56:10 UTC 2023 - 6.6K bytes - Viewed (0)