Forums

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

How to prevent new client attachments clobbering existing comments?

Ben Mann
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
November 20, 2018

Consider the following simple example, using a Service Desk Portal:

1. Client files a ticket "The Pony Generator Is Broken".

The description entered in the portal is "This is what it created" with an attachment, "pony.jpg"

2. Client goes to the portal and adds a response

"When I run it with parameter X it's different!" with attachment "pony.jpg"

portal_1.png

3. The client's view of the portal on doing this shows both images.

portal_2.png

4. If the client happens to refresh the page, they might notice both images are now the second image.

portal_3.png

5. The service desk agent only sees the latest version of "pony.jpg" for both comments, however the ticket does show both images.

agent_1.png

 

How should the agent know which pony image was generated with parameter X?

While it would be very serious if an agent attached a file with the same name in a private comment, this fails unceremoniously with a server error.

error_1.png

and in the logs,

http-nio-8080-exec-18 ERROR benm 801x137751x1 1vpsclq 172.16.251.21,0:0:0:0:0:0:0:1 /secure/attachment/500225/500225_pony.jpg [c.a.j.web.servlet.ViewAttachmentServlet] Error serving file for path /500225/500225_pony.jpg: getWriter() called after getOutputStream()
java.lang.IllegalStateException: getWriter() called after getOutputStream()

 

1 answer

1 accepted

0 votes
Answer accepted
Shannon S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
November 21, 2018

Hello Ben,

Thank you for contacting us about this. We have a few cases below that we're looking into where this is happening:

  • JSDSERVER-4100 Update existing attachment with same name
  • JRASERVER-2169 Jira does not differentiate between attachments of same name in comments while it does in attachment section
  • JSDSERVER-5054 Pasting screenshots with the same name will result in 'duplicated' images shown on the request
  • JSDSERVER-3615 Adding an attachment with an identical file name will change all existing references in a request

At this time, the only way to avoid this happening is if your users attach files of different filenames. Unfortunately this can be quite difficult to control if your users aren't aware of the names of the files already attached to the case.

You can help us out by voting on the above issues, as it helps us to keep track of the number of users who have run into this issue. Please also comment there with your findings. 

Do let us know if you have any questions about this.

Regards,

Shannon

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events