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

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,560,546
Community Members
 
Community Events
185
Community Groups

Is there a way to store custom fields values in jira Home directory file , that already exists?

Edited

Hello , i really need an idea for this one.

I want to read and edit files that are in jira home directory , using my java plugin 

  • Thanks

1 answer

0 votes
Radek Dostál
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.
Mar 22, 2023 • edited

https://docs.atlassian.com/DAC/javadoc/jira/reference/com/atlassian/jira/config/util/JiraHome.html which can be used to get paths or files.

 

What I'm sceptical of is the need to do anything with homes. Nothing stops you from creating or using the files, but the db is generally the better place to store stuff, and far more performant than working with files, especially large ones.

 

In one of my plugins I'm caching things with this:

ComponentAccessor.getComponent(JiraHome.class).getHomePath()

 

I don't remember if I had problems injecting the class to the constructor, but at least this method works for sure.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
Mar 22, 2023

I'm with Radek on this - it's better to store data in the database.

Scriptrunner does a bit of this though - it can store scripts on the file system.  But we tend only to use that when we are doing version control on our scripts (they're kept in a git repo somewhere).  We've got an open improvement for integrating git into the UI so that we can stop using files on the disk.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events