MCPcopy
hub / github.com/pstadler/flightplan / execute

Function execute

lib/flight/remote.js:36–53  ·  view source on GitHub ↗
(transport, fn)

Source from the content-addressed store, hash-verified

34}
35
36function execute(transport, fn) {
37 var future = new Future();
38
39 new Fiber(function() {
40 var t = process.hrtime();
41
42 logger.info('Executing remote task on ' + transport.runtime.host);
43
44 fn(transport);
45
46 logger.info('Remote task on ' + transport.runtime.host +
47 ' finished after ' + prettyTime(process.hrtime(t)));
48
49 return future.return();
50 }).run();
51
52 return future;
53}
54
55exports.run = function(fn, context) {
56 if(_connections.length === 0) {

Callers 1

remote.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected