Forums

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

Why is just exchanging the attachment file not working ?

Albert Cameron August 6, 2021

I wanted to exchange an attachment on the Jira Server.

So I just get the path of the attachment , then deleted it and put a new file

with the same name and same path on the server again.

But when I requested this attachment it was corrupted.

So the only solution was to really delete the attachment and then create a new attachment with this file.

So I really wondering why the attachment was corrupted when I just exchanged the file.

 

1 answer

0 votes
Brant Schroeder
Community Champion
August 6, 2021

@Albert Cameron 

The attachments attributes are stored in the database.  So if you replace the file the application will not recognize it as the same file since the makeup of the file has changed. 

Albert Cameron August 7, 2021

Ok. Makes sense. But I do not put a corrupted file on the server. But why is it corrupted when I request an issue with the attachments. Does Jira just return a different file all of a sudden ?

Brant Schroeder
Community Champion
August 7, 2021

Not file type.  If I remember it is size and other information.  The biggest thing that most likely is the issue is I think that there is a binary string that needs to match.  

Albert Cameron August 7, 2021

But the big question. Why is the file corrupted. I 100% put a clean file there. So maybe Jira detects file attributes changed without its knowledge so corrupts the file and returns it. Just an assumption.

Brant Schroeder
Community Champion
August 8, 2021

I believe if the attributes do not match then you are correct the application determines it is corrupt.  Even if the file is ok on the files server the application is doing a compare on the file load so the application is making the call.

Suggest an answer

Log in or Sign up to answer