1
0
mirror of https://github.com/astaxie/beego.git synced 2024-06-01 22:43:28 +00:00
Commit Graph

74 Commits

Author SHA1 Message Date
Ming Deng
30eb889a91 Format code 2020-07-22 23:00:06 +08:00
dbt4516
b3ae5d4ac6
Update file.go
According to issue#4759 (https://github.com/golang/go/issues/4759) filepath.Walk function in golang cannot handle symbolic path, meanwhile symbolic path for log directory is pretty common used. In such scenario this deleteOldLog function will fail without any error log. Get the real location of the log directory before using walk function can fix this.
2019-10-09 15:53:22 +08:00
wanghz
77fc8e4e38 According to issue#4759 (https://github.com/golang/go/issues/4759) filepath.Walk function in golang cannot handle symbolic path, meanwhile symbolic path for log directory is pretty common used. In such scenario this deleteOldLog function will fail without any error log. Get the real location of the log directory before using walk function can fix this. 2019-10-09 15:33:38 +08:00
two
31c746d9d7 fix all confict 2018-07-26 14:34:25 +08:00
two
38a2f32252 fix one confict 2018-07-26 14:29:26 +08:00
astaxie
96dffcd27f
Merge pull request #3105 from ckahi/hotfix_log_dir
auto create log dir
2018-07-20 15:32:42 +08:00
umasuo
f979050a45
Fix defaut value bug, and add default maxfiles
1. add default value for maxlines(100000), maxsize(1 << 28)
2. add maxfiles for configure, just like `maxlines` & maxsize
2018-06-03 23:08:03 +08:00
chenkaihui
6db9ad7002 auto create log dir 2018-04-04 15:59:52 +08:00
chenxiaonan01
1a42154c64 add file test 2017-12-20 17:54:40 +08:00
chenxiaonan01
e81cca304b add file test 2017-12-20 16:19:58 +08:00
chenxiaonan01
07aa97aa9a add hourly rotate file.go 2017-12-20 15:56:36 +08:00
陈培远
80fa51468c avoid unnecessary read of large log file
If w.MaxLines is not set, there is no need to calc large log file’s lines. It may takes more than 10mins to calc a 10G file.
2017-11-07 22:58:39 +08:00
Jia Li Ong
31b2b21dbc Merge branch 'master' of https://github.com/jialijelly/beego 2017-06-27 10:48:52 +08:00
Jia Li Ong
16b5a11484 Merge branch 'master' of https://github.com/jialijelly/beego 2017-06-22 18:55:25 +08:00
Jia Li Ong
5a2eea07cb Provide permission to access old log files to everyone 2017-06-22 18:51:52 +08:00
Jia Li Ong
0ea34fff27 Provide permission to access old log files to everyone 2017-06-02 10:56:55 +08:00
astaxie
a91e2e9950 add golint check and fix all golints 2017-04-30 22:41:23 +08:00
astaxie
aa8f7bc146 fix ineffectual 2017-04-28 22:36:28 +08:00
astaxie
405c170d45 Merge pull request #2556 from zjjott/master
fix: log mode should be 0440 should not be 440
2017-04-10 21:14:34 +08:00
zjjott
932019770d fix: log mode 0440 should not be 440 2017-04-10 17:37:55 +08:00
Sergey Lanzman
37c1ffc57a add go simple support 2017-03-17 20:22:20 +02:00
codejuan
b788d74fd1 set perm of rotated log to 440 2016-12-06 12:44:00 +08:00
GuyCheung
9572fdcf9a update error on type of w.Perm; change unit test perm value 2016-06-22 09:57:16 +08:00
GuyCheung
cb3f240f44 add os.Chmod when create log file 2016-06-21 15:52:31 +08:00
nullne
2c12383263 remove attribute perm to make it more brief 2016-05-17 10:29:05 +08:00
nullne
d679a4b865 fix bug with file permission in log module 2016-05-14 10:54:09 +08:00
JessonChan
b28581a463 make daily rotate 2016-05-06 12:11:14 +08:00
JessonChan
fa8d94fa69 file rotate by day test 2016-05-06 12:09:00 +08:00
JessonChan
abaa1bbcac file rotate file test 2016-04-13 09:05:16 +08:00
JessonChan
22617aeb13 file rotate name fixed 2016-04-12 15:05:35 +08:00
JessonChan
221306fff4 file rotate bug 2016-03-29 10:05:56 +08:00
JessonChan
03840f3fe8 give each of the adapter a neme 2016-03-24 17:38:26 +08:00
JessonChan
2b1316c738 data race bug fixed 2016-03-16 18:04:07 +08:00
JessonChan
3379a2b7ed remove file bug fixed
remove file by filename and file suffix
2016-03-04 10:43:57 +08:00
JessonChan
26cc040f9a daily log name dot fixed 2016-03-01 17:00:24 +08:00
JessonChan
51b1095e73 add files logger 2016-02-03 16:32:59 +08:00
JessonChan
68cc53e92b when rotate by date ,there's no num after log file 2016-02-03 15:43:15 +08:00
JessonChan
6caa3ecd91 when rotate by date ,there's no num after log file 2016-02-03 15:31:59 +08:00
JessonChan
304a5ccea0 comment fix 2016-02-03 15:06:53 +08:00
JessonChan
9806a43783 make more fast 2016-02-03 15:03:37 +08:00
JessonChan
a1cb000701 remove log package 2016-02-03 14:42:38 +08:00
JessonChan
f2567bc114 some typo fixed 2016-01-26 09:29:04 +08:00
JessonChan
b5a07c6ba8 log file name bug fixed
this bug happens when daily rotate. ex,when it is 2016-01-22 23:59:59 and need a rotate,the file name should named with 2016-01-22 but named with 2016-01-23(next day)
2016-01-26 09:20:49 +08:00
youngsterxyf
bcac4bb8e3 accept @JessonChan suggestion 2016-01-25 20:53:25 +08:00
youngsterxyf
ecf24640fd fix issue #1566 2016-01-23 16:56:54 +08:00
JessonChan
fb5b04506a code refactor and format 2016-01-13 09:24:27 +08:00
JessonChan
7663d50c97 remove the lock writer 2016-01-13 09:21:55 +08:00
JessonChan
e1b73b33d0 improve code 2016-01-13 08:21:44 +08:00
JessonChan
164366ae0d return error 2016-01-12 22:33:52 +08:00
JessonChan
2b9d7ff714 remove log package 2016-01-12 22:32:36 +08:00