[closed] Migrate Jira Comments/Attachments to RTC
Hi All,
CSV Exported from Jira - does not contain comments field. So, we need to use an alternate approach to get it.
Our Jira version is 3.13 - I checked on using Bugzilla as an intermediate , but looks tedious with 1 bug-file per jira-item.
Also, xml exported from Jira has comments in it. I am looking to convert this xml to a csv format with accurate data.
Please advise on the easiest approach to automate this.
Thanks.
The question has been closed for the following reason: "The question is answered, right answer was accepted" by valli Dec 30 '14, 4:57 a.m.
Accepted answer
the bugzilla import isn't that bad.. the jira export makes them, and then the importer reads them..
same approach as with csv.
same approach as with csv.
5 other answers
Hi Sam,
If I export Jira data in XML format, its a single XML file.There looks to be an additional conversion required for bugzilla-xml formation. And finally, the bugzilla XML to be used for RTC import.
Please advise on the Jira to bugzilla part.
Thanks.
Comments
Hi Sam,
I was trying to use curl to download each jira-issue into an xml using below curl command:
xml = %x[curl -u username:password http://jira.wiley.com:9090/sr/jira.issueviews:searchrequest-xml/BUG-#{i}/BUG-#{i}.xml]
I took this URL from Jira->Find issues by creating a search filter for all the required items (Around 89). Not sure how this can be accessed using BUG-#i, as i is a sequence from 1 to 1000 in below script [*from the ruby solution-link]:
# Extract JIRA issues. (Figure out how many issues to include.)
(1..1000).each do |i|
# Use curl with credentials to extract each JIRA issue's XML.
xml = %x[curl -u username:password http://jira.wiley.com:9090/sr/jira.issueviews:searchrequest-xml/BUG-#{i}/BUG-#{i}.xml]
# Save the XML to a file.
f=File.new("BUG-#{i}.xml","w")
f.write(xml)
f.close
end
Please advise on how this Jira individual issue-link is formed
URL that i get on xml view of the filtered Jira issues is:
http://jira.wiley.com:9090/sr/jira.issueviews:searchrequest-xml/11234/SearchRequest-11234.xml?tempMax=1000
Please advise on how to refer the individual items in this view into an xml
Comments
Thanks Sam. It worked with issues.XML URL using key-ids.
While downloading attachments, have you tried .jpg,.xls and so on? Only text files looks to work for me. Other files are not in a correct format type.
Please advise.
Thanks.
Comments
Hi Sam,
Used open-uri in binary mode and all file-types look to work.
I used bugzilla importer with limited fields mainly comments & attachments. Attachments works, but comments has html,ascii encoding issues and doesnt completely reflect the actual comment-text in JIRA.
For comments, did you perform html,ascii encoding and validations in the ruby script? Please advise on how best it can be rendered in RTC.
If comments contains tag-based text like <title>testing<testing>, RTC is not able to import it. The comment is rendered empty.
Thanks.