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

"Status Code: 404" when clicking on "schedule build" and deprecated method used by m2release.

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • m2release-plugin
    • None

      I had the same problem that Gontard posted in JENKINS-6420. The 'fix' that Teilo suggested took care of it; however, before finding that solution I took a look at the source code. I noticed that the m2Release plugin uses a deprecated method (getAbsoluteUrl()) in one of the classes (org.jvnet.hudson.plugins.m2release.M2ReleaseAction) and I wonder whether changing that would also solve the problem?

      I emailed a suggested patch to Teilo, and he recommended that I make a change to the patch and submit it in Jira, so here it is.

          [JENKINS-6873] "Status Code: 404" when clicking on "schedule build" and deprecated method used by m2release.

          Code changed in hudson
          User: : teilo
          Path:
          trunk/hudson/plugins/m2release/plugin/src/main/java/org/jvnet/hudson/plugins/m2release/M2ReleaseAction.java
          http://jenkins-ci.org/commit/32401
          Log:
          FIXED JENKINS-6873 use relative URL when redirecting

          SCM/JIRA link daemon added a comment - Code changed in hudson User: : teilo Path: trunk/hudson/plugins/m2release/plugin/src/main/java/org/jvnet/hudson/plugins/m2release/M2ReleaseAction.java http://jenkins-ci.org/commit/32401 Log: FIXED JENKINS-6873 use relative URL when redirecting

          lacostej added a comment -

          I am seeing issues with m2release 0.5.1 (upgraded from 0.4.0)

          after scheduling a release I am redirected to

          http://ci.example.com/job/project-trunk/m2release/job/project-trunk/

          instead of

          http://ci.example.com/job/project-trunk/

          Is this change the raeson for this regression ?

          lacostej added a comment - I am seeing issues with m2release 0.5.1 (upgraded from 0.4.0) after scheduling a release I am redirected to http://ci.example.com/job/project-trunk/m2release/job/project-trunk/ instead of http://ci.example.com/job/project-trunk/ Is this change the raeson for this regression ?

          James Nord added a comment -

          Cough splutter...

          James Nord added a comment - Cough splutter...

          Code changed in hudson
          User: : teilo
          Path:
          trunk/hudson/plugins/m2release/plugin/src/main/java/org/jvnet/hudson/plugins/m2release/M2ReleaseAction.java
          http://jenkins-ci.org/commit/32586
          Log:
          [FIXED JENKINS-6873]
          Redirect via the context path from the request and the main job URL.

          SCM/JIRA link daemon added a comment - Code changed in hudson User: : teilo Path: trunk/hudson/plugins/m2release/plugin/src/main/java/org/jvnet/hudson/plugins/m2release/M2ReleaseAction.java http://jenkins-ci.org/commit/32586 Log: [FIXED JENKINS-6873] Redirect via the context path from the request and the main job URL.

            Unassigned Unassigned
            sinkha sinkha
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: