Plug.AccessLog.Formatter

Log message formatter.

Source

Summary

format(format, conn)

Formats a log message

Functions

format(format, conn)

Specs:

Formats a log message.

If no format is given a default will be used.

The following format values are supported:

  • %b - Size of response in bytes
  • %h - Remote IP of the client
  • %r - First line of HTTP request
  • %>s - Response status code

For now the http version written to the log message will always be “HTTP/1.1”, regardless of the true http version.

Source