Avatar

Community Advisor

Hey Raj,

 

With some JS you can run checks if servers are running:

20200121-172548-screenshot-31.jpg

Init code:

instance.vars.i = 0;

 

Advanced Javascript code (containing 2 transitions: "continue" and "end":

var array = [
  'https://www.google.com/',
  'https://blog.floriancourgey.com',
  'https://yahoo.com', // returns an HTTP 302 code
];

if(instance.vars.i >= array.length){
  task.postEvent(task.transitionByName('end'));
  return;
}

instance.vars.website = array[instance.vars.i];
instance.vars.i++;
task.postEvent(task.transitionByName('continue'));

 

Download config:

20200121-172829-screenshot-32.jpg

 

 Note: in the Adavanced parameters, you may allow 302 HTTP codes not to trigger an error.

 

 

The above results in the following log:

Starting workflow (operator 'Florian Courgey ()')
httpTransfer Starting transfer of 'https://www.google.com/' to 'www_20200121162521a.google.com.html'
httpTransfer Starting transfer of 'https://blog.floriancourgey.com/' to 'blog_20200121162522a.floriancourgey.com.html'
httpTransfer Starting transfer of 'https://yahoo.com/' to 'yahoo_20200121162522a.com.html'
Workflow finished

 

Best regards

Florian