Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Does a deleted project keep any data in the database?

Adrian Mane October 11, 2022

I'm trying to find out if when I delete a project from Jira Software (Server) is there any data that remains in the DB that can be recovered? This is because I need to sanitize data in current Jira server so the new owner won't be able to see or recover any data from previous owner.

3 answers

1 accepted

1 vote
Answer accepted
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.
October 11, 2022

This generally sounds like something you would want Atlassian's response to - since us community members can be wrong, nor are we willing to be responsible should we indeed turn to be wrong. It's suggestions, at the end of the day.

 

However, when you delete a project, you delete it - Jira doesn't keep any backups about it. At best you would restore it from native Jira backup (xml) files, if you have those going for any reason, or from an .sql one. So unless you provide those as part of the handover, you should be generally fine.

Issues themselves are stored as 'jiraissue' table - this will get deleted along with the project. This table contains majority of system fields, such as description, due date, summary, reporter, etc.

Project itself is in 'project' table - and it just holds some metadata like name, key, but nothing about data. The row will get removed on delete.

Another table 'customfieldvalue' holds, wait for it, customfield values for the issue. This I believe also gets deleted alongside the project, but not that I ever had the need to confirm it. Plus, the data is linked to the jiraissue table via issue id, so there isn't really any way to "re-construct" the issue, even if the value remained, which I doubt.

Another table is 'jiraaction' which keeps hold of comments. Again, I believe this also does get flushed when the project is being deleted, but never had the need to go in postgres and verify it.

There are 2 conjoined twins 'changegroup' and 'changeitem', which keeps hold of issue history. Again, I believe these to be cleaned when the project is deleted, but never had the need to verify.

There is also something called I think 'issuelink' which keeps sourceissueid:destinationissueid relation about issue link types. This does get deleted also.

 

These are the major tables that come to my mind. There may be a few more smaller tables such as 'worklog' or 'votehistory' or something similar, but those are pretty much barely even relevant.

 

What you might want to do though is check for attachments which are normally stored in {{ jira_home }}/data - I believe that the whole project directory gets removed from there along with the project, but it's another thing to confirm it.

 

All in all, I think if you delete the project, it's pretty much unrecoverable, there's not going to be anything left to reconstruct anything, and Jira generally does a fair job at cleaning it.

What you should be aware of, however, is that the data may persist in some form in 3rd party apps - and this ranges wildly. In majority table from 3rd party apps will be similar in nature, something linked to an issueid, or issuekey, they have no need to keep any of your data, because the data is already there, they just need to link to it. But they could potentially keep some values or information about the issues. Some plugins have cleanup/maintenance jobs to clean themselves, some get automatically cleaned in the database (when a dependent column's value is deleted, for instance), and some clean themselves on the go through event ecosystem. Anyway, it's really a no guarantee about 3rd party apps, they have a lot of freedom in what they store.

 

You might though want to ping Atlassian for a more "official" confirmation, or at minimum run a few tests with the mentioned db tables, get a few SELECTs going and see what you end up with in the end - but I reckon it should be pretty clean, I don't think you'll find anything to stitch that data back.

Adrian Mane October 12, 2022

Hi @Radek Dostál ,

 

Thanks for the info.

I'll contact Atlassian Support for a more official answer :).

Vish Reddy {Revyz}
Community Champion
October 12, 2022

Hi @Adrian Mane 

I would love to know what you find out from the support team.

From what I know config items will remain, but actual data would go away, but is it hidden in some table, that is something the support team can tell you.

arno
Contributor
July 26, 2023

Hi @Vish Reddy {Revyz} 

Our current attachment data occupy a large amount, in addition to expansion, is there any way to optimize the processing of this part of data

Vish Reddy {Revyz}
Community Champion
July 26, 2023

Hi @arno 

I can for sure help you how to optimize your attachment data in the cloud, but on-premises I am not 100% sure of an easy way to optimize your attachment data.

1 vote
Nic Brough -Adaptavist-
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.
October 11, 2022

Yes, a line remains in the "project" table - the key, counter, description, category and a couple of other settings for the project.

But all the issue data is destroyed.

There may also be records in the moved issues table indicating when an issue was moved from the deleted project to another, but these are just "old key" and "Issue ID".

Configuration schemes all remain in place, because they are not project items, they are global and may be shared.

1 vote
Bhanu
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.
October 11, 2022

Hi @Adrian Mane 

Yes, there will be configuration data that will be left on the database after any deletion. To get to the data you will have to work through the database tables and delete the data which is not suggested in any scenario. There is a high chance that your data can get corrupted. 

if you are willing to clean up the database, Please do it in a test environment, Keep a copy of it as well, just incase you might need to rework through the process. 

Adrian Mane October 11, 2022

Hi @Bhanu 

I'm not concerned about the config data, I'm more concerned about comments and description. Do you know if those can be restored?

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
VERSION
8.20.11
TAGS
AUG Leaders

Atlassian Community Events