• Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Major Major
    • core
    • None
    • Platform: All, OS: All

      Triggering builds using a CVS commit hook has significant advantages compared to
      polling, specifically builds are started immediately and the CVS server is less
      loaded as it is not being polled constantly.

      It would be very nice if it was possible to trigger hudson to poll CVS when
      triggered, ie. instead of configuring hudson to poll on a schedule it should be
      possible to configure a job to poll CVS when triggered.

      I imagine there could be another text field in the job configuration page when
      Poll SCM is checked where an scm/trigger-id can be specified. The job should
      then poll when an url like the following is invoked (from a commit hook):

      wget -O - http://YOURHUDSON/poll_scm?scm=<scm-id>

          [JENKINS-4898] Poll SCM trigger mechanism

          tsondergaard added a comment -

          Corrected summary

          tsondergaard added a comment - Corrected summary

          Alan Harder added a comment -

          I believe the url is YOURHUDSON/job/JOBNAME/polling
          Use username/password params with wget or use the ?token=.. method to get access
          for this command.

          Alan Harder added a comment - I believe the url is YOURHUDSON/job/JOBNAME/polling Use username/password params with wget or use the ?token=.. method to get access for this command.

          Alan Harder added a comment -

          Hope the above tip is working.. closing issue; reopen if there is still a problem, thanks.

          Alan Harder added a comment - Hope the above tip is working.. closing issue; reopen if there is still a problem, thanks.

          tsondergaard added a comment -

          I am using the tip, but it is not ideal. Here's the line from loginfo that I use to trigger polling from CVS:

          ALL cat >/dev/null; wget --timeout=15 -O - http://hudson:8080/job/

          {job1,job2,job3}

          /polling?token=my_secret >/dev/null 2>&1

          The problem is that when I add a new job I have to check out loginfo and make sure that job is triggered too. It would be nicer to have this functionality in hudson, so I could replace the above with

          ALL cat >/dev/null; wget --timeout=15 -O - http://hudson:8080/polling?token=my_secret >/dev/null 2>&1

          I would expect adding such a feature is trivial?

          tsondergaard added a comment - I am using the tip, but it is not ideal. Here's the line from loginfo that I use to trigger polling from CVS: ALL cat >/dev/null; wget --timeout=15 -O - http://hudson:8080/job/ {job1,job2,job3} /polling?token=my_secret >/dev/null 2>&1 The problem is that when I add a new job I have to check out loginfo and make sure that job is triggered too. It would be nicer to have this functionality in hudson, so I could replace the above with ALL cat >/dev/null; wget --timeout=15 -O - http://hudson:8080/polling?token=my_secret >/dev/null 2>&1 I would expect adding such a feature is trivial?

          Whilst CVS is mentioned in the description, this issue actually needs changes in the core. Adding core as affected component

          Michael Clarke added a comment - Whilst CVS is mentioned in the description, this issue actually needs changes in the core. Adding core as affected component

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

              Created:
              Updated: