本文整理匯總了Golang中github.com/cockroachdb/cockroach/util/log.ErrorfDepth函數的典型用法代碼示例。如果您正苦於以下問題:Golang ErrorfDepth函數的具體用法?Golang ErrorfDepth怎麽用?Golang ErrorfDepth使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。
在下文中一共展示了ErrorfDepth函數的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Golang代碼示例。
示例1: Errorf
func (l queueLog) Errorf(format string, a ...interface{}) {
log.ErrorfDepth(1, l.prefix+format, a...)
l.traceLog.Errorf(format, a...)
}
示例2: serverErrorf
// serverErrorf logs the provided error and returns an error that should be returned by
// the RPC endpoint method.
func (s *adminServer) serverErrorf(format string, args ...interface{}) error {
log.ErrorfDepth(1, format, args...)
return errAdminAPIError
}
示例3: serverErrors
// serverErrors logs the provided errors and returns an error that should be returned by
// the RPC endpoint method.
func (s *adminServer) serverErrors(errors []error) error {
log.ErrorfDepth(1, "%v", errors)
return errAdminAPIError
}
示例4: Errorf
func (r *raftLogger) Errorf(format string, v ...interface{}) {
log.ErrorfDepth(context.TODO(), 1, r.logPrefix()+format, v...)
}
示例5: serverError
// serverError logs the provided error and returns an error that should be returned by
// the RPC endpoint method.
func (s *adminServer) serverError(err error) error {
log.ErrorfDepth(1, "%s", err)
return errAdminAPIError
}
示例6: Error
func (r *raftLogger) Error(v ...interface{}) {
log.ErrorfDepth(context.TODO(), 1, r.logPrefix(), v...)
}
示例7: Panicf
func (r *raftLogger) Panicf(format string, v ...interface{}) {
log.ErrorfDepth(context.TODO(), 1, r.logPrefix()+format, v...)
panic(fmt.Sprintf(r.logPrefix()+format, v...))
}
示例8: Panic
func (r *raftLogger) Panic(v ...interface{}) {
s := fmt.Sprint(v...)
log.ErrorfDepth(context.TODO(), 1, s)
panic(s)
}
示例9: serverError
// serverError logs the provided error and returns an error that should be returned by
// the RPC endpoint method.
func (s *adminServer) serverError(err error) error {
log.ErrorfDepth(context.TODO(), 1, "%s", err)
return errAdminAPIError
}
示例10: Error
func (l queueLog) Error(err error) {
const format = "%s"
log.ErrorfDepth(context.TODO(), 1, l.prefix+format, err)
l.traceLog.Errorf(format, err)
}