Uploaded image for project: 'Infrastructure'
  1. Infrastructure
  2. INFRA-1072

Artifactory returns HTTP 200 instead of HTTP 404 when requesting a missing resource

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Cannot Reproduce
    • Component/s: artifactory
    • Labels:
      None
    • Similar Issues:

      Description

      Current behavior:
      When trying to download a missing file, repo.jenkins-ci.org returns HTTP 200 and a JSON payload:

      {
        "errors" : [ {
          "status" : 404,
          "message" : "File not found."
        } ]
      }
      

      Expected behavior:
      When trying to download a missing file, the server should return HTTP 404:

      The 404 (Not Found) status code indicates that the origin server did
      not find a current representation for the target resource or is not
      willing to disclose that one exists.
      RFC7231, Section 6.5.4

      Steps to reproduce:

      1. curl -s -S https://repo.jenkins-ci.org/releases/org/jenkins-ci/plugins/swarm-client/3.3/swarm-client-3.3-jar-with-dependencies.jar -o client.jar
      2. cat client.jar

        Attachments

          Activity

            People

            • Assignee:
              danielbeck Daniel Beck
              Reporter:
              cryptidvulpes Jami Lindh
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: