package
0.4.0
Repository: https://github.com/opennhp/opennhp.git
Documentation: pkg.go.dev

# README

Log设计

日志log设计为异步写入,相比同步日志写入,在调用时不会立即进行写入日志文件的I/O操作而影响正常业务逻辑,在高并发时可以聚合多条日志并合并为一次文件写入,大幅减少文件I/O操作次数。

Logger对象可以单独创建使用(NewLogger()),也可以在应用程序启动时指定Package全局变量glbLogger,供整个工程使用。

注意:应用程序结束前,需调用Logger.Close(),确保最后缓存的日志能够写入文件。

# Functions

No description provided by the author
Function for use in Logger for discarding logged lines.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
NewLogger constructs a Logger that logs at the specified log l.logLevel and above.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
must be called after SetGlobalLogger().

# Constants

Log levels for use with NewLogger.
Log levels for use with NewLogger.
Log levels for use with NewLogger.
Log levels for use with NewLogger.
Log levels for use with NewLogger.
Log levels for use with NewLogger.
No description provided by the author
No description provided by the author

# Structs

No description provided by the author
A logger that implements async logging by default (logging without impact on real business logic).