aboutsummaryrefslogtreecommitdiffstats
path: root/lib/cloudify.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/cloudify.js')
-rw-r--r--lib/cloudify.js14
1 files changed, 3 insertions, 11 deletions
diff --git a/lib/cloudify.js b/lib/cloudify.js
index 2db460a..053bdb8 100644
--- a/lib/cloudify.js
+++ b/lib/cloudify.js
@@ -67,14 +67,6 @@ ExeQueue.prototype.nextExecution = function(deployment_id) {
const exeQueue = new ExeQueue();
exports.exeQueue = exeQueue;
-// Delay function--returns a promise that's resolved after 'dtime'
-// milliseconds.`
-var delay = function(dtime) {
- return new Promise(function(resolve, reject) {
- setTimeout(resolve, dtime);
- });
-};
-
// Get current status of a workflow execution
const getExecutionStatus = function(req, execution_id) {
var reqOptions = {
@@ -407,8 +399,8 @@ exports.getNodeInstances = function (mainReq, on_next_node_instances, offset) {
const runQueuedExecution = function(mainReq, deployment_id, workflow_id, parameters, waitedCount) {
mainReq = mainReq || {};
var execution_id;
- var exe_deployment_str = " deployment_id " + deployment_id + " to " + workflow_id
- + " with params(" + JSON.stringify(parameters || {}) + ")";
+ const exe_deployment_str = " deployment_id " + deployment_id + " to " + workflow_id
+ + " with params(" + JSON.stringify(parameters || {}) + ")";
startWorkflowExecution(mainReq, deployment_id, workflow_id, parameters)
.then(function(result) {
logger.info(mainReq.dcaeReqId, "result of start the execution for" + exe_deployment_str + ": " + JSON.stringify(result));
@@ -461,7 +453,7 @@ const runQueuedExecution = function(mainReq, deployment_id, workflow_id, paramet
exports.executeOperation = function (mainReq, deployment_id, operation, operation_kwargs, node_instance_ids) {
const workflow_id = "execute_operation";
- var parameters = {
+ const parameters = {
'operation': operation,
'operation_kwargs': operation_kwargs,
'node_instance_ids': node_instance_ids,