Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-27311

404 on actions such as "Add build step" and "Add post-build action"

    • Icon: Bug Bug
    • Resolution: Not A Defect
    • Icon: Minor Minor
    • core
    • None

      When the Jenkins application is started one may be unable to use actions such as "Add build step" and "Add post-build action" when on a job configuration page. Inspecting browser console, a 404 error can be observed, reading (Google Chrome):

      Failed to load resource: the server responded with a status of 404 (Not Found)
      

      The requested URL is:

      http://<jenkins.tld>:<port>/$stapler/bound/c5f8ba68-a3aa-4750-a824-dbc4db0aae0d/render
      

      From my observations, the issue is always stops reproducing after the Jenkins service is restarted.

      The behaviour has been observed with Jenkins versions 1.597, 1.601, 1.602. We haven't tested the versions in between. The issue does not seem to be dependent on the browser used, we've tested with latest Firefox and Google Chrome.

      The logs don't indicate an error.

      Request when the functionality is working (status code 200):

      Remote Address:<ip>:<port>
      Request URL:http://<domain>:<port>/$stapler/bound/944a638d-94cf-4eaa-b5b2-b3c25c9a536f/render
      Request Method:POST
      Status Code:200 OK
      Request Headersview source
      .crumb:732309a1f15b07f707c4f9db713b1b36
      Accept:text/javascript, text/html, application/xml, text/xml, */*
      Accept-Encoding:gzip, deflate
      Accept-Language:en-US,en;q=0.8
      Connection:keep-alive
      Content-Length:2
      Content-type:application/x-stapler-method-invocation;charset=UTF-8
      Cookie:ACEGI_SECURITY_HASHED_REMEMBER_ME_COOKIE="aXZvOjE0MjY4NTU0NzA3Njk6OWIwYTM0NmY3ZDcwNzNhNWM4ZGU4NDJjMmRiNWFwZQ=="; screenResolution=1920x1080; JSESSIONID.fd92a8fb=4km5o289xgg31ioc1pe66bv26
      Crumb:732309a1f15b07f707c4f9db713b1b36
      Host:<domain>:<port>
      Origin:http://<domain>:<port>
      Referer:http://<domain>:<port>/job/bubefit/configure
      User-Agent:Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.115 Safari/537.36
      X-Prototype-Version:1.7
      X-Requested-With:XMLHttpRequest
      Request Payloadview source
      []
      No Properties
      Response Headersview source
      Content-Encoding:gzip
      Content-Length:778
      Content-Type:text/html;charset=UTF-8
      Server:Jetty(winstone-2.8)
      

      Although I can't find any specific difference, I am adding below the requests that are being send in each situation (note I've collected those from separate machines, both running 1.602).

      Request when it is returning a 404:

      Remote Address:<ip>:<port>
      Request URL:http://<domain>:<port>/$stapler/bound/1ae868f4-612b-481a-b7a1-56b7017dc053/render
      Request Method:POST
      Status Code:404 Not Found
      Request Headersview source
      Accept:text/javascript, text/html, application/xml, text/xml, */*
      Accept-Encoding:gzip, deflate
      Accept-Language:en-US,en;q=0.8
      Connection:keep-alive
      Content-Length:2
      Content-type:application/x-stapler-method-invocation;charset=UTF-8
      Cookie:ACEGI_SECURITY_HASHED_REMEMBER_ME_COOKIE="aXZheWxvLm1hcmlua292OjE0MjY4NTQ0MjM2MjU6OTgzZjFiMWJkM0YzE2Ng=="
      Crumb:abf7ffe4-4cf5-45d1-af58-f7a4197ef28a
      Host:<domain>:<port>
      Origin:http://<domain>:<port>
      Referer:http://<domain>:<port>/job/cloudhub-testing/configure
      User-Agent:Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.115 Safari/537.36
      X-Prototype-Version:1.7
      X-Requested-With:XMLHttpRequest
      Request Payloadview source
      []
      No Properties
      Response Headersview source
      Cache-Control:must-revalidate,no-cache,no-store
      Content-Length:1423
      Content-Type:text/html;charset=ISO-8859-1
      Server:Jetty(winstone-2.8)
      

      I will be happy to provide any additional details you may think may be relevant to this issue.

          [JENKINS-27311] 404 on actions such as "Add build step" and "Add post-build action"

          Ivaïlo Marinkov created issue -
          Ivaïlo Marinkov made changes -
          Environment Original: 1.602, 1.601, 1.597 New: 1.602, 1.601, 1.597 on CentOS release 6.6
          Ivaïlo Marinkov made changes -
          Attachment New: System Information [Jenkins].html [ 28722 ]
          Environment Original: 1.602, 1.601, 1.597 on CentOS release 6.6
          New: Jenkins 1.602, 1.601, 1.597 on CentOS release 6.6 (64bit)
          java version "1.7.0_67"
          Java(TM) SE Runtime Environment (build 1.7.0_67-b01)
          Java HotSpot(TM) Server VM (build 24.65-b04, mixed mode)
          Browsers: Firefox 36.0.1 and Chrome v. 40.0.2214.115 m on Windows 7

          The output from /systemInfo for one of the machines is attached to this Jira
          Ivaïlo Marinkov made changes -
          Attachment New: BoundObjectTable-log.txt [ 28725 ]
          Ivaïlo Marinkov made changes -
          Attachment New: org.kohsuke.stapler.Stapler-log.txt [ 28742 ]
          Ivaïlo Marinkov made changes -
          Attachment New: org.kohsuke.stapler.Dispatcher-log.txt [ 28747 ]
          Daniel Beck made changes -
          Resolution New: Not A Defect [ 7 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]
          R. Tyler Croy made changes -
          Workflow Original: JNJira [ 161516 ] New: JNJira + In-Review [ 196785 ]

            Unassigned Unassigned
            imarinkov Ivaïlo Marinkov
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: