-
New Feature
-
Resolution: Unresolved
-
Medium
-
None
-
None
There should be an option to log whole RESTCONF traffic - requests and responses - without external dependency.
Customer-based requirements about the contents of logs (user ID is probably one of the most important fields - native Jetty logger/LoggingFeature from Jersey will not help much):
- timestamp (human-readable format & unix format - milliseconds)
- log level
- logging filter name
- remote address
- controller user ID (resolved using AAA)
- request method
- request URI
- request body size
- response code
- response payload size
- duration in milliseconds
- request/response body
- http headers
- query parameters
Next requirements:
- option to enable/disable logging at runtime + providing a configuration using cfg file in etc
- option to configure whether HTTP headers, query parameters, and bodies should be part of output logs
- option to hide selected headers - Authorization/Cookie
- option to redirect logs to separate file - logs should be generated from separate classes, so it will be possible to easily configure log4j2 appender
- simple column-based format (using ' | ' for separation of fields)
Requests and responses can be logged separately.
Note: we can inspire by LoggingFeature or LoggingFilter (jersey).