Issue Details (XML | Word | Printable)

Key: JRA-5319
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Critical Critical
Assignee: Unassigned
Reporter: Jarno Peltoniemi
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
JIRA

XML import fails due to invalid characters

Created: 23/Nov/04 12:29 AM   Updated: 04/Dec/07 10:12 PM
Component/s: Import / Export
Affects Version/s: 3.0.1
Fix Version/s: 3.1

Time Tracking:
Not Specified

Issue Links:
Reference
 

Participants: Anton Mazkovoi [Atlassian], Gunnar Wagenknecht, Jarno Peltoniemi and Jeff Turner [Atlassian]
Since last comment: 44 weeks, 4 days ago
Resolution Date: 06/Dec/04 05:25 PM
Labels:


 Description  « Hide
Our JIRA users have somehow entered 0x1c-characters (file separator) to description-field on a couple of issues. When the database is exported to XML and imported back, the import fails due to the 0x1c character in a CDATA block. It can't even be fixed by changing the description using JIRA, as the invalid character is also in the change history. We had to remove these by hand from the database.

Marked this issue critical as it also breaks upgrading from 3.0.1 to 3.0.3 which relies on export/import.



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
Jeff Turner [Atlassian] added a comment - 23/Nov/04 09:58 PM
Hi,

We've been working on a fix for this, which is present but disabled in 3.0.3. If you edit WEB-INF/classes/jira-application.properties and set the jira.exportimport.cleanxml flag to true, then any invalid characters in the XML file will be ignored, and the import should succeed.

We've made the same XML cleaning utility available as a standalone tool, downloadable from:

http://repository.atlassian.com/atlassian-xml-cleaner/jars/

You can clean your data export by running 'java -jar atlassian-xml-cleaner-0.1.jar yourdata.zip|yourdata.xml > yourdata-clean.xml' and then importing yourdata-clean.xml

Let us know if you have any problems with this.

Cheers,
Jeff


Gunnar Wagenknecht added a comment - 03/Dec/07 12:13 AM
FYI, I have the property enabled and I also used the XML cleaner. However, I still have XML which is not importable into JIRA. The problematic character in my case is 0x11. If I manually edit the XML and replace all these chars it works.

Anton Mazkovoi [Atlassian] added a comment - 04/Dec/07 02:36 AM
Gunnar,

Which version of JIRa are you using? Would you be able to create a support request in our support system:
http://support.atlassian.com
and attach a copy of the XML data that causes the issue?

This way we can reproduce and open a bug if necessary.

Cheers,
Anton


Gunnar Wagenknecht added a comment - 04/Dec/07 03:00 AM
I opened JSP-17888 with the data.

Anton Mazkovoi [Atlassian] added a comment - 04/Dec/07 10:12 PM
Thanks!