func Panic(ctx context.Context, fields map[string]interface{}, format string, args ...interface{}) {
	if logger.Level >= log.ErrorLevel {
		entry := log.WithField("pid", os.Getpid())

		if ctx != nil {
			entry = entry.WithField("req_id", extractRequestID(ctx))
			identity_id, err := extractIdentityID(ctx)
			if err == nil { // Otherwise we don't use the identity_id
				entry = entry.WithField("identity_id", identity_id)
			}
		}

		if len(args) > 0 {
			entry.WithFields(fields).Panicf(format, args)
		} else {
			entry.WithFields(fields).Panicln(format)
		}
	}
}
// Panic logs a panic message that might contain the following attributes:
// the request id if provided by the context and the pid. In this function, the
// parameter fields enables to additional attributes to the message. The format
// and args input arguments are used to print a detailed information about the
// reasons of this log.
Panic logs a panic message that might contain the following attributes:
the request id if provided by the context and the pid. In this function, the
parameter fields enables to additional attributes to the message. The format
and args input arguments are used to print a detailed information about the
reasons of this log.
// Panic logs a panic message that might contain the following attributes : // the request id if provided by the context and the pid . In this function the // parameter fields enables to additional attributes to the message . The format // and args input arguments are used to print a detailed information about the // reasons of this log .
func Panic(ctx context.Context, fields map[string]interface{}, format string, args ...interface{}) {
	if logger.Level >= log.ErrorLevel {
		entry := log.WithField("pid", os.Getpid())
		if ctx != nil {
			entry = entry.WithField("req_id", extractRequestID(ctx))
			identity_id, err := extractIdentityID(ctx)
			if err == nil { 
				entry = entry.WithField("identity_id", identity_id)
			}
		}
		if len(args) > 0 {
			entry.WithFields(fields).Panicf(format, args)
		} else {
			entry.WithFields(fields).Panicln(format)
		}
	}
}
func Panic ( ctx context . Context , fields map [ string ] interface { } , format string , args ... interface { } ) { if logger . Level >= log . ErrorLevel { entry := log . WithField ( " " , os . Getpid ( ) ) if ctx != nil { entry = entry . WithField ( " " , extractRequestID ( ctx ) ) identity_id , err := extractIdentityID ( ctx ) if err == nil { entry = entry . WithField ( " " , identity_id ) } } if len ( args ) > 0 { entry . WithFields ( fields ) . Panicf ( format , args ) } else { entry . WithFields ( fields ) . Panicln ( format ) } } }
Panic logs a panic message that might contain the following attributes:
the request id if provided by the context and the pid.
Panic logs a panic message that might contain the following attributes : the request id if provided by the context and the pid .
// Otherwise we don't use the identity_id