[Engine-devel] Java 7: Fix namespaces use in OVF writer

Hello, I recently submitted a change to fix the way we manage namespaces in the OVF writer: http://gerrit.ovirt.org/4540 The problem is that it doesn't work with the StAX reference implementation included with Java 7. With the patched OVF writer I generated the attached OVF file. I would appreciate if someone can take a quick look at it and tell me if it is correct. I would also appreciate if you can send me known good OVF files generated by the engine, to compare them with the ones produced with the patched OVF writer. Thanks in advance, Juan Hernandez -- Dirección Comercial: C/Jose Bardasano Baos, 9, Edif. Gorbea 3, planta 3ºD, 28016 Madrid, Spain Inscrita en el Reg. Mercantil de Madrid – C.I.F. B82657941 - Red Hat S.L.

This is a multi-part message in MIME format. --------------030402010905010207040707 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Juan, I wouldn't consider it an exhaustive test by any means, but I have a simple .ovf file in the Image Uploader GIT repo that I do unit testing with. You can review the OVF XML file therein if you like. FWIW, I would recommend you simply export an image from an "unpatched" oVirt engine and just compare the resulting XML to a patched version. 1: git clone gerrit.ovirt.org:ovirt-image-uploader 2: cd ovirt-image-uploader/src 3: tar -xvf sample.ovf <- This is a portable/exported "image" - Note: For some reason there seems to be a consensus to append/apply the .ovf extension to .tgz file image files. It is somewhat confusing, IMHO. 4: Look at master/vms/5272b689-cd9f-4532-9b5d-2413eb7b9402/5272b689-cd9f-4532-9b5d-2413eb7b9402.ovf for an OVF XML file. Cheers, Keith On 05/18/2012 06:43 AM, Juan Hernandez wrote:
Hello,
I recently submitted a change to fix the way we manage namespaces in the OVF writer:
The problem is that it doesn't work with the StAX reference implementation included with Java 7.
With the patched OVF writer I generated the attached OVF file. I would appreciate if someone can take a quick look at it and tell me if it is correct. I would also appreciate if you can send me known good OVF files generated by the engine, to compare them with the ones produced with the patched OVF writer.
Thanks in advance, Juan Hernandez
_______________________________________________ Engine-devel mailing list Engine-devel@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-devel
--------------030402010905010207040707 Content-Type: text/html; charset=windows-1252 Content-Transfer-Encoding: 8bit <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <meta content="text/html; charset=windows-1252" http-equiv="Content-Type"> </head> <body bgcolor="#ffffff" text="#000000"> Juan,<br> <br> I wouldn't consider it an exhaustive test by any means, but I have a simple .ovf file in the Image Uploader GIT repo that I do unit testing with. You can review the OVF XML file therein if you like.<br> <br> FWIW, I would recommend you simply export an image from an "unpatched" oVirt engine and just compare the resulting XML to a patched version.<br> <br> 1: git clone gerrit.ovirt.org:ovirt-image-uploader<br> 2: cd ovirt-image-uploader/src<br> 3: tar -xvf sample.ovf <- This is a portable/exported "image"<br> - Note: For some reason there seems to be a consensus to append/apply the .ovf extension to .tgz file image files. It is somewhat confusing, IMHO.<br> 4: Look at master/vms/5272b689-cd9f-4532-9b5d-2413eb7b9402/5272b689-cd9f-4532-9b5d-2413eb7b9402.ovf for an OVF XML file.<br> <br> Cheers,<br> Keith<br> <br> <br> On 05/18/2012 06:43 AM, Juan Hernandez wrote: <blockquote cite="mid:4FB627CF.8050805@redhat.com" type="cite">Hello, <br> <br> I recently submitted a change to fix the way we manage namespaces in the OVF writer: <br> <br> <a class="moz-txt-link-freetext" href="http://gerrit.ovirt.org/4540">http://gerrit.ovirt.org/4540</a> <br> <br> The problem is that it doesn't work with the StAX reference implementation included with Java 7. <br> <br> With the patched OVF writer I generated the attached OVF file. I would appreciate if someone can take a quick look at it and tell me if it is correct. I would also appreciate if you can send me known good OVF files generated by the engine, to compare them with the ones produced with the patched OVF writer. <br> <br> Thanks in advance, <br> Juan Hernandez <br> <pre wrap=""> <fieldset class="mimeAttachmentHeader"></fieldset> _______________________________________________ Engine-devel mailing list <a class="moz-txt-link-abbreviated" href="mailto:Engine-devel@ovirt.org">Engine-devel@ovirt.org</a> <a class="moz-txt-link-freetext" href="http://lists.ovirt.org/mailman/listinfo/engine-devel">http://lists.ovirt.org/mailman/listinfo/engine-devel</a> </pre> </blockquote> <br> </body> </html> --------------030402010905010207040707--

On 05/18/2012 03:58 PM, Keith Robertson wrote:
Juan,
I wouldn't consider it an exhaustive test by any means, but I have a simple .ovf file in the Image Uploader GIT repo that I do unit testing with. You can review the OVF XML file therein if you like.
FWIW, I would recommend you simply export an image from an "unpatched" oVirt engine and just compare the resulting XML to a patched version.
1: git clone gerrit.ovirt.org:ovirt-image-uploader 2: cd ovirt-image-uploader/src 3: tar -xvf sample.ovf<- This is a portable/exported "image" - Note: For some reason there seems to be a consensus to append/apply the .ovf extension to .tgz file image files. It is somewhat confusing, IMHO. 4: Look at master/vms/5272b689-cd9f-4532-9b5d-2413eb7b9402/5272b689-cd9f-4532-9b5d-2413eb7b9402.ovf for an OVF XML file.
Keith, that helped a lot, thanks! After comparing with your example I updated the patch and now the result almost identical to the example. The resulting XML that I get now is attached. I appreciate if someone can take a look.
On 05/18/2012 06:43 AM, Juan Hernandez wrote:
Hello,
I recently submitted a change to fix the way we manage namespaces in the OVF writer:
The problem is that it doesn't work with the StAX reference implementation included with Java 7.
With the patched OVF writer I generated the attached OVF file. I would appreciate if someone can take a quick look at it and tell me if it is correct. I would also appreciate if you can send me known good OVF files generated by the engine, to compare them with the ones produced with the patched OVF writer.
Thanks in advance, Juan Hernandez
-- Dirección Comercial: C/Jose Bardasano Baos, 9, Edif. Gorbea 3, planta 3ºD, 28016 Madrid, Spain Inscrita en el Reg. Mercantil de Madrid – C.I.F. B82657941 - Red Hat S.L.
participants (2)
-
Juan Hernandez
-
Keith Robertson