File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -149,7 +149,7 @@ json_logging.config_root_logger()
149
149
```
150
150
151
151
# 3. Configuration
152
- logging library can be configured by setting the value in json_logging
152
+ logging library can be configured by setting the value in json_logging, all configuration must be placed before json_logging.init method call
153
153
154
154
Name | Description | Default value
155
155
--- | --- | ---
Original file line number Diff line number Diff line change 7
7
8
8
app = flask .Flask (__name__ )
9
9
json_logging .ENABLE_JSON_LOGGING = True
10
+ # json_logging.CREATE_CORRELATION_ID_IF_NOT_EXISTS = False
10
11
json_logging .init (framework_name = 'flask' )
11
12
json_logging .init_request_instrument (app )
12
13
15
16
logger .setLevel (logging .DEBUG )
16
17
logger .addHandler (logging .StreamHandler (sys .stdout ))
17
18
18
-
19
19
@app .route ('/' )
20
20
def home ():
21
21
logger .info ("test log statement" )
You can’t perform that action at this time.
0 commit comments