* Copyright (C) 2017 AT&T Intellectual Property. All rights
* reserved.
* ================================================================================
+ * Modifications Copyright (C) 2018 IBM.
+ * ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
public class SaveNodeExecutor extends AbstractSvcLogicNodeExecutor {
private static final Logger LOG = LoggerFactory.getLogger(SaveNodeExecutor.class);
+ private static final String FAILURE= "failure";
@Override
public SvcLogicNode execute(SvcLogicServiceBase svc, SvcLogicNode node, SvcLogicContext ctx)
boolean force = "true".equalsIgnoreCase(forceStr);
boolean localOnly = "true".equalsIgnoreCase(localOnlyStr);
- Map<String, String> parmMap = new HashMap<String, String>();
+ Map<String, String> parmMap = new HashMap<>();
Set<Map.Entry<String, SvcLogicExpression>> parmSet = node.getParameterSet();
boolean hasParms = false;
}
}
- String outValue = "failure";
+ String outValue = FAILURE;
if (LOG.isDebugEnabled()) {
LOG.debug("save node encountered - looking for resource class " + plugin);
break;
case FAILURE:
default:
- outValue = "failure";
+ outValue = FAILURE;
}
} catch (SvcLogicException e) {
LOG.error("Caught exception from resource plugin", e);
- outValue = "failure";
+ outValue = FAILURE;
}
} else {
LOG.warn("Could not find SvcLogicResource object for plugin " + plugin);