throw new RuntimeException("Could not find metric by name["+name+"] ");
}
if ( !(iMetric instanceof IShellMetric)) {
throw new RuntimeException("Metric["+name+"] is not IShellMetric, can not call by RPC");
}
IShellMetric iShellMetric = (IShellMetric)iMetric;
//call updateMetricFromRPC with params
Object paramsObj = shellMsg.getMetricParams();
try {
iShellMetric.updateMetricFromRPC(paramsObj);
} catch (RuntimeException re) {
throw re;
} catch (Exception e) {
throw new RuntimeException(e);
}