jira-plugin icon indicating copy to clipboard operation
jira-plugin copied to clipboard

Add Jira Issue update step to pipeline

Open aatarasoff opened this issue 8 years ago • 11 comments

Similar as JiraIssueUpdateBuilder, but for pipeline


This change is Reviewable

aatarasoff avatar Jun 14 '16 14:06 aatarasoff

Coverage Status

Coverage increased (+0.5%) to 48.215% when pulling 69621d8ec55fb440fd5ee2bf70969752e1874641 on aatarasoff:pipeline-jira-issue-updater into a79b0fd5b002cd6aea2055d21934016bd96d1150 on jenkinsci:master.

coveralls avatar Jun 14 '16 14:06 coveralls

Looks good to me as a code. But I'm not sure what's the problem with the original JiraIssueUpdateBuilder. It implements SimpleBuildStep, hence it should be available in Pipeline

oleg-nenashev avatar Jun 15 '16 11:06 oleg-nenashev

I don't know how builder will look in pipeline, but I think that notation like:

jiraIssueUpdate(
  jqlSearch: jql,
  workflowActionName: action,
  comment: "Some comment"
)

is really easier for use. Could you provide an example with JiraIssueUpdateBuilder? And in pipeline syntax help I didn't see this builder.

aatarasoff avatar Jun 15 '16 13:06 aatarasoff

Add new pipeline steps. One for updating issue field and one for strict workflow process, cause issue updater set build only Unstable, but not Failure.

aatarasoff avatar Jul 04 '16 15:07 aatarasoff

Coverage Status

Coverage increased (+1.0%) to 48.712% when pulling da4fac3de32bf869d532fa1f1adf47aa3920a9c2 on aatarasoff:pipeline-jira-issue-updater into a79b0fd5b002cd6aea2055d21934016bd96d1150 on jenkinsci:master.

coveralls avatar Jul 04 '16 15:07 coveralls

I'll take a look at this tomorrow because it looks like some of the code is duplicated from the original JiraIssueUpdateBuilder class which as @oleg-nenashev pointed out should be usable already as a Pipeline step. On the other hand, I would warmly welcome the IssueFieldUpdateStep functionality as a separate PR!

rantoniuk avatar Aug 30 '16 01:08 rantoniuk

Please finish work on this so it can be merged, it would enable pipelines for our organization. This is the missing step.

z00dev avatar Sep 08 '16 07:09 z00dev

@eskobaba what about https://github.com/jenkinsci/jira-plugin/pull/101#issuecomment-226165515? did you try this one?

rantoniuk avatar Sep 14 '16 08:09 rantoniuk

I need pipeline compatibility to post a value to a customfield Have i overlooked something?

z00dev avatar Sep 14 '16 10:09 z00dev

@aatarasoff

I don't know how builder will look in pipeline, but I think that notation like:

jiraIssueUpdate(
  jqlSearch: jql,
  workflowActionName: action,
  comment: "Some comment"
)

is really easier for use. Could you provide an example with JiraIssueUpdateBuilder? And in pipeline syntax help I didn't see this builder.

This argument is quite convincing for me, but this PR needs a rebase. Would you have some time for it? if not, I'll try to take it over.

rantoniuk avatar Jun 10 '20 13:06 rantoniuk

@aatarasoff are you still using this construct? if so, could you rebase it to the current version?

rantoniuk avatar May 08 '24 13:05 rantoniuk