Return-Path: X-Original-To: apmail-incubator-cloudstack-dev-archive@minotaur.apache.org Delivered-To: apmail-incubator-cloudstack-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 93883D414 for ; Tue, 5 Feb 2013 12:57:14 +0000 (UTC) Received: (qmail 52611 invoked by uid 500); 5 Feb 2013 12:57:13 -0000 Delivered-To: apmail-incubator-cloudstack-dev-archive@incubator.apache.org Received: (qmail 52492 invoked by uid 500); 5 Feb 2013 12:57:13 -0000 Mailing-List: contact cloudstack-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: cloudstack-dev@incubator.apache.org Delivered-To: mailing list cloudstack-dev@incubator.apache.org Received: (qmail 52454 invoked by uid 99); 5 Feb 2013 12:57:12 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 05 Feb 2013 12:57:12 +0000 Date: Tue, 5 Feb 2013 12:57:12 +0000 (UTC) From: "Wido den Hollander (JIRA)" To: cloudstack-dev@incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (CLOUDSTACK-1158) Wrap qemu-img in objects instead of using simpleBashScript MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 Wido den Hollander created CLOUDSTACK-1158: ---------------------------------------------- Summary: Wrap qemu-img in objects instead of using simpleBashScript Key: CLOUDSTACK-1158 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-1158 Project: CloudStack Issue Type: Improvement Security Level: Public (Anyone can view this level - this is the default.) Components: KVM Affects Versions: 4.0.0 Reporter: Wido den Hollander Fix For: 4.2.0 Currently when we are doing something with qemu-img in the KVM Agent we do things like this: .. String result = executeBashScript("qemu-img --help|grep convert"); .. Script.runSimpleBashScript("qemu-img convert" .. This is not reliable and could be fixed by wrapping qemu-img like this: QemuImg.convert(String sourceFormat, String source, String destFormat, string dest); This could then handle all the stuff like checking the output and more importantly also checking the exit status of Qemu to see if everything works. It could throw exceptions where needed so it makes life easier when doing such operations in the KVM Agent. Hopefully we can then also get rid of all kinds of bash scripts being called by the KVM Agent. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira