Hello,

      Currently one can specify a list of depot path for which changes in them will not trigger a build.
      I would like to be able to specify a list of depot path that would trigger a build, implying any changes outside of this list will NOT trigger a build.
      I could achieve that feature using a combination of view mappings and exclude filters. However in my case it would require a huge list of excludes which would be painful to maintain.
      I don't expect excludes and includes to be supported concurrently for the same job, i.e one would have to use only one of this kind of filter.

      Thank you.

          [JENKINS-28225] Add include filters for build trigger

          Paul Allen added a comment -

          How are you triggering the Jenkins Job? Polling by SCM or a Perforce trigger?

          The free Perforce Swarm review tool can trigger the Jenkins job for a particular Perforce project/codeline.

          Paul Allen added a comment - How are you triggering the Jenkins Job? Polling by SCM or a Perforce trigger? The free Perforce Swarm review tool can trigger the Jenkins job for a particular Perforce project/codeline.

          Francois E added a comment -

          Triggering by polling SCM.

          I didn't know about the ability of perforce swarm review tool to trigger job. I looked at the swarm documentation and it seems there is no API to create projects, so this would be involve manual steps. Definitely a blocker.
          Anyway a solution that doesn't introduce a dependency on swarm would be much preferred.
          Thank you!

          Francois E added a comment - Triggering by polling SCM. I didn't know about the ability of perforce swarm review tool to trigger job. I looked at the swarm documentation and it seems there is no API to create projects, so this would be involve manual steps. Definitely a blocker. Anyway a solution that doesn't introduce a dependency on swarm would be much preferred. Thank you!

          James B. added a comment - - edited

          Paul Allen wrote: "The free Perforce Swarm review tool..."

          Swam may be free to download, but money is not the only cost of adopting a new tool. My company is currently exploring Swarm as a replacement for other code review tools, but our IT department hasn't yet set a timeline for deployment.

          I would find this feature helpful. It's the first missing feature I noticed in the P4 plugin and my primary gripe. Not a Blocker for me, and I guess not Critical since the (painful) exclude filter workaround exists, but I'd be in favor of upgrading from Minor to Major. Adding and maintaining a long list of exclude filters doesn't sound fun.

          EDIT: Adding many exclude filters is especially painful due to the "one at a time" user interface. If that were a big text field that let me copy and paste from a workspace mapping (or even better, pull from a file in Perforce), I'd be less grumpy.

          James B. added a comment - - edited Paul Allen wrote: "The free Perforce Swarm review tool..." Swam may be free to download, but money is not the only cost of adopting a new tool. My company is currently exploring Swarm as a replacement for other code review tools, but our IT department hasn't yet set a timeline for deployment. I would find this feature helpful. It's the first missing feature I noticed in the P4 plugin and my primary gripe. Not a Blocker for me, and I guess not Critical since the (painful) exclude filter workaround exists, but I'd be in favor of upgrading from Minor to Major. Adding and maintaining a long list of exclude filters doesn't sound fun. EDIT: Adding many exclude filters is especially painful due to the "one at a time" user interface. If that were a big text field that let me copy and paste from a workspace mapping (or even better, pull from a file in Perforce), I'd be less grumpy.

          Code changed in jenkins
          User: Paul Allen
          Path:
          src/main/java/org/jenkinsci/plugins/p4/filters/FilterViewMaskImpl.java
          src/main/java/org/jenkinsci/plugins/p4/tasks/PollTask.java
          src/main/resources/org/jenkinsci/plugins/p4/filters/FilterViewMaskImpl/config.jelly
          src/main/resources/org/jenkinsci/plugins/p4/filters/FilterViewMaskImpl/help-viewMask.html
          src/test/java/org/jenkinsci/plugins/p4/client/ConnectionTest.java
          http://jenkins-ci.org/commit/p4-plugin/a4b9b3a00983586f41da8fd0da685902d307c1f9
          Log:
          (@stuartr) Implementing View Mask Filter.

          JENKINS-30622
          JENKINS-28225

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Paul Allen Path: src/main/java/org/jenkinsci/plugins/p4/filters/FilterViewMaskImpl.java src/main/java/org/jenkinsci/plugins/p4/tasks/PollTask.java src/main/resources/org/jenkinsci/plugins/p4/filters/FilterViewMaskImpl/config.jelly src/main/resources/org/jenkinsci/plugins/p4/filters/FilterViewMaskImpl/help-viewMask.html src/test/java/org/jenkinsci/plugins/p4/client/ConnectionTest.java http://jenkins-ci.org/commit/p4-plugin/a4b9b3a00983586f41da8fd0da685902d307c1f9 Log: (@stuartr) Implementing View Mask Filter. JENKINS-30622 JENKINS-28225

          Paul Allen added a comment -

          Ready for release

          Paul Allen added a comment - Ready for release

          Paul Allen added a comment -

          Released in 1.4.7

          Paul Allen added a comment - Released in 1.4.7

            Unassigned Unassigned
            fechanti Francois E
            Votes:
            4 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: