@xyo-network/xl1-cli 1.7.5 → 1.7.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +29 -6
- package/dist/cli-min.mjs +96 -96
- package/package.json +22 -18
- package/lib/node/commands/api/index.d.ts +0 -2
- package/lib/node/commands/api/index.d.ts.map +0 -1
- package/lib/node/commands/api/runApi.d.ts +0 -9
- package/lib/node/commands/api/runApi.d.ts.map +0 -1
- package/lib/node/commands/index.d.ts +0 -4
- package/lib/node/commands/index.d.ts.map +0 -1
- package/lib/node/commands/producer/createDeclaration.d.ts +0 -3
- package/lib/node/commands/producer/createDeclaration.d.ts.map +0 -1
- package/lib/node/commands/producer/index.d.ts +0 -3
- package/lib/node/commands/producer/index.d.ts.map +0 -1
- package/lib/node/commands/producer/runProducer.d.ts +0 -11
- package/lib/node/commands/producer/runProducer.d.ts.map +0 -1
- package/lib/node/commands/validator/index.d.ts +0 -2
- package/lib/node/commands/validator/index.d.ts.map +0 -1
- package/lib/node/commands/validator/runValidator.d.ts +0 -9
- package/lib/node/commands/validator/runValidator.d.ts.map +0 -1
- package/lib/node/images.d.ts +0 -2
- package/lib/node/images.d.ts.map +0 -1
- package/lib/node/index.d.ts +0 -4
- package/lib/node/index.d.ts.map +0 -1
- package/lib/node/index.mjs +0 -1610
- package/lib/node/index.mjs.map +0 -1
- package/lib/node/initConfig.d.ts +0 -3
- package/lib/node/initConfig.d.ts.map +0 -1
- package/lib/node/initEnv.d.ts +0 -2
- package/lib/node/initEnv.d.ts.map +0 -1
- package/lib/node/initLogger.d.ts +0 -4
- package/lib/node/initLogger.d.ts.map +0 -1
- package/lib/node/optionsFromZodSchema.d.ts +0 -4
- package/lib/node/optionsFromZodSchema.d.ts.map +0 -1
- package/lib/node/orchestration/ChainInitializableParams.d.ts +0 -9
- package/lib/node/orchestration/ChainInitializableParams.d.ts.map +0 -1
- package/lib/node/orchestration/actor/implementation/BalanceActor.d.ts +0 -17
- package/lib/node/orchestration/actor/implementation/BalanceActor.d.ts.map +0 -1
- package/lib/node/orchestration/actor/implementation/ChainHeadUpdateActor.d.ts +0 -17
- package/lib/node/orchestration/actor/implementation/ChainHeadUpdateActor.d.ts.map +0 -1
- package/lib/node/orchestration/actor/implementation/ProducerActor.d.ts +0 -26
- package/lib/node/orchestration/actor/implementation/ProducerActor.d.ts.map +0 -1
- package/lib/node/orchestration/actor/implementation/index.d.ts +0 -4
- package/lib/node/orchestration/actor/implementation/index.d.ts.map +0 -1
- package/lib/node/orchestration/actor/index.d.ts +0 -3
- package/lib/node/orchestration/actor/index.d.ts.map +0 -1
- package/lib/node/orchestration/actor/model/Actor.d.ts +0 -37
- package/lib/node/orchestration/actor/model/Actor.d.ts.map +0 -1
- package/lib/node/orchestration/actor/model/Orchestrator.d.ts +0 -27
- package/lib/node/orchestration/actor/model/Orchestrator.d.ts.map +0 -1
- package/lib/node/orchestration/actor/model/index.d.ts +0 -3
- package/lib/node/orchestration/actor/model/index.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/ChainFinalized/archivist.d.ts +0 -4
- package/lib/node/orchestration/archivists/ChainFinalized/archivist.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/ChainFinalized/index.d.ts +0 -2
- package/lib/node/orchestration/archivists/ChainFinalized/index.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/ChainFinalized/local.d.ts +0 -4
- package/lib/node/orchestration/archivists/ChainFinalized/local.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/ChainFinalized/remote.d.ts +0 -4
- package/lib/node/orchestration/archivists/ChainFinalized/remote.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/ChainSubmissions/archivist.d.ts +0 -4
- package/lib/node/orchestration/archivists/ChainSubmissions/archivist.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/ChainSubmissions/index.d.ts +0 -2
- package/lib/node/orchestration/archivists/ChainSubmissions/index.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/ChainSubmissions/remote.d.ts +0 -4
- package/lib/node/orchestration/archivists/ChainSubmissions/remote.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/PendingTransactions/archivist.d.ts +0 -4
- package/lib/node/orchestration/archivists/PendingTransactions/archivist.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/PendingTransactions/index.d.ts +0 -2
- package/lib/node/orchestration/archivists/PendingTransactions/index.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/PendingTransactions/local.d.ts +0 -4
- package/lib/node/orchestration/archivists/PendingTransactions/local.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/PendingTransactions/remote.d.ts +0 -4
- package/lib/node/orchestration/archivists/PendingTransactions/remote.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/RejectedTransactions/archivist.d.ts +0 -4
- package/lib/node/orchestration/archivists/RejectedTransactions/archivist.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/RejectedTransactions/index.d.ts +0 -2
- package/lib/node/orchestration/archivists/RejectedTransactions/index.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/RejectedTransactions/local.d.ts +0 -4
- package/lib/node/orchestration/archivists/RejectedTransactions/local.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/StakeIntentState/archivist.d.ts +0 -5
- package/lib/node/orchestration/archivists/StakeIntentState/archivist.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/StakeIntentState/index.d.ts +0 -2
- package/lib/node/orchestration/archivists/StakeIntentState/index.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/StakeIntentState/local.d.ts +0 -4
- package/lib/node/orchestration/archivists/StakeIntentState/local.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/index.d.ts +0 -6
- package/lib/node/orchestration/archivists/index.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/lib/index.d.ts +0 -2
- package/lib/node/orchestration/archivists/lib/index.d.ts.map +0 -1
- package/lib/node/orchestration/archivists/lib/localPersistentArchivist.d.ts +0 -12
- package/lib/node/orchestration/archivists/lib/localPersistentArchivist.d.ts.map +0 -1
- package/lib/node/orchestration/health/index.d.ts +0 -2
- package/lib/node/orchestration/health/index.d.ts.map +0 -1
- package/lib/node/orchestration/health/initHealthEndpoints.d.ts +0 -7
- package/lib/node/orchestration/health/initHealthEndpoints.d.ts.map +0 -1
- package/lib/node/orchestration/host/implementation/DefaultHost.d.ts +0 -12
- package/lib/node/orchestration/host/implementation/DefaultHost.d.ts.map +0 -1
- package/lib/node/orchestration/host/implementation/DefaultServiceCollection.d.ts +0 -24
- package/lib/node/orchestration/host/implementation/DefaultServiceCollection.d.ts.map +0 -1
- package/lib/node/orchestration/host/implementation/DefaultServiceProvider.d.ts +0 -7
- package/lib/node/orchestration/host/implementation/DefaultServiceProvider.d.ts.map +0 -1
- package/lib/node/orchestration/host/implementation/index.d.ts +0 -3
- package/lib/node/orchestration/host/implementation/index.d.ts.map +0 -1
- package/lib/node/orchestration/host/index.d.ts +0 -3
- package/lib/node/orchestration/host/index.d.ts.map +0 -1
- package/lib/node/orchestration/host/model/Host.d.ts +0 -19
- package/lib/node/orchestration/host/model/Host.d.ts.map +0 -1
- package/lib/node/orchestration/host/model/ServiceCollection.d.ts +0 -20
- package/lib/node/orchestration/host/model/ServiceCollection.d.ts.map +0 -1
- package/lib/node/orchestration/host/model/ServiceProvider.d.ts +0 -4
- package/lib/node/orchestration/host/model/ServiceProvider.d.ts.map +0 -1
- package/lib/node/orchestration/host/model/index.d.ts +0 -4
- package/lib/node/orchestration/host/model/index.d.ts.map +0 -1
- package/lib/node/orchestration/index.d.ts +0 -6
- package/lib/node/orchestration/index.d.ts.map +0 -1
- package/lib/node/orchestration/initServices.d.ts +0 -10
- package/lib/node/orchestration/initServices.d.ts.map +0 -1
- package/lib/node/orchestration/map/BalanceSummary/index.d.ts +0 -2
- package/lib/node/orchestration/map/BalanceSummary/index.d.ts.map +0 -1
- package/lib/node/orchestration/map/BalanceSummary/initBalanceSummaryMap.d.ts +0 -7
- package/lib/node/orchestration/map/BalanceSummary/initBalanceSummaryMap.d.ts.map +0 -1
- package/lib/node/orchestration/map/BalanceSummary/local.d.ts +0 -7
- package/lib/node/orchestration/map/BalanceSummary/local.d.ts.map +0 -1
- package/lib/node/orchestration/map/driver/index.d.ts +0 -2
- package/lib/node/orchestration/map/driver/index.d.ts.map +0 -1
- package/lib/node/orchestration/map/driver/lmdb/Params.d.ts +0 -7
- package/lib/node/orchestration/map/driver/lmdb/Params.d.ts.map +0 -1
- package/lib/node/orchestration/map/driver/lmdb/SynchronousLmdbMap.d.ts +0 -32
- package/lib/node/orchestration/map/driver/lmdb/SynchronousLmdbMap.d.ts.map +0 -1
- package/lib/node/orchestration/map/driver/lmdb/index.d.ts +0 -2
- package/lib/node/orchestration/map/driver/lmdb/index.d.ts.map +0 -1
- package/lib/node/orchestration/map/driver/lmdb/spec/SynchronousLmdbMap.spec.d.ts +0 -2
- package/lib/node/orchestration/map/driver/lmdb/spec/SynchronousLmdbMap.spec.d.ts.map +0 -1
- package/lib/node/orchestration/map/index.d.ts +0 -3
- package/lib/node/orchestration/map/index.d.ts.map +0 -1
- package/lib/node/orchestration/map/localPersistentMap.d.ts +0 -12
- package/lib/node/orchestration/map/localPersistentMap.d.ts.map +0 -1
- package/lib/node/orchestration/repository/index.d.ts +0 -2
- package/lib/node/orchestration/repository/index.d.ts.map +0 -1
- package/lib/node/orchestration/repository/lib/index.d.ts +0 -2
- package/lib/node/orchestration/repository/lib/index.d.ts.map +0 -1
- package/lib/node/orchestration/repository/lib/repositoryFromArchivist.d.ts +0 -6
- package/lib/node/orchestration/repository/lib/repositoryFromArchivist.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/account.d.ts +0 -4
- package/lib/node/orchestration/services/implementation/account.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/balance.d.ts +0 -4
- package/lib/node/orchestration/services/implementation/balance.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/chain/evm.d.ts +0 -6
- package/lib/node/orchestration/services/implementation/chain/evm.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/chain/index.d.ts +0 -4
- package/lib/node/orchestration/services/implementation/chain/index.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/evm/index.d.ts +0 -2
- package/lib/node/orchestration/services/implementation/evm/index.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/evm/initChainId.d.ts +0 -3
- package/lib/node/orchestration/services/implementation/evm/initChainId.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/evm/initEvmProvider.d.ts +0 -4
- package/lib/node/orchestration/services/implementation/evm/initEvmProvider.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/evm/initGanacheProvider.d.ts +0 -5
- package/lib/node/orchestration/services/implementation/evm/initGanacheProvider.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/evm/initInfuraProvider.d.ts +0 -5
- package/lib/node/orchestration/services/implementation/evm/initInfuraProvider.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/head.d.ts +0 -10
- package/lib/node/orchestration/services/implementation/head.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/index.d.ts +0 -11
- package/lib/node/orchestration/services/implementation/index.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/iterator.d.ts +0 -6
- package/lib/node/orchestration/services/implementation/iterator.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/pendingTransactions.d.ts +0 -4
- package/lib/node/orchestration/services/implementation/pendingTransactions.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/producer.d.ts +0 -4
- package/lib/node/orchestration/services/implementation/producer.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/reward.d.ts +0 -4
- package/lib/node/orchestration/services/implementation/reward.d.ts.map +0 -1
- package/lib/node/orchestration/services/implementation/validator.d.ts +0 -4
- package/lib/node/orchestration/services/implementation/validator.d.ts.map +0 -1
- package/lib/node/orchestration/services/index.d.ts +0 -2
- package/lib/node/orchestration/services/index.d.ts.map +0 -1
- package/lib/node/orchestration/status/RuntimeStatusMonitor.d.ts +0 -31
- package/lib/node/orchestration/status/RuntimeStatusMonitor.d.ts.map +0 -1
- package/lib/node/orchestration/status/ServiceStatus.d.ts +0 -9
- package/lib/node/orchestration/status/ServiceStatus.d.ts.map +0 -1
- package/lib/node/orchestration/status/index.d.ts +0 -3
- package/lib/node/orchestration/status/index.d.ts.map +0 -1
- package/lib/node/orchestration/store/StoreKind.d.ts +0 -2
- package/lib/node/orchestration/store/StoreKind.d.ts.map +0 -1
- package/lib/node/orchestration/store/getStoreDirectory.d.ts +0 -9
- package/lib/node/orchestration/store/getStoreDirectory.d.ts.map +0 -1
- package/lib/node/orchestration/store/index.d.ts +0 -3
- package/lib/node/orchestration/store/index.d.ts.map +0 -1
- package/lib/node/runCLI.d.ts +0 -2
- package/lib/node/runCLI.d.ts.map +0 -1
- package/lib/node/spec/BootstrapChain.spec.d.ts +0 -2
- package/lib/node/spec/BootstrapChain.spec.d.ts.map +0 -1
- package/lib/node/start.d.ts +0 -2
- package/lib/node/start.d.ts.map +0 -1
- package/lib/node/waitForHostPort.d.ts +0 -2
- package/lib/node/waitForHostPort.d.ts.map +0 -1
- package/lib/node/xl1.d.ts +0 -2
- package/lib/node/xl1.d.ts.map +0 -1
- package/lib/node/xl1.mjs +0 -1582
- package/lib/node/xl1.mjs.map +0 -1
- package/nodemon.json +0 -9
- package/rollup.config.mjs +0 -79
- package/src/commands/api/index.ts +0 -1
- package/src/commands/api/runApi.ts +0 -12
- package/src/commands/index.ts +0 -3
- package/src/commands/producer/createDeclaration.ts +0 -18
- package/src/commands/producer/index.ts +0 -2
- package/src/commands/producer/runProducer.ts +0 -35
- package/src/commands/validator/index.ts +0 -1
- package/src/commands/validator/runValidator.ts +0 -22
- package/src/images.ts +0 -19
- package/src/index.ts +0 -3
- package/src/initConfig.ts +0 -6
- package/src/initEnv.ts +0 -8
- package/src/initLogger.ts +0 -16
- package/src/optionsFromZodSchema.ts +0 -69
- package/src/orchestration/ChainInitializableParams.ts +0 -10
- package/src/orchestration/actor/implementation/BalanceActor.ts +0 -51
- package/src/orchestration/actor/implementation/ChainHeadUpdateActor.ts +0 -65
- package/src/orchestration/actor/implementation/ProducerActor.ts +0 -250
- package/src/orchestration/actor/implementation/index.ts +0 -3
- package/src/orchestration/actor/index.ts +0 -2
- package/src/orchestration/actor/model/Actor.ts +0 -112
- package/src/orchestration/actor/model/Orchestrator.ts +0 -71
- package/src/orchestration/actor/model/index.ts +0 -2
- package/src/orchestration/archivists/ChainFinalized/archivist.ts +0 -27
- package/src/orchestration/archivists/ChainFinalized/index.ts +0 -1
- package/src/orchestration/archivists/ChainFinalized/local.ts +0 -16
- package/src/orchestration/archivists/ChainFinalized/remote.ts +0 -18
- package/src/orchestration/archivists/ChainSubmissions/archivist.ts +0 -19
- package/src/orchestration/archivists/ChainSubmissions/index.ts +0 -1
- package/src/orchestration/archivists/ChainSubmissions/remote.ts +0 -18
- package/src/orchestration/archivists/PendingTransactions/archivist.ts +0 -29
- package/src/orchestration/archivists/PendingTransactions/index.ts +0 -1
- package/src/orchestration/archivists/PendingTransactions/local.ts +0 -20
- package/src/orchestration/archivists/PendingTransactions/remote.ts +0 -18
- package/src/orchestration/archivists/RejectedTransactions/archivist.ts +0 -18
- package/src/orchestration/archivists/RejectedTransactions/index.ts +0 -1
- package/src/orchestration/archivists/RejectedTransactions/local.ts +0 -20
- package/src/orchestration/archivists/StakeIntentState/archivist.ts +0 -21
- package/src/orchestration/archivists/StakeIntentState/index.ts +0 -1
- package/src/orchestration/archivists/StakeIntentState/local.ts +0 -17
- package/src/orchestration/archivists/index.ts +0 -5
- package/src/orchestration/archivists/lib/index.ts +0 -1
- package/src/orchestration/archivists/lib/localPersistentArchivist.ts +0 -44
- package/src/orchestration/health/index.ts +0 -1
- package/src/orchestration/health/initHealthEndpoints.ts +0 -70
- package/src/orchestration/host/implementation/DefaultHost.ts +0 -25
- package/src/orchestration/host/implementation/DefaultServiceCollection.ts +0 -60
- package/src/orchestration/host/implementation/DefaultServiceProvider.ts +0 -12
- package/src/orchestration/host/implementation/index.ts +0 -2
- package/src/orchestration/host/index.ts +0 -2
- package/src/orchestration/host/model/Host.ts +0 -21
- package/src/orchestration/host/model/ServiceCollection.ts +0 -22
- package/src/orchestration/host/model/ServiceProvider.ts +0 -3
- package/src/orchestration/host/model/index.ts +0 -3
- package/src/orchestration/index.ts +0 -5
- package/src/orchestration/initServices.ts +0 -241
- package/src/orchestration/map/BalanceSummary/index.ts +0 -1
- package/src/orchestration/map/BalanceSummary/initBalanceSummaryMap.ts +0 -22
- package/src/orchestration/map/BalanceSummary/local.ts +0 -20
- package/src/orchestration/map/driver/index.ts +0 -1
- package/src/orchestration/map/driver/lmdb/Params.ts +0 -7
- package/src/orchestration/map/driver/lmdb/SynchronousLmdbMap.ts +0 -67
- package/src/orchestration/map/driver/lmdb/index.ts +0 -1
- package/src/orchestration/map/index.ts +0 -2
- package/src/orchestration/map/localPersistentMap.ts +0 -39
- package/src/orchestration/repository/index.ts +0 -1
- package/src/orchestration/repository/lib/index.ts +0 -1
- package/src/orchestration/repository/lib/repositoryFromArchivist.ts +0 -27
- package/src/orchestration/services/implementation/account.ts +0 -23
- package/src/orchestration/services/implementation/balance.ts +0 -13
- package/src/orchestration/services/implementation/chain/evm.ts +0 -35
- package/src/orchestration/services/implementation/chain/index.ts +0 -27
- package/src/orchestration/services/implementation/evm/index.ts +0 -1
- package/src/orchestration/services/implementation/evm/initChainId.ts +0 -18
- package/src/orchestration/services/implementation/evm/initEvmProvider.ts +0 -21
- package/src/orchestration/services/implementation/evm/initGanacheProvider.ts +0 -19
- package/src/orchestration/services/implementation/evm/initInfuraProvider.ts +0 -25
- package/src/orchestration/services/implementation/head.ts +0 -44
- package/src/orchestration/services/implementation/index.ts +0 -10
- package/src/orchestration/services/implementation/iterator.ts +0 -36
- package/src/orchestration/services/implementation/pendingTransactions.ts +0 -14
- package/src/orchestration/services/implementation/producer.ts +0 -13
- package/src/orchestration/services/implementation/reward.ts +0 -37
- package/src/orchestration/services/implementation/validator.ts +0 -14
- package/src/orchestration/services/index.ts +0 -1
- package/src/orchestration/status/RuntimeStatusMonitor.ts +0 -117
- package/src/orchestration/status/ServiceStatus.ts +0 -21
- package/src/orchestration/status/index.ts +0 -2
- package/src/orchestration/store/StoreKind.ts +0 -1
- package/src/orchestration/store/getStoreDirectory.ts +0 -15
- package/src/orchestration/store/index.ts +0 -2
- package/src/runCLI.ts +0 -111
- package/src/spec/MultiProducer.ChainOutput.json +0 -864
- package/src/start.ts +0 -7
- package/src/waitForHostPort.ts +0 -26
- package/src/xl1.ts +0 -7
- package/vitest.config.ts +0 -11
- package/xy.config.ts +0 -23
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
import { delay } from '@xylabs/delay'
|
|
2
|
-
import { ZERO_ADDRESS } from '@xylabs/hex'
|
|
3
|
-
import type { Promisable } from '@xylabs/promise'
|
|
4
|
-
import type { ArchivistInstance } from '@xyo-network/archivist-model'
|
|
5
|
-
import { createGenesisBlock, findMostRecentBlock } from '@xyo-network/chain-protocol'
|
|
6
|
-
import type { WithStorageMeta } from '@xyo-network/payload-model'
|
|
7
|
-
import type { WalletInstance } from '@xyo-network/wallet-model'
|
|
8
|
-
import type { BlockBoundWitness, Initializable } from '@xyo-network/xl1-protocol'
|
|
9
|
-
import { flattenHydratedBlock } from '@xyo-network/xl1-protocol-sdk'
|
|
10
|
-
|
|
11
|
-
let headSingleton: Promisable<WithStorageMeta<BlockBoundWitness>> | undefined
|
|
12
|
-
|
|
13
|
-
const createBootstrapHead = async (
|
|
14
|
-
chainSubmissionsArchivistWrite: ArchivistInstance,
|
|
15
|
-
chainArchivist: ArchivistInstance,
|
|
16
|
-
account: WalletInstance,
|
|
17
|
-
): Promise<WithStorageMeta<BlockBoundWitness>> => {
|
|
18
|
-
const block = await createGenesisBlock(account, ZERO_ADDRESS, 10_000_000n, account.address)
|
|
19
|
-
const [bw] = block
|
|
20
|
-
await chainSubmissionsArchivistWrite.insert(flattenHydratedBlock(block))
|
|
21
|
-
// Wait for block to show up in finalized archivist
|
|
22
|
-
while (true) {
|
|
23
|
-
const result = await chainArchivist.get([bw._hash])
|
|
24
|
-
if (result.length > 0) break
|
|
25
|
-
await delay(1000) // Wait 1 second before retrying
|
|
26
|
-
}
|
|
27
|
-
return bw
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
export const initHead: Initializable<{
|
|
31
|
-
account: WalletInstance
|
|
32
|
-
chainArchivist: ArchivistInstance
|
|
33
|
-
chainSubmissionsArchivistWrite: ArchivistInstance
|
|
34
|
-
}, WithStorageMeta<BlockBoundWitness>>
|
|
35
|
-
= async (params): Promise<WithStorageMeta<BlockBoundWitness>> => {
|
|
36
|
-
const {
|
|
37
|
-
account, chainArchivist, chainSubmissionsArchivistWrite,
|
|
38
|
-
} = params
|
|
39
|
-
if (headSingleton) return headSingleton
|
|
40
|
-
let head = await findMostRecentBlock(chainArchivist)
|
|
41
|
-
if (!head) head = await createBootstrapHead(chainSubmissionsArchivistWrite, chainArchivist, account)
|
|
42
|
-
headSingleton = head
|
|
43
|
-
return headSingleton
|
|
44
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
export * from './account.ts'
|
|
2
|
-
export * from './balance.ts'
|
|
3
|
-
export * from './chain/index.ts'
|
|
4
|
-
export * from './evm/index.ts'
|
|
5
|
-
export * from './head.ts'
|
|
6
|
-
export * from './iterator.ts'
|
|
7
|
-
export * from './pendingTransactions.ts'
|
|
8
|
-
export * from './producer.ts'
|
|
9
|
-
export * from './reward.ts'
|
|
10
|
-
export * from './validator.ts'
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
BaseElectionServicesParams,
|
|
3
|
-
XyoChainIteratorParams,
|
|
4
|
-
XyoStakeIntentServiceParams,
|
|
5
|
-
} from '@xyo-network/chain-services'
|
|
6
|
-
import {
|
|
7
|
-
BaseElectionService, ChainBlockNumberIterationService,
|
|
8
|
-
XyoStakeIntentService,
|
|
9
|
-
} from '@xyo-network/chain-services'
|
|
10
|
-
import type {
|
|
11
|
-
ElectionService, EventingChainBlockNumberIterator, Initializable, StakeIntentService,
|
|
12
|
-
} from '@xyo-network/xl1-protocol'
|
|
13
|
-
|
|
14
|
-
let chainIteratorServiceSingleton: Promise<EventingChainBlockNumberIterator> | undefined
|
|
15
|
-
let stakeIntentServiceSingleton: Promise<StakeIntentService> | undefined
|
|
16
|
-
let electionServiceSingleton: Promise<ElectionService> | undefined
|
|
17
|
-
|
|
18
|
-
export const initChainIterator: Initializable<XyoChainIteratorParams, EventingChainBlockNumberIterator> = (params) => {
|
|
19
|
-
if (chainIteratorServiceSingleton) return chainIteratorServiceSingleton
|
|
20
|
-
chainIteratorServiceSingleton = ChainBlockNumberIterationService.create(params)
|
|
21
|
-
return chainIteratorServiceSingleton
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
export const initStakeIntentService: Initializable<XyoStakeIntentServiceParams, StakeIntentService>
|
|
25
|
-
= (params) => {
|
|
26
|
-
if (stakeIntentServiceSingleton) return stakeIntentServiceSingleton
|
|
27
|
-
stakeIntentServiceSingleton = XyoStakeIntentService.create(params)
|
|
28
|
-
return stakeIntentServiceSingleton
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
export const initElectionService: Initializable<BaseElectionServicesParams, ElectionService>
|
|
32
|
-
= (params) => {
|
|
33
|
-
if (electionServiceSingleton) return electionServiceSingleton
|
|
34
|
-
electionServiceSingleton = BaseElectionService.create(params)
|
|
35
|
-
return electionServiceSingleton
|
|
36
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import type { Promisable } from '@xylabs/promise'
|
|
2
|
-
import type { BasePendingTransactionsServiceParams } from '@xyo-network/chain-services'
|
|
3
|
-
import { BasePendingTransactionsService } from '@xyo-network/chain-services'
|
|
4
|
-
import type { Initializable, PendingTransactionsService } from '@xyo-network/xl1-protocol'
|
|
5
|
-
|
|
6
|
-
let serviceSingleton: Promisable<PendingTransactionsService> | undefined
|
|
7
|
-
|
|
8
|
-
export const initPendingTransactions: Initializable<BasePendingTransactionsServiceParams, PendingTransactionsService> = async (
|
|
9
|
-
params: BasePendingTransactionsServiceParams,
|
|
10
|
-
): Promise<PendingTransactionsService> => {
|
|
11
|
-
if (serviceSingleton) return serviceSingleton
|
|
12
|
-
serviceSingleton = await BasePendingTransactionsService.create(params)
|
|
13
|
-
return serviceSingleton
|
|
14
|
-
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import type { Promisable } from '@xylabs/promise'
|
|
2
|
-
import type { BaseBlockProducerServiceParams } from '@xyo-network/chain-services'
|
|
3
|
-
import { BaseBlockProducerService } from '@xyo-network/chain-services'
|
|
4
|
-
import type { BlockProducerService, Initializable } from '@xyo-network/xl1-protocol'
|
|
5
|
-
|
|
6
|
-
let serviceSingleton: Promisable<BlockProducerService> | undefined
|
|
7
|
-
|
|
8
|
-
export const initBlockProducer: Initializable<BaseBlockProducerServiceParams, BlockProducerService>
|
|
9
|
-
= async (params: BaseBlockProducerServiceParams): Promise<BlockProducerService> => {
|
|
10
|
-
if (serviceSingleton) return serviceSingleton
|
|
11
|
-
serviceSingleton = await BaseBlockProducerService.create(params)
|
|
12
|
-
return serviceSingleton
|
|
13
|
-
}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import { assertEx } from '@xylabs/assert'
|
|
2
|
-
import type { BaseBlockRewardServiceParams, EvmBlockRewardServiceParams } from '@xyo-network/chain-services'
|
|
3
|
-
import { EvmBlockRewardService, MemoryBlockRewardService } from '@xyo-network/chain-services'
|
|
4
|
-
import type { BlockRewardService, Initializable } from '@xyo-network/xl1-protocol'
|
|
5
|
-
|
|
6
|
-
import { canUseEvmProvider, initEvmProvider } from './evm/index.ts'
|
|
7
|
-
|
|
8
|
-
let rewardServiceSingleton: Promise<BlockRewardService> | undefined
|
|
9
|
-
|
|
10
|
-
export const initBlockRewardService: Initializable<
|
|
11
|
-
BaseBlockRewardServiceParams | EvmBlockRewardServiceParams,
|
|
12
|
-
BlockRewardService
|
|
13
|
-
> = (params): Promise<BlockRewardService> => {
|
|
14
|
-
if (rewardServiceSingleton) return rewardServiceSingleton
|
|
15
|
-
rewardServiceSingleton = canUseEvmBlockRewardService() ? initEvmBlockRewardService(params as EvmBlockRewardServiceParams) : initXyoBlockRewardService(params)
|
|
16
|
-
return rewardServiceSingleton
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
const initXyoBlockRewardService = (params: BaseBlockRewardServiceParams): Promise<BlockRewardService> => {
|
|
20
|
-
if (rewardServiceSingleton) return rewardServiceSingleton
|
|
21
|
-
rewardServiceSingleton = MemoryBlockRewardService.create(params)
|
|
22
|
-
return rewardServiceSingleton
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
const canUseEvmBlockRewardService = () => canUseEvmProvider()
|
|
26
|
-
|
|
27
|
-
const initEvmBlockRewardService = async (params: EvmBlockRewardServiceParams): Promise<BlockRewardService> => {
|
|
28
|
-
if (rewardServiceSingleton) return rewardServiceSingleton
|
|
29
|
-
const { account: paramsAccount } = params
|
|
30
|
-
const account = assertEx(paramsAccount, () => 'Error: Account is required')
|
|
31
|
-
const provider = assertEx(await initEvmProvider())
|
|
32
|
-
const evmBlockRewardServiceParams: EvmBlockRewardServiceParams = {
|
|
33
|
-
...params, provider, account,
|
|
34
|
-
}
|
|
35
|
-
rewardServiceSingleton = EvmBlockRewardService.create(evmBlockRewardServiceParams)
|
|
36
|
-
return rewardServiceSingleton
|
|
37
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import type { Promisable } from '@xylabs/promise'
|
|
2
|
-
import type { BaseBlockProducerServiceParams } from '@xyo-network/chain-services'
|
|
3
|
-
import type { BlockProducerService, Initializable } from '@xyo-network/xl1-protocol'
|
|
4
|
-
|
|
5
|
-
import { initBlockProducer } from './producer.ts'
|
|
6
|
-
|
|
7
|
-
let serviceSingleton: Promisable<BlockProducerService> | undefined
|
|
8
|
-
|
|
9
|
-
export const initValidator: Initializable<BaseBlockProducerServiceParams, BlockProducerService>
|
|
10
|
-
= (params: BaseBlockProducerServiceParams): Promisable<BlockProducerService> => {
|
|
11
|
-
if (serviceSingleton) return serviceSingleton
|
|
12
|
-
serviceSingleton = initBlockProducer(params)
|
|
13
|
-
return serviceSingleton
|
|
14
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './implementation/index.ts'
|
|
@@ -1,117 +0,0 @@
|
|
|
1
|
-
import type { CreatableStatus } from '@xylabs/creatable'
|
|
2
|
-
|
|
3
|
-
import { LoggerStatusReporter } from './ServiceStatus.ts'
|
|
4
|
-
|
|
5
|
-
/**
|
|
6
|
-
* Enum-like record for statuses with priority allowing
|
|
7
|
-
* for determination of the aggregated status.
|
|
8
|
-
*/
|
|
9
|
-
const statusPriority: Record<CreatableStatus, number> = {
|
|
10
|
-
error: 0,
|
|
11
|
-
stopped: 1,
|
|
12
|
-
stopping: 2,
|
|
13
|
-
creating: 3,
|
|
14
|
-
created: 4,
|
|
15
|
-
starting: 5,
|
|
16
|
-
started: 6,
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
/**
|
|
20
|
-
* A sentinel status that represents the initial state
|
|
21
|
-
* before any statuses are reported.
|
|
22
|
-
* It is used to ensure that the monitor has a valid status
|
|
23
|
-
* even when no statuses have been reported yet and to
|
|
24
|
-
* prevent the system from showing an "error" state
|
|
25
|
-
* when no statuses are available.
|
|
26
|
-
*/
|
|
27
|
-
const SENTINEL_STATUS: CreatableStatus = 'starting'
|
|
28
|
-
|
|
29
|
-
/**
|
|
30
|
-
* Given an array of statuses, this function reduces them
|
|
31
|
-
* to the minimum status based on the defined priority.
|
|
32
|
-
* @param statuses An array of statuses to reduce.
|
|
33
|
-
* @returns The minimum status based on priority.
|
|
34
|
-
*/
|
|
35
|
-
const reduceToMinimumStatus = (statuses: CreatableStatus[]): CreatableStatus => {
|
|
36
|
-
let minStatus: CreatableStatus = SENTINEL_STATUS
|
|
37
|
-
let minPriority = Infinity
|
|
38
|
-
|
|
39
|
-
for (const status of statuses) {
|
|
40
|
-
const priority = statusPriority[status]
|
|
41
|
-
if (priority < minPriority) {
|
|
42
|
-
minPriority = priority
|
|
43
|
-
minStatus = status
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
return minStatus
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
export type GlobalTransitionHandler = {
|
|
50
|
-
from?: CreatableStatus
|
|
51
|
-
handler: (from: CreatableStatus, to: CreatableStatus) => void
|
|
52
|
-
to?: CreatableStatus
|
|
53
|
-
}
|
|
54
|
-
export type TransitionHandler = GlobalTransitionHandler & {
|
|
55
|
-
name?: string
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
export class RuntimeStatusMonitor extends LoggerStatusReporter {
|
|
59
|
-
private globalTransitions: GlobalTransitionHandler[] = []
|
|
60
|
-
private transitions: TransitionHandler[] = []
|
|
61
|
-
|
|
62
|
-
getGlobalStatus(): CreatableStatus {
|
|
63
|
-
// If no statuses have been reported, return the sentinel status
|
|
64
|
-
if (Object.keys(this.statusMap).length === 0) return SENTINEL_STATUS
|
|
65
|
-
return reduceToMinimumStatus(Object.values(this.statusMap))
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
getStatus(name: string): CreatableStatus | undefined {
|
|
69
|
-
return this.statusMap[name]
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
onGlobalTransition(match: { from?: CreatableStatus; to?: CreatableStatus }, handler: (from: CreatableStatus, to: CreatableStatus) => void) {
|
|
73
|
-
this.globalTransitions.push({ ...match, handler })
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
/**
|
|
77
|
-
* Register a callback to be called on a specific transition.
|
|
78
|
-
*/
|
|
79
|
-
onTransition(match: { from?: CreatableStatus; name: string; to?: CreatableStatus }, handler: (from: CreatableStatus, to: CreatableStatus) => void) {
|
|
80
|
-
this.transitions.push({ ...match, handler })
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
override report(name: string, status: CreatableStatus, progress?: number | Error): void {
|
|
84
|
-
// Capture the current status before updating
|
|
85
|
-
const previous = this.statusMap[name]
|
|
86
|
-
const previousGlobal = this.getGlobalStatus()
|
|
87
|
-
|
|
88
|
-
// Update the status map with the new status
|
|
89
|
-
super.report(name, status, progress)
|
|
90
|
-
|
|
91
|
-
// If the status hasn't changed, do not run handlers
|
|
92
|
-
if (previous === status) return
|
|
93
|
-
this.runTransitions(this.transitions, previous, status, name)
|
|
94
|
-
|
|
95
|
-
// If the global status hasn't changed, do not run handlers
|
|
96
|
-
const globalStatus = this.getGlobalStatus()
|
|
97
|
-
if (previousGlobal === globalStatus) return
|
|
98
|
-
this.runTransitions(this.globalTransitions, previousGlobal, globalStatus)
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
private runTransitions(
|
|
102
|
-
transitions: (TransitionHandler | GlobalTransitionHandler)[],
|
|
103
|
-
prev: CreatableStatus,
|
|
104
|
-
next: CreatableStatus,
|
|
105
|
-
name?: string,
|
|
106
|
-
) {
|
|
107
|
-
for (const {
|
|
108
|
-
from, to, name: matchName, handler,
|
|
109
|
-
} of transitions as TransitionHandler[]) {
|
|
110
|
-
if ((matchName === undefined || matchName === name)
|
|
111
|
-
&& (from === undefined || from === prev)
|
|
112
|
-
&& (to === undefined || to === next)) {
|
|
113
|
-
handler(prev, next)
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
CreatableName, CreatableStatus, CreatableStatusReporter,
|
|
3
|
-
} from '@xylabs/creatable'
|
|
4
|
-
import type { Logger } from '@xylabs/logger'
|
|
5
|
-
|
|
6
|
-
export class LoggerStatusReporter implements CreatableStatusReporter {
|
|
7
|
-
protected logger: Logger
|
|
8
|
-
|
|
9
|
-
protected statusMap: Record<CreatableName, CreatableStatus> = {}
|
|
10
|
-
|
|
11
|
-
constructor(logger: Logger) {
|
|
12
|
-
this.logger = logger
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
report(name: string, status: CreatableStatus, progress?: number | Error): void {
|
|
16
|
-
this.statusMap[name] = status
|
|
17
|
-
const starting = (Object.entries(this.statusMap).map(([, value]): number => value === 'starting' ? 1 : 0)).reduce((a, b) => a + b, 0)
|
|
18
|
-
const started = (Object.entries(this.statusMap).map(([, value]): number => value === 'started' ? 1 : 0)).reduce((a, b) => a + b, 0)
|
|
19
|
-
this.logger.info(`${started}/${starting + started} ${name} status: ${status}`, { progress })
|
|
20
|
-
}
|
|
21
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type StoreKind = 'lmdb'
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import Path from 'node:path'
|
|
2
|
-
|
|
3
|
-
import type { StoreKind } from './StoreKind.ts'
|
|
4
|
-
|
|
5
|
-
const STORAGE_ROOT = process.env.STORAGE_ROOT ?? Path.join(process.cwd(), '.store')
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* Creates a convention-based directory path for an archivist store
|
|
9
|
-
* @param name The name of the archivist
|
|
10
|
-
* @param kind The kind of the archivist (optional)
|
|
11
|
-
* @returns The directory path for the archivist store
|
|
12
|
-
*/
|
|
13
|
-
export const getStoreDirectory = (name: string, kind?: StoreKind): string => {
|
|
14
|
-
return (kind === undefined) ? Path.join(STORAGE_ROOT, name) : Path.join(STORAGE_ROOT, kind, name)
|
|
15
|
-
}
|
package/src/runCLI.ts
DELETED
|
@@ -1,111 +0,0 @@
|
|
|
1
|
-
import type { Logger } from '@xylabs/logger'
|
|
2
|
-
import { isDefined } from '@xylabs/typeof'
|
|
3
|
-
import { type Config, ConfigSchema } from '@xyo-network/chain-protocol'
|
|
4
|
-
import type { Argv } from 'yargs'
|
|
5
|
-
import yargs from 'yargs'
|
|
6
|
-
import { hideBin } from 'yargs/helpers'
|
|
7
|
-
import { ZodError } from 'zod'
|
|
8
|
-
|
|
9
|
-
import { runApi, runProducer } from './commands/index.ts'
|
|
10
|
-
import { XL1LogoColorizedAscii } from './images.ts'
|
|
11
|
-
import { initLogger } from './initLogger.ts'
|
|
12
|
-
import { optionsFromZodSchema } from './optionsFromZodSchema.ts'
|
|
13
|
-
import { Orchestrator } from './orchestration/index.ts'
|
|
14
|
-
import { waitForHostPort } from './waitForHostPort.ts'
|
|
15
|
-
|
|
16
|
-
/** Version string injected by Rollup at build time. */
|
|
17
|
-
declare const __VERSION__: string
|
|
18
|
-
|
|
19
|
-
interface RunCliContext {
|
|
20
|
-
logger: Logger
|
|
21
|
-
orchestrator: Orchestrator
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* The configuration that will be used throughout the CLI.
|
|
26
|
-
* This is materialized after parsing the command-line arguments,
|
|
27
|
-
* environment variables, and defaults.
|
|
28
|
-
*/
|
|
29
|
-
let config: Config
|
|
30
|
-
|
|
31
|
-
const version = isDefined(__VERSION__) ? __VERSION__ : 'unknown'
|
|
32
|
-
|
|
33
|
-
const getContextFromConfig = (config: Config): RunCliContext => {
|
|
34
|
-
const logger = initLogger(config)
|
|
35
|
-
const orchestrator = new Orchestrator(logger)
|
|
36
|
-
// Handle cancellation (Ctrl+C)
|
|
37
|
-
process.on('SIGINT', () => {
|
|
38
|
-
void (async () => {
|
|
39
|
-
try {
|
|
40
|
-
logger.log('\nSIGINT received. Attempting graceful shutdown...')
|
|
41
|
-
await orchestrator?.stop()
|
|
42
|
-
logger.log('Orchestrator stopped, exiting now.')
|
|
43
|
-
process.exit(0)
|
|
44
|
-
} catch (err) {
|
|
45
|
-
logger.error('Error stopping orchestrator:', err)
|
|
46
|
-
process.exit(1)
|
|
47
|
-
}
|
|
48
|
-
})()
|
|
49
|
-
})
|
|
50
|
-
return { logger, orchestrator }
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
// Main entry point
|
|
54
|
-
export async function runCLI() {
|
|
55
|
-
// Parse command-line arguments using Yargs
|
|
56
|
-
const y = yargs(hideBin(process.argv)) as Argv<Config>
|
|
57
|
-
const argv = y
|
|
58
|
-
.usage(`
|
|
59
|
-
🚀 XL1 Node CLI (${version})
|
|
60
|
-
${XL1LogoColorizedAscii}
|
|
61
|
-
Run various components of the XL1 ecosystem.
|
|
62
|
-
|
|
63
|
-
Usage:
|
|
64
|
-
$0 <command> [options]`)
|
|
65
|
-
.parserConfiguration({ 'dot-notation': true }) // foo.bar → { foo: { bar } }
|
|
66
|
-
.env('XL1')
|
|
67
|
-
.scriptName('xl1')
|
|
68
|
-
.config()
|
|
69
|
-
.version(version)
|
|
70
|
-
.middleware((argv) => {
|
|
71
|
-
try {
|
|
72
|
-
// Parse and validate the config
|
|
73
|
-
config = ConfigSchema.parse(argv)
|
|
74
|
-
} catch (err) {
|
|
75
|
-
if (err instanceof ZodError) {
|
|
76
|
-
for (const issue of err.errors) {
|
|
77
|
-
console.error(`${issue.path.join('.')} → ${issue.message}`)
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
throw new Error('Invalid configuration')
|
|
81
|
-
}
|
|
82
|
-
})
|
|
83
|
-
.options(optionsFromZodSchema(ConfigSchema.shape))
|
|
84
|
-
// .commandDir('./command/commands', opts) // Not yet supported for ESM
|
|
85
|
-
.wrap(y.terminalWidth())
|
|
86
|
-
.command('api', 'Run a XL1 API Node', (yargs) => {
|
|
87
|
-
return yargs
|
|
88
|
-
.command('$0', 'Run a XL1 API Node', () => {}, () => {
|
|
89
|
-
const context = getContextFromConfig(config)
|
|
90
|
-
runApi({ ...context, config })
|
|
91
|
-
})
|
|
92
|
-
})
|
|
93
|
-
.command('producer', 'Run a XL1 Producer Node', (yargs) => {
|
|
94
|
-
return yargs
|
|
95
|
-
.command('$0', 'Run a XL1 Producer Node', () => {}, async () => {
|
|
96
|
-
const context = getContextFromConfig(config)
|
|
97
|
-
await runProducer({ ...context, config })
|
|
98
|
-
})
|
|
99
|
-
})
|
|
100
|
-
.command('$0', 'Run a full XL1 Node', () => {}, async () => {
|
|
101
|
-
const context = getContextFromConfig(config)
|
|
102
|
-
runApi({ ...context, config })
|
|
103
|
-
await waitForHostPort('localhost', config.api.port)
|
|
104
|
-
await runProducer({ ...context, config })
|
|
105
|
-
})
|
|
106
|
-
.help()
|
|
107
|
-
.alias('help', 'h')
|
|
108
|
-
.argv
|
|
109
|
-
|
|
110
|
-
await argv
|
|
111
|
-
}
|