Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Next challenges

Recent achievements

  • Global
  • Personal

Recognition

  • Give kudos
  • Received
  • Given

Leaderboard

  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Calling plugin by different methods

Hi,

I am working on an auto-cloning plugin that will create clones in different fix versions based on data pulled from an external application. One of the requirements is to be able to invoke it both manually (as a web-item in the operations bar) or through a transition post-function.

I have found two plugins I have considered basing my plugin on. The JIRA Clone Plus Plugin which operates as a web-item in the operations bar and the JIRA GroovyScript Runner plugin which can clone from a transition post-function, but I would really like a single method to do it both ways.

I am open to thoughts and suggestions on how you might implement such a thing...

P.S. One option I have considered but I am not sure I like would be to add an Auto-Cone transition to every status (transitioning back to the same status). This would allow auto-cloning on demand or when a regular transition called it - my concern with this approach is maintaining the workflow. Thoughts?

Thanks,

Jon

2 answers

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

1 vote
Answer accepted

I would write the code as a service (not a JIRA service, but just as a concept) registered as a Spring Component in JIRA and then call this from either a Transition or the handler from the web-item.

Thanks Colin,
I have been taking a look at it and so far I like what I see (still have a lot to learn tho!).
Anyone know if there are tutorials or examples I could use to suppliment the docs I found here:
http://confluence.atlassian.com/display/PLUGINFRAMEWORK/_Content+for+Component+Plugin+Module
http://confluence.atlassian.com/display/PLUGINFRAMEWORK/Component+Import+Plugin+Module
J

In the end I did use a looping "AutoClone" transition (back to the initial status) to trigger a post-function groovy script. This allowed AutoCloning to be run manually by clicking the AutoClone Transition button or through a normal transition from Status A -> Status B where the post-function was defined.

I never got to try Colin's suggestion, but it sounds reasonable so I will mark it as an answer too.

Thanks Colin.

TAGS
Community showcase
Posted in Europe

RSVP: Warten auf das Christkind (Virtual International Edition)

    There are a lot of holidays between November  and January every year (too many to list here, see https://en.wikipedia.org/wiki/Lists_of_holidays) and for most ...

38 views 0 1
View post

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you