Documentation ¶
Index ¶
- func AdditionalFields(req *restful.Request, fields map[string]interface{})
- func Debug(req *restful.Request, eventID int, message ...interface{})
- func Error(req *restful.Request, eventID int, message ...interface{})
- func Fatal(req *restful.Request, eventID int, message ...interface{})
- func Info(req *restful.Request, eventID int, message ...interface{})
- func Log(realm string, fn ExtractAttribute) restful.FilterFunction
- func TargetUser(req *restful.Request, id, namespace string)
- func Warn(req *restful.Request, eventID int, message ...interface{})
- type ExtractAttribute
- type UTCFormatter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AdditionalFields ¶
func AdditionalFields(req *restful.Request, fields map[string]interface{})
AdditionalFields injects additional log fields to the event in the request
func Debug ¶
func Debug(req *restful.Request, eventID int, message ...interface{})
Debug sets the event level to debug along with the event ID and message
func Error ¶
func Error(req *restful.Request, eventID int, message ...interface{})
Error sets the event level to error along with the event ID and message
func Fatal ¶
func Fatal(req *restful.Request, eventID int, message ...interface{})
Fatal sets the event level to fatal along with the event ID and message
func Info ¶
func Info(req *restful.Request, eventID int, message ...interface{})
Info sets the event level to info along with the event ID and message
func Log ¶
func Log(realm string, fn ExtractAttribute) restful.FilterFunction
Log is a filter that will log incoming request with AccelByte's Event Log Format
func TargetUser ¶
func TargetUser(req *restful.Request, id, namespace string)
TargetUser injects the target user ID and namespace to current event in the request
Types ¶
type ExtractAttribute ¶
ExtractAttribute is a function to extract userID, clientID and namespace from restful.Request
var ExtractNull ExtractAttribute = func(_ *restful.Request) (userID string, clientID string, namespace string) {
return "", "", ""
}
ExtractNull is null function for extracting attribute