Open jwulf opened 9 years ago
And here is the adapterDebugMessage function code:
adapterDebugMessage = function (msg, callback) {
debug(msg);
if (callback) callback();
};
It seems quite unreliable, running it again gives me:
(This time Swarms 1 and 3 went missing)
WebTestAdapter /startParallelTest +10m
ParallelTestSwarm Starting Parallel Test Swarm 1 +6ms
ParallelTestSwarm Swarm 1 payload is 9597e1a0-1d56-11e5-959b-03f820ecbeb2 +0ms
ParallelTestSwarm Starting Parallel Test Swarm 2 +10ms
ParallelTestSwarm Swarm 2 payload is 95996840-1d56-11e5-959b-03f820ecbeb2 +0ms
ParallelTestSwarm Starting Parallel Test Swarm 3 +18ms
ParallelTestSwarm Swarm 3 payload is 959c2760-1d56-11e5-959b-03f820ecbeb2 +0ms
ParallelTestSwarm Starting Parallel Test Swarm 4 +8ms
ParallelTestSwarm Swarm 4 payload is 959d5fe0-1d56-11e5-959b-03f820ecbeb2 +0ms
ParallelTestSwarm Swarm 2 entered MindBodyAdapter +10m
MindBodyAdapter Swarm 2 payload is: 95996840-1d56-11e5-959b-03f820ecbeb2 +1ms
ParallelTestSwarm Swarm 4 entered MindBodyAdapter +14ms
MindBodyAdapter Swarm 4 payload is: 959d5fe0-1d56-11e5-959b-03f820ecbeb2 +1ms
ParallelTestSwarm Swarm 2 entered ParseAdapter +10m
ParseAdapter Swarm 2 payload is: 95996840-1d56-11e5-959b-03f820ecbeb2 +1ms
ParallelTestSwarm Swarm 4 entered ParseAdapter +17ms
ParseAdapter Swarm 4 payload is: 959d5fe0-1d56-11e5-959b-03f820ecbeb2 +0ms
ParallelTestSwarm Swarm 2 entered CalendarAdapter +10m
CalendarAdapter Swarm 2 payload is: 95996840-1d56-11e5-959b-03f820ecbeb2 +0ms
Clearing redis information about dead node _AtmaMindBodyAPIAdapter(d67d3c89-5b7e-4cca-8f4a-0fe1ae3116a8)
Clearing redis information about dead node _AtmaMindBodyAPIAdapter(d67d3c89-5b7e-4cca-8f4a-0fe1ae3116a8)
ParallelTestSwarm Swarm 4 entered CalendarAdapter +20ms
CalendarAdapter Swarm 4 payload is: 959d5fe0-1d56-11e5-959b-03f820ecbeb2 +0ms
ParallelTestSwarm Swarm 2 entered ConductorAdapter +10m
Conductor Swarm 2 payload is: 95996840-1d56-11e5-959b-03f820ecbeb2 +1ms
ParallelTestSwarm Swarm 4 entered ConductorAdapter +3ms
Conductor Swarm 4 payload is: 959d5fe0-1d56-11e5-959b-03f820ecbeb2 +0ms
I fail to reproduce this bug. Take a look in SwarmESB, i have added a special adapter demoBroadcast.js and ParallelSwarmsTest.js swarm. Everything works as expected... Can you confirm or infirm it on your system? May be you have an old version of adapter AtmaMindBodyAPIAdapter running and swallows swarm messages because it fails? Close or node processes, run again, it still reproducible? Could you make my example going wrong?
I'm launching parallel swarms, and they don't behave as expected. Some go missing, and some stop after a while.
So I made a minimal test case of 4 parallel swarms that just visit different adapters and invoke a message in the adapter.
What happened to Swarm 2??
Here's the output:
Here's the code to spawn the parallel swarms in the Adapter:
Here is the Swarm code: