forked from Qortal/qortal
minAccountLevelForBlockSubmissions moved to blockchain.json
This commit is contained in:
parent
d4ff7bbe4d
commit
a35e309a2f
@ -142,6 +142,7 @@ public class BlockChain {
|
|||||||
private List<BlockTimingByHeight> blockTimingsByHeight;
|
private List<BlockTimingByHeight> blockTimingsByHeight;
|
||||||
|
|
||||||
private int minAccountLevelToMint = 1;
|
private int minAccountLevelToMint = 1;
|
||||||
|
private int minAccountLevelForBlockSubmissions;
|
||||||
private int minAccountLevelToRewardShare;
|
private int minAccountLevelToRewardShare;
|
||||||
private int maxRewardSharesPerMintingAccount;
|
private int maxRewardSharesPerMintingAccount;
|
||||||
private int founderEffectiveMintingLevel;
|
private int founderEffectiveMintingLevel;
|
||||||
@ -344,6 +345,10 @@ public class BlockChain {
|
|||||||
return this.minAccountLevelToMint;
|
return this.minAccountLevelToMint;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public int getMinAccountLevelForBlockSubmissions() {
|
||||||
|
return this.minAccountLevelForBlockSubmissions;
|
||||||
|
}
|
||||||
|
|
||||||
public int getMinAccountLevelToRewardShare() {
|
public int getMinAccountLevelToRewardShare() {
|
||||||
return this.minAccountLevelToRewardShare;
|
return this.minAccountLevelToRewardShare;
|
||||||
}
|
}
|
||||||
|
@ -47,11 +47,6 @@ public class BlockMinter extends Thread {
|
|||||||
// Recovery
|
// Recovery
|
||||||
public static final long INVALID_BLOCK_RECOVERY_TIMEOUT = 10 * 60 * 1000L; // ms
|
public static final long INVALID_BLOCK_RECOVERY_TIMEOUT = 10 * 60 * 1000L; // ms
|
||||||
|
|
||||||
// Min effective account level to submit blocks
|
|
||||||
// This is an unvalidated version of Blockchain.minAccountLevelToMint
|
|
||||||
// and exists only to reduce block candidates by default.
|
|
||||||
private static int MIN_EFFECTIVE_LEVEL_FOR_BLOCK_SUBMISSION = 6;
|
|
||||||
|
|
||||||
// Constructors
|
// Constructors
|
||||||
|
|
||||||
public BlockMinter() {
|
public BlockMinter() {
|
||||||
@ -136,9 +131,11 @@ public class BlockMinter extends Thread {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Optional (non-validated) prevention of block submissions below a defined level
|
// Optional (non-validated) prevention of block submissions below a defined level.
|
||||||
|
// This is an unvalidated version of Blockchain.minAccountLevelToMint
|
||||||
|
// and exists only to reduce block candidates by default.
|
||||||
int level = mintingAccount.getEffectiveMintingLevel();
|
int level = mintingAccount.getEffectiveMintingLevel();
|
||||||
if (level < MIN_EFFECTIVE_LEVEL_FOR_BLOCK_SUBMISSION) {
|
if (level < BlockChain.getInstance().getMinAccountLevelForBlockSubmissions()) {
|
||||||
madi.remove();
|
madi.remove();
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
@ -8,6 +8,7 @@
|
|||||||
"requireGroupForApproval": false,
|
"requireGroupForApproval": false,
|
||||||
"defaultGroupId": 0,
|
"defaultGroupId": 0,
|
||||||
"oneNamePerAccount": true,
|
"oneNamePerAccount": true,
|
||||||
|
"minAccountLevelForBlockSubmissions": 6,
|
||||||
"minAccountLevelToRewardShare": 5,
|
"minAccountLevelToRewardShare": 5,
|
||||||
"maxRewardSharesPerMintingAccount": 6,
|
"maxRewardSharesPerMintingAccount": 6,
|
||||||
"founderEffectiveMintingLevel": 10,
|
"founderEffectiveMintingLevel": 10,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user