Merge pull request #65 from M5M400/TX-priority

adding config setting for TX priority
This commit is contained in:
Snipa22 2017-05-04 07:48:02 -07:00 committed by GitHub
commit 32fb924fab
3 changed files with 15 additions and 1 deletions

View file

@ -230,8 +230,9 @@ INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('general', 'emailSig', 'NodeJS-Pool Administration Team', 'string', 'Signature line for the emails.');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'timer', '120', 'int', 'Number of minutes between main payment daemon cycles');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'timerRetry', '25', 'int', 'Number of minutes between payment daemon retrying due to not enough funds');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'priority', '0', 'int', 'Payout priority setting. 0 = use default (4x fee); 1 = low prio (1x fee)');
INSERT INTO pool.users (username, pass, email, admin, payout_threshold) VALUES ('Administrator', null, 'Password123', 1, 0);
INSERT INTO pool.port_config (poolPort, difficulty, portDesc, portType, hidden, `ssl`) VALUES (3333, 1000, 'Low-End Hardware (Up to 30-40 h/s)', 'pplns', 0, 0);
INSERT INTO pool.port_config (poolPort, difficulty, portDesc, portType, hidden, `ssl`) VALUES (5555, 5000, 'Medium-Range Hardware (Up to 160 h/s)', 'pplns', 0, 0);
INSERT INTO pool.port_config (poolPort, difficulty, portDesc, portType, hidden, `ssl`) VALUES (7777, 10000, 'High-End Hardware (Anything else!)', 'pplns', 0, 0);
INSERT INTO pool.port_config (poolPort, difficulty, portDesc, portType, hidden, `ssl`) VALUES (9000, 20000, 'Claymore SSL', 'pplns', 0, 1);
INSERT INTO pool.port_config (poolPort, difficulty, portDesc, portType, hidden, `ssl`) VALUES (9000, 20000, 'Claymore SSL', 'pplns', 0, 1);

View file

@ -107,6 +107,7 @@ let shapeshiftQueue = async.queue(function (task, callback) {
address: shapeshiftTxnData.sAddress
}
],
priority: global.config.payout.priority,
mixin: global.config.payout.mixIn,
payment_id: shapeshiftTxnData.deposit
};
@ -257,6 +258,7 @@ let xmrToQueue = async.queue(function (task, callback) {
address: orderStatus.xmr_receiving_address
}
],
priority: global.config.payout.priority,
mixin: global.config.payout.mixIn,
payment_id: orderStatus.xmr_required_payment_id
};
@ -502,6 +504,7 @@ function Payee(amount, address, paymentID, bitcoin) {
address: this.address
}
],
priority: global.config.payout.priority,
mixin: global.config.payout.mixIn,
payment_id: this.paymentID
};
@ -533,6 +536,7 @@ function Payee(amount, address, paymentID, bitcoin) {
address: this.address
}
],
priority: global.config.payout.priority,
mixin: global.config.payout.mixIn
};
let identifier = this.id;
@ -640,6 +644,7 @@ function makePayments() {
while (paymentDestinations.length > 0) {
let paymentDetails = {
destinations: paymentDestinations.splice(0, global.config.payout.maxPaymentTxns),
priority: global.config.payout.priority,
mixin: global.config.payout.mixIn
};
console.log("Paying out: " + paymentDetails.destinations.length + " people");

View file

@ -550,5 +550,13 @@
"item_value": "25",
"item_type": "int",
"Item_desc": "Number of minutes between payment daemon retrying due to not enough funds"
},
{
"id": 75,
"module": "payout",
"item": "priority",
"item_value": "0",
"item_type": "int",
"Item_desc": "Payout priority setting. 0 = use default (4x fee); 1 = low prio (1x fee)"
}
]