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

EASY WAY : Update jira patch or change Single .class file

tousifs
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 21, 2012

Hi All,

Sometimes most people face problem when we have to do certern changes in jira source code running under JIRA system. For example,
they want to have some Functionality to be added in Running jira Instance i found an easy way of doing it.


Jira System is made up of classes,so eaditing classes directly not possible.

Do the following changes.

Identify the classes in which functionality needs to be change.


1) I assume you have Jira source

2) now you have to find the Required classes from the Jira Source and Update Required Changes in java file for the functionality we are expecting.(In my case i wanted to hide the RoadMap from certain roles)

3) you can have any plugin which is compatible with jira required version.
create the same package over there and keep the .java file in that.

4) now when we compile the plug-in the .class file's get created in target/classes/package/ now we have .class file under plug –in environment the new file is available with Required functionality(e.g ahide the RoadMap from certain role)

5) Shutdown Jira

6) Go to :- \WEB-INF\classes\ at the required destination ,replace the .class file with newly created .class file

7) Restart Jira


Now you can get expected out-put.

Hope this will be Helpful

3 answers

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

0 votes
Answer accepted
Mizan
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 25, 2012

Hi Tousif ,

Had to do something similar , for this i was reffering this document , i tried your way(trick) and i was able to compile the single java class . Thanks :)

0 votes
Michael Lee August 21, 2012

Hi Tousif,

I have a few questions and I am very new to JIRA so I hope you understand.

I am hoping you can answer some of my followup questions.

1) By having the JIRA source, do you mean the .java file I am trying to modify?

- I have the java class file that I am trying to modify

2) Does this step mean make the changes in the file that I am trying to make?

3) Not exactly sure about this step

Is there anyone who can give some insight on this?

tousifs
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 21, 2012

Hi Mike,

you have the java class file that you want to modify?

yes at the runtime the jira system communicate with applcation using the class file only.

if we analyzed the jira file structure its made up with classes.

we have to implement the change to specific class to enhance the default jira functionality.

please explain your problem what exactly you want to achive so i can give you suggections accordingly.

Thanks,

Tousif shaikh.

Michael Lee August 21, 2012

Hi Tousif,

Thank you for your reply. I have started a thread on https://answers.atlassian.com/questions/79719/patching-jira-createissuehandler

0 votes
Kapil Bolli
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 21, 2012

Hi Tousif,

I usually do this lot's i find helpful thank's.

TAGS
AUG Leaders

Atlassian Community Events