0.1.1 • Published 7 years ago

betolerant v0.1.1

Weekly downloads
3
License
MIT
Repository
github
Last release
7 years ago

betolerant

NPM Version Build Status

let betolerant = require("betolerant");

betolerant(3 /*tries*/, 10000 /*timeout*/, function* {
    yield asyncOp();
    yield sleep(1000);
    result = yield checkAsyncOpResult();
    if (!result.failed) {
        throw Error("op failed");
    }
}).then(function(){
    // done;
}).catch(function(){
    // all three attemps timed out or failed
});
0.1.1

7 years ago

0.1.0

7 years ago

0.0.2

8 years ago

0.0.1

8 years ago