kvii
311016862b
feat: use writer directly in stdLogger. ( #3121 )
...
* feat: use writer directly in stdLogger.
* fix: Add newlines for each Log
* fix: remove break changes.
---------
Co-authored-by: Daemon <haiyux@foxmail.com>
2024-03-16 14:25:37 +08:00
言肆
d4edd442bb
feat(log): Prevent log.Helper sprintf from running early #3209 ( #3221 )
...
* feat(log): Prevent log.Helper sprintf from running early
* fix(log): add benchmark helper filter level
* chore(log): rename log Level Enabled
2024-03-15 11:09:57 +08:00
ionling
ff105d5bca
fix(log): WithContext()
changed the ctx field of the parent log.Filter ( #3069 )
...
* fix(log): `WithContext()` changed the ctx field of the parent log.Filter
* test(log): add concurrence test for `WithContext()`
* fix(log): concurrence problem of `Filter`
---------
Co-authored-by: 包子 <baozhecheng@foxmail.com>
2023-11-22 11:35:58 +08:00
freezeChen
3445f3ea8e
fix: logging middle don't get trace_id value when logger is filterLogger ( #2869 )
...
* Description (what this PR does / why we need it):
fix logging middle don't get trace_id value when logger is filterLogger
Which issue(s) this PR fixes (resolves / be part of):
#2570
#2571
* format
* fix:remove unuse test
2023-06-16 19:45:58 +08:00
woniu317
d0847cd462
feat: log helper support sprint option ( #2616 )
...
* feat:add sprint option
* fix: with helper need sprint
---------
Co-authored-by: zhoushijie <shijie.zhou@yunzhanghu.com>
2023-04-07 18:09:50 +08:00
jessetang
9a973d29c2
fix: rectification of non-standard lint codes ( #2746 )
2023-03-21 15:33:08 +08:00
Miguel Martínez Triviño
0f38511ea8
fix(filter): filter out keyvals if keyFunc is provided ( #2484 )
2022-11-07 14:24:41 +08:00
Jesse
a911f8f9ee
fix(log): toString float32 precision loss and convert uint use FormatUint
( #2461 )
...
* fix(log): toString float32 precision loss
* convert uint to string
2022-10-19 15:07:58 +08:00
jesse.tang
9737a3c5e4
fix: typo and grammatical errors ( #2368 )
...
* fix: grammar
* fix: grammar
* fix overrode
* translate to English
* translate to English
2022-09-19 10:39:54 +08:00
Tony Chen
2d206076f8
fix logger caller depth ( #2283 )
2022-08-16 22:54:55 +08:00
Haibo
6d665c0ce6
fix: wrong order of Logger prefix kvs ( #2273 )
2022-08-13 13:00:43 +08:00
SeniorPlayer
b9b7888d51
fix(log): DefaultCaller doesn't returns "pkg/file:line", it returns "file:line" now. For example, both biz/user.go and data/user.go are printed as user.go in logger. It's not clear. ( #2274 )
...
Co-authored-by: SeniorPlayer <SeniorPlayer@gg.com>
2022-08-13 13:00:02 +08:00
realityone
f0c2a6ed90
Global logger ( #2265 )
...
* global logger
* return global logger appliance instead of inner logger
* fix lint issues
* global logger test
2022-08-11 11:32:10 +08:00
jakezhu9
85af73a84b
test(log): increase tests coverage ( #2197 )
2022-07-14 20:20:38 +08:00
Betula-L
e09d294388
feat: add logrus to contrib log ( #2077 )
...
* add logrus to contrib log
* add readme
* fix test
* fix lint
* fix lint
* fix lint
2022-07-07 23:07:03 +08:00
Tony Chen
97c103a395
fix with logger ( #2062 )
...
* fix with logger
2022-05-28 19:45:37 +08:00
Tony Chen
dccee86141
log: remove component logger to use global logger ( #2061 )
...
* remove component logger to user global logger
2022-05-27 16:29:07 +08:00
longxboy
944d480f78
feat:add context for log ( #2041 )
...
* add context
2022-05-26 10:55:05 +08:00
Tony Chen
79497dd3a5
log: fix global logger ( #2034 )
...
* log: fix global logger
2022-05-24 00:40:45 +08:00
songzhibin97
2eb615b38a
style:log ( #2014 )
2022-05-21 16:23:09 +08:00
Elric Li
eb2dcae83d
feat(log): Helper implemented io.Writer ( #1927 )
...
* feat(log): Add writerWrapper implementing io.Writer
* fix(kratos): fix format has wrong type
* fix(log): rename writerOption to WriterOptionFn.
2022-05-06 15:59:50 +08:00
Cluas
13208d7908
fix(log): FilterFunc keyvals lost logger prefix ( #1901 )
2022-03-30 08:55:48 +08:00
Cluas
d4c0c57681
feat(log): log load config only when Debug level ( #1899 )
2022-03-29 16:39:31 +08:00
Tony Chen
51fb0e0440
fix(log): call depth ( #1885 )
...
* fix log caller
2022-03-18 00:03:33 +08:00
Chen Xinyuan
4387085047
fix: fix some typos ( #1869 )
2022-03-09 10:51:17 +08:00
haiyux
9dec67bddd
update contrib readme ( #1831 )
2022-02-21 18:37:20 +08:00
haiyux
9bf178b1d1
fix:fix log caller error ( #1773 )
...
* fix:fix log caller error
2022-01-17 21:00:22 +08:00
realityone
83fad75c0f
make logger appliance as logger proxy ( #1765 )
2022-01-14 13:16:25 +08:00
MARATRIX Li
c6c5e4595c
optimization: optimize global logger ( #1763 )
2022-01-13 10:11:23 +08:00
realityone
0ed2e0f379
feat(log): add global logger appliance, as process level default logger ( #1761 )
...
* add global logger appliance, as process level default logger
* replace DefaultLogger as global logger
2022-01-12 15:34:49 +08:00
haiyux
1c3185f9e5
readme:add log third party log library readme ( #1753 )
2022-01-07 17:54:40 +08:00
Eng Zer Jun
77b16286f8
refactor: move from io/ioutil to io and os packages ( #1633 )
...
The io/ioutil package has been deprecated as of Go 1.16, see
https://golang.org/doc/go1.16#ioutil . This commit replaces the existing
io/ioutil functions with their new definitions in io and os packages.
Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
2021-11-16 13:22:35 +08:00
海雨
7cd9503b95
test: add log test ( #1576 )
...
* test: add log test
* fix
* fix lint
2021-10-21 17:39:33 +08:00
sxpsxp12
63b1764a04
fix: fix log.Helper.WithContext msg key missing ( #1571 )
2021-10-20 18:50:52 +08:00
letian
3d23d295c4
feat(log): default message key ( #1545 )
2021-10-13 16:15:34 +08:00
包子
250bb5c8e7
feat(log/helper): log helper add WithMessageKey option ( #1541 )
2021-10-11 21:52:12 +08:00
404_K
aba30889c9
chrone: fix doc error ( #1498 )
2021-09-22 09:38:33 +08:00
Kagaya
f7588a47de
fix: ci lint error ( #1391 )
...
* fix lint check
* fix lll lint error
* fix build error
* fix gomnd
* fix shadow declaration
* add make test command
* update
2021-08-31 10:14:57 +08:00
包子
7b6332ee75
deps: middleware add separate go.mod and removes framework deps ( #1385 )
...
* deps: middleware add separate go.mod and removes framework deps
2021-08-30 23:07:31 +08:00
Xudong Cai
b44e47b087
refactor: optimize the code and use golangci-lint to check for any errors ( #1298 )
...
* feat: optimize the code and use golangci-lint to check for any errors
* fix: TestLogger unit test
2021-08-16 10:35:08 +08:00
拉小轰
5d07a94b16
use "and" replace "sub" ( #1207 )
2021-07-18 15:01:08 +08:00
longxboy
07f9fa3e91
change debug level to -1 ( #1105 )
2021-06-24 18:04:55 +08:00
包子
b4dd478bc9
update log/readme.md ( #1085 )
...
* update log/readme.md
Co-authored-by: chenzhihui <zhihui_chen@foxmail.com>
2021-06-20 21:23:57 +08:00
拉小轰
a928622f27
golang syntax log README.md ( #1084 )
...
* golang syntax log README.md
* golang syntax
2021-06-20 21:10:40 +08:00
包子
53522c4098
add log fatal level ( #1067 )
2021-06-16 14:53:44 +08:00
包子
258e911f4f
fix log filter ( #1056 )
...
* fix log filter
Co-authored-by: Tony Chen <zhihui_chen@foxmail.com>
2021-06-14 21:00:18 +08:00
chenzhihui
dc476c3b57
fix
2021-06-14 11:21:56 +08:00
chenzhihui
b378f993c4
fix
2021-06-14 11:19:39 +08:00
chenzhihui
91a01798f4
fix
2021-06-14 11:18:44 +08:00
chenzhihui
f92d4742bb
fix
2021-06-14 11:12:58 +08:00