Skip to content

Commit 39f3fb1

Browse files
author
Nicolás Tallar
authored
Merge branch 'develop' into tweak/tweak-fast-sync-config-params
2 parents e7c8604 + 51be0f4 commit 39f3fb1

27 files changed

+241
-1540
lines changed

README.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,12 @@ The latest release can be downloaded from [here](https://github.com/input-output
1717

1818
### Command line version
1919

20-
Depending on network you want to join you can use appropriate launcher, all can be found in `bin` directory:
21-
- `mantis-etc` - for joining Ethereum Classic network
22-
- `mantis-eth` - for joining Ethereum
20+
You can use generic launcher with appropriate parameter to connect with pre-configured network, it can be found in `bin` directory.
21+
22+
Example:
23+
- `./bin/mantis-launcher etc` - for joining Ethereum Classic network
24+
25+
Possible networks: `etc`, `eth`, `mordor`, `testnet-internal`
2326

2427
### Building the client
2528

src/main/resources/application.conf

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -242,6 +242,7 @@ mantis {
242242
# If false then that 20% gets burned
243243
# Doesn't have any effect is ecip1098 is not yet activated
244244
treasury-opt-out = false
245+
245246
}
246247

247248
# This is the section dedicated to Ethash mining.
@@ -387,8 +388,6 @@ mantis {
387388
# Sets max number of blocks that can be stored in queue to import on fetcher side
388389
# Warning! This setting affects ability to go back in case of branch resolution so it should not be too low
389390
max-fetcher-queue-size = 1000
390-
391-
use-new-regular-sync = true
392391
}
393392

394393
pruning {

src/main/resources/chains/etc-chain.conf

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,4 +154,7 @@
154154
"enode://715171f50508aba88aecd1250af392a45a330af91d7b90701c436b618c86aaa1589c9184561907bebbb56439b8f8787bc01f49a7c77276c58c1b09822d75e8e8@52.231.165.108:30303", // bootnode-azure-koreasouth-001
155155
"enode://5d6d7cd20d6da4bb83a1d28cadb5d409b64edf314c0335df658c1a54e32c7c4a7ab7823d57c39b6a757556e68ff1df17c748b698544a55cb488b52479a92b60f@104.42.217.25:30303" // bootnode-azure-westus-001
156156
]
157+
158+
# List of hex encoded public keys of Checkpoint Authorities
159+
checkpoint-public-keys = []
157160
}

src/main/resources/chains/testnet-internal-chain.conf

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,4 +127,7 @@
127127

128128
# Set of initial nodes
129129
bootstrap-nodes = []
130+
131+
# List of hex encoded public keys of Checkpoint Authorities
132+
checkpoint-public-keys = []
130133
}

src/main/scala/io/iohk/ethereum/blockchain/sync/SyncController.scala

Lines changed: 3 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package io.iohk.ethereum.blockchain.sync
22

33
import akka.actor.{Actor, ActorLogging, ActorRef, PoisonPill, Props, Scheduler}
4-
import io.iohk.ethereum.blockchain.sync.regular.{OldRegularSync, RegularSync}
4+
import io.iohk.ethereum.blockchain.sync.regular.RegularSync
55
import io.iohk.ethereum.consensus.validators.Validators
66
import io.iohk.ethereum.db.storage.{AppStateStorage, FastSyncStateStorage}
77
import io.iohk.ethereum.domain.Blockchain
@@ -85,9 +85,7 @@ class SyncController(
8585
context become runningFastSync(fastSync)
8686
}
8787

88-
def startRegularSync(): Unit = if (syncConfig.useNewRegularSync) startNewRegularSync() else startOldRegularSync()
89-
90-
def startNewRegularSync(): Unit = {
88+
def startRegularSync(): Unit = {
9189
val peersClient = context.actorOf(PeersClient.props(etcPeerManager, peerEventBus, syncConfig, scheduler), "peers-client")
9290
val regularSync = context.actorOf(
9391
RegularSync.props(
@@ -100,29 +98,12 @@ class SyncController(
10098
ommersPool,
10199
pendingTransactionsManager,
102100
scheduler),
103-
"new-regular-sync"
101+
"regular-sync"
104102
)
105103
regularSync ! RegularSync.Start
106104
context become runningRegularSync(regularSync)
107105
}
108106

109-
def startOldRegularSync(): Unit = {
110-
val regularSync = context.actorOf(OldRegularSync.props(
111-
appStateStorage = appStateStorage,
112-
etcPeerManager = etcPeerManager,
113-
peerEventBus = peerEventBus,
114-
ommersPool = ommersPool,
115-
pendingTransactionsManager = pendingTransactionsManager,
116-
broadcaster = new BlockBroadcast(etcPeerManager, syncConfig),
117-
ledger = ledger,
118-
blockchain = blockchain,
119-
syncConfig = syncConfig,
120-
scheduler = scheduler
121-
), "old-regular-sync")
122-
123-
regularSync ! OldRegularSync.Start
124-
context become runningRegularSync(regularSync)
125-
}
126107
}
127108

128109
object SyncController {

0 commit comments

Comments
 (0)