- Sort Score
- Result 10 results
- Languages All
Results 1 - 7 of 7 for CriticalIf (0.14 sec)
-
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...)
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Aug 22 09:43:48 UTC 2024 - 12.4K bytes - Viewed (0) -
cmd/metrics.go
float64(disk.TotalSpace), disk.DrivePath, ) } } func metricsHandler() http.Handler { registry := prometheus.NewRegistry() logger.CriticalIf(GlobalContext, registry.Register(minioVersionInfo)) logger.CriticalIf(GlobalContext, registry.Register(newMinioCollector())) gatherers := prometheus.Gatherers{ prometheus.DefaultGatherer, registry, }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Aug 15 12:04:40 UTC 2024 - 16.6K bytes - Viewed (0) -
cmd/metrics-v3-types.go
} // There is no way to handle errors here, so we panic the current goroutine // and the Metrics API handler returns a 500 HTTP status code. This should // normally not happen, and usually indicates a bug. logger.CriticalIf(GlobalContext, errors.Wrap(err, "failed to get metrics")) promMetrics := metricValues.ToPromMetrics(mg.CollectorPath.metricPrefix(), mg.ExtraLabels) for _, metric := range promMetrics { ch <- metric }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Tue Jul 30 22:28:46 UTC 2024 - 15.6K bytes - Viewed (0) -
cmd/encryption-v1.go
// sio max. size is 256 TB reqInfo := (&logger.ReqInfo{}).AppendTags("size", strconv.FormatUint(size, 10)) ctx := logger.SetReqInfo(GlobalContext, reqInfo) logger.CriticalIf(ctx, err) } return int64(size) } // DecryptObjectInfo tries to decrypt the provided object if it is encrypted. // It fails if the object is encrypted and the HTTP headers don't contain
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Sun Oct 13 13:06:08 UTC 2024 - 37.2K bytes - Viewed (0) -
cmd/object-api-utils.go
func mustGetUUID() string { u, err := uuid.NewRandom() if err != nil { logger.CriticalIf(GlobalContext, err) } return u.String() } // mustGetUUIDBytes - get a random UUID as 16 bytes unencoded. func mustGetUUIDBytes() []byte { u, err := uuid.NewRandom() if err != nil { logger.CriticalIf(GlobalContext, err) } return u[:] }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Aug 08 15:29:58 UTC 2024 - 37.1K bytes - Viewed (0) -
cmd/generic-handlers.go
w.Header().Set(xhttp.AmzRequestHostID, globalLocalNodeNameHex) } h.ServeHTTP(w, r) }) } // criticalErrorHandler handles panics and fatal errors by // `panic(logger.ErrCritical)` as done by `logger.CriticalIf`. // // It should be always the first / highest HTTP handler. func setCriticalErrorHandler(h http.Handler) http.Handler { return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { defer func() {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Jul 29 18:10:04 UTC 2024 - 20.5K bytes - Viewed (0) -
cmd/utils.go
return strings.TrimSpace(s) != s } func request2BucketObjectName(r *http.Request) (bucketName, objectName string) { path, err := getResource(r.URL.Path, r.Host, globalDomainNames) if err != nil { logger.CriticalIf(GlobalContext, err) } return path2BucketObject(path) } // path2BucketObjectWithBasePath returns bucket and prefix, if any, // of a 'path'. basePath is trimmed from the front of the 'path'.
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Tue Aug 13 22:22:04 UTC 2024 - 31.9K bytes - Viewed (0)