- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 465 for atomic (0.39 sec)
-
internal/logger/target/http/http.go
func (h *Target) IsOnline(ctx context.Context) bool { return atomic.LoadInt32(&h.status) == statusOnline } // Stats returns the target statistics. func (h *Target) Stats() types.TargetStats { h.logChMu.RLock() queueLength := len(h.logCh) h.logChMu.RUnlock() stats := types.TargetStats{ TotalMessages: atomic.LoadInt64(&h.totalMessages), FailedMessages: atomic.LoadInt64(&h.failedMessages), QueueLength: queueLength,
Go - Registered: Sun Apr 21 19:28:08 GMT 2024 - Last Modified: Mon Mar 25 16:44:20 GMT 2024 - 14.9K bytes - Viewed (0) -
cmd/consolelogger.go
return logger.ConsoleLoggerTgt } // Stats returns the target statistics. func (sys *HTTPConsoleLoggerSys) Stats() types.TargetStats { return types.TargetStats{ TotalMessages: atomic.LoadInt64(&sys.totalMessages), FailedMessages: atomic.LoadInt64(&sys.failedMessages), QueueLength: 0, } } // Content returns the console stdout log func (sys *HTTPConsoleLoggerSys) Content() (logs []log.Entry) { sys.RLock()
Go - Registered: Sun Apr 28 19:28:10 GMT 2024 - Last Modified: Fri Feb 02 00:13:57 GMT 2024 - 5.4K bytes - Viewed (0) -
cmd/http-stats.go
serverStats := ServerHTTPStats{} serverStats.S3RequestsIncoming = atomic.SwapUint64(&st.s3RequestsIncoming, 0) serverStats.S3RequestsInQueue = atomic.LoadInt32(&st.s3RequestsInQueue) serverStats.TotalS3RejectedAuth = atomic.LoadUint64(&st.rejectedRequestsAuth) serverStats.TotalS3RejectedTime = atomic.LoadUint64(&st.rejectedRequestsTime) serverStats.TotalS3RejectedHeader = atomic.LoadUint64(&st.rejectedRequestsHeader)
Go - Registered: Sun Apr 28 19:28:10 GMT 2024 - Last Modified: Sun Mar 10 09:15:15 GMT 2024 - 11.4K bytes - Viewed (0) -
cni/pkg/nodeagent/healthServer.go
_ = http.ListenAndServe(":"+constants.ReadinessPort, router) }() return } func initRouter(router *http.ServeMux) (installReady *atomic.Value, watchReady *atomic.Value) { installReady = &atomic.Value{} watchReady = &atomic.Value{} installReady.Store(false) watchReady.Store(false) router.HandleFunc(constants.LivenessEndpoint, healthz) router.HandleFunc(constants.ReadinessEndpoint, readyz(installReady, watchReady)) return
Go - Registered: Wed May 01 22:53:12 GMT 2024 - Last Modified: Mon Apr 15 01:29:35 GMT 2024 - 1.8K bytes - Viewed (0) -
cni/pkg/nodeagent/fakes_test.go
return &fakeFileFakeFds{File: f, fd: 0} } type fakeIptablesDeps struct { AddRouteErr error AddInpodMarkIPRuleCnt atomic.Int32 DelInpodMarkIPRuleCnt atomic.Int32 AddLoopbackRoutesCnt atomic.Int32 DelLoopbackRoutesCnt atomic.Int32 } var _ iptables.NetlinkDependencies = &fakeIptablesDeps{} func (r *fakeIptablesDeps) AddInpodMarkIPRule(cfg *iptables.Config) error {
Go - Registered: Wed May 01 22:53:12 GMT 2024 - Last Modified: Fri Apr 12 21:47:31 GMT 2024 - 3.9K bytes - Viewed (0) -
internal/grid/benchmark_test.go
} PutByteBuffer(resp) n++ } atomic.AddInt64(&ops, int64(n)) atomic.AddInt64(&lat, latency) }) spent := time.Since(t) if spent > 0 && n > 0 { // Since we are benchmarking n parallel servers we need to multiply by n. // This will give an estimate of the total ops/s. latency := float64(atomic.LoadInt64(&lat)) / float64(time.Millisecond)
Go - Registered: Sun Apr 21 19:28:08 GMT 2024 - Last Modified: Tue Nov 21 01:09:35 GMT 2023 - 12.2K bytes - Viewed (0) -
internal/bucket/bandwidth/measurement.go
// // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see <http://www.gnu.org/licenses/>. package bandwidth import ( "sync" "sync/atomic" "time" ) const ( // betaBucket is the weight used to calculate exponential moving average betaBucket = 0.1 // Number of averages considered = 1/(1-betaObject) )
Go - Registered: Sun Apr 28 19:28:10 GMT 2024 - Last Modified: Sat Jun 03 20:41:51 GMT 2023 - 2.9K bytes - Viewed (0) -
internal/once/init.go
func (l *Init) Do(f func() error) error { if atomic.LoadUint32(&l.done) == 0 { return l.do(f) } return nil } func (l *Init) do(f func() error) error { l.m.Lock() defer l.m.Unlock() if atomic.LoadUint32(&l.done) == 0 { if err := f(); err != nil { return err } // Mark as done only when f() is successful atomic.StoreUint32(&l.done, 1) } return nil }
Go - Registered: Sun Apr 21 19:28:08 GMT 2024 - Last Modified: Tue May 09 04:20:31 GMT 2023 - 2.1K bytes - Viewed (0) -
internal/rest/client.go
} return clnt } // IsOnline returns whether the client is likely to be online. func (c *Client) IsOnline() bool { return atomic.LoadInt32(&c.connected) == online } // LastConn returns when the disk was (re-)connected func (c *Client) LastConn() time.Time { return time.Unix(0, atomic.LoadInt64(&c.lastConn)) } // LastError returns previous error func (c *Client) LastError() error { c.RLock()
Go - Registered: Sun Apr 21 19:28:08 GMT 2024 - Last Modified: Thu Apr 04 12:04:40 GMT 2024 - 14K bytes - Viewed (0) -
cmd/dynamic-timeouts.go
// We are hitting the timeout too often, so increase the timeout by 25% timeout := atomic.LoadInt64(&dt.timeout) * 125 / 100 // Set upper cap. if timeout > int64(maxDynamicTimeout) { timeout = int64(maxDynamicTimeout) } // Safety, shouldn't happen if timeout < dt.minimum { timeout = dt.minimum } atomic.StoreInt64(&dt.timeout, timeout) } else if failPct < dynamicTimeoutDecreaseThresholdPct {
Go - Registered: Sun Apr 28 19:28:10 GMT 2024 - Last Modified: Fri Aug 19 23:21:05 GMT 2022 - 4.5K bytes - Viewed (0)