[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Paul Allen closed an issue as Fixed Released in 1.3.9 Jenkins / JENKINS-33858 Improvement of the P4 Trigger functionality Change By: Paul Allen Status: Resolved Closed Assignee: Paul Allen Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Allan BURDAJEWICZ commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality Paul Allen Indeed ParameterizedJobMixIn is quite helpful in that case. Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Paul Allen resolved as Fixed Jenkins / JENKINS-33858 Improvement of the P4 Trigger functionality Change By: Paul Allen Status: In Progress Resolved Resolution: Fixed Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title SCM/JIRA link daemon commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality Code changed in jenkins User: Paul Allen Path: src/main/java/org/jenkinsci/plugins/p4/trigger/P4Hook.java src/main/java/org/jenkinsci/plugins/p4/trigger/P4Trigger.java src/main/resources/org/jenkinsci/plugins/p4/trigger/P4Hook/index.jelly http://jenkins-ci.org/commit/p4-plugin/8c08ed7ef44e5c04e80fe4d7426580fd31587ab0 Log: Schedule build on trigger for subscribed Jobs. JENKINS-33858 Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Paul Allen commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality I see you use ParameterizedJobMixIn and not Job, hence the scheduleBuild(cause) method. I'll need to read up on what it does. Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Paul Allen commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality Unfortunately Queue does not seem to support Job for any of the schedule methods? If you know of a newer alternative please can you send me a complete example. Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Allan BURDAJEWICZ commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality > AbstractProject project = (AbstractProject) job; For compatibility with Pipeline I would suggest to use the type Job. > CauseAction cause = new CauseAction(new Cause.UserIdCause()); The UserIdCause does not provide useful information about who/what triggers the build. It would display something like 'Started by anonymous user' on the build page. IMHO, the _SCMTriggerCause _ would make more sense. By default, it displays a cause message like 'Started by an SCM change'. > I may add a manual trigger button (currently the 'p4' button does nothing). That sounds great. Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Paul Allen commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality I'm working on it right now... Was going to use the following in P4Trigger: /** * Schedule build * * @param job */ private void build(Job job) { AbstractProject project = (AbstractProject) job; TimeDuration delay = new TimeDuration(project.getQuietPeriod()); CauseAction cause = new CauseAction(new Cause.UserIdCause()); Queue queue = Jenkins.getInstance().getQueue(); queue.schedule(project, delay.getTime(), null, cause); } I may add a manual trigger button (currently the 'p4' button does nothing). Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Allan BURDAJEWICZ commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality Paul Allen Link to some code I worked on: https://github.com/Dohbedoh/p4-plugin/tree/trigger-builds Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Paul Allen started work on JENKINS-33858 Change By: Paul Allen Status: Open In Progress Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Allan BURDAJEWICZ commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality The current implementation of the Perforce trigger only detect changes and does not trigger any build as far as I understand: https://github.com/jenkinsci/p4-plugin/blob/master/src/main/java/org/jenkinsci/plugins/p4/trigger/P4Trigger.java#L70. A quick fix would be to add a `job.scheduleBuild(...)` Regarding the option to configure the trigger with a label, this could be made possible by adding some configuration to the Perforce trigger so that the user can choose and/or add a different "probing" strategy. > The triggering should be fairly light on Perforce I understand the point. P4 plugin is above all an SCM plugin and cover most common use-case. This label requirement might be too specific and not relevant to the majority of users but could well be extended. Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title mohamed badran commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality Yes, i do use a script that will send the trigger to Jenkins, and P4PORT in the trigger matches the same P4PORT in the credential. If i'm talking about your example then the p4port that i use is localhost:1777. Note my job runs on a slave not on Master Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Paul Allen commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality Sorry to keep verifying, but because you mentioned a proxy the Credential P4PORT matches your : e.g. localhost:1777 in my example: The reason I ask is the code just matches the two strings (there is no DNS name resolve) also 'user:' is definitely not going to work. Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title mohamed badran commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality Yes, it exactly matches. I've even tried to put my username to match and didn't work I've tried 2 ways Received trigger event: {"change":"2975743","p4port":":"} Received trigger event: {"change":"2975743","p4port":"::"} Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Paul Allen edited a comment on JENKINS-33858 Re: Improvement of the P4 Trigger functionality Does the P4PORT string in your Jenkins Perforce Credentials match EXACTLY the JSON string passed by the tigger trigger ? Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Paul Allen commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality Does the P4PORT string in your Jenkins Perforce Credentials match EXACTLY the JSON string passed by the tigger? Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title mohamed badran commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality By the way I've tried triggering the job, even if i've 'Perforce triggered build' set and the job doesn't build. Jenkins receives the trigger but the job doesn't run. Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title mohamed badran commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality I'm thinking about it to be like a "label" as what we do when creating slave nodes. Jobs does use the label, and then later on Jenkins builds the jobs on the right slaves. If we take the same analogy with triggers, and we can create something like a label in the payload, and Jenkins job configuration we add the same label then what would happen when we've few subscribed jobs: 1- Jobs that are with label and p4port should be triggered only when the payload matches i.e. we specify p4port, and label 2- When submitting payload with p4port only then only jobs with no labels should be triggered How would you trigger the job but not end up being built, unless you put conditions in Jenkins job itself not to continue running? Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title mohamed badran edited a comment on JENKINS-33858 Re: Improvement of the P4 Trigger functionality Hi Paul, Is there a way to make the P4 trigger feature only trigger few jobs not all jobs having the same p4port? According to what you said in her here that you've to subscribe, but what if I've many jobs that are subscribed using "Perforce triggered build" and they have same p4port? Is there a way to specify like a tag in the paylaod to trigger few jobs not all jobs that are subscribed and having same p4port? Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Paul Allen commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality How would you limit the triggering of a subscribed job? Perhaps a Project identifier? The triggering should be fairly light on Perforce, does it matter if many subscribed jobs are triggered that don't end up being build? Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title mohamed badran commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality Hi Paul, Is there a way to make the P4 trigger feature only trigger few jobs not all jobs having the same p4port? According to what you said in her that you've to subscribe, but what if I've many jobs that are subscribed using "Perforce triggered build" and they have same p4port? Is there a way to specify like a tag in the paylaod to trigger few jobs not all jobs that are subscribed and having same p4port? Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Paul Allen commented on JENKINS-33858 Re: Improvement of the P4 Trigger functionality The P4 Trigger feature should trigger a build if the Jenkins Job has subscribed to the trigger. Under 'Build Triggers' you need to check the 'Perforce triggered build.' option. I have not tested and/or exposed this to DSL/Workflow, but you may be able to use a pure class definition instead of the DSL. Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] [p4-plugin] (JENKINS-33858) Improvement of the P4 Trigger functionality
Title: Message Title Allan BURDAJEWICZ updated an issue Jenkins / JENKINS-33858 Improvement of the P4 Trigger functionality Change By: Allan BURDAJEWICZ Summary: Improvement of the P4 Trigger functionality Add Comment This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.