try {
// TODO(sateesh): Change the type of peakBandwidth & burstRate in
// PolicyMap to long.
if (averageBandwidth > 0) {
s_logger.debug("Adding policy map " + policyName);
netconfClient.addPolicyMap(policyName, averageBandwidth, (int) peakBandwidth, (int) burstSize);
}
} catch (CloudRuntimeException e) {
msg = "Failed to add policy map of " + policyName + " with parameters " + "committed rate = "
+ averageBandwidth + "peak bandwidth = " + peakBandwidth + "burst size = " + burstSize
+ ". Exception: " + e.toString();