mirror of
https://github.com/apache/cloudstack.git
synced 2025-11-03 04:12:31 +01:00
SWIFT: add error handling code
add swift plugin for XenServer 6.0
This commit is contained in:
parent
c66897e329
commit
331bd6c103
@ -3300,6 +3300,7 @@ public abstract class CitrixResourceBase implements ServerResource, HypervisorRe
|
||||
|
||||
protected String callHostPlugin(Connection conn, String plugin, String cmd, String... params) {
|
||||
Map<String, String> args = new HashMap<String, String>();
|
||||
String msg;
|
||||
try {
|
||||
for (int i = 0; i < params.length; i += 2) {
|
||||
args.put(params[i], params[i + 1]);
|
||||
@ -3315,11 +3316,13 @@ public abstract class CitrixResourceBase implements ServerResource, HypervisorRe
|
||||
}
|
||||
return result.replace("\n", "");
|
||||
} catch (XenAPIException e) {
|
||||
s_logger.warn("callHostPlugin failed for cmd: " + cmd + " with args " + getArgsString(args) + " due to " + e.toString());
|
||||
msg = "callHostPlugin failed for cmd: " + cmd + " with args " + getArgsString(args) + " due to " + e.toString();
|
||||
s_logger.warn(msg);
|
||||
} catch (XmlRpcException e) {
|
||||
s_logger.debug("callHostPlugin failed for cmd: " + cmd + " with args " + getArgsString(args) + " due to " + e.getMessage());
|
||||
msg = "callHostPlugin failed for cmd: " + cmd + " with args " + getArgsString(args) + " due to " + e.getMessage();
|
||||
s_logger.debug(msg);
|
||||
}
|
||||
return null;
|
||||
throw new CloudRuntimeException(msg);
|
||||
}
|
||||
|
||||
protected String getArgsString(Map<String, String> args) {
|
||||
|
||||
@ -43,3 +43,10 @@ vhd-util=..,0755,/opt/xensource/bin
|
||||
vmopspremium=..,0755,/etc/xapi.d/plugins
|
||||
create_privatetemplate_from_snapshot.sh=..,0755,/opt/xensource/bin
|
||||
upgrade_snapshot.sh=..,0755,/opt/xensource/bin
|
||||
cloud-clean-vlan.sh=..,0755,/opt/xensource/bin
|
||||
cloud-prepare-upgrade.sh=..,0755,/opt/xensource/bin
|
||||
getRouterStatus.sh=../../../../network/domr/,0755,/opt/xensource/bin
|
||||
bumpUpPriority.sh=../../../../network/domr/,0755,/opt/xensource/bin
|
||||
getDomRVersion.sh=../../../../network/domr/,0755,/opt/xensource/bin
|
||||
swift=..,0755,/opt/xensource/bin
|
||||
swiftxen=..,0755,/etc/xapi.d/plugins
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user