Fixed global hashrate problem
This commit is contained in:
parent
2b553d08b7
commit
314dacf98a
@ -20,7 +20,7 @@
|
||||
"enabled": true,
|
||||
"siteTitle": "Cryppit",
|
||||
"port": 80,
|
||||
"statUpdateInterval": 3,
|
||||
"statUpdateInterval": 5,
|
||||
"hashrateWindow": 600
|
||||
},
|
||||
"proxy": {
|
||||
|
||||
@ -139,10 +139,10 @@ module.exports = function(logger, portalConfig, poolConfigs){
|
||||
var shareMultiplier = algoMultipliers[coinStats.algorithm];
|
||||
var hashratePre = shareMultiplier * coinStats.shares / portalConfig.website.hashrateWindow;
|
||||
coinStats.hashrate = hashratePre / 1e3 | 0;
|
||||
delete coinStats.hashrates;
|
||||
delete coinStats.shares;
|
||||
portalStats.global.hashrate += coinStats.hashrate;
|
||||
portalStats.global.workers += Object.keys(coinStats.workers).length;
|
||||
delete coinStats.hashrates;
|
||||
delete coinStats.shares;
|
||||
});
|
||||
|
||||
_this.stats = portalStats;
|
||||
|
||||
@ -55,7 +55,8 @@ module.exports = function(logger){
|
||||
portalConfig: portalConfig
|
||||
});
|
||||
}
|
||||
logger.debug(logSystem, 'Stats', 'Website updated to latest stats');
|
||||
|
||||
//logger.debug(logSystem, 'Stats', 'Website updated to latest stats');
|
||||
};
|
||||
|
||||
|
||||
|
||||
@ -7,6 +7,28 @@
|
||||
"txRefreshInterval": 20000,
|
||||
"connectionTimeout": 600,
|
||||
|
||||
"shareProcessing": {
|
||||
"internal": {
|
||||
"enabled": true,
|
||||
"validateWorkerAddress": true,
|
||||
"paymentInterval": 10,
|
||||
"minimumPayment": 100.001,
|
||||
"minimumReserve": 10,
|
||||
"feePercent": 0.02,
|
||||
"feeReceiveAddress": "GRAiuGCWLrL8Psdr6pkhLpxrQGHdYfrSEz",
|
||||
"feeWithdrawalThreshold": 5,
|
||||
"daemon": {
|
||||
"host": "localhost",
|
||||
"port": 19632,
|
||||
"user": "testuser",
|
||||
"password": "testpass"
|
||||
},
|
||||
"redis": {
|
||||
"host": "localhost",
|
||||
"port": 6379
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
"ports": {
|
||||
"3537": {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user