@@ -24,44 +24,48 @@ The following log levels can be configured through the configuration CLI:
24
24
### Configuring Log Levels
25
25
Use the following commands to get information on the logging module configuration:
26
26
27
- ``` bash
28
- $ /opt/jans/jans-cli/config-cli.py --info ConfigurationLogging
29
- # Log configuration operations
30
- Operation ID: get-config-logging
31
- Description: Returns Jans Authorization Server logging settings.
32
- Operation ID: put-config-logging
33
- Description: Updates Jans Authorization Server logging settings.
34
- Schema: /components/schemas/LoggingConfiguration
35
-
36
- To get sample schema type /opt/jans/jans-cli/config-cli.py --schema < schma> , for example /opt/jans/jans-cli/config-cli.py --schema /components/schemas/LoggingConfiguration
37
-
38
- $ /opt/jans/jans-cli/config-cli.py --schema /components/schemas/LoggingConfiguration
39
- # Generic configuration schema
40
- {
41
- " loggingLevel" : " TRACE" ,
42
- " loggingLayout" : " json" ,
43
- " httpLoggingEnabled" : true,
44
- " disableJdkLogger" : false,
45
- " enabledOAuthAuditLogging" : true,
46
- " externalLoggerConfiguration" : null,
47
- " httpLoggingExcludePaths" : [
48
- " /auth/img" ,
49
- " /auth/stylesheet"
50
- ]
51
- }
52
-
53
- $ /opt/jans/jans-cli/config-cli.py --operation-id get-config-logging
54
- # Current log configuration
55
- {
56
- " loggingLevel" : " INFO" ,
57
- " loggingLayout" : " text" ,
58
- " httpLoggingEnabled" : false,
59
- " disableJdkLogger" : true,
60
- " enabledOAuthAuditLogging" : false,
61
- " externalLoggerConfiguration" : null,
62
- " httpLoggingExcludePaths" : null
63
- }
64
- ```
27
+ - To get the logging configuration operation ID: ` /opt/jans/jans-cli/config-cli.py --info ConfigurationLogging `
28
+ - Output would be:
29
+ ```
30
+ # Log configuration operations
31
+ Operation ID: get-config-logging
32
+ Description: Returns Jans Authorization Server logging settings.
33
+ Operation ID: put-config-logging
34
+ Description: Updates Jans Authorization Server logging settings.
35
+ Schema: /components/schemas/LoggingConfiguration
36
+ ```
37
+ - To get sample schema type /opt/jans/jans-cli/config-cli.py --schema <schma>,
38
+ for example `/opt/jans/jans-cli/config-cli.py --schema /components/schemas/LoggingConfiguration`
39
+ - Output:
40
+ ```
41
+ # Generic configuration schema
42
+ {
43
+ "loggingLevel": "TRACE",
44
+ "loggingLayout": "json",
45
+ "httpLoggingEnabled": true,
46
+ "disableJdkLogger": false,
47
+ "enabledOAuthAuditLogging": true,
48
+ "externalLoggerConfiguration": null,
49
+ "httpLoggingExcludePaths": [
50
+ "/auth/img",
51
+ "/auth/stylesheet"
52
+ ]
53
+ }
54
+ ```
55
+ - Status of current configuration logging: `/opt/jans/jans-cli/config-cli.py --operation-id get-config-logging`
56
+ - Output:
57
+ ```
58
+ # Current log configuration
59
+ {
60
+ "loggingLevel": "INFO",
61
+ "loggingLayout": "text",
62
+ "httpLoggingEnabled": false,
63
+ "disableJdkLogger": true,
64
+ "enabledOAuthAuditLogging": false,
65
+ "externalLoggerConfiguration": null,
66
+ "httpLoggingExcludePaths": null
67
+ }
68
+ ```
65
69
66
70
Let's assume we want to update logging configuration to `TRACE`. To do this, create a file `/tmp/log.json` with the following content:
67
71
```json
@@ -77,7 +81,7 @@ Let's assume we want to update logging configuration to `TRACE`. To do this, cre
77
81
```
78
82
And use the PUT operation with this file as the payload:
79
83
```
80
- $ /opt/jans/jans-cli/config-cli.py --operation-id put-config-logging --data /tmp/log.json
84
+ /opt/jans/jans-cli/config-cli.py --operation-id put-config-logging --data /tmp/log.json
81
85
```
82
86
The server will now have logs set to TRACE.
83
87
0 commit comments