use of org.irods.jargon.core.rule.IRODSRuleExecResult in project metalnx-web by irods-contrib.
the class RuleServiceImpl method executeRule.
@Override
public Map<String, IRODSRuleExecResultOutputParameter> executeRule(String rule) throws DataGridRuleException, DataGridConnectionRefusedException {
if (rule == null || rule.isEmpty())
return null;
Map<String, IRODSRuleExecResultOutputParameter> ruleResultMap;
try {
IRODSRuleExecResult result = is.getRuleProcessingAO().executeRule(rule);
ruleResultMap = result.getOutputParameterResults();
} catch (JargonException e) {
String error = String.format("Could not execute rule %s: %s", rule, e.getMessage());
logger.error(error);
throw new DataGridRuleException(error);
}
return ruleResultMap;
}
Aggregations