Skip to content

Commit

Permalink
Revert "Partition healing (#264) and "Periodical partition healing (#…
Browse files Browse the repository at this point in the history
…265)" (#270)

6c025bcc67bdeb1dd5b55269195a740f2e283fc5a and 02be536 are using a dev-dependency (async) from production code. This commit those two commits so master is in a stable state again.
  • Loading branch information
mennopruijssers committed May 17, 2016
1 parent 02be536 commit d74618b
Show file tree
Hide file tree
Showing 16 changed files with 14 additions and 1,104 deletions.
13 changes: 0 additions & 13 deletions config.js
Original file line number Diff line number Diff line change
Expand Up @@ -131,19 +131,6 @@ Config.prototype._seed = function _seed(seed) {
// Number of allowable inflight requests sent by RingpopClient.
seedOrDefault('inflightClientRequestsLimit', 100);

// Healer config
// Maximum number of heal failures in one period.
seedOrDefault('discoverProviderHealerMaxFailures', 10);
// The time of a period in ms.
seedOrDefault('discoverProviderHealerPeriod', 30000);
// The base probability of a node to run in a period: the average number
// of nodes in each period that will perform the heal algorithm in a period.
// E.g. if there are 100 nodes and the base probability is 3, there is a
// chance of 3/100 that a node will run.
seedOrDefault('discoverProviderHealerBaseProbability', 3);
// Enable the period healer.
seedOrDefault('discoverProviderHealerPeriodicEnabled', true);

function seedOrDefault(name, defaultVal, validator, reason) {
var seedVal = seed[name];
if (typeof seedVal === 'undefined') {
Expand Down
3 changes: 0 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,6 @@ var validateHostPort = require('./lib/util').validateHostPort;
var sendJoin = require('./lib/gossip/joiner.js').joinCluster;
var TracerStore = require('./lib/trace/store.js');
var middleware = require('./lib/middleware');
var DiscoverProviderHealer = require('./lib/partition_healing').DiscoverProviderHealer;

var HOST_PORT_PATTERN = /^(\d+.\d+.\d+.\d+):\d+$/;
var MEMBERSHIP_UPDATE_FLUSH_INTERVAL = 5000;
Expand Down Expand Up @@ -204,8 +203,6 @@ function RingPop(options) {

this.tchannelVersion = getTChannelVersion();
this.ringpopVersion = packageJSON.version;

this.healer = new DiscoverProviderHealer(this);
}

require('util').inherits(RingPop, EventEmitter);
Expand Down
5 changes: 0 additions & 5 deletions lib/on_ringpop_event.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ function createDestroyedHandler(ringpop) {
ringpop.lagSampler.stop();
ringpop.membership.stopDampScoreDecayer();
ringpop.damper.destroy();
ringpop.healer.stop();
};
}

Expand All @@ -38,10 +37,6 @@ function createReadyHandler(ringpop) {
if (ringpop.config.get('backpressureEnabled')) {
ringpop.lagSampler.start();
}

if (ringpop.config.get('discoverProviderHealerPeriodicEnabled')) {
ringpop.healer.start();
}
};
}

Expand Down
224 changes: 0 additions & 224 deletions lib/partition_healing/discover_provider_healer.js

This file was deleted.

Loading

0 comments on commit d74618b

Please sign in to comment.