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

Cannot use regular expressions on Poll Exclude User(s) to restrict build triggers to a particular list of users.

    • Icon: New Feature New Feature
    • Resolution: Unresolved
    • Icon: Major Major
    • p4-plugin
    • None
    • Ubuntu 10.10 x86_64 server

      The Poll Exclude User(s) feature prevents certain Perforce user IDs from triggering a build. I have a very large number (appx. 1000) P4 users doing check-ins, but only what to trigger builds from a small subset of them (maybe 15 individuals). Since HTTP GET fails if I try to list a huge number of users in this box, I need to use a regular expression with ! operations to specify the triggers, as the built in help claims you can do.

      So if I want ONLY john.doe and jane.smith to trigger a build I should be able to type the following into the Poll Exclude User(s) box:

      !(john\.doe||jane\.smith)

      Unfortunately, this does not work. What I am finding is every change makes it through the filter. It would be nice to instead whitelist the users who will trigger builds, but that feature is not provided. I am setting up a CI server for a subgroup within the company, and while they would like to be able to pick up everybody's changes, they are only interested in triggering builds when a member of their group checks something in.

      Is this a genuine bug, or is there a problem with my regular expression syntax? Unfortunately, there isn't any examples of how to use this feature that I can find. The online help or wiki should probably provide a bit more examples how to use regular expressions here.

          [JENKINS-9572] Cannot use regular expressions on Poll Exclude User(s) to restrict build triggers to a particular list of users.

          Oleg Nenashev added a comment -

          Not a bug, wrong component

          Oleg Nenashev added a comment - Not a bug, wrong component

          • I did not reproduce the problem outlined in the description with version 1.3.27. The regular expression that I used is:
            ^((?!(john\.doe|jane\.smith)).*)$
          • The documentation is pretty explicit: it states that the "Poll Exclude User(s)" feature supports Java regular expressions with a link to http://docs.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html
          • I think the issue can be closed.

          Gregory SSI-YAN-KAI added a comment - I did not reproduce the problem outlined in the description with version 1.3.27 . The regular expression that I used is: ^((?!(john\.doe|jane\.smith)).*)$ The documentation is pretty explicit: it states that the "Poll Exclude User(s)" feature supports Java regular expressions with a link to http://docs.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html I think the issue can be closed.

            Unassigned Unassigned
            gary_c Gary Cameron
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: