Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
D
docs
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
backend
docs
Commits
b98d7518
Commit
b98d7518
authored
9 years ago
by
柯阳
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
log filename specified
parent
d00e9ef8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
5 deletions
+10
-5
log.md
log.md
+10
-5
No files found.
log.md
View file @
b98d7518
...
...
@@ -12,7 +12,12 @@
原始日志应存放于
`/data/log/${SRV_NAME}/`
文件夹下,其中
`${SRV_NAME}`
为服务名。可以根据需求拆分子文件夹。
目前对原始日志的文件名没有要求。
通常情况下,日志文件名应该以模块名为前缀。对于不同日志等级的文件名后缀如下:
*
`DEBUG`
: 以
`.log.debug`
为后缀,如
`gaia.log.debug`
。
*
`INFO`
: 以
`.log`
为后缀,如
`gaia.log`
。
*
`WARNING`
: 以
`.log.warn`
为后缀,如
`gaia.log.warn`
。
*
`ERROR`
: 以
`.log.err`
为后缀,如
`gaia.log.err`
。
对于非当天的日志(logrotate的日志),需要加上日期后缀
`.YYYY-MM-DD`
,如
`gaia.log.warn.2015-10-14`
为2015-10-14的本机gaia WARNING日志。
## 日志编码
...
...
@@ -31,16 +36,16 @@
所有日志必须包含以下字段
* `LEVEL`: 日志等级。`DEBUG`, `INFO`, `WARNING`, `ERROR`等。
- debug
-
debug
记录调试信息,用于线上排查故障。
- info
-
info
记录正常的业务信息.
- warning
-
warning
系统存在问题但不影响系统正常使用, 可关注此问题并在下一个release里修复.
- error
-
error
系统存在影响用户正常使用的严重问题,需要立即上线修复.
* `LOGID`: trace用,暂时空缺,填空字符串。
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment