The NiFi REST API includes a RequestLogger implemented as a Java Servlet Filter which logs requests using the following format:
The RequestLogger writes this message prior to request completion, so it is does not include HTTP response status information.
The identity field may not include username information when authenticating using a JWT. Additional information, such as User Agent and negotiated TLS version could also provide useful details.
HTTP request logging should be improved to include additional details and output information in a standardized format.
The W3C Extended Log File Format provides one potential option for access logging. The Common Log Format and Combined Log Format also provide de facto standards for access logging, while omitting some fields.