Uploaded image for project: 'Dev - Nexus Repo'
  1. Dev - Nexus Repo
  2. NEXUS-16903

include HTTP request Content-Length header value in request.log

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Medium
    • Resolution: Fixed
    • Affects Version/s: 3.0.0, 3.10.0
    • Fix Version/s: 3.13.0
    • Component/s: Logging
    • Labels:
    • Story Points:
      1
    • Release Note:
      Yes

      Description

      Sometimes problem diagnosis in Nexus Repository Manager may benefit from knowing the inbound http request anticipated content size.

      For a large majority of requests to add content into Nexus, HTTP PUT is used. In those cases, the request content size information is usually available from the HTTP request Content-Length header value.. ( there are some exceptions, in particular "When a message does not have a Transfer-Encoding header field, a Content-Length header field can provide the anticipated size, as a decimal number of octets, for a potential payload body." )

      Expected

      The default request.log log pattern for Nexus should be adjusted to include the value if any of the Content-Length header of the request.

      Current pattern as of nexus 3.10.0

      %clientHost %l %user [%date] "%requestURL" %statusCode %bytesSent %elapsedTime "%header{User-Agent}"
      

      Proposed new format:

      %clientHost %l %user [%date] "%requestURL" %statusCode %header{Content-Length} %bytesSent %elapsedTime "%header{User-Agent}"
      

      This change should be announced in release notes in case users have configured external request log parsers which may need adjustment or prefer to not have this value printed.

        Attachments

          Activity

            People

            Assignee:
            Unassigned
            Reporter:
            plynch Peter Lynch
            Last Updated By:
            Peter Lynch
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Date of First Response:

                tigCommentSecurity.panel-title