@icarus_31 try using async.waterfall(). I'd expect @luchillo17 's approach to call all the then() functions at the same time.
See: http://spion.github.io/promise-nuggets/12-doing-things-in-series.html
Otherwise you can implement something like this:
var datafunctions= [serviceA.getData, serviceB.getData, serviceC.getData];
function getNext() {
var func = datafunctions.pop();
func().then(function () {
if (datafunctions.length > 0) getNext();
});
}
getNext();
You're probably better off with waterfall as this ignores errors.
If you can do the services parallel you could try Promise.all(datafunctions).then(function () { console.log("all done"); });