Reg : Issue with inline images in recent builds of SDP

Reg : Issue with inline images in recent builds of SDP

Many of the customer's would have reported missing images in description, resolution, notes etc... after moving to version 11138 and above. This is a product issue which we have identified and released a couple of patch's yesterday. The details are as below,
  • 11144 - for customer's who are in builds between 11138 to 11143.
  • 11201 - for customer's who are in build 11200.
This issue can have a potential data loss of inline images in a few scenario's and we request customer's who are in the affected version to move to either 11144 or 11201. 

Details of the Issue :  

Inline images can be added to a description, notes, resolution etc.. in multiple ways.
  • Request created through mail with inline images in them ( This has no issue. Everything will work fine and no loss of data )
  • Request / resolution / notes created through the UI and inline images added using the image upload option available in the Rich text area menu ( This has no issue. Everything will work fine and no loss of data ). 
  • Request / resolution / notes created through the UI and inline images added using Copy - Paste mechanism in the description area ( Potential loss of images added to requests / notes by certain users after 11138 and loss of images added by certain users to resolution post 11106 )
What happened?

While an inline image is added  to a request / notes etc... it will first be added to a temp directory and then when the request / notes / resolution gets saved, it will be moved to the actual directory. A few changes where done in the 11138 release,
  • All of request pages where moved to API based implementation during which the movement of the files that where copy - pasted got left out and so they stayed in the temp location itself.
  • To address a different vulnerability issue where a user adds some images in the request creation form, but decides to cancel the operation or if he never submits the form, the images stayed in the temp folder itself. To address this we brought in a mechanism to delete the folder on certain scenario's so that they do not remain in the system for ever. 
A combination of both led to the inline images missing issue. 

Who will face data loss?

Assume a user is adding an image always through the image upload function or always through the copy - paste mechanism, they will not have any issue or data loss.

If a user uses a mix of these operation's then images that he added using the copy-paste mechanism  would have been deleted while the one's added using the upload option would remain intact. So not all images would have been deleted from the temp folder, but only those of user's who did a mix of image upload operations.

The fix

We have rectified the problem of the inline images added through the copy - paste method not getting moved to the actual directory and have released it in 11144 and 11201. 

For Customer's who have regular backup, we can retrieve some of the images from the backup and restore them in the latest build. Customer's can get in touch with support.

For data that got stored in the temp directory itself due to this issue, we are working on a migration patch to move them to the correct directory. Since this involves a lot of work, it will take some time to get this released. Till then, if customers move to the latest (11144 or 11201), they should have no issues.    

Another issue related to inline images where the person who uploaded the images is able to see them but the rest of the people cannot will also be addressed along with this issue fix release. 

Data loss is a critical issue and we completely understand the impact of such issue. We always ensure that any changes to code does not lead to any data loss scenario. This somehow missed our checks.  We will analyze and ensure we do not make such errors in future. 

Thanks
Shanmugam PL
Development Manager - SDP