From 4cab6060c63529d5a9ee77b8aee6834f8386c74d Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:11:00 +0100 Subject: [PATCH 01/28] feat: add new structure to config.conf file --- framework/src/main/resources/config.conf | 1400 +++++++++++++--------- 1 file changed, 803 insertions(+), 597 deletions(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 661a592e431..7ad209890a2 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -1,49 +1,113 @@ +# * ------------------------------------- NODE CONFIGURATION -------------------------------------- +# * This file is used to configure a TRON network node (Full Node, Super Representative, Solidity Node, Lite Full Node). +# * This file uses a standardized commenting convention, designed to improve readability and developer experience when using +# * the Better Comments extension in Visual Studio Code. +# * The file leverages categorized comment prefixes to visually distinguish different types of information: +# ! (Important comments) +# * Used for critical notes that require developer attention. +# * These comments typically highlight constraints, warnings, or non-obvious behaviors. +# * By convention, they are always followed by a “Please note” statement. +# * (Informational comments) +# * Used to provide contextual explanations about a specific parameter or configuration section. +# * These comments are purely descriptive and do not require any action from the developer. +# ? (Reference comments) +# * Used to include external resources, documentation links, or additional references related to a parameter or section. +# * These are supplementary and do not require immediate attention. +# * This structure ensures a consistent, scannable configuration file where critical information stands out +# * while maintaining clear and accessible documentation inline. +# ? Ref (Better Comments): https://marketplace.visualstudio.com/items?itemName=aaron-bond.better-comments +# ? Ref: https://tronprotocol.github.io/documentation-en/using_javatron/private_network/ +# * --------------------------------------------- SECTIONS ---------------------------------------- +# * 1. net +# * 2. storage +# * 3. crypto +# * 4. node +# * 5. rate.limiter +# * 6. seed.node +# * 7. genesis.block +# * 8. localWitnessAccountAddress +# * 9. localwitness +# * 10. localwitnesskeystore +# * 11. block +# * 12. trx +# * 13. vm +# * 14. committee +# * 15. event.subscribe +# * --------------------------------------------- NET --------------------------------------------- +# * This configuration defines the network type +# * Use: +# * - mainnet, when working with the TRON main network +# * - testnet, when working with a local testnet +# * - everything else (like "privatenet") when working on a private chain +# ! Please note: +# ! changing this value determines the genesis block and seed nodes used. net { - # type is deprecated and has no effect. - # type = mainnet + type = privatenet } - +# * ------------------------------------------- STORAGE ------------------------------------------- +# * TRON uses a LevelDB database +# * LevelDB ref: https://github.com/google/leveldb storage { - # Directory for storing persistent data - db.engine = "LEVELDB", // deprecated for arm, because arm only support "ROCKSDB". - db.sync = false, - db.directory = "database", - - # Whether to write transaction result in transactionRetStore - transHistory.switch = "on", - - # setting can improve leveldb performance .... start, deprecated for arm - # node: if this will increase process fds,you may be check your ulimit if 'too many open files' error occurs - # see https://github.com/tronprotocol/tips/blob/master/tip-343.md for detail - # if you find block sync has lower performance, you can try this settings + # * Directory for storing persistent data + db.engine = "LEVELDB" + db.sync = false + db.directory = "database" + index.directory = "index" + transHistory.switch = "on" + + # * These are the databases which will be created when starting the node for the first time + # * You _can_ custom these 14 databases' configurations: + # * - account + # * - account-index + # * - asset-issue + # * - block + # * - block-index + # * - block_KDB + # * - peers + # * - properties + # * - recent-block + # * - trans + # * - utxo + # * - votes + # * - witness + # * - witness_schedule + # * If you don't change these configurations, + # * default db configs will be used, + # * and data will be stored in the path of "output-directory", + # * or the one set by "-d" (or "--output-directory"). + + # ? If you want to improve LevelDB performances, you can use the following settings: + # ! Please note: + # ! if this configuration causes the node to open more file descriptors, check your system ulimit if you get a too many open files error. + # ! See: https://github.com/tronprotocol/tips/blob/master/tip-343.md for more detail + # * ----- Improvement settings start here ----- # default = { - # maxOpenFiles = 100 + # maxOpenFiles = 100 # } # defaultM = { - # maxOpenFiles = 500 + # maxOpenFiles = 500 # } # defaultL = { - # maxOpenFiles = 1000 + # maxOpenFiles = 1000 # } - # setting can improve leveldb performance .... end, deprecated for arm + # * ----- Improvement settings end here ----- - # You can customize the configuration for each database. Otherwise, the database settings will use - # their defaults, and data will be stored in the "output-directory" or in the directory specified - # by the "-d" or "--output-directory" option. Attention: name is a required field that must be set! - # In this configuration, the name and path properties take effect for both LevelDB and RocksDB storage engines, - # while the additional properties (such as createIfMissing, paranoidChecks, compressionType, etc.) only take effect when using LevelDB. + # * Please note: + # * when using a different configuration for the RocksDB + # ! Please note: + # ! "name" is a required field that must be set! properties = [ # { # name = "account", # path = "storage_directory_test", - # createIfMissing = true, // deprecated for arm start + # createIfMissing = true, # paranoidChecks = true, # verifyChecksums = true, - # compressionType = 1, // compressed with snappy - # blockSize = 4096, // 4 KB = 4 * 1024 B - # writeBufferSize = 10485760, // 10 MB = 10 * 1024 * 1024 B - # cacheSize = 10485760, // 10 MB = 10 * 1024 * 1024 B - # maxOpenFiles = 100 // deprecated for arm end + # compressionType = 1, # * compressed with snappy + # blockSize = 4096, # * 4 KB = 4 * 1024 B + # writeBufferSize = 10485760, # * 10 MB = 10 * 1024 * 1024 B + # cacheSize = 10485760, # * 10 MB = 10 * 1024 * 1024 B + # maxOpenFiles = 100 # }, # { # name = "account-index", @@ -51,364 +115,465 @@ storage { # createIfMissing = true, # paranoidChecks = true, # verifyChecksums = true, - # compressionType = 1, // compressed with snappy - # blockSize = 4096, // 4 KB = 4 * 1024 B - # writeBufferSize = 10485760, // 10 MB = 10 * 1024 * 1024 B - # cacheSize = 10485760, // 10 MB = 10 * 1024 * 1024 B + # compressionType = 1, # * compressed with snappy + # blockSize = 4096, # * 4 KB = 4 * 1024 B + # writeBufferSize = 10485760, # * 10 MB = 10 * 1024 * 1024 B + # cacheSize = 10485760, # * 10 MB = 10 * 1024 * 1024 B # maxOpenFiles = 100 # }, ] + # * This tells the node whether it needs to update old asset formats + # * to the new TRC10/20 format when reading older blocks. + # * Keep it "true" for backward compatibility. needToUpdateAsset = true - # dbsettings is needed when using rocksdb as the storage implement (db.engine="ROCKSDB"). - # we'd strongly recommend that do not modify it unless you know every item's meaning clearly. + # * dbsettings is needed when using rocksdb as the storage implement (db.engine="ROCKSDB"). + # ! Please note: + # ! it is strongly recommended to not modify these parameters + # ! unless you know what you're doing. dbSettings = { levelNumber = 7 # compactThreads = 32 - blocksize = 64 // n * KB - maxBytesForLevelBase = 256 // n * MB + blocksize = 64 # * n * KB + maxBytesForLevelBase = 256 # * n * MB maxBytesForLevelMultiplier = 10 level0FileNumCompactionTrigger = 4 - targetFileSizeBase = 256 // n * MB + targetFileSizeBase = 256 # * n * MB targetFileSizeMultiplier = 1 - maxOpenFiles = 5000 } - balance.history.lookup = false - - # checkpoint.version = 2 - # checkpoint.sync = true - - # the estimated number of block transactions (default 1000, min 100, max 10000). - # so the total number of cached transactions is 65536 * txCache.estimatedTransactions - # txCache.estimatedTransactions = 1000 - - # if true, transaction cache initialization will be faster. Default: false - txCache.initOptimization = true + # ! Please note: + # ! the backup plugin is available only when db.engine="ROCKSDB" + backup = { + enable = false # * Indicate whether enable the backup plugin + propPath = "prop.properties" # * Record which .bak directory is valid + bak1path = "bak1/database" # * Two backup directories must be set to prevent application halt unexpected (e.g. kill -9). + bak2path = "bak2/database" + frequency = 10000 # * Indicates that the db backup should occur every 10000 blocks processed + } - # The number of blocks flushed to db in each batch during node syncing. Default: 1 - # snapshot.maxFlushCount = 1 + # * If true, the node keeps a lookup index of historical balances per account for time-based queries. + # * Default false saves disk and improves speed, but historical balance queries won't work. + # * Only enable if you need that API. + balance.history.lookup = false - # data root setting, for check data, currently, only reward-vi is used. + # * Used for resuming blockchain sync from a "checkpoint" snapshot + # * instead of starting from genesis (first block generated). + # ! Please note: + # ! usually not used in a private blockchain. + # checkpoint.version = 2 # * version number of the snapshot + # checkpoint.sync = true # * whether to enable checkpoint synchronization + + # * Defines transaction caching parameters (used to speed up node startup time) + # * The estimated number of block transactions (min 100, max 10000). + # * The total number of cached transactions is 65536 (UINT8) * txCache.estimatedTransactions + # txCache.estimatedTransactions = 1000 # * Number of transactions expected per block (used to size cache arrays) + # * If true, transaction cache initialization will be faster + # txCache.initOptimization = true # * Speeds up initialization by preallocating cache memory + + # * Data root setting, for check data, currently, only reward-vi is used. + # ! Please note: + # ! leave untouched (even for private networks). # merkleRoot = { - # reward-vi = 9debcb9924055500aaae98cdee10501c5c39d4daa75800a996f4bdda73dbccd8 // main-net, Sha256Hash, hexString + # reward-vi = 9debcb9924055500aaae98cdee10501c5c39d4daa75800a996f4bdda73dbccd8 # * main-net, Sha256Hash, hexString # } } - -node.discovery = { - enable = true - persist = true -} - -# custom stop condition -#node.shutdown = { -# BlockTime = "54 59 08 * * ?" # if block header time in persistent db matched. -# BlockHeight = 33350800 # if block header height in persistent db matched. -# BlockCount = 12 # block sync count after node start. -#} - -node.backup { - # udp listen port, each member should have the same configuration - port = 10001 - - # my priority, each member should use different priority - priority = 8 - - # time interval to send keepAlive message, each member should have the same configuration - keepAliveInterval = 3000 - - # peer's ip list, can't contain mine - members = [ - # "ip", - # "ip" - ] -} - -# Specify the algorithm for generating a public key from private key. To avoid forks, please do not modify it +# * -------------------------------------------- CRYPTO ------------------------------------------- +# * Specifies the cryptographic algorithm used for signing and verifying transactions +# ! Please note: never change this value to anything else crypto { - engine = "eckey" + engine = "eckey" # * standard ECDSA (secp256k1), used across TRON } +# * --------------------------------------------- NODE -------------------------------------------- +# * This section keeps the node configuration +node { + # * These settings control the node visibility and discovery to/for other peers, and save discovered peers by the (current) node in the network + # ! Depending on the type of network that you are trying to create/join, + # ! you might want to disable the node discovery. + # ! For example, a Solidity Node should not have this option enabled, + # ! since its source of information (blockchain state, hence blocks) + # ! comes from the Full Node, which is controlled by the parameter "trustNode" + # ! in this section ("node"). + discovery { + enable = true # * Enable/Disable automatic peer discovery in the network + # * (controls whether the node searches for and announces itself to other peers) + persist = true # * Persist the discovered peers in a local file or database + } -node.metrics = { - # prometheus metrics - prometheus { - enable = false - port = 9527 + # * This section is used to export node metrics to an external tool such as "Prometheus" + # * If enabled, your node will expose data like block sync speed, TPS, memory usage. + metrics = { + # prometheus + # { + # enable = true + # port = "9527" + # } } - # influxdb metrics - storageEnable = false # Whether write metrics data into InfluxDb. Default: false. - influxdb { - ip = "" - port = 8086 - database = "" - metricsReportInterval = 10 + # * This section is used to configure the node backup + backup { + # * Determines which node acts as leader in a backup cluster (lower value = higher priority) + # priority = 8 + + # * UDP port used for backup communication between members + # ! Please note: + # ! each member should have the same configuration + # port = 10001 + + # * How often nodes send "I'm alive" messages + # ! Please note: + # ! each member should have the same configuration + # keepAliveInterval = 3000 # * milliseconds + + # * List of IPs of other nodes in the same cluster (not including yourself) + # ! Please note: + # ! do not include the current configuration's node IP + # members = [ + # # "ip", + # # "ip" + # ] } -} -node { - # trust node for solidity node + # * This section is used to shutdown the node in specific conditions + shutdown { + # BlockTime = "54 59 08 * * ?" # * When the Block Timestamp matches the pattern (Cron format) + # BlockHeight = 33350800 # * When the Block Height (Block Number) matches the value + # BlockCount = 12 # * When the block sync count after the node has started is matched + } + + # * trustNode is used by a Solidity Node (or light node) to designate which FullNode it "trusts" + # * to fetch confirmed (or "solidified") blocks. + # ! Please note: + # ! this is used when another node (which is a Solidity Node or a Lite Full Node) connects + # ! to a Full Node (to query data from the blockchain), + # ! since neither the Solidity Node nor the Lite Full Node store the network history (blockchain). # trustNode = "ip:port" - trustNode = "127.0.0.1:50051" + # trustNode = "127.0.0.1:50051" - # expose extension api to public or not + # * Enable extra wallet extended API interface walletExtensionApi = true + # * Defines the TCP port on which your node listens for incoming peer-to-peer (P2P) + # * connections from other nodes in the network (Full Nodes, Solidity Nodes, SRs) + # * This value can be the same for every node in the network, since it refers to different nodes anyway. + # ! Please note: + # ! this is not the port where HTTP, rpc or grpc API listen on listen.port = 18888 - connection.timeout = 2 + # * Max time to wait when connecting to a peer + connection.timeout = 5 # * seconds - fetchBlock.timeout = 200 - # syncFetchBatchNum = 2000 + # * Max time to wait for a block response from a peer + fetchBlock.timeout = 200 # * seconds - # Number of validate sign thread, default availableProcessors - # validateSignThreadNum = 16 + # * These define how many network IO threads are used by the Netty framework + # * 0: auto, based on CPU cores + # ! Please note: + # ! only change if you're optimizing very high-performance nodes. + tcpNettyWorkThreadNum = 0 + udpNettyWorkThreadNum = 1 + # * Maximum total peer-to-peer connections your node will maintain (both inbound and outbound), + # * without any distinction between node type + # * Pro tip: adjust accordingly based on the number of peers in the private network maxConnections = 30 + + # * This is the lower threshold of peer connections the node tries to keep alive. + # * If the active peers drop below minConnections, + # * the node will try to open new outbound connections to reachable peers (via discovery or seed) + # * to bring itself back up. + # ! Please note: + # ! it ensures the node doesn't stay isolated with too few peers. + # * Pro tip: adjust accordingly based on the number of peers in the private network, + # * to avoid that the node will search for nodes for an undefinitely amount of time + minConnections = 2 + + # * Number of peers that must be active to sync data + # * This the minimum number of active peers required for the node to start or continue data synchronization + # * (block downloads, network sync). + # * "Active" means peers that are fully connected and exchanging data, not just idle or handshake-only. + # * If the number of active peers falls below this threshold, + # * the node may temporarily stall or refuse to sync until enough peers are back online. + # * If you set minActiveConnections = 3, + # * then unless the node has at least 3 fully active peers, it might not perform block sync. + # * Pro tip: adjust accordingly based on the number of peers in the private network, + # * to avoid that the node will perform data synchronization + minActiveConnections = 2 + + # * This parameter sets the number of threads dedicated to signature validation / signing operations + # * (for verifying incoming transactions or blocks). + # ! Please note: + # ! adjust accordingly by using this formula + # ! validateSignThreadNum = availableProcessors / 2 + # validateSignThreadNum = 16 - minConnections = 8 - - minActiveConnections = 3 - + # * Prevents DDoS / redundant connections maxConnectionsWithSameIp = 2 + # * Maximum number of concurrent HTTP API connections your node will handle maxHttpConnectNumber = 50 - minParticipationRate = 15 - - # allowShieldedTransactionApi = true - - # openPrintLog = true - - # If set to true, SR packs transactions into a block in descending order of fee; otherwise, it packs - # them based on their receive timestamp. Default: false - # openTransactionSort = false - - # The threshold for the number of broadcast transactions received from each peer every second, - # transactions exceeding this threshold will be discarded - # maxTps = 1000 - + # * Minimum required block participation rate (%) to remain active. + # ! Please note: + # ! applies to Super Representatives only. + # * If your SR fails to produce enough blocks, it may be penalized. + # * This parameter defines the minimum required participation rate of Super Representatives (SRs) + # * during block production. + # * In other words, how many SRs must actually produce blocks during an Epoch + # * (6 hour by default, dictated by the value of maintenanceTimeInterval parameter in this config file). + # * So, for example, if there are 5 SRs, and the minParticipationRate is 15 (%), + # * then at least (0.75, rounded up to the nearest integer) 1 SR must produce blocks in a round. + # * A "round" is a time range during which all network SRs can produce a block in their slot. + # * In case they fail, rewards will not be shared between them. + # * It's mainly used in Super Representative consensus logic - not configurable elsewhere. + # * It ensures the network stays stable and avoids finalizing rounds with too few active producers. + # ! Please note: + # ! set this parameter to 0 to disable the check + minParticipationRate = 15 # * percentage + + # * When true, this setting might enable full TCP disconnect logic + # * for peers under certain conditions (e.g. poor performance). + # * When false (default), the node retains more leniency in connection persistence. + # * It's a kind of fail-safe/disconnect policy for TCP connections; + # * unless you're debugging connectivity you can leave it false. isOpenFullTcpDisconnect = false - inactiveThreshold = 600 //seconds + # * This is a time threshold (in seconds) after which a peer is considered inactive if no communication. + # * If a peer hasn't sent or responded in more than inactiveThreshold, the node may drop it or mark it unhealthy. + inactiveThreshold = 600 # * seconds + + # * Defines protocol version to communicate with other peers + # * Possible values: + # * - 11111: mainnet + # * - 20180622: testnet + # * - user defined value (integer) + # ! Please note: + # ! for private networks use your own, + # ! and keep it consistent between ALL the private network peers. + # ! Depending on the type of network that you are trying to create/join, + # ! you might want to comment out this parameter. + # ! For example, a Solidity Node should not have this value filled, + # ! since it doesn't participate to peer-to-peer communication, + # ! but it's using the Full Node (through the "trustNode" parameter) to interact in the network. p2p { - version = 11111 # Mainnet:11111; Nile:201910292; Shasta:1 + version = 11111 } + # * These are static peer lists: + # * - active -> peer addresses to which the node actively attempts connection (outbound). + # * - passive -> peer addresses from which the node accepts inbound connections (or those expected to connect to you). + # * If left empty, node discovers peers dynamically via discovery/seeds. + # * Use these if you want to pinpoint specific peers rather than rely entirely on discovery. active = [ - # Active establish connection in any case - # Sample entries: - # "ip:port", - # "ip:port" + # * Active establish connection in any case + # * Sample entries: + # * "ip:port", + # * "ip:port" ] passive = [ - # Passive accept connection in any case - # Sample entries: - # "ip:port", - # "ip:port" + # * Passive accept connection in any case + # * Sample entries: + # * "ip:port", + # * "ip:port" ] + # * fastForward is a list of trusted peers for fast sync (early block download). + # * Since the block production is a "long" process (production -> propagation -> finalization), + # * using fastForward nodes can speed up the process. + # * If left empty, the node just uses its normal peer list/discovery - slower but works. + # * With entries, when starting, the node prioritizes connecting to these peers to accelerate synchronization. fastForward = [ - "100.27.171.62:18888", - "15.188.6.125:18888" ] + # * This section includes the following configurations: + # * - FullNode + # * - SolidityNode + # * - PBFT + # * In detail: + # * - FullNode: provides full blockchain data + APIs + can produce blocks (if SR). + # * - SolidityNode: **historically** a separate component optimized for contract-state queries and light reads. + # * If you want efficient contract access (especially for dApps), having a Solidity Node helps. + # * But in modern Java-Tron, FullNode already supports solidity data queries, so you may not strictly need a separate SolidityNode. + # * - PBFT: stands for Practical Byzantine Fault Tolerance - the consensus mechanism layer. + # * The HTTP / PBFT port settings allow APIs to interact with PBFT modules (e.g. proposals, votes). + # * If you're doing smart contracts and blockchain operations, you should enable FullNode's HTTP and RPC; + # * a separate SolidityNode is optional unless performance demands it. http { - fullNodeEnable = true + fullNodeEnable = false # ! Please note: + # ! this should be disabled on a SR fullNodePort = 8090 - solidityEnable = true + solidityEnable = false # ! Please note: + # ! this should be disabled on a SR. + # ! Additionally, depending on the type of network you are trying to create/join, + # ! you might want to use a different host for the Solidity Node. + # ! Anyway, there are no rules that deny to use a Full Node AND a Solidity Node + # ! on the same host. solidityPort = 8091 - PBFTEnable = true + PBFTEnable = true # * Practical Byzantine Fault Tolerance (consensus mechanism) + # ! Please note: + # ! this option should be disabled on every node except for SRs. + # ! IS IT IMPORTANT to understand that this option should be enabled + # ! on ALL network SRs if enable at least on one, + # ! or disabled on ALL network SRs if disabled at least on one. PBFTPort = 8092 } + # * Leave it false unless your host uses IPv6 only for node discovery and TCP connection + enableIpv6 = false + + # * If enabled, node automatically checks if it's lagging behind peers, and tries to reconnect if needed + # ! Please note: + # ! can help maintain sync, but may cause frequent reconnections on unstable networks + effectiveCheckEnable = false + + # * treeUrls is a list of DNS-based bootstrap peers in "tree://" format, including public domain and key info. + # * The node will use DNS to discover peers using these URLs. + # * If left empty, peer discovery relies solely on seed.node and active/passive lists. + dns { + # * URL format tree://{pubkey}@{domain}, default empty + treeUrls = [ + # "tree://AKMQMNAJJBL73LXWPXDI4I5ZWWIZ4AWO34DWQ636QOBBXNFXH3LQS@main.trondisco.net", + ] + } + + # * Configures gRPC APIs (used by tronWeb, TronLink) rpc { - enable = true + enable = false # ! Please note: + # ! this should be disabled on a SR port = 50051 - solidityEnable = true + solidityEnable = false # ! Please note: + # ! this should be disabled on a SR. + # ! Additionally, depending on the type of network you are trying to create/join, + # ! you might want to use a different host for the Solidity Node. + # ! Anyway, there are no rules that deny to use a Full Node AND a Solidity Node + # ! on the same host. solidityPort = 50061 - PBFTEnable = true + PBFTEnable = true # * Practical Byzantine Fault Tolerance (consensus mechanism) + # ! Please note: + # ! this option should be disabled on every node except for SRs. + # ! IS IT IMPORTANT to understand that this option should be enabled + # ! on ALL network SRs if enable at least on one, + # ! or disabled on ALL network SRs if disabled at least on one. PBFTPort = 50071 - - # Number of gRPC thread, default availableProcessors / 2 + + # * Number of gRPC thread, default availableProcessors / 2 # thread = 16 - # The maximum number of concurrent calls permitted for each incoming connection + # * The maximum number of concurrent calls permitted for each incoming connection + # * Helps throttle misuse. # maxConcurrentCallsPerConnection = - # The HTTP/2 flow control window, default 1MB - # flowControlWindow = + # * The HTTP/2 flow control window + # * If left commented, the default value is 1MB + # * This parameter is used in the gRPC networking layer - it defines how much data (in bytes) can be "in flight" + # * (unacknowledged) over a gRPC connection between nodes. + # * It prevents one node from overwhelming another with too many messages. + # * It's essentially a backpressure mechanism, similar to TCP's sliding window. + # flowControlWindow = - # Connection being idle for longer than which will be gracefully terminated - maxConnectionIdleInMillis = 60000 + # * Closes idle gRPC connections after n milliseconds + # * Connection being idle for longer than which will be gracefully terminated + maxConnectionIdleInMillis = 60000 # * milliseconds - # Connection lasting longer than which will be gracefully terminated + # * Connection lasting longer than which will be gracefully terminated # maxConnectionAgeInMillis = - # The maximum message size allowed to be received on the server, default 4MB + # * The maximum message size allowed to be received on the server + # * If left commented, the default value is 4MB # maxMessageSize = - # The maximum size of header list allowed to be received, default 8192 + # * The maximum size of header list allowed to be received + # * If left commented, the default value is 8192 # maxHeaderListSize = - # The number of RST_STREAM frames allowed to be sent per connection per period for grpc, by default there is no limit. - # maxRstStream = - - # The number of seconds per period for grpc - # secondsPerWindow = - - # Transactions can only be broadcast if the number of effective connections is reached. + # * How many peer connections are needed before allowing broadcast. + # * Please note: transactions can only be broadcasted if the number of effective connections is reached. minEffectiveConnection = 1 - # The switch of the reflection service, effective for all gRPC services, used for grpcurl tool. Default: false - reflectionService = false + # * The switch of the reflection service, effective for all gRPC services + # * toggles gRPC reflection (metadata introspection), + # * useful for clients/tools to inspect services dynamically. + # reflectionService = true } - # number of solidity thread in the FullNode. - # If accessing solidity rpc and http interface timeout, could increase the number of threads, - # The default value is the number of cpu cores of the machine. + # * Number of worker threads handling Solidity (read-only) queries like contract state lookups. + # * If you see timeouts, increase it to match your CPU cores. + # * Even on an SR or block-producing FullNode, + # * if the node also handles contract queries (i.e. acts as Solidity provider), this setting is relevant. + # * If your node doesn't run a separate Solidity module, + # * this may still be used internally by the FullNode's contract query layer. # solidity.threads = 8 - # Limits the maximum percentage (default 75%) of producing block interval - # to provide sufficient time to perform other operations e.g. broadcast block + # * Maximum allowed percentage of block time used to produce a block. + # * Default 75% → ensures block is produced and broadcast before the next SR's turn. + # * It means that the timeout is fired after the threshold of 0,25 seconds (for this case) is overtook + # * to produce a block + # * 75% of a block time (or a slot), which is 3 seconds, so (75 * 3) / 100 = 0,25 seconds # blockProducedTimeOut = 75 - # Limits the maximum number (default 700) of transaction from network layer + # * Rate limit for incoming transactions per second from network peers # netMaxTrxPerSecond = 700 - # Whether to enable the node detection function. Default: false - # nodeDetectEnable = false - - # use your ipv6 address for node discovery and tcp connection. Default: false - # enableIpv6 = false - - # if your node's highest block num is below than all your pees', try to acquire new connection. Default: false - # effectiveCheckEnable = false - - # Dynamic loading configuration function, disabled by default - dynamicConfig = { - # enable = false - # checkInterval = 600 // Check interval of Configuration file's change, default is 600 seconds - } - - # Whether to continue broadcast transactions after at least maxUnsolidifiedBlocks are not solidified. Default: false - # unsolidifiedBlockCheck = false - # maxUnsolidifiedBlocks = 54 - - dns { - # dns urls to get nodes, url format tree://{pubkey}@{domain}, default empty - treeUrls = [ - #"tree://AKMQMNAJJBL73LXWPXDI4I5ZWWIZ4AWO34DWQ636QOBBXNFXH3LQS@main.trondisco.net", - ] - - # enable or disable dns publish. Default: false - # publish = false - - # dns domain to publish nodes, required if publish is true - # dnsDomain = "nodes1.example.org" - - # dns private key used to publish, required if publish is true, hex string of length 64 - # dnsPrivate = "b71c71a67e1177ad4e901695e1b4b9ee17ae16c6668d313eac2f96dbcda3f291" - - # known dns urls to publish if publish is true, url format tree://{pubkey}@{domain}, default empty - # knownUrls = [ - #"tree://APFGGTFOBVE2ZNAB3CSMNNX6RRK3ODIRLP2AA5U4YFAA6MSYZUYTQ@nodes2.example.org", - # ] - - # staticNodes = [ - # static nodes to published on dns - # Sample entries: - # "ip:port", - # "ip:port" - # ] - - # merge several nodes into a leaf of tree, should be 1~5 - # maxMergeSize = 5 - - # only nodes change percent is bigger then the threshold, we update data on dns - # changeThreshold = 0.1 - - # dns server to publish, required if publish is true, only aws or aliyun is support - # serverType = "aws" - - # access key id of aws or aliyun api, required if publish is true, string - # accessKeyId = "your-key-id" - - # access key secret of aws or aliyun api, required if publish is true, string - # accessKeySecret = "your-key-secret" - - # if publish is true and serverType is aliyun, it's endpoint of aws dns server, string - # aliyunDnsEndpoint = "alidns.aliyuncs.com" - - # if publish is true and serverType is aws, it's region of aws api, such as "eu-south-1", string - # awsRegion = "us-east-1" - - # if publish is true and server-type is aws, it's host zone id of aws's domain, string - # awsHostZoneId = "your-host-zone-id" - } - - # open the history query APIs(http&GRPC) when node is a lite FullNode, - # like {getBlockByNum, getBlockByID, getTransactionByID...}. Default: false. - # note: above APIs may return null even if blocks and transactions actually are on the blockchain - # when opening on a lite FullNode. only open it if the consequences being clearly known + # * Enables read APIs for block/transaction history when running a Lite Full Node (one that doesn't store full blockchain). + # * Leave false unless you explicitly run a lite node. # openHistoryQueryWhenLiteFN = false + # * This exposes Ethereum-compatible JSON-RPC APIs (like eth_getLogs). + # * If you want compatibility with tools like Web3.js, you can enable this. jsonrpc { - # Note: Before release_4.8.1, if you turn on jsonrpc and run it for a while and then turn it off, - # you will not be able to get the data from eth_getLogs for that period of time. Default: false - # httpFullNodeEnable = false + # * Note: If you turn on jsonrpc and run it for a while and then turn it off, you will not + # * be able to get the data from eth_getLogs for that period of time. + + # httpFullNodeEnable = true # httpFullNodePort = 8545 - # httpSolidityEnable = false + # httpSolidityEnable = true # httpSolidityPort = 8555 - # httpPBFTEnable = false + # httpPBFTEnable = true # httpPBFTPort = 8565 - # The maximum blocks range to retrieve logs for eth_getLogs, default value is 5000, - # should be > 0, otherwise means no limit. - maxBlockRange = 5000 + # * The maximum blocks range to retrieve logs for eth_getLogs, default value is 5000, + # * should be > 0, otherwise means no limit. + # maxBlockRange = 5000 - # The maximum number of allowed topics within a topic criteria, default value is 1000, - # should be > 0, otherwise means no limit. - maxSubTopics = 1000 - # Allowed maximum number for blockFilter - maxBlockFilterNum = 50000 + # * The maximum number of allowed topics within a topic criteria, default value is 1000, + # * should be > 0, otherwise means no limit. + # maxSubTopics = 1000 } - # Disabled api list, it will work for http, rpc and pbft, both FullNode and SolidityNode, - # but not jsonrpc. The setting is case insensitive, GetNowBlock2 is equal to getnowblock2 - disabledApi = [ - # "getaccount", - # "getnowblock2" - ] + # * Disabled api list, it will work for http, rpc and pbft, both fullnode and soliditynode, + # * but not for jsonrpc. + # ! Please note: + # ! the setting is case insensitive, GetNowBlock2 is equal to getnowblock2 + # disabledApi = [ + # "getaccount", + # "getnowblock2" + # ] } - -## rate limiter config +# * ----------------------------------------- RATE.LIMITER ---------------------------------------- +# * Controls API rate limiting rate.limiter = { - # Every api could only set a specific rate limit strategy. Three blocking strategy are supported: - # GlobalPreemptibleAdapter: The number of preemptible resource or maximum concurrent requests globally. - # QpsRateLimiterAdapter: qps is the average request count in one second supported by the server, it could be a Double or a Integer. - # IPQPSRateLimiterAdapter: similar to the QpsRateLimiterAdapter, qps could be a Double or a Integer. - # If not set, QpsRateLimiterAdapter with qps=1000 is the default strategy. - # - # Sample entries: - # + # * Every api could be set a specific rate limit strategy. + # * A number of three strategies are supported: + # * - GlobalPreemptibleAdapter -> limits total concurrent requests + # * - QpsRateLimiterAdapter -> limits total QPS (queries/sec) + # * - IPQPSRateLimiterAdapter -> limits per-IP QPS + # ! Please note: + # ! if not set, the default strategy is QpsRateLimiterAdapter, with 10,000 QPS. http = [ # { # component = "GetNowBlockServlet", # strategy = "GlobalPreemptibleAdapter", # paramString = "permit=1" # }, - # { # component = "GetAccountServlet", # strategy = "IPQPSRateLimiterAdapter", # paramString = "qps=1" # }, - # { # component = "ListWitnessesServlet", # strategy = "QpsRateLimiterAdapter", @@ -435,403 +600,444 @@ rate.limiter = { # paramString = "qps=1" # }, ] - - p2p = { - # syncBlockChain = 3.0 - # fetchInvData = 3.0 - # disconnect = 1.0 - } - - # global qps, default 50000 - global.qps = 50000 - # IP-based global qps, default 10000 - global.ip.qps = 10000 } - - - +# * ------------------------------------------ SEED.NODE ------------------------------------------ +# ! Please note: +# ! in private networks, you should list the IP and port of your +# ! Super Representatives (SRs) and/or Full Nodes here. +# ! These act as initial peers ("bootstrap nodes") that other nodes +# ! will connect to when starting up, to discover the rest of the network. +# ! Do NOT include the address and port of the current node itself. +# * These are the peers the node initially connects to (bootstrap nodes). seed.node = { - # List of the seed nodes - # Seed nodes are stable full nodes - # example: + # * Example: # ip.list = [ # "ip:port", # "ip:port" # ] ip.list = [ - "3.225.171.164:18888", - "52.8.46.215:18888", - "3.79.71.167:18888", - "108.128.110.16:18888", - "18.133.82.227:18888", - "35.180.81.133:18888", - "13.210.151.5:18888", - "18.231.27.82:18888", - "3.12.212.122:18888", - "52.24.128.7:18888", - "15.207.144.3:18888", - "3.39.38.55:18888", - "54.151.226.240:18888", - "35.174.93.198:18888", - "18.210.241.149:18888", - "54.177.115.127:18888", - "54.254.131.82:18888", - "18.167.171.167:18888", - "54.167.11.177:18888", - "35.74.7.196:18888", - "52.196.244.176:18888", - "54.248.129.19:18888", - "43.198.142.160:18888", - "3.0.214.7:18888", - "54.153.59.116:18888", - "54.153.94.160:18888", - "54.82.161.39:18888", - "54.179.207.68:18888", - "18.142.82.44:18888", - "18.163.230.203:18888", - # "[2a05:d014:1f2f:2600:1b15:921:d60b:4c60]:18888", // use this if support ipv6 - # "[2600:1f18:7260:f400:8947:ebf3:78a0:282b]:18888", // use this if support ipv6 ] } - +# * ---------------------------------------- GENESIS.BLOCK ---------------------------------------- +# * This defines the initial blockchain state (balances and witnesses). +# ! Please note: +# ! the genesis block MUST BE the same for all the nodes in the network, +# ! either they are SRs or Full Nodes. +# ! This ensure a consistent and identical genesis block across the whole network, +# ! otherwise it would reject all blocks as invalid (INCOMPATIBLE_CHAIN error). genesis.block = { - # Reserve balance + # * Reserve initial balances assets = [ + # * Initial supply holder address { accountName = "Zion" accountType = "AssetIssue" address = "TLLM21wteSPs4hKjbxgmH1L6poyMjeTbHm" balance = "99000000000000000" }, + # * TRON founder address { accountName = "Sun" accountType = "AssetIssue" address = "TXmVpin5vq5gdZsciyyjdZgKRUju4st1wM" balance = "0" }, + # * Burn address + # ! Please note: + # ! only the Blackhole is mandatory for internal consistency + # * The blackhole address is a designated burn address in TRON. + # * It's used internally for reward deductions, fee burns, or traps. + # * Even in a private chain, you should define a blackhole address so that + # * TRON's internal accounting logic (e.g. deductions, fees) doesn't break. { accountName = "Blackhole" accountType = "AssetIssue" address = "TLsV52sRDL79HXGGm9yzwKibb6BeruhUzy" balance = "-9223372036854775808" } + # ! Please note: + # ! the SR information must be set here when configuring a SR node + # { + # accountName = "SR" + # accountType = "AssetIssue" + # address = "base58-SR-address" + # balance = "1000000000000000000" # * SUN -> 1 TRX = 1,000,000 SUN, so that quantity is 1,000,000,000,000 TRX + # } ] + # * These are the initial Super Representatives (SRs) at genesis. + # * Each has: + # * address -> SR account + # * url -> optional info page + # * voteCount -> initial votes (defines ranking order) and block generation order + # ! Please note: + # ! the more the votes, the better for the SR witnesses = [ { - address: THKJYuUmMKKARNf7s2VT51g5uPY6KEqnat, - url = "http://GR1.com", - voteCount = 100000026 - }, - { - address: TVDmPWGYxgi5DNeW8hXrzrhY8Y6zgxPNg4, - url = "http://GR2.com", - voteCount = 100000025 - }, - { - address: TWKZN1JJPFydd5rMgMCV5aZTSiwmoksSZv, - url = "http://GR3.com", - voteCount = 100000024 - }, - { - address: TDarXEG2rAD57oa7JTK785Yb2Et32UzY32, - url = "http://GR4.com", - voteCount = 100000023 - }, - { - address: TAmFfS4Tmm8yKeoqZN8x51ASwdQBdnVizt, - url = "http://GR5.com", - voteCount = 100000022 - }, - { - address: TK6V5Pw2UWQWpySnZyCDZaAvu1y48oRgXN, - url = "http://GR6.com", - voteCount = 100000021 - }, - { - address: TGqFJPFiEqdZx52ZR4QcKHz4Zr3QXA24VL, - url = "http://GR7.com", - voteCount = 100000020 - }, - { - address: TC1ZCj9Ne3j5v3TLx5ZCDLD55MU9g3XqQW, - url = "http://GR8.com", - voteCount = 100000019 - }, - { - address: TWm3id3mrQ42guf7c4oVpYExyTYnEGy3JL, - url = "http://GR9.com", - voteCount = 100000018 - }, - { - address: TCvwc3FV3ssq2rD82rMmjhT4PVXYTsFcKV, - url = "http://GR10.com", - voteCount = 100000017 - }, - { - address: TFuC2Qge4GxA2U9abKxk1pw3YZvGM5XRir, - url = "http://GR11.com", - voteCount = 100000016 - }, - { - address: TNGoca1VHC6Y5Jd2B1VFpFEhizVk92Rz85, - url = "http://GR12.com", - voteCount = 100000015 - }, - { - address: TLCjmH6SqGK8twZ9XrBDWpBbfyvEXihhNS, - url = "http://GR13.com", - voteCount = 100000014 - }, - { - address: TEEzguTtCihbRPfjf1CvW8Euxz1kKuvtR9, - url = "http://GR14.com", - voteCount = 100000013 - }, - { - address: TZHvwiw9cehbMxrtTbmAexm9oPo4eFFvLS, - url = "http://GR15.com", - voteCount = 100000012 - }, - { - address: TGK6iAKgBmHeQyp5hn3imB71EDnFPkXiPR, - url = "http://GR16.com", - voteCount = 100000011 - }, - { - address: TLaqfGrxZ3dykAFps7M2B4gETTX1yixPgN, - url = "http://GR17.com", - voteCount = 100000010 - }, - { - address: TX3ZceVew6yLC5hWTXnjrUFtiFfUDGKGty, - url = "http://GR18.com", - voteCount = 100000009 - }, - { - address: TYednHaV9zXpnPchSywVpnseQxY9Pxw4do, - url = "http://GR19.com", - voteCount = 100000008 - }, - { - address: TCf5cqLffPccEY7hcsabiFnMfdipfyryvr, - url = "http://GR20.com", - voteCount = 100000007 - }, - { - address: TAa14iLEKPAetX49mzaxZmH6saRxcX7dT5, - url = "http://GR21.com", - voteCount = 100000006 - }, - { - address: TBYsHxDmFaRmfCF3jZNmgeJE8sDnTNKHbz, - url = "http://GR22.com", - voteCount = 100000005 - }, - { - address: TEVAq8dmSQyTYK7uP1ZnZpa6MBVR83GsV6, - url = "http://GR23.com", - voteCount = 100000004 - }, - { - address: TRKJzrZxN34YyB8aBqqPDt7g4fv6sieemz, - url = "http://GR24.com", - voteCount = 100000003 - }, - { - address: TRMP6SKeFUt5NtMLzJv8kdpYuHRnEGjGfe, - url = "http://GR25.com", - voteCount = 100000002 - }, - { - address: TDbNE1VajxjpgM5p7FyGNDASt3UVoFbiD3, - url = "http://GR26.com", - voteCount = 100000001 - }, - { - address: TLTDZBcPoJ8tZ6TTEeEqEvwYFk2wgotSfD, - url = "http://GR27.com", - voteCount = 100000000 + address = "THKJYuUmMKKARNf7s2VT51g5uPY6KEqnat" + url = "http://SR-INFO-PAGE-URL.com" + voteCount = 1000000000000000 } ] - timestamp = "0" # Genesis block timestamp, milli seconds + # * Genesis block timestamp + timestamp = "0" + # * Always "0x0" (64 characters long) for the genesis block, but TRON uses a placeholder for backward compatibility. + # * Safe to keep as is. parentHash = "0xe58f33f9baf9305dc6f82b9f1934ea8f0ade2defb951258d50167028c780351f" } - -# Optional. The default is empty. It is used when the witness account has set the witnessPermission. -# When it is not empty, the localWitnessAccountAddress represents the address of the witness account, -# and the localwitness is configured with the private key of the witnessPermissionAddress in the witness account. -# When it is empty,the localwitness is configured with the private key of the witness account. -# localWitnessAccountAddress = - +# * ---------------------------------- LOCALWITNESSACCOUNTADDRESS --------------------------------- +# * "Witness permissions" refer to a mechanism where a SR can delegate block production permission to another account. +# * If localWitnessAccountAddress is set, that means the node may use a permissioned address +# * to produce blocks instead of the SR's primary account. +# * It allows flexibility in permission models (e.g. key rotation or proxy delegation). +# * If you leave that blank, the node uses the private key addresses +# * in localwitness directly (SR account itself) for signing. +# * It is used when the witness account has set the witnessPermission. +# localWitnessAccountAddress = "" +# * ----------------------------------------- LOCALWITNESS ---------------------------------------- +# * List of private keys for SR accounts used to sign blocks +# ! Please note: +# ! required if your node participates as an SR (block producer) localwitness = [ ] - +# * ------------------------------------- LOCALWITNESSKEYSTORE ------------------------------------ +# * This configuration is used when a localwitness address is stored in a JSON file +# ! Please note: +# ! localwitness and localwitnesskeystore are mutually exclusive +# ? Ref: https://developers.tron.network/docs/deploy-the-fullnode-or-supernode#how-to-use-keystore--password-to-specify-the-private-key-of-the-super-representative-accounts # localwitnesskeystore = [ # "localwitnesskeystore.json" # ] - +# * -------------------------------------------- BLOCK -------------------------------------------- +# * Block configuration: +# * - block.needSyncCheck: controls whether the node performs synchronization checks when receiving +# * or producing new blocks. +# * If you disable it, the node may accept or broadcast blocks even if it's not fully synced, +# * which can lead to forks or inconsistencies in your private network. +# ! Please note: +# ! in a private network, set: +# ! - one SR with this parameter to false +# ! - all other SRs and Full Nodes to true +# ! This ensures that there is only one source of truth for block data. +# ! Additionally, when you create a brand new private chain, there's a moment where: +# ! - the blockchain is empty (only genesis block exists); +# ! - there are no other nodes to sync from yet; +# ! The first SR must produce the very first block(s) to bootstrap the chain. +# ! If needSyncCheck = true on that first SR, it will try to check peers' height, +# ! and since it finds no peers (everyone's empty), it assumes it's out of sync and refuses to produce blocks. +# * - block.maintenanceTimeInterval: time interval during which SRs generate blocks +# * - block.proposalExpireTime: time interval after which a proposal (to change a network parameter) expires block = { - needSyncCheck = true - maintenanceTimeInterval = 21600000 // 6 hours: 21600000(ms) - proposalExpireTime = 259200000 // default value: 3 days: 259200000(ms), Note: this value is controlled by committee proposal - # checkFrozenTime = 1 // for test only + needSyncCheck = true # * default: true + # ! Please note: + # ! maintenanceTimeInterval and proposalExpireTime take effect just when the node is a SR! + maintenanceTimeInterval = 21600000 # * default: 21600000, in milliseconds (6 hours -> Epoch) + proposalExpireTime = 259200000 # * default: 259200000, in milliseconds (3 days) } - -# Transaction reference block, default is "solid", configure to "head" may cause TaPos error -trx.reference.block = "solid" // "head" or "solid" - -# This property sets the number of milliseconds after the creation of the transaction that is expired, default value is 60000. -# trx.expiration.timeInMilliseconds = 60000 - +# * --------------------------------------------- TRX --------------------------------------------- +trx { + # * This setting determines whether transactions must reference a specific recent block when being created. + # * It's a security and replay protection feature. + # * If enabled, each transaction must include: + # * - ref_block_bytes + # * - ref_block_hash + # * These refer to a recent block (e.g., the latest 1–2 minutes old). + # * This ensures that: + # * - transactions cannot be replayed long after being broadcast + # * - nodes know the context for validation + # * It's similar to Ethereum's nonce + blockHash consistency mechanism. + # * If disabled, the node might accept transactions referencing older blocks, which is not recommended. + # * Accepted values: + # * - solid (reccomended) + # * - head (may cause TaPos error) + reference.block = "solid" + + # * Transaction expiration time + expiration.timeInMilliseconds = 60000 # * default: 60000, in milliseconds (1 minute) +} +# * ---------------------------------------------- VM --------------------------------------------- +# * This section configures execution environment for smart contracts vm = { - supportConstant = false - maxEnergyLimitForConstant = 100000000 - minTimeRatio = 0.0 - maxTimeRatio = 5.0 - saveInternalTx = false - # lruCacheSize = 500 - # vmTrace = false - - # Indicates whether the node stores featured internal transactions, such as freeze, vote and so on. Default: false. - # saveFeaturedInternalTx = false - - # Indicates whether the node stores the details of the internal transactions generated by the CANCELALLUNFREEZEV2 opcode, - # such as bandwidth/energy/tronpower cancel amount. Default: false. - # saveCancelAllUnfreezeV2Details = false - - # In rare cases, transactions that will be within the specified maximum execution time (default 10(ms)) are re-executed and packaged - # longRunningTime = 10 - - # Indicates whether the node support estimate energy API. Default: false. - # estimateEnergy = false - - # Indicates the max retry time for executing transaction in estimating energy. Default 3. - # estimateEnergyMaxRetry = 3 + supportConstant = true # * Whether constant / pure view methods calls are supported (enabled) + # ! Please note: + # ! it should be configured only for Full Nodes, not SRs. + maxEnergyLimitForConstant = 100000000 # * Energy limit for constant calls (in SUN, and since 1 TRX = 1,000,000 SUN, so 100 TRX) + # ! Please note: + # ! pure/view functions are gas free, + # ! but they need Energy (computation) to be executed. + # ! It's a safety measure to avoid DoS (Denial of Service), + # ! due to the high volume of computation required + minTimeRatio = 0.0 # * Relative bounds on execution time scaling + maxTimeRatio = 5.0 + saveInternalTx = false # * Whether to persist internal transactions (calls within contracts), + # * when a contract calls another contract's method and emit a transaction. + # saveFeaturedInternalTx = false # * Indicates whether the node stores featured internal transactions, + # * such as freeze, vote and so on + # saveCancelAllUnfreezeV2Details = false # * Indicates whether the node stores the details of the internal + # * transactions generated by the CANCELALLUNFREEZEV2 opcode, + # * such as bandwidth/energy/tronpower cancel amount. + # longRunningTime = 10 # * In rare cases, transactions that will be within the specified + # * maximum execution time (default 10(ms)) are re-executed and packaged + # estimateEnergy = false # * Indicates whether the node support estimate energy API. + # estimateEnergyMaxRetry = 3 # * Indicates the max retry time for executing transaction in estimating energy. } - -# These parameters are designed for private chain testing only and cannot be freely switched on or off in production systems. +# * ------------------------------------------ COMMITTEE ------------------------------------------ +# * The Committee is a governance component of the TRON protocol. +# * It's not a node or a machine. +# * It's a logical group formed by the top 27 Super Representatives (SRs) the ones elected by TRX holders. +# * The Committee votes on network parameters, such as: +# * - block size +# * - energy limit +# * - proposal thresholds +# * - transaction fees +# * - resource model updates +# * These parameters are stored in the Chain Parameters on-chain. +# * When you run a private TRON network, the Committee still exists, but since you control all SRs, +# * it's effectively you (your SR nodes) who make up the Committee. +# * You can change parameters via proposals (API: /wallet/proposalcreate). +# ! Please note: +# ! keep this section equal for every node in the network. +# * ------------------------------------------ COMMITTEE ------------------------------------------ +# * The Committee is a governance component of the TRON protocol. +# * It's not a node or a machine. +# * It's a logical group formed by the top 27 Super Representatives (SRs) the ones elected by TRX holders. +# * The Committee votes on network parameters, such as: +# * - block size +# * - energy limit +# * - proposal thresholds +# * - transaction fees +# * - resource model updates +# * These parameters are stored in the Chain Parameters on-chain. +# * When you run a private TRON network, the Committee still exists, but since you control all SRs, +# * it's effectively you (your SR nodes) who make up the Committee. +# * You can change parameters via proposals (API: /wallet/proposalcreate). +# ! Please note: +# ! keep this section equal for every node in the network. +# ? Ref: https://github.com/tronprotocol/java-tron/blob/develop/framework/src/main/java/org/tron/core/config/args/Args.java committee = { - allowCreationOfContracts = 0 //mainnet:0 (reset by committee),test:1 - allowAdaptiveEnergy = 0 //mainnet:0 (reset by committee),test:1 - # allowCreationOfContracts = 0 - # allowMultiSign = 0 - # allowAdaptiveEnergy = 0 - # allowDelegateResource = 0 - # allowSameTokenName = 0 - # allowTvmTransferTrc10 = 0 - # allowTvmConstantinople = 0 - # allowTvmSolidity059 = 0 - # forbidTransferToContract = 0 - # allowShieldedTRC20Transaction = 0 - # allowTvmIstanbul = 0 - # allowMarketTransaction = 0 - # allowProtoFilterNum = 0 - # allowAccountStateRoot = 0 - # changedDelegation = 0 - # allowPBFT = 0 - # pBFTExpireNum = 0 - # allowTransactionFeePool = 0 - # allowBlackHoleOptimization = 0 - # allowNewResourceModel = 0 - # allowReceiptsMerkleRoot = 0 - # allowTvmFreeze = 0 - # allowTvmVote = 0 - # unfreezeDelayDays = 0 - # allowTvmLondon = 0 - # allowTvmCompatibleEvm = 0 - # allowNewRewardAlgorithm = 0 - # allowAccountAssetOptimization = 0 - # allowAssetOptimization = 0 - # allowNewReward = 0 - # memoFee = 0 - # allowDelegateOptimization = 0 - # allowDynamicEnergy = 0 - # dynamicEnergyThreshold = 0 - # dynamicEnergyMaxFactor = 0 - # allowTvmShangHai = 0 - # allowOldRewardOpt = 0 - # allowEnergyAdjustment = 0 - # allowStrictMath = 0 - # allowTvmCancun = 0 - # allowTvmBlob = 0 - # consensusLogicOptimization = 0 - # allowOptimizedReturnValueOfChainId = 0 + # ! Please note: + # ! you must enable this feature if you intend to deploy (and use) smart contracts + allowCreationOfContracts = 1 # Whether new contract deployment is allowed (0 = disallowed; 1 = allowed) + allowDynamicEnergy = 1 # Enables the dynamic energy system + # ! Please note: + # ! - this should be 0 on private blockchain, + # ! so the energy used when calling contracts is always the same + # ! - this value must match with the SRs' ones, + # ! or a different formula will be used to calculate the energy of a transaction, + # ! and it will result in a BAD_BLOCK error. + dynamicEnergyThreshold = 10000 # * Threshold value for triggering energy cost adjustments + dynamicEnergyIncreaseFactor = 2000 # * Increase factor for energy cost when threshold is exceeded + dynamicEnergyMaxFactor = 34000 # * Maximum allowed increase multiplier for energy cost + allowUpdateAccountName = 1 # * Allows users to change their account name after creation + allowSameTokenName = 1 # * Controls whether TRC-10 tokens can share the same name + allowDelegateResource = 1 # * Enables Resource Delegation -> the ability to delegate Bandwidth and Energy to another account + changedDelegation = 1 # * Enables newer version of delegation behavior introduced after certain network upgrades + allowDelegateOptimization = 1 # * Optimizes delegation logic for performance and reduced resource cost + allowTvmTransferTrc10 = 1 # * Allows TRC-10 token transfers from inside smart contracts executed by the TVM (Tron Virtual Machine) + allowMultiSign = 1 # * Enables multi-signature accounts on your chain + allowShieldedTRC20Transaction = 1 # * Enables ZK-SNARK based shielded (private) TRC20 transactions + allowOptimizeBlackHole = 1 # * Optimization for the "black hole" account (used when burning TRX) + allowTvmVote = 1 # * Enables smart contracts to participate in voting (via TVM) + allowTvmConstantinople = 1 # * Enables opcodes and logic from the Constantinople upgrade (e.g., CREATE2, EXTCODEHASH) + allowTvmSolidity059 = 1 # * Ensures full compatibility with Solidity 0.5.9+ compiled contracts + allowTvmIstanbul = 1 # * Enables Istanbul fork features (cheaper opcodes, better gas efficiency) + allowTvmLondon = 1 # * Adds EIP-1559-style changes and gas-related behavior updates + allowTvmShangHai = 1 # * Latest fork compatibility (Shanghai), enables new EVM behavior and improved gas metering + allowHigherLimitForMaxCpuTimeOfOneTx = 1 # * Increases CPU time limit for complex transactions (e.g., heavy smart contract execution) + allowAssetOptimization = 1 # * Enables optimized TRC10 asset management for performance + allowNewReward = 1 # * Uses new reward distribution logic for SRs + memoFee = 1000000 # * Fee (in SUN) for including a memo with a transaction + unfreezeDelayDays = 1 # * Number of days before frozen balance can be unfrozen again + # ! Please note: + # ! when this parameter is > 0, then ALLOW_TVM_FREEZE_V2 is going to be 1 (enabled) + allowOptimizedReturnValueOfChainId = 1 # * Optimizes the return value of the TVM CHAINID opcode + allowCancelAllUnfreezeV2 = 1 # * Enables the newer version (V2) of the "Cancel All Unfreeze" feature for resources + maxDelegateLockPeriod = 30 # * Maximum period (in days) for locking delegated resources + allowOldRewardOpt = 1 # * Keeps compatibility with old reward optimization behavior + allowEnergyAdjustment = 1 # * Allows dynamic adjustment of transaction energy consumption + allowStrictMath = 1 # * Forces strict arithmetic rules in TVM (no silent overflows/underflows) } - +# * --------------------------------------- EVENT.SUBSCRIBE --------------------------------------- +# * This section is used to register to blockchain events +# * For example, when a block is created, a transaction is verified, and many more +# ? Ref: https://developers.tron.network/docs/event-subscription event.subscribe = { + # * There are two ways to use the events subscription: + # * 1. using the Event Plugin (Kafka or MongoDB), which is the RECOMMENDED way + # * 2. using the native ZeroMQ + + # * Version of the event service framework: + # * - use the value of 1 for the V2.0 + # * - use the value of 0 for the V1.0 + version = 1 + + # * This is a new feature in v2.0 designed for historical data subscriptions. + # * It allows the service to start processing and pushing events from a specific historical block height (number) + # * stored on the local node. + # * When: + # * - startSyncBlockNum <= 0, this feature is disabled. + # * - startSyncBlockNum > 0, this feature is enabled, and historical event synchronization + # * will begin from the specified block height. Note: We recommend using the latest version + # * of the event plugin when enabling this feature. + startSyncBlockNum = 0 + + # * Settings to use (or not) the native event subscripiton plugin native = { - useNativeQueue = true // if true, use native message queue, else use event plugin. - bindport = 5555 // bind port - sendqueuelength = 1000 //max length of send queue + useNativeQueue = false # * true = use ZeroMQ queue; false = use Kafka or MongoDB + bindport = 5555 # * Port used by the ZeroMQ (native) queue + sendqueuelength = 1000 # * Max length of the send ZeroMQ queue } - version = 0 - # Specify the starting block number to sync historical events. This is only applicable when version = 1. - # After performing a full event sync, set this value to 0 or a negative number. - # startSyncBlockNum = 1 - - path = "" // absolute path of plugin - server = "" // target server address to receive event triggers - # dbname|username|password, if you want to create indexes for collections when the collections - # are not exist, you can add version and set it to 2, as dbname|username|password|version - # if you use version 2 and one collection not exists, it will create index automaticaly; - # if you use version 2 and one collection exists, it will not create index, you must create index manually; - dbconfig = "" + + # * The absolute local path to the plugin-(kafka/mongodb)-1.0.0.zip file. + # ! Please note: + # ! ensure the path is correct, or the plugin will fail to load. + path = "/event-plugin/build/plugins/plugin-mongodb-1.0.0.zip" + + # * The Kafka/MongoDB server address in ip:port format. + # * The default Kafka port is 9092. + # * The default MongoDB port is 27017. + # ! Please note: + # ! ensure the port number is correct and that the Kafka/MongoDB service is accessible. + server = "mongo:27017" + + # ! Please note: + # ! this option is only for the MongoDB plugin and should be ignored for the Kafka plugin. + # * Config as follow: dbname|username|password + dbconfig = "eventlog|tron|123456" + + # * Parse events emitted from smart contracts contractParse = true + + # * Configure the events to subscribe to. + # ? For more details, please refer to the Event Types section below: + # ? https://tronprotocol.github.io/documentation-en/architecture/event/#event-types + # ! Please note: + # ! for performance reasons, don't enable more than two topics. + # * Each topic allows the configuration of these parameters: + # * https://github.com/tronprotocol/java-tron/blob/master/common/src/main/java/org/tron/common/logsfilter/TriggerConfig.java topics = [ { - triggerName = "block" // block trigger, the value can't be modified - enable = false - topic = "block" // plugin topic, the value could be modified - solidified = false // if set true, just need solidified block. Default: false + triggerName = "transaction" # * (String) The event type identifier. + # * For transaction events, this value is fixed to transaction. + enable = true # * (Boolean) Enables or disables the subscription for this event type. + topic = "transaction" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log + # * for transactions included in solidified blocks. + ethCompatible = false # * (Boolean) If set to true, the event payload will include Ethereum-compatible + # * fields (e.g., transactionIndex, logList). + # ! Please note: + # ! this field is available just for the "transaction" trigger. + solidified = false # * (Boolean) If set to true, the subscription will only deliver events }, { - triggerName = "transaction" - enable = false - topic = "transaction" - solidified = false - ethCompatible = false // if set true, add transactionIndex, cumulativeEnergyUsed, preCumulativeLogCount, logList, energyUnitPrice. Default: false + triggerName = "block" # * (String) The event type identifier. + # * For block events, this value is fixed to block. + enable = false # * (Boolean) Enables or disables the subscription for this event type. + topic = "block" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log + solidified = false # * (Boolean) If set to true, the subscription will only deliver events + # * for transactions included in solidified blocks. }, { - triggerName = "contractevent" // contractevent represents contractlog data decoded by the ABI. - enable = false - topic = "contractevent" + triggerName = "contractevent" # * (String) The event type identifier. + # * Subscribes to all contract events from all blocks. + enable = true # * (Boolean) Enables or disables the subscription for this event type. + topic = "contractevent" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log + solidified = false # * (Boolean) If set to true, the subscription will only deliver events + # * for transactions included in solidified blocks. }, { - triggerName = "contractlog" - enable = false - topic = "contractlog" - redundancy = false // if set true, contractevent will also be regarded as contractlog + triggerName = "contractlog" # * (String) The event type identifier. + # * Subscribes to all contract logs from all blocks. + enable = false # * (Boolean) Enables or disables the subscription for this event type. + topic = "contractlog" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log + solidified = false # * (Boolean) If set to true, the subscription will only deliver events + # * for transactions included in solidified blocks. }, { - triggerName = "solidity" // solidity block trigger(just include solidity block number and timestamp), the value can't be modified - enable = true // Default: true - topic = "solidity" + triggerName = "solidityevent" # * (String) The event type identifier. + # * Subscribes only to contract events from solidified blocks. + enable = false # * (Boolean) Enables or disables the subscription for this event type. + topic = "solidityevent" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log }, { - triggerName = "solidityevent" - enable = false - topic = "solidityevent" + triggerName = "soliditylog" # * (String) The event type identifier. + # * Subscribes only to contract logs from solidified blocks. + enable = false # * (Boolean) Enables or disables the subscription for this event type. + topic = "soliditylog" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log }, { - triggerName = "soliditylog" - enable = false - topic = "soliditylog" - redundancy = false // if set true, solidityevent will also be regarded as soliditylog + triggerName = "solidity" # * (String) The event type identifier. + # * Subscribes to real-time notifications for the latest solidified block height. + # * This is ideal for applications that need to track the chain's finalized state. + enable = false # * (Boolean) Enables or disables the subscription for this event type. + topic = "solidity" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log } ] + # * Filtering parameters. + # ? For more details, please refer to the Event Types section below: + # ? https://tronprotocol.github.io/documentation-en/architecture/event/#event-types filter = { - fromblock = "" // the value could be "", "earliest" or a specified block number as the beginning of the queried range - toblock = "" // the value could be "", "latest" or a specified block number as end of the queried range + # * Possible values: + # * - "": no filters are applied + # * - "earliest" + # * - specific block number + # * to be used as the beginning of the queried range + fromblock = "" + + # * Possible values: + # * - "": no filters are applied + # * - "latest" + # * - specific block number + # * to be used as the end of the queried range + toblock = "" + + # * Possible values: + # * - "": no filters are applied + # * - "latest"# * Contract address(es) to subscribe the node to filter events + # * If it's set to "", the node will receive contract logs/events with any contract address. + # * - specific block number + # * to be used as the end of the queried range contractAddress = [ - "" // contract address you want to subscribe, if it's set to "", you will receive contract logs/events with any contract address. + "" ] + # * Contract topic to subscribe to node to filter events + # * If it's set to "", the node will receive contract logs/events with any contract topic. contractTopic = [ - "" // contract topic you want to subscribe, if it's set to "", you will receive contract logs/events with any contract topic. + "" ] } } + + # ! Please note: +# ! this parameter is really important when staking energy and bandwidth to invoke smart contracts methods (paid ones) +# * If the block number of the chain is equal to the value specified for this parameter, +# * then the energy is consumed before consuming TRX to handle a transaction +# * Possible settings: +# * - when set to 0, the "threshold" is disabled, making energy consumption immediate instead of burning TRX +# * - when set to a value > 0, the energy consumption is "enabled" when the specified block number is reached +# ? Ref: https://github.com/tronprotocol/java-tron/blob/1e35f79a165424bbae319799d9aca92948b8f5c2/chainbase/src/main/java/org/tron/common/utils/ForkController.java#L112 +enery.limit.block.num = 0 \ No newline at end of file From fc1a4ccfd156e1dbfafeff00a60592548c513f16 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:20:03 +0100 Subject: [PATCH 02/28] feat(config): add syncFetchBatchNum with explanation --- framework/src/main/resources/config.conf | 3 +++ 1 file changed, 3 insertions(+) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 7ad209890a2..f9cd059239f 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -267,6 +267,9 @@ node { # * Max time to wait for a block response from a peer fetchBlock.timeout = 200 # * seconds + + # * Number of requested blocks in a single batch during the node synchronization process + syncFetchBatchNum = 2000 # * default: 2000 - max: 2000 # * These define how many network IO threads are used by the Netty framework # * 0: auto, based on CPU cores From a69cdf757373b7df76be96c54519dc063c251219 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:25:23 +0100 Subject: [PATCH 03/28] feat(config): add allowShieldedTransactionApi to config.conf file --- framework/src/main/resources/config.conf | 3 +++ 1 file changed, 3 insertions(+) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index f9cd059239f..13867de97ff 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -336,6 +336,9 @@ node { # ! set this parameter to 0 to disable the check minParticipationRate = 15 # * percentage + # * Controls whether the node enables API endpoints related to shielded (privacy-preserving) transactions +# allowShieldedTransactionApi = true + # * When true, this setting might enable full TCP disconnect logic # * for peers under certain conditions (e.g. poor performance). # * When false (default), the node retains more leniency in connection persistence. From 8bc7322843ff1e4213b8f154a3291de576e2cf55 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:26:28 +0100 Subject: [PATCH 04/28] feat(config): add openPrintLog parameter to config.conf file --- framework/src/main/resources/config.conf | 3 +++ 1 file changed, 3 insertions(+) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 13867de97ff..830eb23d5c5 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -339,6 +339,9 @@ node { # * Controls whether the node enables API endpoints related to shielded (privacy-preserving) transactions # allowShieldedTransactionApi = true + # * Controls whether the node prints internal processing logs to the console (stdout) +# openPrintLog = true + # * When true, this setting might enable full TCP disconnect logic # * for peers under certain conditions (e.g. poor performance). # * When false (default), the node retains more leniency in connection persistence. From 8dfc1251f1c67b4244bebd4c03c48fe12c96a0d7 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:29:15 +0100 Subject: [PATCH 05/28] feat(config): add openTransactionSort and maxTps parameters --- framework/src/main/resources/config.conf | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 830eb23d5c5..62f5b5f215c 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -342,6 +342,15 @@ node { # * Controls whether the node prints internal processing logs to the console (stdout) # openPrintLog = true + # * If set to true, SR packs transactions into a block in descending order of fee; + # * otherwise, it packs them based on their receive timestamp. +# openTransactionSort = false # * default: false + + # * The threshold for the number of broadcast transactions received from each peer every second. + # ! Please note: + # ! transactions exceeding this threshold will be discarded. +# maxTps = 1000 # * default: 1000 + # * When true, this setting might enable full TCP disconnect logic # * for peers under certain conditions (e.g. poor performance). # * When false (default), the node retains more leniency in connection persistence. From 2cd01566f56b684c2f007b326eb18f38bf07c8b6 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:30:41 +0100 Subject: [PATCH 06/28] feat(config): add Nile network to p2p section --- framework/src/main/resources/config.conf | 1 + 1 file changed, 1 insertion(+) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 62f5b5f215c..43f918681fa 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -366,6 +366,7 @@ node { # * Possible values: # * - 11111: mainnet # * - 20180622: testnet + # * - 201910292: Nile # * - user defined value (integer) # ! Please note: # ! for private networks use your own, From a8b6e153e0a8d642903052db0d0cdda0362b0266 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:32:22 +0100 Subject: [PATCH 07/28] feat(config): add default values for a Full Node in the node.http section --- framework/src/main/resources/config.conf | 26 ++++++++++++------------ 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 43f918681fa..269b79c84a7 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -421,22 +421,22 @@ node { # * If you're doing smart contracts and blockchain operations, you should enable FullNode's HTTP and RPC; # * a separate SolidityNode is optional unless performance demands it. http { - fullNodeEnable = false # ! Please note: + fullNodeEnable = true # ! Please note: # ! this should be disabled on a SR fullNodePort = 8090 - solidityEnable = false # ! Please note: - # ! this should be disabled on a SR. - # ! Additionally, depending on the type of network you are trying to create/join, - # ! you might want to use a different host for the Solidity Node. - # ! Anyway, there are no rules that deny to use a Full Node AND a Solidity Node - # ! on the same host. + solidityEnable = true # ! Please note: + # ! this should be disabled on a SR. + # ! Additionally, depending on the type of network you are trying to create/join, + # ! you might want to use a different host for the Solidity Node. + # ! Anyway, there are no rules that deny to use a Full Node AND a Solidity Node + # ! on the same host. solidityPort = 8091 - PBFTEnable = true # * Practical Byzantine Fault Tolerance (consensus mechanism) - # ! Please note: - # ! this option should be disabled on every node except for SRs. - # ! IS IT IMPORTANT to understand that this option should be enabled - # ! on ALL network SRs if enable at least on one, - # ! or disabled on ALL network SRs if disabled at least on one. + PBFTEnable = true # * Practical Byzantine Fault Tolerance (consensus mechanism) + # ! Please note: + # ! this option should be disabled on every node except for SRs. + # ! IS IT IMPORTANT to understand that this option should be enabled + # ! on ALL network SRs if enable at least on one, + # ! or disabled on ALL network SRs if disabled at least on one. PBFTPort = 8092 } From c2aa6be2264f4f35b2896f4a80b3abe6149bd61e Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:34:10 +0100 Subject: [PATCH 08/28] feat(config): add default values for a Full Node in the node.rpc section --- framework/src/main/resources/config.conf | 28 ++++++++++++------------ 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 269b79c84a7..c4f23f9e485 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -460,22 +460,22 @@ node { # * Configures gRPC APIs (used by tronWeb, TronLink) rpc { - enable = false # ! Please note: + enable = true # ! Please note: # ! this should be disabled on a SR port = 50051 - solidityEnable = false # ! Please note: - # ! this should be disabled on a SR. - # ! Additionally, depending on the type of network you are trying to create/join, - # ! you might want to use a different host for the Solidity Node. - # ! Anyway, there are no rules that deny to use a Full Node AND a Solidity Node - # ! on the same host. - solidityPort = 50061 - PBFTEnable = true # * Practical Byzantine Fault Tolerance (consensus mechanism) - # ! Please note: - # ! this option should be disabled on every node except for SRs. - # ! IS IT IMPORTANT to understand that this option should be enabled - # ! on ALL network SRs if enable at least on one, - # ! or disabled on ALL network SRs if disabled at least on one. + solidityEnable = true # ! Please note: + # ! this should be disabled on a SR. + # ! Additionally, depending on the type of network you are trying to create/join, + # ! you might want to use a different host for the Solidity Node. + # ! Anyway, there are no rules that deny to use a Full Node AND a Solidity Node + # ! on the same host. + solidityPort = 50061 + PBFTEnable = true # * Practical Byzantine Fault Tolerance (consensus mechanism) + # ! Please note: + # ! this option should be disabled on every node except for SRs. + # ! IS IT IMPORTANT to understand that this option should be enabled + # ! on ALL network SRs if enable at least on one, + # ! or disabled on ALL network SRs if disabled at least on one. PBFTPort = 50071 # * Number of gRPC thread, default availableProcessors / 2 From 3ddc7006ced6026e99a9acde52e0add490038b42 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:35:29 +0100 Subject: [PATCH 09/28] feat(config): add maxRstStream and secondsPerWindow parameters --- framework/src/main/resources/config.conf | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index c4f23f9e485..b2e07f8f933 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -508,6 +508,12 @@ node { # * If left commented, the default value is 8192 # maxHeaderListSize = + # * Number of RST_STREAM frames allowed to be sent per connection per period for grpc, by default there is no limit. + # maxRstStream = + + # * Number of seconds per period for grpc + # secondsPerWindow = # * seconds + # * How many peer connections are needed before allowing broadcast. # * Please note: transactions can only be broadcasted if the number of effective connections is reached. minEffectiveConnection = 1 From dfa317c2ba722a6428cdcb9b13c737191295b2bf Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:36:56 +0100 Subject: [PATCH 10/28] feat(config): add nodeDetectEnable parameter --- framework/src/main/resources/config.conf | 3 +++ 1 file changed, 3 insertions(+) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index b2e07f8f933..25b766a526b 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -542,6 +542,9 @@ node { # * Rate limit for incoming transactions per second from network peers # netMaxTrxPerSecond = 700 + # * Whether to enable the node detection function. + # nodeDetectEnable = false # * default: false + # * Enables read APIs for block/transaction history when running a Lite Full Node (one that doesn't store full blockchain). # * Leave false unless you explicitly run a lite node. # openHistoryQueryWhenLiteFN = false From 71d50685384f4934103daf9564fa94180056bd2d Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:39:24 +0100 Subject: [PATCH 11/28] feat(config): add dynamicConfig parameter --- framework/src/main/resources/config.conf | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 25b766a526b..bf1ea5bd9e6 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -448,6 +448,18 @@ node { # ! can help maintain sync, but may cause frequent reconnections on unstable networks effectiveCheckEnable = false + # * Dynamic loading configuration function. + dynamicConfig = { + # enable = false # * default: false + + # * Check interval of configuration file's change. + # checkInterval = 600 # * seconds (default: 600) + } + + # Whether to continue broadcast transactions after at least maxUnsolidifiedBlocks are not solidified. Default: false + # unsolidifiedBlockCheck = false + # maxUnsolidifiedBlocks = 54 + # * treeUrls is a list of DNS-based bootstrap peers in "tree://" format, including public domain and key info. # * The node will use DNS to discover peers using these URLs. # * If left empty, peer discovery relies solely on seed.node and active/passive lists. From 0595c79d89a451fb91a4a5bd1ca9484f70de7cf6 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:52:17 +0100 Subject: [PATCH 12/28] feat(config): add missing parameters to the dns section --- framework/src/main/resources/config.conf | 75 +++++++++++++++++++++++- 1 file changed, 72 insertions(+), 3 deletions(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index bf1ea5bd9e6..45a0cc0f3f1 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -460,10 +460,79 @@ node { # unsolidifiedBlockCheck = false # maxUnsolidifiedBlocks = 54 - # * treeUrls is a list of DNS-based bootstrap peers in "tree://" format, including public domain and key info. - # * The node will use DNS to discover peers using these URLs. - # * If left empty, peer discovery relies solely on seed.node and active/passive lists. dns { + # * Enable or disable DNS publish. + # publish = false # * default: false + + # * DNS domain to publish nodes. + # ! Please note: + # ! required if "publish" parameter is set to true + # dnsDomain = "nodes1.example.org" + + # * DNS private key used to publish. + # ! Please note: + # ! required if "publish" parameter is set to true + # * Composition: hex string of length 64 characters + # dnsPrivate = "b71c71a67e1177ad4e901695e1b4b9ee17ae16c6668d313eac2f96dbcda3f291" + + # * Known DNS URLs to publish + # ! Please note: + # ! required if "publish" parameter is set to true + # * URL format tree://{pubkey}@{domain}, default empty + # knownUrls = [ + # "tree://APFGGTFOBVE2ZNAB3CSMNNX6RRK3ODIRLP2AA5U4YFAA6MSYZUYTQ@nodes2.example.org", + # ] + + # * Static nodes to published on DNS + # staticNodes = [ + # "ip:port", + # "ip:port" + # ] + + # * Merge several nodes into a tree leaf. + # ! Please note: + # ! the value should be set between 1 and 5 + # maxMergeSize = 5 + + # * Minimum threshold of node change to update data on DNS + # changeThreshold = 0.1 + + # * DNS server to publish + # ! Please note: + # ! required if "publish" parameter is set to true + # * Supported values: + # * - aws + # * - aliyun + # serverType = "aws" + + # * Access key id of AWS or aliyun API + # ! Please note: + # ! required if "publish" parameter is set to true + # accessKeyId = "your-key-id" + + # Access key secret of AWS or aliyun API + # ! Please note: + # ! required if "publish" parameter is set to true + # accessKeySecret = "your-key-secret" + + # * Specifies the DNS service endpoint used for peer discovery via Alibaba Cloud (Aliyun) + # ! Please note: + # ! required if "publish" parameter is set to true and "serverType" is set to "aliyun" + # aliyunDnsEndpoint = "alidns.aliyuncs.com" + + # * Specifies the AWS Region used by the node when interacting with AWS-based infrastructure + # ! Please note: + # ! required if "publish" parameter is set to true and "serverType" is set to "aws" + # awsRegion = "us-east-1" + + # * Route 53 Hosted Zone identifier used by Amazon Web Services for DNS-based peer discovery. + # ! Please note: + # ! required if "publish" parameter is set to true and "serverType" is set to "aws" + # awsHostZoneId = "your-host-zone-id" + + # * treeUrls is a list of DNS-based bootstrap peers in "tree://" format, including public domain and key info. + # * The node will use DNS to discover peers using these URLs. + # * If left empty, peer discovery relies solely on seed.node and active/passive lists. # * URL format tree://{pubkey}@{domain}, default empty treeUrls = [ # "tree://AKMQMNAJJBL73LXWPXDI4I5ZWWIZ4AWO34DWQ636QOBBXNFXH3LQS@main.trondisco.net", From e519a8fd146e4c86954e38186b637cc5041177a1 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:58:17 +0100 Subject: [PATCH 13/28] feat(config): add missing parameters to rate.limiter section --- framework/src/main/resources/config.conf | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 45a0cc0f3f1..52494ca5e7c 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -709,6 +709,24 @@ rate.limiter = { # paramString = "qps=1" # }, ] + + # * This section defines per-endpoint rate limits (QPS = queries per second) for specific P2P message types + p2p = { + # syncBlockChain = 3.0 # * Limits how often a peer can request blockchain synchronization + # * Protects against excessive sync requests (potential DoS vector) + # fetchInvData = 3.0 # * Controls requests for inventory data (blocks / transactions) + # * Prevents peers from aggressively pulling data + # disconnect = 1.0 # * Limits how frequently disconnect actions can be triggered + # * Avoids abuse of connection churn + } + + # * Maximum total number of requests per second the node will handle across all peers and endpoints: + # * - acts as a global throttle + # * - protects the node from overload + global.qps = 50000 # * default: 50000 + + # * Sets a per-IP rate limit. + global.ip.qps = 10000 # * default: 10000 } # * ------------------------------------------ SEED.NODE ------------------------------------------ # ! Please note: From ea8f8af85e68f342794d27ccb9e9e33bc42b0d0d Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:58:41 +0100 Subject: [PATCH 14/28] feat(config): add default ip.list seed nodes --- framework/src/main/resources/config.conf | 32 ++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 52494ca5e7c..4a1fdbea0c1 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -743,6 +743,38 @@ seed.node = { # "ip:port" # ] ip.list = [ + "3.225.171.164:18888", + "52.8.46.215:18888", + "3.79.71.167:18888", + "108.128.110.16:18888", + "18.133.82.227:18888", + "35.180.81.133:18888", + "13.210.151.5:18888", + "18.231.27.82:18888", + "3.12.212.122:18888", + "52.24.128.7:18888", + "15.207.144.3:18888", + "3.39.38.55:18888", + "54.151.226.240:18888", + "35.174.93.198:18888", + "18.210.241.149:18888", + "54.177.115.127:18888", + "54.254.131.82:18888", + "18.167.171.167:18888", + "54.167.11.177:18888", + "35.74.7.196:18888", + "52.196.244.176:18888", + "54.248.129.19:18888", + "43.198.142.160:18888", + "3.0.214.7:18888", + "54.153.59.116:18888", + "54.153.94.160:18888", + "54.82.161.39:18888", + "54.179.207.68:18888", + "18.142.82.44:18888", + "18.163.230.203:18888", + # "[2a05:d014:1f2f:2600:1b15:921:d60b:4c60]:18888", // use this if support ipv6 + # "[2600:1f18:7260:f400:8947:ebf3:78a0:282b]:18888", // use this if support ipv6 ] } # * ---------------------------------------- GENESIS.BLOCK ---------------------------------------- From cc9264c5418b776943d7a2135733b04e6c5a84e3 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 14:59:38 +0100 Subject: [PATCH 15/28] chore(config): improve comments in seed.node ip.list section --- framework/src/main/resources/config.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 4a1fdbea0c1..a58c3e01d4c 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -773,8 +773,8 @@ seed.node = { "54.179.207.68:18888", "18.142.82.44:18888", "18.163.230.203:18888", - # "[2a05:d014:1f2f:2600:1b15:921:d60b:4c60]:18888", // use this if support ipv6 - # "[2600:1f18:7260:f400:8947:ebf3:78a0:282b]:18888", // use this if support ipv6 + # "[2a05:d014:1f2f:2600:1b15:921:d60b:4c60]:18888", # * Use this address if your node supports ipv6 + # "[2600:1f18:7260:f400:8947:ebf3:78a0:282b]:18888", # * Use this address if your node supports ipv6 ] } # * ---------------------------------------- GENESIS.BLOCK ---------------------------------------- From 89aa2b14aa7904a3e34e48bfaee439d13e0a1415 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Mon, 23 Mar 2026 15:04:17 +0100 Subject: [PATCH 16/28] feat(config): add checkFrozenTime parameter --- framework/src/main/resources/config.conf | 2 ++ 1 file changed, 2 insertions(+) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index a58c3e01d4c..3f2c019b291 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -894,6 +894,8 @@ block = { # ! maintenanceTimeInterval and proposalExpireTime take effect just when the node is a SR! maintenanceTimeInterval = 21600000 # * default: 21600000, in milliseconds (6 hours -> Epoch) proposalExpireTime = 259200000 # * default: 259200000, in milliseconds (3 days) + # * Controls whether the node validates the lock (freeze) duration of funds when processing transactions and account state + # checkFrozenTime = 1 # * default: 1 } # * --------------------------------------------- TRX --------------------------------------------- trx { From 9d2073871c36505bcee84583a11d9b00e73d5309 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Tue, 24 Mar 2026 22:13:17 +0100 Subject: [PATCH 17/28] feat: add sample entries for fastForward parameter --- framework/src/main/resources/config.conf | 3 +++ 1 file changed, 3 insertions(+) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 3f2c019b291..62305290363 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -404,6 +404,9 @@ node { # * using fastForward nodes can speed up the process. # * If left empty, the node just uses its normal peer list/discovery - slower but works. # * With entries, when starting, the node prioritizes connecting to these peers to accelerate synchronization. + # * Sample entries: + # * "ip:port", + # * "ip:port" fastForward = [ ] From d5c54f048f0ebe879e1bf12a3be4a68eb284d37a Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Tue, 24 Mar 2026 22:13:44 +0100 Subject: [PATCH 18/28] chore: remove spaces --- framework/src/main/resources/config.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 62305290363..aa19e5bd5b3 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -424,8 +424,8 @@ node { # * If you're doing smart contracts and blockchain operations, you should enable FullNode's HTTP and RPC; # * a separate SolidityNode is optional unless performance demands it. http { - fullNodeEnable = true # ! Please note: - # ! this should be disabled on a SR + fullNodeEnable = true # ! Please note: + # ! this should be disabled on a SR fullNodePort = 8090 solidityEnable = true # ! Please note: # ! this should be disabled on a SR. From 3a83fa4d2701013576ac98b58743db8c466528b2 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Tue, 24 Mar 2026 22:15:14 +0100 Subject: [PATCH 19/28] chore(config): remove spaces --- framework/src/main/resources/config.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index aa19e5bd5b3..5a179e04d3f 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -544,8 +544,8 @@ node { # * Configures gRPC APIs (used by tronWeb, TronLink) rpc { - enable = true # ! Please note: - # ! this should be disabled on a SR + enable = true # ! Please note: + # ! this should be disabled on a SR port = 50051 solidityEnable = true # ! Please note: # ! this should be disabled on a SR. From 6c1b8e1363614ca53d6aa702b75a4c2613a7e2c3 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Tue, 24 Mar 2026 22:49:32 +0100 Subject: [PATCH 20/28] chore(config): format document --- framework/src/main/resources/config.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 5a179e04d3f..0c093cf1fd7 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -818,7 +818,7 @@ genesis.block = { balance = "-9223372036854775808" } # ! Please note: - # ! the SR information must be set here when configuring a SR node + # ! the SR information must be set here when configuring a SR node # { # accountName = "SR" # accountType = "AssetIssue" From 73b99a14b685b62936573305db1af02cb8fc8113 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Tue, 24 Mar 2026 22:50:26 +0100 Subject: [PATCH 21/28] chore(config): remove sample address --- framework/src/main/resources/config.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 0c093cf1fd7..60bbb143aed 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -836,7 +836,7 @@ genesis.block = { # ! the more the votes, the better for the SR witnesses = [ { - address = "THKJYuUmMKKARNf7s2VT51g5uPY6KEqnat" + address = "base58-SR-address" url = "http://SR-INFO-PAGE-URL.com" voteCount = 1000000000000000 } From 0a62536a234c67a357816182971c9a50740089e6 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Tue, 24 Mar 2026 22:53:37 +0100 Subject: [PATCH 22/28] chore(config): format document --- framework/src/main/resources/config.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 60bbb143aed..6f504547995 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -1196,7 +1196,7 @@ event.subscribe = { } } - # ! Please note: +# ! Please note: # ! this parameter is really important when staking energy and bandwidth to invoke smart contracts methods (paid ones) # * If the block number of the chain is equal to the value specified for this parameter, # * then the energy is consumed before consuming TRX to handle a transaction From dd57d6095a186fd6ee1428d99d216126657eba30 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Wed, 25 Mar 2026 15:50:16 +0100 Subject: [PATCH 23/28] feat(config): add * for explicative comments --- framework/src/main/resources/config.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 6f504547995..11638623581 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -983,8 +983,8 @@ vm = { committee = { # ! Please note: # ! you must enable this feature if you intend to deploy (and use) smart contracts - allowCreationOfContracts = 1 # Whether new contract deployment is allowed (0 = disallowed; 1 = allowed) - allowDynamicEnergy = 1 # Enables the dynamic energy system + allowCreationOfContracts = 1 # * Whether new contract deployment is allowed (0 = disallowed; 1 = allowed) + allowDynamicEnergy = 1 # * Enables the dynamic energy system # ! Please note: # ! - this should be 0 on private blockchain, # ! so the energy used when calling contracts is always the same From f2a2bb2d735ab4e45b828249b94472c70bd2c7c7 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Fri, 27 Mar 2026 13:31:42 +0100 Subject: [PATCH 24/28] feat(config): add additional information regarding active, passive, fastForward and seed nodes --- framework/src/main/resources/config.conf | 2418 +++++++++++----------- 1 file changed, 1212 insertions(+), 1206 deletions(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 11638623581..7e0db2e351f 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -1,1207 +1,1213 @@ -# * ------------------------------------- NODE CONFIGURATION -------------------------------------- -# * This file is used to configure a TRON network node (Full Node, Super Representative, Solidity Node, Lite Full Node). -# * This file uses a standardized commenting convention, designed to improve readability and developer experience when using -# * the Better Comments extension in Visual Studio Code. -# * The file leverages categorized comment prefixes to visually distinguish different types of information: -# ! (Important comments) -# * Used for critical notes that require developer attention. -# * These comments typically highlight constraints, warnings, or non-obvious behaviors. -# * By convention, they are always followed by a “Please note” statement. -# * (Informational comments) -# * Used to provide contextual explanations about a specific parameter or configuration section. -# * These comments are purely descriptive and do not require any action from the developer. -# ? (Reference comments) -# * Used to include external resources, documentation links, or additional references related to a parameter or section. -# * These are supplementary and do not require immediate attention. -# * This structure ensures a consistent, scannable configuration file where critical information stands out -# * while maintaining clear and accessible documentation inline. -# ? Ref (Better Comments): https://marketplace.visualstudio.com/items?itemName=aaron-bond.better-comments -# ? Ref: https://tronprotocol.github.io/documentation-en/using_javatron/private_network/ -# * --------------------------------------------- SECTIONS ---------------------------------------- -# * 1. net -# * 2. storage -# * 3. crypto -# * 4. node -# * 5. rate.limiter -# * 6. seed.node -# * 7. genesis.block -# * 8. localWitnessAccountAddress -# * 9. localwitness -# * 10. localwitnesskeystore -# * 11. block -# * 12. trx -# * 13. vm -# * 14. committee -# * 15. event.subscribe -# * --------------------------------------------- NET --------------------------------------------- -# * This configuration defines the network type -# * Use: -# * - mainnet, when working with the TRON main network -# * - testnet, when working with a local testnet -# * - everything else (like "privatenet") when working on a private chain -# ! Please note: -# ! changing this value determines the genesis block and seed nodes used. -net { - type = privatenet -} -# * ------------------------------------------- STORAGE ------------------------------------------- -# * TRON uses a LevelDB database -# * LevelDB ref: https://github.com/google/leveldb -storage { - # * Directory for storing persistent data - db.engine = "LEVELDB" - db.sync = false - db.directory = "database" - index.directory = "index" - transHistory.switch = "on" - - # * These are the databases which will be created when starting the node for the first time - # * You _can_ custom these 14 databases' configurations: - # * - account - # * - account-index - # * - asset-issue - # * - block - # * - block-index - # * - block_KDB - # * - peers - # * - properties - # * - recent-block - # * - trans - # * - utxo - # * - votes - # * - witness - # * - witness_schedule - # * If you don't change these configurations, - # * default db configs will be used, - # * and data will be stored in the path of "output-directory", - # * or the one set by "-d" (or "--output-directory"). - - # ? If you want to improve LevelDB performances, you can use the following settings: - # ! Please note: - # ! if this configuration causes the node to open more file descriptors, check your system ulimit if you get a too many open files error. - # ! See: https://github.com/tronprotocol/tips/blob/master/tip-343.md for more detail - # * ----- Improvement settings start here ----- - # default = { - # maxOpenFiles = 100 - # } - # defaultM = { - # maxOpenFiles = 500 - # } - # defaultL = { - # maxOpenFiles = 1000 - # } - # * ----- Improvement settings end here ----- - - # * Please note: - # * when using a different configuration for the RocksDB - # ! Please note: - # ! "name" is a required field that must be set! - properties = [ - # { - # name = "account", - # path = "storage_directory_test", - # createIfMissing = true, - # paranoidChecks = true, - # verifyChecksums = true, - # compressionType = 1, # * compressed with snappy - # blockSize = 4096, # * 4 KB = 4 * 1024 B - # writeBufferSize = 10485760, # * 10 MB = 10 * 1024 * 1024 B - # cacheSize = 10485760, # * 10 MB = 10 * 1024 * 1024 B - # maxOpenFiles = 100 - # }, - # { - # name = "account-index", - # path = "storage_directory_test", - # createIfMissing = true, - # paranoidChecks = true, - # verifyChecksums = true, - # compressionType = 1, # * compressed with snappy - # blockSize = 4096, # * 4 KB = 4 * 1024 B - # writeBufferSize = 10485760, # * 10 MB = 10 * 1024 * 1024 B - # cacheSize = 10485760, # * 10 MB = 10 * 1024 * 1024 B - # maxOpenFiles = 100 - # }, - ] - - # * This tells the node whether it needs to update old asset formats - # * to the new TRC10/20 format when reading older blocks. - # * Keep it "true" for backward compatibility. - needToUpdateAsset = true - - # * dbsettings is needed when using rocksdb as the storage implement (db.engine="ROCKSDB"). - # ! Please note: - # ! it is strongly recommended to not modify these parameters - # ! unless you know what you're doing. - dbSettings = { - levelNumber = 7 - # compactThreads = 32 - blocksize = 64 # * n * KB - maxBytesForLevelBase = 256 # * n * MB - maxBytesForLevelMultiplier = 10 - level0FileNumCompactionTrigger = 4 - targetFileSizeBase = 256 # * n * MB - targetFileSizeMultiplier = 1 - } - - # ! Please note: - # ! the backup plugin is available only when db.engine="ROCKSDB" - backup = { - enable = false # * Indicate whether enable the backup plugin - propPath = "prop.properties" # * Record which .bak directory is valid - bak1path = "bak1/database" # * Two backup directories must be set to prevent application halt unexpected (e.g. kill -9). - bak2path = "bak2/database" - frequency = 10000 # * Indicates that the db backup should occur every 10000 blocks processed - } - - # * If true, the node keeps a lookup index of historical balances per account for time-based queries. - # * Default false saves disk and improves speed, but historical balance queries won't work. - # * Only enable if you need that API. - balance.history.lookup = false - - # * Used for resuming blockchain sync from a "checkpoint" snapshot - # * instead of starting from genesis (first block generated). - # ! Please note: - # ! usually not used in a private blockchain. - # checkpoint.version = 2 # * version number of the snapshot - # checkpoint.sync = true # * whether to enable checkpoint synchronization - - # * Defines transaction caching parameters (used to speed up node startup time) - # * The estimated number of block transactions (min 100, max 10000). - # * The total number of cached transactions is 65536 (UINT8) * txCache.estimatedTransactions - # txCache.estimatedTransactions = 1000 # * Number of transactions expected per block (used to size cache arrays) - # * If true, transaction cache initialization will be faster - # txCache.initOptimization = true # * Speeds up initialization by preallocating cache memory - - # * Data root setting, for check data, currently, only reward-vi is used. - # ! Please note: - # ! leave untouched (even for private networks). - # merkleRoot = { - # reward-vi = 9debcb9924055500aaae98cdee10501c5c39d4daa75800a996f4bdda73dbccd8 # * main-net, Sha256Hash, hexString - # } - -} -# * -------------------------------------------- CRYPTO ------------------------------------------- -# * Specifies the cryptographic algorithm used for signing and verifying transactions -# ! Please note: never change this value to anything else -crypto { - engine = "eckey" # * standard ECDSA (secp256k1), used across TRON -} -# * --------------------------------------------- NODE -------------------------------------------- -# * This section keeps the node configuration -node { - # * These settings control the node visibility and discovery to/for other peers, and save discovered peers by the (current) node in the network - # ! Depending on the type of network that you are trying to create/join, - # ! you might want to disable the node discovery. - # ! For example, a Solidity Node should not have this option enabled, - # ! since its source of information (blockchain state, hence blocks) - # ! comes from the Full Node, which is controlled by the parameter "trustNode" - # ! in this section ("node"). - discovery { - enable = true # * Enable/Disable automatic peer discovery in the network - # * (controls whether the node searches for and announces itself to other peers) - persist = true # * Persist the discovered peers in a local file or database - } - - # * This section is used to export node metrics to an external tool such as "Prometheus" - # * If enabled, your node will expose data like block sync speed, TPS, memory usage. - metrics = { - # prometheus - # { - # enable = true - # port = "9527" - # } - } - - # * This section is used to configure the node backup - backup { - # * Determines which node acts as leader in a backup cluster (lower value = higher priority) - # priority = 8 - - # * UDP port used for backup communication between members - # ! Please note: - # ! each member should have the same configuration - # port = 10001 - - # * How often nodes send "I'm alive" messages - # ! Please note: - # ! each member should have the same configuration - # keepAliveInterval = 3000 # * milliseconds - - # * List of IPs of other nodes in the same cluster (not including yourself) - # ! Please note: - # ! do not include the current configuration's node IP - # members = [ - # # "ip", - # # "ip" - # ] - } - - # * This section is used to shutdown the node in specific conditions - shutdown { - # BlockTime = "54 59 08 * * ?" # * When the Block Timestamp matches the pattern (Cron format) - # BlockHeight = 33350800 # * When the Block Height (Block Number) matches the value - # BlockCount = 12 # * When the block sync count after the node has started is matched - } - - # * trustNode is used by a Solidity Node (or light node) to designate which FullNode it "trusts" - # * to fetch confirmed (or "solidified") blocks. - # ! Please note: - # ! this is used when another node (which is a Solidity Node or a Lite Full Node) connects - # ! to a Full Node (to query data from the blockchain), - # ! since neither the Solidity Node nor the Lite Full Node store the network history (blockchain). - # trustNode = "ip:port" - # trustNode = "127.0.0.1:50051" - - # * Enable extra wallet extended API interface - walletExtensionApi = true - - # * Defines the TCP port on which your node listens for incoming peer-to-peer (P2P) - # * connections from other nodes in the network (Full Nodes, Solidity Nodes, SRs) - # * This value can be the same for every node in the network, since it refers to different nodes anyway. - # ! Please note: - # ! this is not the port where HTTP, rpc or grpc API listen on - listen.port = 18888 - - # * Max time to wait when connecting to a peer - connection.timeout = 5 # * seconds - - # * Max time to wait for a block response from a peer - fetchBlock.timeout = 200 # * seconds - - # * Number of requested blocks in a single batch during the node synchronization process - syncFetchBatchNum = 2000 # * default: 2000 - max: 2000 - - # * These define how many network IO threads are used by the Netty framework - # * 0: auto, based on CPU cores - # ! Please note: - # ! only change if you're optimizing very high-performance nodes. - tcpNettyWorkThreadNum = 0 - udpNettyWorkThreadNum = 1 - - # * Maximum total peer-to-peer connections your node will maintain (both inbound and outbound), - # * without any distinction between node type - # * Pro tip: adjust accordingly based on the number of peers in the private network - maxConnections = 30 - - # * This is the lower threshold of peer connections the node tries to keep alive. - # * If the active peers drop below minConnections, - # * the node will try to open new outbound connections to reachable peers (via discovery or seed) - # * to bring itself back up. - # ! Please note: - # ! it ensures the node doesn't stay isolated with too few peers. - # * Pro tip: adjust accordingly based on the number of peers in the private network, - # * to avoid that the node will search for nodes for an undefinitely amount of time - minConnections = 2 - - # * Number of peers that must be active to sync data - # * This the minimum number of active peers required for the node to start or continue data synchronization - # * (block downloads, network sync). - # * "Active" means peers that are fully connected and exchanging data, not just idle or handshake-only. - # * If the number of active peers falls below this threshold, - # * the node may temporarily stall or refuse to sync until enough peers are back online. - # * If you set minActiveConnections = 3, - # * then unless the node has at least 3 fully active peers, it might not perform block sync. - # * Pro tip: adjust accordingly based on the number of peers in the private network, - # * to avoid that the node will perform data synchronization - minActiveConnections = 2 - - # * This parameter sets the number of threads dedicated to signature validation / signing operations - # * (for verifying incoming transactions or blocks). - # ! Please note: - # ! adjust accordingly by using this formula - # ! validateSignThreadNum = availableProcessors / 2 - # validateSignThreadNum = 16 - - # * Prevents DDoS / redundant connections - maxConnectionsWithSameIp = 2 - - # * Maximum number of concurrent HTTP API connections your node will handle - maxHttpConnectNumber = 50 - - # * Minimum required block participation rate (%) to remain active. - # ! Please note: - # ! applies to Super Representatives only. - # * If your SR fails to produce enough blocks, it may be penalized. - # * This parameter defines the minimum required participation rate of Super Representatives (SRs) - # * during block production. - # * In other words, how many SRs must actually produce blocks during an Epoch - # * (6 hour by default, dictated by the value of maintenanceTimeInterval parameter in this config file). - # * So, for example, if there are 5 SRs, and the minParticipationRate is 15 (%), - # * then at least (0.75, rounded up to the nearest integer) 1 SR must produce blocks in a round. - # * A "round" is a time range during which all network SRs can produce a block in their slot. - # * In case they fail, rewards will not be shared between them. - # * It's mainly used in Super Representative consensus logic - not configurable elsewhere. - # * It ensures the network stays stable and avoids finalizing rounds with too few active producers. - # ! Please note: - # ! set this parameter to 0 to disable the check - minParticipationRate = 15 # * percentage - - # * Controls whether the node enables API endpoints related to shielded (privacy-preserving) transactions -# allowShieldedTransactionApi = true - - # * Controls whether the node prints internal processing logs to the console (stdout) -# openPrintLog = true - - # * If set to true, SR packs transactions into a block in descending order of fee; - # * otherwise, it packs them based on their receive timestamp. -# openTransactionSort = false # * default: false - - # * The threshold for the number of broadcast transactions received from each peer every second. - # ! Please note: - # ! transactions exceeding this threshold will be discarded. -# maxTps = 1000 # * default: 1000 - - # * When true, this setting might enable full TCP disconnect logic - # * for peers under certain conditions (e.g. poor performance). - # * When false (default), the node retains more leniency in connection persistence. - # * It's a kind of fail-safe/disconnect policy for TCP connections; - # * unless you're debugging connectivity you can leave it false. - isOpenFullTcpDisconnect = false - - # * This is a time threshold (in seconds) after which a peer is considered inactive if no communication. - # * If a peer hasn't sent or responded in more than inactiveThreshold, the node may drop it or mark it unhealthy. - inactiveThreshold = 600 # * seconds - - # * Defines protocol version to communicate with other peers - # * Possible values: - # * - 11111: mainnet - # * - 20180622: testnet - # * - 201910292: Nile - # * - user defined value (integer) - # ! Please note: - # ! for private networks use your own, - # ! and keep it consistent between ALL the private network peers. - # ! Depending on the type of network that you are trying to create/join, - # ! you might want to comment out this parameter. - # ! For example, a Solidity Node should not have this value filled, - # ! since it doesn't participate to peer-to-peer communication, - # ! but it's using the Full Node (through the "trustNode" parameter) to interact in the network. - p2p { - version = 11111 - } - - # * These are static peer lists: - # * - active -> peer addresses to which the node actively attempts connection (outbound). - # * - passive -> peer addresses from which the node accepts inbound connections (or those expected to connect to you). - # * If left empty, node discovers peers dynamically via discovery/seeds. - # * Use these if you want to pinpoint specific peers rather than rely entirely on discovery. - active = [ - # * Active establish connection in any case - # * Sample entries: - # * "ip:port", - # * "ip:port" - ] - - passive = [ - # * Passive accept connection in any case - # * Sample entries: - # * "ip:port", - # * "ip:port" - ] - - # * fastForward is a list of trusted peers for fast sync (early block download). - # * Since the block production is a "long" process (production -> propagation -> finalization), - # * using fastForward nodes can speed up the process. - # * If left empty, the node just uses its normal peer list/discovery - slower but works. - # * With entries, when starting, the node prioritizes connecting to these peers to accelerate synchronization. - # * Sample entries: - # * "ip:port", - # * "ip:port" - fastForward = [ - ] - - # * This section includes the following configurations: - # * - FullNode - # * - SolidityNode - # * - PBFT - # * In detail: - # * - FullNode: provides full blockchain data + APIs + can produce blocks (if SR). - # * - SolidityNode: **historically** a separate component optimized for contract-state queries and light reads. - # * If you want efficient contract access (especially for dApps), having a Solidity Node helps. - # * But in modern Java-Tron, FullNode already supports solidity data queries, so you may not strictly need a separate SolidityNode. - # * - PBFT: stands for Practical Byzantine Fault Tolerance - the consensus mechanism layer. - # * The HTTP / PBFT port settings allow APIs to interact with PBFT modules (e.g. proposals, votes). - # * If you're doing smart contracts and blockchain operations, you should enable FullNode's HTTP and RPC; - # * a separate SolidityNode is optional unless performance demands it. - http { - fullNodeEnable = true # ! Please note: - # ! this should be disabled on a SR - fullNodePort = 8090 - solidityEnable = true # ! Please note: - # ! this should be disabled on a SR. - # ! Additionally, depending on the type of network you are trying to create/join, - # ! you might want to use a different host for the Solidity Node. - # ! Anyway, there are no rules that deny to use a Full Node AND a Solidity Node - # ! on the same host. - solidityPort = 8091 - PBFTEnable = true # * Practical Byzantine Fault Tolerance (consensus mechanism) - # ! Please note: - # ! this option should be disabled on every node except for SRs. - # ! IS IT IMPORTANT to understand that this option should be enabled - # ! on ALL network SRs if enable at least on one, - # ! or disabled on ALL network SRs if disabled at least on one. - PBFTPort = 8092 - } - - # * Leave it false unless your host uses IPv6 only for node discovery and TCP connection - enableIpv6 = false - - # * If enabled, node automatically checks if it's lagging behind peers, and tries to reconnect if needed - # ! Please note: - # ! can help maintain sync, but may cause frequent reconnections on unstable networks - effectiveCheckEnable = false - - # * Dynamic loading configuration function. - dynamicConfig = { - # enable = false # * default: false - - # * Check interval of configuration file's change. - # checkInterval = 600 # * seconds (default: 600) - } - - # Whether to continue broadcast transactions after at least maxUnsolidifiedBlocks are not solidified. Default: false - # unsolidifiedBlockCheck = false - # maxUnsolidifiedBlocks = 54 - - dns { - # * Enable or disable DNS publish. - # publish = false # * default: false - - # * DNS domain to publish nodes. - # ! Please note: - # ! required if "publish" parameter is set to true - # dnsDomain = "nodes1.example.org" - - # * DNS private key used to publish. - # ! Please note: - # ! required if "publish" parameter is set to true - # * Composition: hex string of length 64 characters - # dnsPrivate = "b71c71a67e1177ad4e901695e1b4b9ee17ae16c6668d313eac2f96dbcda3f291" - - # * Known DNS URLs to publish - # ! Please note: - # ! required if "publish" parameter is set to true - # * URL format tree://{pubkey}@{domain}, default empty - # knownUrls = [ - # "tree://APFGGTFOBVE2ZNAB3CSMNNX6RRK3ODIRLP2AA5U4YFAA6MSYZUYTQ@nodes2.example.org", - # ] - - # * Static nodes to published on DNS - # staticNodes = [ - # "ip:port", - # "ip:port" - # ] - - # * Merge several nodes into a tree leaf. - # ! Please note: - # ! the value should be set between 1 and 5 - # maxMergeSize = 5 - - # * Minimum threshold of node change to update data on DNS - # changeThreshold = 0.1 - - # * DNS server to publish - # ! Please note: - # ! required if "publish" parameter is set to true - # * Supported values: - # * - aws - # * - aliyun - # serverType = "aws" - - # * Access key id of AWS or aliyun API - # ! Please note: - # ! required if "publish" parameter is set to true - # accessKeyId = "your-key-id" - - # Access key secret of AWS or aliyun API - # ! Please note: - # ! required if "publish" parameter is set to true - # accessKeySecret = "your-key-secret" - - # * Specifies the DNS service endpoint used for peer discovery via Alibaba Cloud (Aliyun) - # ! Please note: - # ! required if "publish" parameter is set to true and "serverType" is set to "aliyun" - # aliyunDnsEndpoint = "alidns.aliyuncs.com" - - # * Specifies the AWS Region used by the node when interacting with AWS-based infrastructure - # ! Please note: - # ! required if "publish" parameter is set to true and "serverType" is set to "aws" - # awsRegion = "us-east-1" - - # * Route 53 Hosted Zone identifier used by Amazon Web Services for DNS-based peer discovery. - # ! Please note: - # ! required if "publish" parameter is set to true and "serverType" is set to "aws" - # awsHostZoneId = "your-host-zone-id" - - # * treeUrls is a list of DNS-based bootstrap peers in "tree://" format, including public domain and key info. - # * The node will use DNS to discover peers using these URLs. - # * If left empty, peer discovery relies solely on seed.node and active/passive lists. - # * URL format tree://{pubkey}@{domain}, default empty - treeUrls = [ - # "tree://AKMQMNAJJBL73LXWPXDI4I5ZWWIZ4AWO34DWQ636QOBBXNFXH3LQS@main.trondisco.net", - ] - } - - # * Configures gRPC APIs (used by tronWeb, TronLink) - rpc { - enable = true # ! Please note: - # ! this should be disabled on a SR - port = 50051 - solidityEnable = true # ! Please note: - # ! this should be disabled on a SR. - # ! Additionally, depending on the type of network you are trying to create/join, - # ! you might want to use a different host for the Solidity Node. - # ! Anyway, there are no rules that deny to use a Full Node AND a Solidity Node - # ! on the same host. - solidityPort = 50061 - PBFTEnable = true # * Practical Byzantine Fault Tolerance (consensus mechanism) - # ! Please note: - # ! this option should be disabled on every node except for SRs. - # ! IS IT IMPORTANT to understand that this option should be enabled - # ! on ALL network SRs if enable at least on one, - # ! or disabled on ALL network SRs if disabled at least on one. - PBFTPort = 50071 - - # * Number of gRPC thread, default availableProcessors / 2 - # thread = 16 - - # * The maximum number of concurrent calls permitted for each incoming connection - # * Helps throttle misuse. - # maxConcurrentCallsPerConnection = - - # * The HTTP/2 flow control window - # * If left commented, the default value is 1MB - # * This parameter is used in the gRPC networking layer - it defines how much data (in bytes) can be "in flight" - # * (unacknowledged) over a gRPC connection between nodes. - # * It prevents one node from overwhelming another with too many messages. - # * It's essentially a backpressure mechanism, similar to TCP's sliding window. - # flowControlWindow = - - # * Closes idle gRPC connections after n milliseconds - # * Connection being idle for longer than which will be gracefully terminated - maxConnectionIdleInMillis = 60000 # * milliseconds - - # * Connection lasting longer than which will be gracefully terminated - # maxConnectionAgeInMillis = - - # * The maximum message size allowed to be received on the server - # * If left commented, the default value is 4MB - # maxMessageSize = - - # * The maximum size of header list allowed to be received - # * If left commented, the default value is 8192 - # maxHeaderListSize = - - # * Number of RST_STREAM frames allowed to be sent per connection per period for grpc, by default there is no limit. - # maxRstStream = - - # * Number of seconds per period for grpc - # secondsPerWindow = # * seconds - - # * How many peer connections are needed before allowing broadcast. - # * Please note: transactions can only be broadcasted if the number of effective connections is reached. - minEffectiveConnection = 1 - - # * The switch of the reflection service, effective for all gRPC services - # * toggles gRPC reflection (metadata introspection), - # * useful for clients/tools to inspect services dynamically. - # reflectionService = true - } - - # * Number of worker threads handling Solidity (read-only) queries like contract state lookups. - # * If you see timeouts, increase it to match your CPU cores. - # * Even on an SR or block-producing FullNode, - # * if the node also handles contract queries (i.e. acts as Solidity provider), this setting is relevant. - # * If your node doesn't run a separate Solidity module, - # * this may still be used internally by the FullNode's contract query layer. - # solidity.threads = 8 - - # * Maximum allowed percentage of block time used to produce a block. - # * Default 75% → ensures block is produced and broadcast before the next SR's turn. - # * It means that the timeout is fired after the threshold of 0,25 seconds (for this case) is overtook - # * to produce a block - # * 75% of a block time (or a slot), which is 3 seconds, so (75 * 3) / 100 = 0,25 seconds - # blockProducedTimeOut = 75 - - # * Rate limit for incoming transactions per second from network peers - # netMaxTrxPerSecond = 700 - - # * Whether to enable the node detection function. - # nodeDetectEnable = false # * default: false - - # * Enables read APIs for block/transaction history when running a Lite Full Node (one that doesn't store full blockchain). - # * Leave false unless you explicitly run a lite node. - # openHistoryQueryWhenLiteFN = false - - # * This exposes Ethereum-compatible JSON-RPC APIs (like eth_getLogs). - # * If you want compatibility with tools like Web3.js, you can enable this. - jsonrpc { - # * Note: If you turn on jsonrpc and run it for a while and then turn it off, you will not - # * be able to get the data from eth_getLogs for that period of time. - - # httpFullNodeEnable = true - # httpFullNodePort = 8545 - # httpSolidityEnable = true - # httpSolidityPort = 8555 - # httpPBFTEnable = true - # httpPBFTPort = 8565 - - # * The maximum blocks range to retrieve logs for eth_getLogs, default value is 5000, - # * should be > 0, otherwise means no limit. - # maxBlockRange = 5000 - - # * The maximum number of allowed topics within a topic criteria, default value is 1000, - # * should be > 0, otherwise means no limit. - # maxSubTopics = 1000 - } - - # * Disabled api list, it will work for http, rpc and pbft, both fullnode and soliditynode, - # * but not for jsonrpc. - # ! Please note: - # ! the setting is case insensitive, GetNowBlock2 is equal to getnowblock2 - # disabledApi = [ - # "getaccount", - # "getnowblock2" - # ] - -} -# * ----------------------------------------- RATE.LIMITER ---------------------------------------- -# * Controls API rate limiting -rate.limiter = { - # * Every api could be set a specific rate limit strategy. - # * A number of three strategies are supported: - # * - GlobalPreemptibleAdapter -> limits total concurrent requests - # * - QpsRateLimiterAdapter -> limits total QPS (queries/sec) - # * - IPQPSRateLimiterAdapter -> limits per-IP QPS - # ! Please note: - # ! if not set, the default strategy is QpsRateLimiterAdapter, with 10,000 QPS. - http = [ - # { - # component = "GetNowBlockServlet", - # strategy = "GlobalPreemptibleAdapter", - # paramString = "permit=1" - # }, - # { - # component = "GetAccountServlet", - # strategy = "IPQPSRateLimiterAdapter", - # paramString = "qps=1" - # }, - # { - # component = "ListWitnessesServlet", - # strategy = "QpsRateLimiterAdapter", - # paramString = "qps=1" - # } - ], - - rpc = [ - # { - # component = "protocol.Wallet/GetBlockByLatestNum2", - # strategy = "GlobalPreemptibleAdapter", - # paramString = "permit=1" - # }, - - # { - # component = "protocol.Wallet/GetAccount", - # strategy = "IPQPSRateLimiterAdapter", - # paramString = "qps=1" - # }, - - # { - # component = "protocol.Wallet/ListWitnesses", - # strategy = "QpsRateLimiterAdapter", - # paramString = "qps=1" - # }, - ] - - # * This section defines per-endpoint rate limits (QPS = queries per second) for specific P2P message types - p2p = { - # syncBlockChain = 3.0 # * Limits how often a peer can request blockchain synchronization - # * Protects against excessive sync requests (potential DoS vector) - # fetchInvData = 3.0 # * Controls requests for inventory data (blocks / transactions) - # * Prevents peers from aggressively pulling data - # disconnect = 1.0 # * Limits how frequently disconnect actions can be triggered - # * Avoids abuse of connection churn - } - - # * Maximum total number of requests per second the node will handle across all peers and endpoints: - # * - acts as a global throttle - # * - protects the node from overload - global.qps = 50000 # * default: 50000 - - # * Sets a per-IP rate limit. - global.ip.qps = 10000 # * default: 10000 -} -# * ------------------------------------------ SEED.NODE ------------------------------------------ -# ! Please note: -# ! in private networks, you should list the IP and port of your -# ! Super Representatives (SRs) and/or Full Nodes here. -# ! These act as initial peers ("bootstrap nodes") that other nodes -# ! will connect to when starting up, to discover the rest of the network. -# ! Do NOT include the address and port of the current node itself. -# * These are the peers the node initially connects to (bootstrap nodes). -seed.node = { - # * Example: - # ip.list = [ - # "ip:port", - # "ip:port" - # ] - ip.list = [ - "3.225.171.164:18888", - "52.8.46.215:18888", - "3.79.71.167:18888", - "108.128.110.16:18888", - "18.133.82.227:18888", - "35.180.81.133:18888", - "13.210.151.5:18888", - "18.231.27.82:18888", - "3.12.212.122:18888", - "52.24.128.7:18888", - "15.207.144.3:18888", - "3.39.38.55:18888", - "54.151.226.240:18888", - "35.174.93.198:18888", - "18.210.241.149:18888", - "54.177.115.127:18888", - "54.254.131.82:18888", - "18.167.171.167:18888", - "54.167.11.177:18888", - "35.74.7.196:18888", - "52.196.244.176:18888", - "54.248.129.19:18888", - "43.198.142.160:18888", - "3.0.214.7:18888", - "54.153.59.116:18888", - "54.153.94.160:18888", - "54.82.161.39:18888", - "54.179.207.68:18888", - "18.142.82.44:18888", - "18.163.230.203:18888", - # "[2a05:d014:1f2f:2600:1b15:921:d60b:4c60]:18888", # * Use this address if your node supports ipv6 - # "[2600:1f18:7260:f400:8947:ebf3:78a0:282b]:18888", # * Use this address if your node supports ipv6 - ] -} -# * ---------------------------------------- GENESIS.BLOCK ---------------------------------------- -# * This defines the initial blockchain state (balances and witnesses). -# ! Please note: -# ! the genesis block MUST BE the same for all the nodes in the network, -# ! either they are SRs or Full Nodes. -# ! This ensure a consistent and identical genesis block across the whole network, -# ! otherwise it would reject all blocks as invalid (INCOMPATIBLE_CHAIN error). -genesis.block = { - # * Reserve initial balances - assets = [ - # * Initial supply holder address - { - accountName = "Zion" - accountType = "AssetIssue" - address = "TLLM21wteSPs4hKjbxgmH1L6poyMjeTbHm" - balance = "99000000000000000" - }, - # * TRON founder address - { - accountName = "Sun" - accountType = "AssetIssue" - address = "TXmVpin5vq5gdZsciyyjdZgKRUju4st1wM" - balance = "0" - }, - # * Burn address - # ! Please note: - # ! only the Blackhole is mandatory for internal consistency - # * The blackhole address is a designated burn address in TRON. - # * It's used internally for reward deductions, fee burns, or traps. - # * Even in a private chain, you should define a blackhole address so that - # * TRON's internal accounting logic (e.g. deductions, fees) doesn't break. - { - accountName = "Blackhole" - accountType = "AssetIssue" - address = "TLsV52sRDL79HXGGm9yzwKibb6BeruhUzy" - balance = "-9223372036854775808" - } - # ! Please note: - # ! the SR information must be set here when configuring a SR node - # { - # accountName = "SR" - # accountType = "AssetIssue" - # address = "base58-SR-address" - # balance = "1000000000000000000" # * SUN -> 1 TRX = 1,000,000 SUN, so that quantity is 1,000,000,000,000 TRX - # } - ] - - # * These are the initial Super Representatives (SRs) at genesis. - # * Each has: - # * address -> SR account - # * url -> optional info page - # * voteCount -> initial votes (defines ranking order) and block generation order - # ! Please note: - # ! the more the votes, the better for the SR - witnesses = [ - { - address = "base58-SR-address" - url = "http://SR-INFO-PAGE-URL.com" - voteCount = 1000000000000000 - } - ] - - # * Genesis block timestamp - timestamp = "0" - - # * Always "0x0" (64 characters long) for the genesis block, but TRON uses a placeholder for backward compatibility. - # * Safe to keep as is. - parentHash = "0xe58f33f9baf9305dc6f82b9f1934ea8f0ade2defb951258d50167028c780351f" -} -# * ---------------------------------- LOCALWITNESSACCOUNTADDRESS --------------------------------- -# * "Witness permissions" refer to a mechanism where a SR can delegate block production permission to another account. -# * If localWitnessAccountAddress is set, that means the node may use a permissioned address -# * to produce blocks instead of the SR's primary account. -# * It allows flexibility in permission models (e.g. key rotation or proxy delegation). -# * If you leave that blank, the node uses the private key addresses -# * in localwitness directly (SR account itself) for signing. -# * It is used when the witness account has set the witnessPermission. -# localWitnessAccountAddress = "" -# * ----------------------------------------- LOCALWITNESS ---------------------------------------- -# * List of private keys for SR accounts used to sign blocks -# ! Please note: -# ! required if your node participates as an SR (block producer) -localwitness = [ -] -# * ------------------------------------- LOCALWITNESSKEYSTORE ------------------------------------ -# * This configuration is used when a localwitness address is stored in a JSON file -# ! Please note: -# ! localwitness and localwitnesskeystore are mutually exclusive -# ? Ref: https://developers.tron.network/docs/deploy-the-fullnode-or-supernode#how-to-use-keystore--password-to-specify-the-private-key-of-the-super-representative-accounts -# localwitnesskeystore = [ -# "localwitnesskeystore.json" -# ] -# * -------------------------------------------- BLOCK -------------------------------------------- -# * Block configuration: -# * - block.needSyncCheck: controls whether the node performs synchronization checks when receiving -# * or producing new blocks. -# * If you disable it, the node may accept or broadcast blocks even if it's not fully synced, -# * which can lead to forks or inconsistencies in your private network. -# ! Please note: -# ! in a private network, set: -# ! - one SR with this parameter to false -# ! - all other SRs and Full Nodes to true -# ! This ensures that there is only one source of truth for block data. -# ! Additionally, when you create a brand new private chain, there's a moment where: -# ! - the blockchain is empty (only genesis block exists); -# ! - there are no other nodes to sync from yet; -# ! The first SR must produce the very first block(s) to bootstrap the chain. -# ! If needSyncCheck = true on that first SR, it will try to check peers' height, -# ! and since it finds no peers (everyone's empty), it assumes it's out of sync and refuses to produce blocks. -# * - block.maintenanceTimeInterval: time interval during which SRs generate blocks -# * - block.proposalExpireTime: time interval after which a proposal (to change a network parameter) expires -block = { - needSyncCheck = true # * default: true - # ! Please note: - # ! maintenanceTimeInterval and proposalExpireTime take effect just when the node is a SR! - maintenanceTimeInterval = 21600000 # * default: 21600000, in milliseconds (6 hours -> Epoch) - proposalExpireTime = 259200000 # * default: 259200000, in milliseconds (3 days) - # * Controls whether the node validates the lock (freeze) duration of funds when processing transactions and account state - # checkFrozenTime = 1 # * default: 1 -} -# * --------------------------------------------- TRX --------------------------------------------- -trx { - # * This setting determines whether transactions must reference a specific recent block when being created. - # * It's a security and replay protection feature. - # * If enabled, each transaction must include: - # * - ref_block_bytes - # * - ref_block_hash - # * These refer to a recent block (e.g., the latest 1–2 minutes old). - # * This ensures that: - # * - transactions cannot be replayed long after being broadcast - # * - nodes know the context for validation - # * It's similar to Ethereum's nonce + blockHash consistency mechanism. - # * If disabled, the node might accept transactions referencing older blocks, which is not recommended. - # * Accepted values: - # * - solid (reccomended) - # * - head (may cause TaPos error) - reference.block = "solid" - - # * Transaction expiration time - expiration.timeInMilliseconds = 60000 # * default: 60000, in milliseconds (1 minute) -} -# * ---------------------------------------------- VM --------------------------------------------- -# * This section configures execution environment for smart contracts -vm = { - supportConstant = true # * Whether constant / pure view methods calls are supported (enabled) - # ! Please note: - # ! it should be configured only for Full Nodes, not SRs. - maxEnergyLimitForConstant = 100000000 # * Energy limit for constant calls (in SUN, and since 1 TRX = 1,000,000 SUN, so 100 TRX) - # ! Please note: - # ! pure/view functions are gas free, - # ! but they need Energy (computation) to be executed. - # ! It's a safety measure to avoid DoS (Denial of Service), - # ! due to the high volume of computation required - minTimeRatio = 0.0 # * Relative bounds on execution time scaling - maxTimeRatio = 5.0 - saveInternalTx = false # * Whether to persist internal transactions (calls within contracts), - # * when a contract calls another contract's method and emit a transaction. - # saveFeaturedInternalTx = false # * Indicates whether the node stores featured internal transactions, - # * such as freeze, vote and so on - # saveCancelAllUnfreezeV2Details = false # * Indicates whether the node stores the details of the internal - # * transactions generated by the CANCELALLUNFREEZEV2 opcode, - # * such as bandwidth/energy/tronpower cancel amount. - # longRunningTime = 10 # * In rare cases, transactions that will be within the specified - # * maximum execution time (default 10(ms)) are re-executed and packaged - # estimateEnergy = false # * Indicates whether the node support estimate energy API. - # estimateEnergyMaxRetry = 3 # * Indicates the max retry time for executing transaction in estimating energy. -} -# * ------------------------------------------ COMMITTEE ------------------------------------------ -# * The Committee is a governance component of the TRON protocol. -# * It's not a node or a machine. -# * It's a logical group formed by the top 27 Super Representatives (SRs) the ones elected by TRX holders. -# * The Committee votes on network parameters, such as: -# * - block size -# * - energy limit -# * - proposal thresholds -# * - transaction fees -# * - resource model updates -# * These parameters are stored in the Chain Parameters on-chain. -# * When you run a private TRON network, the Committee still exists, but since you control all SRs, -# * it's effectively you (your SR nodes) who make up the Committee. -# * You can change parameters via proposals (API: /wallet/proposalcreate). -# ! Please note: -# ! keep this section equal for every node in the network. -# * ------------------------------------------ COMMITTEE ------------------------------------------ -# * The Committee is a governance component of the TRON protocol. -# * It's not a node or a machine. -# * It's a logical group formed by the top 27 Super Representatives (SRs) the ones elected by TRX holders. -# * The Committee votes on network parameters, such as: -# * - block size -# * - energy limit -# * - proposal thresholds -# * - transaction fees -# * - resource model updates -# * These parameters are stored in the Chain Parameters on-chain. -# * When you run a private TRON network, the Committee still exists, but since you control all SRs, -# * it's effectively you (your SR nodes) who make up the Committee. -# * You can change parameters via proposals (API: /wallet/proposalcreate). -# ! Please note: -# ! keep this section equal for every node in the network. -# ? Ref: https://github.com/tronprotocol/java-tron/blob/develop/framework/src/main/java/org/tron/core/config/args/Args.java -committee = { - # ! Please note: - # ! you must enable this feature if you intend to deploy (and use) smart contracts - allowCreationOfContracts = 1 # * Whether new contract deployment is allowed (0 = disallowed; 1 = allowed) - allowDynamicEnergy = 1 # * Enables the dynamic energy system - # ! Please note: - # ! - this should be 0 on private blockchain, - # ! so the energy used when calling contracts is always the same - # ! - this value must match with the SRs' ones, - # ! or a different formula will be used to calculate the energy of a transaction, - # ! and it will result in a BAD_BLOCK error. - dynamicEnergyThreshold = 10000 # * Threshold value for triggering energy cost adjustments - dynamicEnergyIncreaseFactor = 2000 # * Increase factor for energy cost when threshold is exceeded - dynamicEnergyMaxFactor = 34000 # * Maximum allowed increase multiplier for energy cost - allowUpdateAccountName = 1 # * Allows users to change their account name after creation - allowSameTokenName = 1 # * Controls whether TRC-10 tokens can share the same name - allowDelegateResource = 1 # * Enables Resource Delegation -> the ability to delegate Bandwidth and Energy to another account - changedDelegation = 1 # * Enables newer version of delegation behavior introduced after certain network upgrades - allowDelegateOptimization = 1 # * Optimizes delegation logic for performance and reduced resource cost - allowTvmTransferTrc10 = 1 # * Allows TRC-10 token transfers from inside smart contracts executed by the TVM (Tron Virtual Machine) - allowMultiSign = 1 # * Enables multi-signature accounts on your chain - allowShieldedTRC20Transaction = 1 # * Enables ZK-SNARK based shielded (private) TRC20 transactions - allowOptimizeBlackHole = 1 # * Optimization for the "black hole" account (used when burning TRX) - allowTvmVote = 1 # * Enables smart contracts to participate in voting (via TVM) - allowTvmConstantinople = 1 # * Enables opcodes and logic from the Constantinople upgrade (e.g., CREATE2, EXTCODEHASH) - allowTvmSolidity059 = 1 # * Ensures full compatibility with Solidity 0.5.9+ compiled contracts - allowTvmIstanbul = 1 # * Enables Istanbul fork features (cheaper opcodes, better gas efficiency) - allowTvmLondon = 1 # * Adds EIP-1559-style changes and gas-related behavior updates - allowTvmShangHai = 1 # * Latest fork compatibility (Shanghai), enables new EVM behavior and improved gas metering - allowHigherLimitForMaxCpuTimeOfOneTx = 1 # * Increases CPU time limit for complex transactions (e.g., heavy smart contract execution) - allowAssetOptimization = 1 # * Enables optimized TRC10 asset management for performance - allowNewReward = 1 # * Uses new reward distribution logic for SRs - memoFee = 1000000 # * Fee (in SUN) for including a memo with a transaction - unfreezeDelayDays = 1 # * Number of days before frozen balance can be unfrozen again - # ! Please note: - # ! when this parameter is > 0, then ALLOW_TVM_FREEZE_V2 is going to be 1 (enabled) - allowOptimizedReturnValueOfChainId = 1 # * Optimizes the return value of the TVM CHAINID opcode - allowCancelAllUnfreezeV2 = 1 # * Enables the newer version (V2) of the "Cancel All Unfreeze" feature for resources - maxDelegateLockPeriod = 30 # * Maximum period (in days) for locking delegated resources - allowOldRewardOpt = 1 # * Keeps compatibility with old reward optimization behavior - allowEnergyAdjustment = 1 # * Allows dynamic adjustment of transaction energy consumption - allowStrictMath = 1 # * Forces strict arithmetic rules in TVM (no silent overflows/underflows) -} -# * --------------------------------------- EVENT.SUBSCRIBE --------------------------------------- -# * This section is used to register to blockchain events -# * For example, when a block is created, a transaction is verified, and many more -# ? Ref: https://developers.tron.network/docs/event-subscription -event.subscribe = { - # * There are two ways to use the events subscription: - # * 1. using the Event Plugin (Kafka or MongoDB), which is the RECOMMENDED way - # * 2. using the native ZeroMQ - - # * Version of the event service framework: - # * - use the value of 1 for the V2.0 - # * - use the value of 0 for the V1.0 - version = 1 - - # * This is a new feature in v2.0 designed for historical data subscriptions. - # * It allows the service to start processing and pushing events from a specific historical block height (number) - # * stored on the local node. - # * When: - # * - startSyncBlockNum <= 0, this feature is disabled. - # * - startSyncBlockNum > 0, this feature is enabled, and historical event synchronization - # * will begin from the specified block height. Note: We recommend using the latest version - # * of the event plugin when enabling this feature. - startSyncBlockNum = 0 - - # * Settings to use (or not) the native event subscripiton plugin - native = { - useNativeQueue = false # * true = use ZeroMQ queue; false = use Kafka or MongoDB - bindport = 5555 # * Port used by the ZeroMQ (native) queue - sendqueuelength = 1000 # * Max length of the send ZeroMQ queue - } - - # * The absolute local path to the plugin-(kafka/mongodb)-1.0.0.zip file. - # ! Please note: - # ! ensure the path is correct, or the plugin will fail to load. - path = "/event-plugin/build/plugins/plugin-mongodb-1.0.0.zip" - - # * The Kafka/MongoDB server address in ip:port format. - # * The default Kafka port is 9092. - # * The default MongoDB port is 27017. - # ! Please note: - # ! ensure the port number is correct and that the Kafka/MongoDB service is accessible. - server = "mongo:27017" - - # ! Please note: - # ! this option is only for the MongoDB plugin and should be ignored for the Kafka plugin. - # * Config as follow: dbname|username|password - dbconfig = "eventlog|tron|123456" - - # * Parse events emitted from smart contracts - contractParse = true - - # * Configure the events to subscribe to. - # ? For more details, please refer to the Event Types section below: - # ? https://tronprotocol.github.io/documentation-en/architecture/event/#event-types - # ! Please note: - # ! for performance reasons, don't enable more than two topics. - # * Each topic allows the configuration of these parameters: - # * https://github.com/tronprotocol/java-tron/blob/master/common/src/main/java/org/tron/common/logsfilter/TriggerConfig.java - topics = [ - { - triggerName = "transaction" # * (String) The event type identifier. - # * For transaction events, this value is fixed to transaction. - enable = true # * (Boolean) Enables or disables the subscription for this event type. - topic = "transaction" # * The name of the topic for receiving this event type in MongoDB or Kafka. - # ! Please note: - # ! this value must be consistent with the configuration in MongoDB or Kafka. - redundancy = false # * If true, the event will also write to the tron.log - # * for transactions included in solidified blocks. - ethCompatible = false # * (Boolean) If set to true, the event payload will include Ethereum-compatible - # * fields (e.g., transactionIndex, logList). - # ! Please note: - # ! this field is available just for the "transaction" trigger. - solidified = false # * (Boolean) If set to true, the subscription will only deliver events - }, - { - triggerName = "block" # * (String) The event type identifier. - # * For block events, this value is fixed to block. - enable = false # * (Boolean) Enables or disables the subscription for this event type. - topic = "block" # * The name of the topic for receiving this event type in MongoDB or Kafka. - # ! Please note: - # ! this value must be consistent with the configuration in MongoDB or Kafka. - redundancy = false # * If true, the event will also write to the tron.log - solidified = false # * (Boolean) If set to true, the subscription will only deliver events - # * for transactions included in solidified blocks. - }, - { - triggerName = "contractevent" # * (String) The event type identifier. - # * Subscribes to all contract events from all blocks. - enable = true # * (Boolean) Enables or disables the subscription for this event type. - topic = "contractevent" # * The name of the topic for receiving this event type in MongoDB or Kafka. - # ! Please note: - # ! this value must be consistent with the configuration in MongoDB or Kafka. - redundancy = false # * If true, the event will also write to the tron.log - solidified = false # * (Boolean) If set to true, the subscription will only deliver events - # * for transactions included in solidified blocks. - }, - { - triggerName = "contractlog" # * (String) The event type identifier. - # * Subscribes to all contract logs from all blocks. - enable = false # * (Boolean) Enables or disables the subscription for this event type. - topic = "contractlog" # * The name of the topic for receiving this event type in MongoDB or Kafka. - # ! Please note: - # ! this value must be consistent with the configuration in MongoDB or Kafka. - redundancy = false # * If true, the event will also write to the tron.log - solidified = false # * (Boolean) If set to true, the subscription will only deliver events - # * for transactions included in solidified blocks. - }, - { - triggerName = "solidityevent" # * (String) The event type identifier. - # * Subscribes only to contract events from solidified blocks. - enable = false # * (Boolean) Enables or disables the subscription for this event type. - topic = "solidityevent" # * The name of the topic for receiving this event type in MongoDB or Kafka. - # ! Please note: - # ! this value must be consistent with the configuration in MongoDB or Kafka. - redundancy = false # * If true, the event will also write to the tron.log - }, - { - triggerName = "soliditylog" # * (String) The event type identifier. - # * Subscribes only to contract logs from solidified blocks. - enable = false # * (Boolean) Enables or disables the subscription for this event type. - topic = "soliditylog" # * The name of the topic for receiving this event type in MongoDB or Kafka. - # ! Please note: - # ! this value must be consistent with the configuration in MongoDB or Kafka. - redundancy = false # * If true, the event will also write to the tron.log - }, - { - triggerName = "solidity" # * (String) The event type identifier. - # * Subscribes to real-time notifications for the latest solidified block height. - # * This is ideal for applications that need to track the chain's finalized state. - enable = false # * (Boolean) Enables or disables the subscription for this event type. - topic = "solidity" # * The name of the topic for receiving this event type in MongoDB or Kafka. - # ! Please note: - # ! this value must be consistent with the configuration in MongoDB or Kafka. - redundancy = false # * If true, the event will also write to the tron.log - } - ] - - # * Filtering parameters. - # ? For more details, please refer to the Event Types section below: - # ? https://tronprotocol.github.io/documentation-en/architecture/event/#event-types - filter = { - # * Possible values: - # * - "": no filters are applied - # * - "earliest" - # * - specific block number - # * to be used as the beginning of the queried range - fromblock = "" - - # * Possible values: - # * - "": no filters are applied - # * - "latest" - # * - specific block number - # * to be used as the end of the queried range - toblock = "" - - # * Possible values: - # * - "": no filters are applied - # * - "latest"# * Contract address(es) to subscribe the node to filter events - # * If it's set to "", the node will receive contract logs/events with any contract address. - # * - specific block number - # * to be used as the end of the queried range - contractAddress = [ - "" - ] - - # * Contract topic to subscribe to node to filter events - # * If it's set to "", the node will receive contract logs/events with any contract topic. - contractTopic = [ - "" - ] - } -} - -# ! Please note: -# ! this parameter is really important when staking energy and bandwidth to invoke smart contracts methods (paid ones) -# * If the block number of the chain is equal to the value specified for this parameter, -# * then the energy is consumed before consuming TRX to handle a transaction -# * Possible settings: -# * - when set to 0, the "threshold" is disabled, making energy consumption immediate instead of burning TRX -# * - when set to a value > 0, the energy consumption is "enabled" when the specified block number is reached -# ? Ref: https://github.com/tronprotocol/java-tron/blob/1e35f79a165424bbae319799d9aca92948b8f5c2/chainbase/src/main/java/org/tron/common/utils/ForkController.java#L112 +# * ------------------------------------- NODE CONFIGURATION -------------------------------------- +# * This file is used to configure a TRON network node (Full Node, Super Representative, Solidity Node, Lite Full Node). +# * This file uses a standardized commenting convention, designed to improve readability and developer experience when using +# * the Better Comments extension in Visual Studio Code. +# * The file leverages categorized comment prefixes to visually distinguish different types of information: +# ! (Important comments) +# * Used for critical notes that require developer attention. +# * These comments typically highlight constraints, warnings, or non-obvious behaviors. +# * By convention, they are always followed by a “Please note” statement. +# * (Informational comments) +# * Used to provide contextual explanations about a specific parameter or configuration section. +# * These comments are purely descriptive and do not require any action from the developer. +# ? (Reference comments) +# * Used to include external resources, documentation links, or additional references related to a parameter or section. +# * These are supplementary and do not require immediate attention. +# * This structure ensures a consistent, scannable configuration file where critical information stands out +# * while maintaining clear and accessible documentation inline. +# ? Ref (Better Comments): https://marketplace.visualstudio.com/items?itemName=aaron-bond.better-comments +# ? Ref: https://tronprotocol.github.io/documentation-en/using_javatron/private_network/ +# * --------------------------------------------- SECTIONS ---------------------------------------- +# * 1. net +# * 2. storage +# * 3. crypto +# * 4. node +# * 5. rate.limiter +# * 6. seed.node +# * 7. genesis.block +# * 8. localWitnessAccountAddress +# * 9. localwitness +# * 10. localwitnesskeystore +# * 11. block +# * 12. trx +# * 13. vm +# * 14. committee +# * 15. event.subscribe +# * --------------------------------------------- NET --------------------------------------------- +# * This configuration defines the network type +# * Use: +# * - mainnet, when working with the TRON main network +# * - testnet, when working with a local testnet +# * - everything else (like "privatenet") when working on a private chain +# ! Please note: +# ! changing this value determines the genesis block and seed nodes used. +net { + type = privatenet +} +# * ------------------------------------------- STORAGE ------------------------------------------- +# * TRON uses a LevelDB database +# * LevelDB ref: https://github.com/google/leveldb +storage { + # * Directory for storing persistent data + db.engine = "LEVELDB" + db.sync = false + db.directory = "database" + index.directory = "index" + transHistory.switch = "on" + + # * These are the databases which will be created when starting the node for the first time + # * You _can_ custom these 14 databases' configurations: + # * - account + # * - account-index + # * - asset-issue + # * - block + # * - block-index + # * - block_KDB + # * - peers + # * - properties + # * - recent-block + # * - trans + # * - utxo + # * - votes + # * - witness + # * - witness_schedule + # * If you don't change these configurations, + # * default db configs will be used, + # * and data will be stored in the path of "output-directory", + # * or the one set by "-d" (or "--output-directory"). + + # ? If you want to improve LevelDB performances, you can use the following settings: + # ! Please note: + # ! if this configuration causes the node to open more file descriptors, check your system ulimit if you get a too many open files error. + # ! See: https://github.com/tronprotocol/tips/blob/master/tip-343.md for more detail + # * ----- Improvement settings start here ----- + # default = { + # maxOpenFiles = 100 + # } + # defaultM = { + # maxOpenFiles = 500 + # } + # defaultL = { + # maxOpenFiles = 1000 + # } + # * ----- Improvement settings end here ----- + + # * Please note: + # * when using a different configuration for the RocksDB + # ! Please note: + # ! "name" is a required field that must be set! + properties = [ + # { + # name = "account", + # path = "storage_directory_test", + # createIfMissing = true, + # paranoidChecks = true, + # verifyChecksums = true, + # compressionType = 1, # * compressed with snappy + # blockSize = 4096, # * 4 KB = 4 * 1024 B + # writeBufferSize = 10485760, # * 10 MB = 10 * 1024 * 1024 B + # cacheSize = 10485760, # * 10 MB = 10 * 1024 * 1024 B + # maxOpenFiles = 100 + # }, + # { + # name = "account-index", + # path = "storage_directory_test", + # createIfMissing = true, + # paranoidChecks = true, + # verifyChecksums = true, + # compressionType = 1, # * compressed with snappy + # blockSize = 4096, # * 4 KB = 4 * 1024 B + # writeBufferSize = 10485760, # * 10 MB = 10 * 1024 * 1024 B + # cacheSize = 10485760, # * 10 MB = 10 * 1024 * 1024 B + # maxOpenFiles = 100 + # }, + ] + + # * This tells the node whether it needs to update old asset formats + # * to the new TRC10/20 format when reading older blocks. + # * Keep it "true" for backward compatibility. + needToUpdateAsset = true + + # * dbsettings is needed when using rocksdb as the storage implement (db.engine="ROCKSDB"). + # ! Please note: + # ! it is strongly recommended to not modify these parameters + # ! unless you know what you're doing. + dbSettings = { + levelNumber = 7 + # compactThreads = 32 + blocksize = 64 # * n * KB + maxBytesForLevelBase = 256 # * n * MB + maxBytesForLevelMultiplier = 10 + level0FileNumCompactionTrigger = 4 + targetFileSizeBase = 256 # * n * MB + targetFileSizeMultiplier = 1 + } + + # ! Please note: + # ! the backup plugin is available only when db.engine="ROCKSDB" + backup = { + enable = false # * Indicate whether enable the backup plugin + propPath = "prop.properties" # * Record which .bak directory is valid + bak1path = "bak1/database" # * Two backup directories must be set to prevent application halt unexpected (e.g. kill -9). + bak2path = "bak2/database" + frequency = 10000 # * Indicates that the db backup should occur every 10000 blocks processed + } + + # * If true, the node keeps a lookup index of historical balances per account for time-based queries. + # * Default false saves disk and improves speed, but historical balance queries won't work. + # * Only enable if you need that API. + balance.history.lookup = false + + # * Used for resuming blockchain sync from a "checkpoint" snapshot + # * instead of starting from genesis (first block generated). + # ! Please note: + # ! usually not used in a private blockchain. + # checkpoint.version = 2 # * version number of the snapshot + # checkpoint.sync = true # * whether to enable checkpoint synchronization + + # * Defines transaction caching parameters (used to speed up node startup time) + # * The estimated number of block transactions (min 100, max 10000). + # * The total number of cached transactions is 65536 (UINT8) * txCache.estimatedTransactions + # txCache.estimatedTransactions = 1000 # * Number of transactions expected per block (used to size cache arrays) + # * If true, transaction cache initialization will be faster + # txCache.initOptimization = true # * Speeds up initialization by preallocating cache memory + + # * Data root setting, for check data, currently, only reward-vi is used. + # ! Please note: + # ! leave untouched (even for private networks). + # merkleRoot = { + # reward-vi = 9debcb9924055500aaae98cdee10501c5c39d4daa75800a996f4bdda73dbccd8 # * main-net, Sha256Hash, hexString + # } + +} +# * -------------------------------------------- CRYPTO ------------------------------------------- +# * Specifies the cryptographic algorithm used for signing and verifying transactions +# ! Please note: never change this value to anything else +crypto { + engine = "eckey" # * standard ECDSA (secp256k1), used across TRON +} +# * --------------------------------------------- NODE -------------------------------------------- +# * This section keeps the node configuration +node { + # * These settings control the node visibility and discovery to/for other peers, and save discovered peers by the (current) node in the network + # ! Depending on the type of network that you are trying to create/join, + # ! you might want to disable the node discovery. + # ! For example, a Solidity Node should not have this option enabled, + # ! since its source of information (blockchain state, hence blocks) + # ! comes from the Full Node, which is controlled by the parameter "trustNode" + # ! in this section ("node"). + discovery { + enable = true # * Enable/Disable automatic peer discovery in the network + # * (controls whether the node searches for and announces itself to other peers) + persist = true # * Persist the discovered peers in a local file or database + } + + # * This section is used to export node metrics to an external tool such as "Prometheus" + # * If enabled, your node will expose data like block sync speed, TPS, memory usage. + metrics = { + # prometheus + # { + # enable = true + # port = "9527" + # } + } + + # * This section is used to configure the node backup + backup { + # * Determines which node acts as leader in a backup cluster (lower value = higher priority) + # priority = 8 + + # * UDP port used for backup communication between members + # ! Please note: + # ! each member should have the same configuration + # port = 10001 + + # * How often nodes send "I'm alive" messages + # ! Please note: + # ! each member should have the same configuration + # keepAliveInterval = 3000 # * milliseconds + + # * List of IPs of other nodes in the same cluster (not including yourself) + # ! Please note: + # ! do not include the current configuration's node IP + # members = [ + # # "ip", + # # "ip" + # ] + } + + # * This section is used to shutdown the node in specific conditions + shutdown { + # BlockTime = "54 59 08 * * ?" # * When the Block Timestamp matches the pattern (Cron format) + # BlockHeight = 33350800 # * When the Block Height (Block Number) matches the value + # BlockCount = 12 # * When the block sync count after the node has started is matched + } + + # * trustNode is used by a Solidity Node (or light node) to designate which FullNode it "trusts" + # * to fetch confirmed (or "solidified") blocks. + # ! Please note: + # ! this is used when another node (which is a Solidity Node or a Lite Full Node) connects + # ! to a Full Node (to query data from the blockchain), + # ! since neither the Solidity Node nor the Lite Full Node store the network history (blockchain). + # trustNode = "ip:port" + # trustNode = "127.0.0.1:50051" + + # * Enable extra wallet extended API interface + walletExtensionApi = true + + # * Defines the TCP port on which your node listens for incoming peer-to-peer (P2P) + # * connections from other nodes in the network (Full Nodes, Solidity Nodes, SRs) + # * This value can be the same for every node in the network, since it refers to different nodes anyway. + # ! Please note: + # ! this is not the port where HTTP, rpc or grpc API listen on + listen.port = 18888 + + # * Max time to wait when connecting to a peer + connection.timeout = 5 # * seconds + + # * Max time to wait for a block response from a peer + fetchBlock.timeout = 200 # * seconds + + # * Number of requested blocks in a single batch during the node synchronization process + syncFetchBatchNum = 2000 # * default: 2000 - max: 2000 + + # * These define how many network IO threads are used by the Netty framework + # * 0: auto, based on CPU cores + # ! Please note: + # ! only change if you're optimizing very high-performance nodes. + tcpNettyWorkThreadNum = 0 + udpNettyWorkThreadNum = 1 + + # * Maximum total peer-to-peer connections your node will maintain (both inbound and outbound), + # * without any distinction between node type + # * Pro tip: adjust accordingly based on the number of peers in the private network + maxConnections = 30 + + # * This is the lower threshold of peer connections the node tries to keep alive. + # * If the active peers drop below minConnections, + # * the node will try to open new outbound connections to reachable peers (via discovery or seed) + # * to bring itself back up. + # ! Please note: + # ! it ensures the node doesn't stay isolated with too few peers. + # * Pro tip: adjust accordingly based on the number of peers in the private network, + # * to avoid that the node will search for nodes for an undefinitely amount of time + minConnections = 2 + + # * Number of peers that must be active to sync data + # * This the minimum number of active peers required for the node to start or continue data synchronization + # * (block downloads, network sync). + # * "Active" means peers that are fully connected and exchanging data, not just idle or handshake-only. + # * If the number of active peers falls below this threshold, + # * the node may temporarily stall or refuse to sync until enough peers are back online. + # * If you set minActiveConnections = 3, + # * then unless the node has at least 3 fully active peers, it might not perform block sync. + # * Pro tip: adjust accordingly based on the number of peers in the private network, + # * to avoid that the node will perform data synchronization + minActiveConnections = 2 + + # * This parameter sets the number of threads dedicated to signature validation / signing operations + # * (for verifying incoming transactions or blocks). + # ! Please note: + # ! adjust accordingly by using this formula + # ! validateSignThreadNum = availableProcessors / 2 + # validateSignThreadNum = 16 + + # * Prevents DDoS / redundant connections + maxConnectionsWithSameIp = 2 + + # * Maximum number of concurrent HTTP API connections your node will handle + maxHttpConnectNumber = 50 + + # * Minimum required block participation rate (%) to remain active. + # ! Please note: + # ! applies to Super Representatives only. + # * If your SR fails to produce enough blocks, it may be penalized. + # * This parameter defines the minimum required participation rate of Super Representatives (SRs) + # * during block production. + # * In other words, how many SRs must actually produce blocks during an Epoch + # * (6 hour by default, dictated by the value of maintenanceTimeInterval parameter in this config file). + # * So, for example, if there are 5 SRs, and the minParticipationRate is 15 (%), + # * then at least (0.75, rounded up to the nearest integer) 1 SR must produce blocks in a round. + # * A "round" is a time range during which all network SRs can produce a block in their slot. + # * In case they fail, rewards will not be shared between them. + # * It's mainly used in Super Representative consensus logic - not configurable elsewhere. + # * It ensures the network stays stable and avoids finalizing rounds with too few active producers. + # ! Please note: + # ! set this parameter to 0 to disable the check + minParticipationRate = 15 # * percentage + + # * Controls whether the node enables API endpoints related to shielded (privacy-preserving) transactions +# allowShieldedTransactionApi = true + + # * Controls whether the node prints internal processing logs to the console (stdout) +# openPrintLog = true + + # * If set to true, SR packs transactions into a block in descending order of fee; + # * otherwise, it packs them based on their receive timestamp. +# openTransactionSort = false # * default: false + + # * The threshold for the number of broadcast transactions received from each peer every second. + # ! Please note: + # ! transactions exceeding this threshold will be discarded. +# maxTps = 1000 # * default: 1000 + + # * When true, this setting might enable full TCP disconnect logic + # * for peers under certain conditions (e.g. poor performance). + # * When false (default), the node retains more leniency in connection persistence. + # * It's a kind of fail-safe/disconnect policy for TCP connections; + # * unless you're debugging connectivity you can leave it false. + isOpenFullTcpDisconnect = false + + # * This is a time threshold (in seconds) after which a peer is considered inactive if no communication. + # * If a peer hasn't sent or responded in more than inactiveThreshold, the node may drop it or mark it unhealthy. + inactiveThreshold = 600 # * seconds + + # * Defines protocol version to communicate with other peers + # * Possible values: + # * - 11111: mainnet + # * - 20180622: testnet + # * - 201910292: Nile + # * - user defined value (integer) + # ! Please note: + # ! for private networks use your own, + # ! and keep it consistent between ALL the private network peers. + # ! Depending on the type of network that you are trying to create/join, + # ! you might want to comment out this parameter. + # ! For example, a Solidity Node should not have this value filled, + # ! since it doesn't participate to peer-to-peer communication, + # ! but it's using the Full Node (through the "trustNode" parameter) to interact in the network. + p2p { + version = 11111 + } + + # * These are static peer lists: + # * - active -> peer addresses to which the node actively attempts connection (outbound). + # * Active nodes usually participate to the network a lot, sending and receiving data to and from them. + # * - passive -> peer addresses from which the node accepts inbound connections (or those expected to connect to you). + # * Passive nodes usually don't participate to the network that much, but they just receive data. + # * If left empty, node discovers peers dynamically via discovery/seeds. + # * Use these if you want to pinpoint specific peers rather than rely entirely on discovery. + active = [ + # * Active establish connection in any case + # * Sample entries: + # * "ip:port", + # * "ip:port" + ] + + passive = [ + # * Passive accept connection in any case + # * Sample entries: + # * "ip:port", + # * "ip:port" + ] + + # * fastForward is a list of trusted peers for fast sync (early block download). + # * Since the block production is a "long" process (production -> propagation -> finalization), + # * using fastForward nodes can speed up the process. + # * If left empty, the node just uses its normal peer list/discovery - slower but works. + # * With entries, when starting, the node prioritizes connecting to these peers to accelerate synchronization. + # ! Please note: + # ! these nodes are used just for fast synchronization. + # ! Only trusted nodes should be added to this list. + # * Sample entries: + # * "ip:port", + # * "ip:port" + fastForward = [ + ] + + # * This section includes the following configurations: + # * - FullNode + # * - SolidityNode + # * - PBFT + # * In detail: + # * - FullNode: provides full blockchain data + APIs + can produce blocks (if SR). + # * - SolidityNode: **historically** a separate component optimized for contract-state queries and light reads. + # * If you want efficient contract access (especially for dApps), having a Solidity Node helps. + # * But in modern Java-Tron, FullNode already supports solidity data queries, so you may not strictly need a separate SolidityNode. + # * - PBFT: stands for Practical Byzantine Fault Tolerance - the consensus mechanism layer. + # * The HTTP / PBFT port settings allow APIs to interact with PBFT modules (e.g. proposals, votes). + # * If you're doing smart contracts and blockchain operations, you should enable FullNode's HTTP and RPC; + # * a separate SolidityNode is optional unless performance demands it. + http { + fullNodeEnable = true # ! Please note: + # ! this should be disabled on a SR + fullNodePort = 8090 + solidityEnable = true # ! Please note: + # ! this should be disabled on a SR. + # ! Additionally, depending on the type of network you are trying to create/join, + # ! you might want to use a different host for the Solidity Node. + # ! Anyway, there are no rules that deny to use a Full Node AND a Solidity Node + # ! on the same host. + solidityPort = 8091 + PBFTEnable = true # * Practical Byzantine Fault Tolerance (consensus mechanism) + # ! Please note: + # ! this option should be disabled on every node except for SRs. + # ! IS IT IMPORTANT to understand that this option should be enabled + # ! on ALL network SRs if enable at least on one, + # ! or disabled on ALL network SRs if disabled at least on one. + PBFTPort = 8092 + } + + # * Leave it false unless your host uses IPv6 only for node discovery and TCP connection + enableIpv6 = false + + # * If enabled, node automatically checks if it's lagging behind peers, and tries to reconnect if needed + # ! Please note: + # ! can help maintain sync, but may cause frequent reconnections on unstable networks + effectiveCheckEnable = false + + # * Dynamic loading configuration function. + dynamicConfig = { + # enable = false # * default: false + + # * Check interval of configuration file's change. + # checkInterval = 600 # * seconds (default: 600) + } + + # Whether to continue broadcast transactions after at least maxUnsolidifiedBlocks are not solidified. Default: false + # unsolidifiedBlockCheck = false + # maxUnsolidifiedBlocks = 54 + + dns { + # * Enable or disable DNS publish. + # publish = false # * default: false + + # * DNS domain to publish nodes. + # ! Please note: + # ! required if "publish" parameter is set to true + # dnsDomain = "nodes1.example.org" + + # * DNS private key used to publish. + # ! Please note: + # ! required if "publish" parameter is set to true + # * Composition: hex string of length 64 characters + # dnsPrivate = "b71c71a67e1177ad4e901695e1b4b9ee17ae16c6668d313eac2f96dbcda3f291" + + # * Known DNS URLs to publish + # ! Please note: + # ! required if "publish" parameter is set to true + # * URL format tree://{pubkey}@{domain}, default empty + # knownUrls = [ + # "tree://APFGGTFOBVE2ZNAB3CSMNNX6RRK3ODIRLP2AA5U4YFAA6MSYZUYTQ@nodes2.example.org", + # ] + + # * Static nodes to published on DNS + # staticNodes = [ + # "ip:port", + # "ip:port" + # ] + + # * Merge several nodes into a tree leaf. + # ! Please note: + # ! the value should be set between 1 and 5 + # maxMergeSize = 5 + + # * Minimum threshold of node change to update data on DNS + # changeThreshold = 0.1 + + # * DNS server to publish + # ! Please note: + # ! required if "publish" parameter is set to true + # * Supported values: + # * - aws + # * - aliyun + # serverType = "aws" + + # * Access key id of AWS or aliyun API + # ! Please note: + # ! required if "publish" parameter is set to true + # accessKeyId = "your-key-id" + + # Access key secret of AWS or aliyun API + # ! Please note: + # ! required if "publish" parameter is set to true + # accessKeySecret = "your-key-secret" + + # * Specifies the DNS service endpoint used for peer discovery via Alibaba Cloud (Aliyun) + # ! Please note: + # ! required if "publish" parameter is set to true and "serverType" is set to "aliyun" + # aliyunDnsEndpoint = "alidns.aliyuncs.com" + + # * Specifies the AWS Region used by the node when interacting with AWS-based infrastructure + # ! Please note: + # ! required if "publish" parameter is set to true and "serverType" is set to "aws" + # awsRegion = "us-east-1" + + # * Route 53 Hosted Zone identifier used by Amazon Web Services for DNS-based peer discovery. + # ! Please note: + # ! required if "publish" parameter is set to true and "serverType" is set to "aws" + # awsHostZoneId = "your-host-zone-id" + + # * treeUrls is a list of DNS-based bootstrap peers in "tree://" format, including public domain and key info. + # * The node will use DNS to discover peers using these URLs. + # * If left empty, peer discovery relies solely on seed.node and active/passive lists. + # * URL format tree://{pubkey}@{domain}, default empty + treeUrls = [ + # "tree://AKMQMNAJJBL73LXWPXDI4I5ZWWIZ4AWO34DWQ636QOBBXNFXH3LQS@main.trondisco.net", + ] + } + + # * Configures gRPC APIs (used by tronWeb, TronLink) + rpc { + enable = true # ! Please note: + # ! this should be disabled on a SR + port = 50051 + solidityEnable = true # ! Please note: + # ! this should be disabled on a SR. + # ! Additionally, depending on the type of network you are trying to create/join, + # ! you might want to use a different host for the Solidity Node. + # ! Anyway, there are no rules that deny to use a Full Node AND a Solidity Node + # ! on the same host. + solidityPort = 50061 + PBFTEnable = true # * Practical Byzantine Fault Tolerance (consensus mechanism) + # ! Please note: + # ! this option should be disabled on every node except for SRs. + # ! IS IT IMPORTANT to understand that this option should be enabled + # ! on ALL network SRs if enable at least on one, + # ! or disabled on ALL network SRs if disabled at least on one. + PBFTPort = 50071 + + # * Number of gRPC thread, default availableProcessors / 2 + # thread = 16 + + # * The maximum number of concurrent calls permitted for each incoming connection + # * Helps throttle misuse. + # maxConcurrentCallsPerConnection = + + # * The HTTP/2 flow control window + # * If left commented, the default value is 1MB + # * This parameter is used in the gRPC networking layer - it defines how much data (in bytes) can be "in flight" + # * (unacknowledged) over a gRPC connection between nodes. + # * It prevents one node from overwhelming another with too many messages. + # * It's essentially a backpressure mechanism, similar to TCP's sliding window. + # flowControlWindow = + + # * Closes idle gRPC connections after n milliseconds + # * Connection being idle for longer than which will be gracefully terminated + maxConnectionIdleInMillis = 60000 # * milliseconds + + # * Connection lasting longer than which will be gracefully terminated + # maxConnectionAgeInMillis = + + # * The maximum message size allowed to be received on the server + # * If left commented, the default value is 4MB + # maxMessageSize = + + # * The maximum size of header list allowed to be received + # * If left commented, the default value is 8192 + # maxHeaderListSize = + + # * Number of RST_STREAM frames allowed to be sent per connection per period for grpc, by default there is no limit. + # maxRstStream = + + # * Number of seconds per period for grpc + # secondsPerWindow = # * seconds + + # * How many peer connections are needed before allowing broadcast. + # * Please note: transactions can only be broadcasted if the number of effective connections is reached. + minEffectiveConnection = 1 + + # * The switch of the reflection service, effective for all gRPC services + # * toggles gRPC reflection (metadata introspection), + # * useful for clients/tools to inspect services dynamically. + # reflectionService = true + } + + # * Number of worker threads handling Solidity (read-only) queries like contract state lookups. + # * If you see timeouts, increase it to match your CPU cores. + # * Even on an SR or block-producing FullNode, + # * if the node also handles contract queries (i.e. acts as Solidity provider), this setting is relevant. + # * If your node doesn't run a separate Solidity module, + # * this may still be used internally by the FullNode's contract query layer. + # solidity.threads = 8 + + # * Maximum allowed percentage of block time used to produce a block. + # * Default 75% → ensures block is produced and broadcast before the next SR's turn. + # * It means that the timeout is fired after the threshold of 0,25 seconds (for this case) is overtook + # * to produce a block + # * 75% of a block time (or a slot), which is 3 seconds, so (75 * 3) / 100 = 0,25 seconds + # blockProducedTimeOut = 75 + + # * Rate limit for incoming transactions per second from network peers + # netMaxTrxPerSecond = 700 + + # * Whether to enable the node detection function. + # nodeDetectEnable = false # * default: false + + # * Enables read APIs for block/transaction history when running a Lite Full Node (one that doesn't store full blockchain). + # * Leave false unless you explicitly run a lite node. + # openHistoryQueryWhenLiteFN = false + + # * This exposes Ethereum-compatible JSON-RPC APIs (like eth_getLogs). + # * If you want compatibility with tools like Web3.js, you can enable this. + jsonrpc { + # * Note: If you turn on jsonrpc and run it for a while and then turn it off, you will not + # * be able to get the data from eth_getLogs for that period of time. + + # httpFullNodeEnable = true + # httpFullNodePort = 8545 + # httpSolidityEnable = true + # httpSolidityPort = 8555 + # httpPBFTEnable = true + # httpPBFTPort = 8565 + + # * The maximum blocks range to retrieve logs for eth_getLogs, default value is 5000, + # * should be > 0, otherwise means no limit. + # maxBlockRange = 5000 + + # * The maximum number of allowed topics within a topic criteria, default value is 1000, + # * should be > 0, otherwise means no limit. + # maxSubTopics = 1000 + } + + # * Disabled api list, it will work for http, rpc and pbft, both fullnode and soliditynode, + # * but not for jsonrpc. + # ! Please note: + # ! the setting is case insensitive, GetNowBlock2 is equal to getnowblock2 + # disabledApi = [ + # "getaccount", + # "getnowblock2" + # ] + +} +# * ----------------------------------------- RATE.LIMITER ---------------------------------------- +# * Controls API rate limiting +rate.limiter = { + # * Every api could be set a specific rate limit strategy. + # * A number of three strategies are supported: + # * - GlobalPreemptibleAdapter -> limits total concurrent requests + # * - QpsRateLimiterAdapter -> limits total QPS (queries/sec) + # * - IPQPSRateLimiterAdapter -> limits per-IP QPS + # ! Please note: + # ! if not set, the default strategy is QpsRateLimiterAdapter, with 10,000 QPS. + http = [ + # { + # component = "GetNowBlockServlet", + # strategy = "GlobalPreemptibleAdapter", + # paramString = "permit=1" + # }, + # { + # component = "GetAccountServlet", + # strategy = "IPQPSRateLimiterAdapter", + # paramString = "qps=1" + # }, + # { + # component = "ListWitnessesServlet", + # strategy = "QpsRateLimiterAdapter", + # paramString = "qps=1" + # } + ], + + rpc = [ + # { + # component = "protocol.Wallet/GetBlockByLatestNum2", + # strategy = "GlobalPreemptibleAdapter", + # paramString = "permit=1" + # }, + + # { + # component = "protocol.Wallet/GetAccount", + # strategy = "IPQPSRateLimiterAdapter", + # paramString = "qps=1" + # }, + + # { + # component = "protocol.Wallet/ListWitnesses", + # strategy = "QpsRateLimiterAdapter", + # paramString = "qps=1" + # }, + ] + + # * This section defines per-endpoint rate limits (QPS = queries per second) for specific P2P message types + p2p = { + # syncBlockChain = 3.0 # * Limits how often a peer can request blockchain synchronization + # * Protects against excessive sync requests (potential DoS vector) + # fetchInvData = 3.0 # * Controls requests for inventory data (blocks / transactions) + # * Prevents peers from aggressively pulling data + # disconnect = 1.0 # * Limits how frequently disconnect actions can be triggered + # * Avoids abuse of connection churn + } + + # * Maximum total number of requests per second the node will handle across all peers and endpoints: + # * - acts as a global throttle + # * - protects the node from overload + global.qps = 50000 # * default: 50000 + + # * Sets a per-IP rate limit. + global.ip.qps = 10000 # * default: 10000 +} +# * ------------------------------------------ SEED.NODE ------------------------------------------ +# ! Please note: +# ! in private networks, you should list the IP and port of your +# ! Super Representatives (SRs) and/or Full Nodes here. +# ! These act as initial peers ("bootstrap nodes") that other nodes +# ! will connect to when starting up, to discover the rest of the network without relying on node discovery. +# ! This list should include all the trusted nodes (SRs, Full Nodes) that are presented to a node when joining the network. +# ! Do NOT include the address and port of the current node itself. +# * These are the peers the node initially connects to (bootstrap nodes). +seed.node = { + # * Example: + # ip.list = [ + # "ip:port", + # "ip:port" + # ] + ip.list = [ + "3.225.171.164:18888", + "52.8.46.215:18888", + "3.79.71.167:18888", + "108.128.110.16:18888", + "18.133.82.227:18888", + "35.180.81.133:18888", + "13.210.151.5:18888", + "18.231.27.82:18888", + "3.12.212.122:18888", + "52.24.128.7:18888", + "15.207.144.3:18888", + "3.39.38.55:18888", + "54.151.226.240:18888", + "35.174.93.198:18888", + "18.210.241.149:18888", + "54.177.115.127:18888", + "54.254.131.82:18888", + "18.167.171.167:18888", + "54.167.11.177:18888", + "35.74.7.196:18888", + "52.196.244.176:18888", + "54.248.129.19:18888", + "43.198.142.160:18888", + "3.0.214.7:18888", + "54.153.59.116:18888", + "54.153.94.160:18888", + "54.82.161.39:18888", + "54.179.207.68:18888", + "18.142.82.44:18888", + "18.163.230.203:18888", + # "[2a05:d014:1f2f:2600:1b15:921:d60b:4c60]:18888", # * Use this address if your node supports ipv6 + # "[2600:1f18:7260:f400:8947:ebf3:78a0:282b]:18888", # * Use this address if your node supports ipv6 + ] +} +# * ---------------------------------------- GENESIS.BLOCK ---------------------------------------- +# * This defines the initial blockchain state (balances and witnesses). +# ! Please note: +# ! the genesis block MUST BE the same for all the nodes in the network, +# ! either they are SRs or Full Nodes. +# ! This ensure a consistent and identical genesis block across the whole network, +# ! otherwise it would reject all blocks as invalid (INCOMPATIBLE_CHAIN error). +genesis.block = { + # * Reserve initial balances + assets = [ + # * Initial supply holder address + { + accountName = "Zion" + accountType = "AssetIssue" + address = "TLLM21wteSPs4hKjbxgmH1L6poyMjeTbHm" + balance = "99000000000000000" + }, + # * TRON founder address + { + accountName = "Sun" + accountType = "AssetIssue" + address = "TXmVpin5vq5gdZsciyyjdZgKRUju4st1wM" + balance = "0" + }, + # * Burn address + # ! Please note: + # ! only the Blackhole is mandatory for internal consistency + # * The blackhole address is a designated burn address in TRON. + # * It's used internally for reward deductions, fee burns, or traps. + # * Even in a private chain, you should define a blackhole address so that + # * TRON's internal accounting logic (e.g. deductions, fees) doesn't break. + { + accountName = "Blackhole" + accountType = "AssetIssue" + address = "TLsV52sRDL79HXGGm9yzwKibb6BeruhUzy" + balance = "-9223372036854775808" + } + # ! Please note: + # ! the SR information must be set here when configuring a SR node + # { + # accountName = "SR" + # accountType = "AssetIssue" + # address = "base58-SR-address" + # balance = "1000000000000000000" # * SUN -> 1 TRX = 1,000,000 SUN, so that quantity is 1,000,000,000,000 TRX + # } + ] + + # * These are the initial Super Representatives (SRs) at genesis. + # * Each has: + # * address -> SR account + # * url -> optional info page + # * voteCount -> initial votes (defines ranking order) and block generation order + # ! Please note: + # ! the more the votes, the better for the SR + witnesses = [ + { + address = "base58-SR-address" + url = "http://SR-INFO-PAGE-URL.com" + voteCount = 1000000000000000 + } + ] + + # * Genesis block timestamp + timestamp = "0" + + # * Always "0x0" (64 characters long) for the genesis block, but TRON uses a placeholder for backward compatibility. + # * Safe to keep as is. + parentHash = "0xe58f33f9baf9305dc6f82b9f1934ea8f0ade2defb951258d50167028c780351f" +} +# * ---------------------------------- LOCALWITNESSACCOUNTADDRESS --------------------------------- +# * "Witness permissions" refer to a mechanism where a SR can delegate block production permission to another account. +# * If localWitnessAccountAddress is set, that means the node may use a permissioned address +# * to produce blocks instead of the SR's primary account. +# * It allows flexibility in permission models (e.g. key rotation or proxy delegation). +# * If you leave that blank, the node uses the private key addresses +# * in localwitness directly (SR account itself) for signing. +# * It is used when the witness account has set the witnessPermission. +# localWitnessAccountAddress = "" +# * ----------------------------------------- LOCALWITNESS ---------------------------------------- +# * List of private keys for SR accounts used to sign blocks +# ! Please note: +# ! required if your node participates as an SR (block producer) +localwitness = [ +] +# * ------------------------------------- LOCALWITNESSKEYSTORE ------------------------------------ +# * This configuration is used when a localwitness address is stored in a JSON file +# ! Please note: +# ! localwitness and localwitnesskeystore are mutually exclusive +# ? Ref: https://developers.tron.network/docs/deploy-the-fullnode-or-supernode#how-to-use-keystore--password-to-specify-the-private-key-of-the-super-representative-accounts +# localwitnesskeystore = [ +# "localwitnesskeystore.json" +# ] +# * -------------------------------------------- BLOCK -------------------------------------------- +# * Block configuration: +# * - block.needSyncCheck: controls whether the node performs synchronization checks when receiving +# * or producing new blocks. +# * If you disable it, the node may accept or broadcast blocks even if it's not fully synced, +# * which can lead to forks or inconsistencies in your private network. +# ! Please note: +# ! in a private network, set: +# ! - one SR with this parameter to false +# ! - all other SRs and Full Nodes to true +# ! This ensures that there is only one source of truth for block data. +# ! Additionally, when you create a brand new private chain, there's a moment where: +# ! - the blockchain is empty (only genesis block exists); +# ! - there are no other nodes to sync from yet; +# ! The first SR must produce the very first block(s) to bootstrap the chain. +# ! If needSyncCheck = true on that first SR, it will try to check peers' height, +# ! and since it finds no peers (everyone's empty), it assumes it's out of sync and refuses to produce blocks. +# * - block.maintenanceTimeInterval: time interval during which SRs generate blocks +# * - block.proposalExpireTime: time interval after which a proposal (to change a network parameter) expires +block = { + needSyncCheck = true # * default: true + # ! Please note: + # ! maintenanceTimeInterval and proposalExpireTime take effect just when the node is a SR! + maintenanceTimeInterval = 21600000 # * default: 21600000, in milliseconds (6 hours -> Epoch) + proposalExpireTime = 259200000 # * default: 259200000, in milliseconds (3 days) + # * Controls whether the node validates the lock (freeze) duration of funds when processing transactions and account state + # checkFrozenTime = 1 # * default: 1 +} +# * --------------------------------------------- TRX --------------------------------------------- +trx { + # * This setting determines whether transactions must reference a specific recent block when being created. + # * It's a security and replay protection feature. + # * If enabled, each transaction must include: + # * - ref_block_bytes + # * - ref_block_hash + # * These refer to a recent block (e.g., the latest 1–2 minutes old). + # * This ensures that: + # * - transactions cannot be replayed long after being broadcast + # * - nodes know the context for validation + # * It's similar to Ethereum's nonce + blockHash consistency mechanism. + # * If disabled, the node might accept transactions referencing older blocks, which is not recommended. + # * Accepted values: + # * - solid (reccomended) + # * - head (may cause TaPos error) + reference.block = "solid" + + # * Transaction expiration time + expiration.timeInMilliseconds = 60000 # * default: 60000, in milliseconds (1 minute) +} +# * ---------------------------------------------- VM --------------------------------------------- +# * This section configures execution environment for smart contracts +vm = { + supportConstant = true # * Whether constant / pure view methods calls are supported (enabled) + # ! Please note: + # ! it should be configured only for Full Nodes, not SRs. + maxEnergyLimitForConstant = 100000000 # * Energy limit for constant calls (in SUN, and since 1 TRX = 1,000,000 SUN, so 100 TRX) + # ! Please note: + # ! pure/view functions are gas free, + # ! but they need Energy (computation) to be executed. + # ! It's a safety measure to avoid DoS (Denial of Service), + # ! due to the high volume of computation required + minTimeRatio = 0.0 # * Relative bounds on execution time scaling + maxTimeRatio = 5.0 + saveInternalTx = false # * Whether to persist internal transactions (calls within contracts), + # * when a contract calls another contract's method and emit a transaction. + # saveFeaturedInternalTx = false # * Indicates whether the node stores featured internal transactions, + # * such as freeze, vote and so on + # saveCancelAllUnfreezeV2Details = false # * Indicates whether the node stores the details of the internal + # * transactions generated by the CANCELALLUNFREEZEV2 opcode, + # * such as bandwidth/energy/tronpower cancel amount. + # longRunningTime = 10 # * In rare cases, transactions that will be within the specified + # * maximum execution time (default 10(ms)) are re-executed and packaged + # estimateEnergy = false # * Indicates whether the node support estimate energy API. + # estimateEnergyMaxRetry = 3 # * Indicates the max retry time for executing transaction in estimating energy. +} +# * ------------------------------------------ COMMITTEE ------------------------------------------ +# * The Committee is a governance component of the TRON protocol. +# * It's not a node or a machine. +# * It's a logical group formed by the top 27 Super Representatives (SRs) the ones elected by TRX holders. +# * The Committee votes on network parameters, such as: +# * - block size +# * - energy limit +# * - proposal thresholds +# * - transaction fees +# * - resource model updates +# * These parameters are stored in the Chain Parameters on-chain. +# * When you run a private TRON network, the Committee still exists, but since you control all SRs, +# * it's effectively you (your SR nodes) who make up the Committee. +# * You can change parameters via proposals (API: /wallet/proposalcreate). +# ! Please note: +# ! keep this section equal for every node in the network. +# * ------------------------------------------ COMMITTEE ------------------------------------------ +# * The Committee is a governance component of the TRON protocol. +# * It's not a node or a machine. +# * It's a logical group formed by the top 27 Super Representatives (SRs) the ones elected by TRX holders. +# * The Committee votes on network parameters, such as: +# * - block size +# * - energy limit +# * - proposal thresholds +# * - transaction fees +# * - resource model updates +# * These parameters are stored in the Chain Parameters on-chain. +# * When you run a private TRON network, the Committee still exists, but since you control all SRs, +# * it's effectively you (your SR nodes) who make up the Committee. +# * You can change parameters via proposals (API: /wallet/proposalcreate). +# ! Please note: +# ! keep this section equal for every node in the network. +# ? Ref: https://github.com/tronprotocol/java-tron/blob/develop/framework/src/main/java/org/tron/core/config/args/Args.java +committee = { + # ! Please note: + # ! you must enable this feature if you intend to deploy (and use) smart contracts + allowCreationOfContracts = 1 # * Whether new contract deployment is allowed (0 = disallowed; 1 = allowed) + allowDynamicEnergy = 1 # * Enables the dynamic energy system + # ! Please note: + # ! - this should be 0 on private blockchain, + # ! so the energy used when calling contracts is always the same + # ! - this value must match with the SRs' ones, + # ! or a different formula will be used to calculate the energy of a transaction, + # ! and it will result in a BAD_BLOCK error. + dynamicEnergyThreshold = 10000 # * Threshold value for triggering energy cost adjustments + dynamicEnergyIncreaseFactor = 2000 # * Increase factor for energy cost when threshold is exceeded + dynamicEnergyMaxFactor = 34000 # * Maximum allowed increase multiplier for energy cost + allowUpdateAccountName = 1 # * Allows users to change their account name after creation + allowSameTokenName = 1 # * Controls whether TRC-10 tokens can share the same name + allowDelegateResource = 1 # * Enables Resource Delegation -> the ability to delegate Bandwidth and Energy to another account + changedDelegation = 1 # * Enables newer version of delegation behavior introduced after certain network upgrades + allowDelegateOptimization = 1 # * Optimizes delegation logic for performance and reduced resource cost + allowTvmTransferTrc10 = 1 # * Allows TRC-10 token transfers from inside smart contracts executed by the TVM (Tron Virtual Machine) + allowMultiSign = 1 # * Enables multi-signature accounts on your chain + allowShieldedTRC20Transaction = 1 # * Enables ZK-SNARK based shielded (private) TRC20 transactions + allowOptimizeBlackHole = 1 # * Optimization for the "black hole" account (used when burning TRX) + allowTvmVote = 1 # * Enables smart contracts to participate in voting (via TVM) + allowTvmConstantinople = 1 # * Enables opcodes and logic from the Constantinople upgrade (e.g., CREATE2, EXTCODEHASH) + allowTvmSolidity059 = 1 # * Ensures full compatibility with Solidity 0.5.9+ compiled contracts + allowTvmIstanbul = 1 # * Enables Istanbul fork features (cheaper opcodes, better gas efficiency) + allowTvmLondon = 1 # * Adds EIP-1559-style changes and gas-related behavior updates + allowTvmShangHai = 1 # * Latest fork compatibility (Shanghai), enables new EVM behavior and improved gas metering + allowHigherLimitForMaxCpuTimeOfOneTx = 1 # * Increases CPU time limit for complex transactions (e.g., heavy smart contract execution) + allowAssetOptimization = 1 # * Enables optimized TRC10 asset management for performance + allowNewReward = 1 # * Uses new reward distribution logic for SRs + memoFee = 1000000 # * Fee (in SUN) for including a memo with a transaction + unfreezeDelayDays = 1 # * Number of days before frozen balance can be unfrozen again + # ! Please note: + # ! when this parameter is > 0, then ALLOW_TVM_FREEZE_V2 is going to be 1 (enabled) + allowOptimizedReturnValueOfChainId = 1 # * Optimizes the return value of the TVM CHAINID opcode + allowCancelAllUnfreezeV2 = 1 # * Enables the newer version (V2) of the "Cancel All Unfreeze" feature for resources + maxDelegateLockPeriod = 30 # * Maximum period (in days) for locking delegated resources + allowOldRewardOpt = 1 # * Keeps compatibility with old reward optimization behavior + allowEnergyAdjustment = 1 # * Allows dynamic adjustment of transaction energy consumption + allowStrictMath = 1 # * Forces strict arithmetic rules in TVM (no silent overflows/underflows) +} +# * --------------------------------------- EVENT.SUBSCRIBE --------------------------------------- +# * This section is used to register to blockchain events +# * For example, when a block is created, a transaction is verified, and many more +# ? Ref: https://developers.tron.network/docs/event-subscription +event.subscribe = { + # * There are two ways to use the events subscription: + # * 1. using the Event Plugin (Kafka or MongoDB), which is the RECOMMENDED way + # * 2. using the native ZeroMQ + + # * Version of the event service framework: + # * - use the value of 1 for the V2.0 + # * - use the value of 0 for the V1.0 + version = 1 + + # * This is a new feature in v2.0 designed for historical data subscriptions. + # * It allows the service to start processing and pushing events from a specific historical block height (number) + # * stored on the local node. + # * When: + # * - startSyncBlockNum <= 0, this feature is disabled. + # * - startSyncBlockNum > 0, this feature is enabled, and historical event synchronization + # * will begin from the specified block height. Note: We recommend using the latest version + # * of the event plugin when enabling this feature. + startSyncBlockNum = 0 + + # * Settings to use (or not) the native event subscripiton plugin + native = { + useNativeQueue = false # * true = use ZeroMQ queue; false = use Kafka or MongoDB + bindport = 5555 # * Port used by the ZeroMQ (native) queue + sendqueuelength = 1000 # * Max length of the send ZeroMQ queue + } + + # * The absolute local path to the plugin-(kafka/mongodb)-1.0.0.zip file. + # ! Please note: + # ! ensure the path is correct, or the plugin will fail to load. + path = "/event-plugin/build/plugins/plugin-mongodb-1.0.0.zip" + + # * The Kafka/MongoDB server address in ip:port format. + # * The default Kafka port is 9092. + # * The default MongoDB port is 27017. + # ! Please note: + # ! ensure the port number is correct and that the Kafka/MongoDB service is accessible. + server = "mongo:27017" + + # ! Please note: + # ! this option is only for the MongoDB plugin and should be ignored for the Kafka plugin. + # * Config as follow: dbname|username|password + dbconfig = "eventlog|tron|123456" + + # * Parse events emitted from smart contracts + contractParse = true + + # * Configure the events to subscribe to. + # ? For more details, please refer to the Event Types section below: + # ? https://tronprotocol.github.io/documentation-en/architecture/event/#event-types + # ! Please note: + # ! for performance reasons, don't enable more than two topics. + # * Each topic allows the configuration of these parameters: + # * https://github.com/tronprotocol/java-tron/blob/master/common/src/main/java/org/tron/common/logsfilter/TriggerConfig.java + topics = [ + { + triggerName = "transaction" # * (String) The event type identifier. + # * For transaction events, this value is fixed to transaction. + enable = true # * (Boolean) Enables or disables the subscription for this event type. + topic = "transaction" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log + # * for transactions included in solidified blocks. + ethCompatible = false # * (Boolean) If set to true, the event payload will include Ethereum-compatible + # * fields (e.g., transactionIndex, logList). + # ! Please note: + # ! this field is available just for the "transaction" trigger. + solidified = false # * (Boolean) If set to true, the subscription will only deliver events + }, + { + triggerName = "block" # * (String) The event type identifier. + # * For block events, this value is fixed to block. + enable = false # * (Boolean) Enables or disables the subscription for this event type. + topic = "block" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log + solidified = false # * (Boolean) If set to true, the subscription will only deliver events + # * for transactions included in solidified blocks. + }, + { + triggerName = "contractevent" # * (String) The event type identifier. + # * Subscribes to all contract events from all blocks. + enable = true # * (Boolean) Enables or disables the subscription for this event type. + topic = "contractevent" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log + solidified = false # * (Boolean) If set to true, the subscription will only deliver events + # * for transactions included in solidified blocks. + }, + { + triggerName = "contractlog" # * (String) The event type identifier. + # * Subscribes to all contract logs from all blocks. + enable = false # * (Boolean) Enables or disables the subscription for this event type. + topic = "contractlog" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log + solidified = false # * (Boolean) If set to true, the subscription will only deliver events + # * for transactions included in solidified blocks. + }, + { + triggerName = "solidityevent" # * (String) The event type identifier. + # * Subscribes only to contract events from solidified blocks. + enable = false # * (Boolean) Enables or disables the subscription for this event type. + topic = "solidityevent" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log + }, + { + triggerName = "soliditylog" # * (String) The event type identifier. + # * Subscribes only to contract logs from solidified blocks. + enable = false # * (Boolean) Enables or disables the subscription for this event type. + topic = "soliditylog" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log + }, + { + triggerName = "solidity" # * (String) The event type identifier. + # * Subscribes to real-time notifications for the latest solidified block height. + # * This is ideal for applications that need to track the chain's finalized state. + enable = false # * (Boolean) Enables or disables the subscription for this event type. + topic = "solidity" # * The name of the topic for receiving this event type in MongoDB or Kafka. + # ! Please note: + # ! this value must be consistent with the configuration in MongoDB or Kafka. + redundancy = false # * If true, the event will also write to the tron.log + } + ] + + # * Filtering parameters. + # ? For more details, please refer to the Event Types section below: + # ? https://tronprotocol.github.io/documentation-en/architecture/event/#event-types + filter = { + # * Possible values: + # * - "": no filters are applied + # * - "earliest" + # * - specific block number + # * to be used as the beginning of the queried range + fromblock = "" + + # * Possible values: + # * - "": no filters are applied + # * - "latest" + # * - specific block number + # * to be used as the end of the queried range + toblock = "" + + # * Possible values: + # * - "": no filters are applied + # * - "latest"# * Contract address(es) to subscribe the node to filter events + # * If it's set to "", the node will receive contract logs/events with any contract address. + # * - specific block number + # * to be used as the end of the queried range + contractAddress = [ + "" + ] + + # * Contract topic to subscribe to node to filter events + # * If it's set to "", the node will receive contract logs/events with any contract topic. + contractTopic = [ + "" + ] + } +} + +# ! Please note: +# ! this parameter is really important when staking energy and bandwidth to invoke smart contracts methods (paid ones) +# * If the block number of the chain is equal to the value specified for this parameter, +# * then the energy is consumed before consuming TRX to handle a transaction +# * Possible settings: +# * - when set to 0, the "threshold" is disabled, making energy consumption immediate instead of burning TRX +# * - when set to a value > 0, the energy consumption is "enabled" when the specified block number is reached +# ? Ref: https://github.com/tronprotocol/java-tron/blob/1e35f79a165424bbae319799d9aca92948b8f5c2/chainbase/src/main/java/org/tron/common/utils/ForkController.java#L112 enery.limit.block.num = 0 \ No newline at end of file From ccadabd5a3331664ea40bc4b5368d1870acdbf26 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Fri, 27 Mar 2026 21:03:24 +0100 Subject: [PATCH 25/28] feat(config): replace old TRON documentation references with the new ones --- framework/src/main/resources/config.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 7e0db2e351f..0e28b34ead2 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -874,7 +874,7 @@ localwitness = [ # * This configuration is used when a localwitness address is stored in a JSON file # ! Please note: # ! localwitness and localwitnesskeystore are mutually exclusive -# ? Ref: https://developers.tron.network/docs/deploy-the-fullnode-or-supernode#how-to-use-keystore--password-to-specify-the-private-key-of-the-super-representative-accounts +# ? Ref: https://tronprotocol.github.io/documentation-en/using_javatron/installing_javatron/#specifying-super-representative-account-private-key-using-keystore-password # localwitnesskeystore = [ # "localwitnesskeystore.json" # ] @@ -1032,7 +1032,7 @@ committee = { # * --------------------------------------- EVENT.SUBSCRIBE --------------------------------------- # * This section is used to register to blockchain events # * For example, when a block is created, a transaction is verified, and many more -# ? Ref: https://developers.tron.network/docs/event-subscription +# ? Ref: https://tronprotocol.github.io/documentation-en/architecture/event/ event.subscribe = { # * There are two ways to use the events subscription: # * 1. using the Event Plugin (Kafka or MongoDB), which is the RECOMMENDED way From f8e84dc21fd6ac949fbcc9159baa8a3c906aefa4 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Tue, 31 Mar 2026 19:47:51 +0200 Subject: [PATCH 26/28] chore(config): remove Solidity Node due deprecation --- framework/src/main/resources/config.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 0e28b34ead2..9c60737687f 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -1,5 +1,5 @@ # * ------------------------------------- NODE CONFIGURATION -------------------------------------- -# * This file is used to configure a TRON network node (Full Node, Super Representative, Solidity Node, Lite Full Node). +# * This file is used to configure a TRON network node (Full Node, Super Representative, Lite Full Node). # * This file uses a standardized commenting convention, designed to improve readability and developer experience when using # * the Better Comments extension in Visual Studio Code. # * The file leverages categorized comment prefixes to visually distinguish different types of information: From a7a7107ab37c473dc5ed49e20df8775d8474524e Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Tue, 31 Mar 2026 19:51:22 +0200 Subject: [PATCH 27/28] chore(config): remove special characters --- framework/src/main/resources/config.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 9c60737687f..7909a2968c6 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -6,7 +6,7 @@ # ! (Important comments) # * Used for critical notes that require developer attention. # * These comments typically highlight constraints, warnings, or non-obvious behaviors. -# * By convention, they are always followed by a “Please note” statement. +# * By convention, they are always followed by a "Please note" statement. # * (Informational comments) # * Used to provide contextual explanations about a specific parameter or configuration section. # * These comments are purely descriptive and do not require any action from the developer. From 94d48bd22a144ec6ffd618834cf0fb99029b0681 Mon Sep 17 00:00:00 2001 From: Francesco Di Muro Date: Tue, 31 Mar 2026 20:01:54 +0200 Subject: [PATCH 28/28] chore(config): remove milseading comment regarding "Better Comments" VSCode extension --- framework/src/main/resources/config.conf | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/framework/src/main/resources/config.conf b/framework/src/main/resources/config.conf index 5dba6833a7e..ea48896c314 100644 --- a/framework/src/main/resources/config.conf +++ b/framework/src/main/resources/config.conf @@ -1,7 +1,7 @@ # * ------------------------------------- NODE CONFIGURATION -------------------------------------- # * This file is used to configure a TRON network node (Full Node, Super Representative, Lite Full Node). # * This file uses a standardized commenting convention, designed to improve readability and developer experience when using -# * the Better Comments extension in Visual Studio Code. +# * the "Better Comments" extension in Visual Studio Code. # * The file leverages categorized comment prefixes to visually distinguish different types of information: # ! (Important comments) # * Used for critical notes that require developer attention. @@ -15,8 +15,11 @@ # * These are supplementary and do not require immediate attention. # * This structure ensures a consistent, scannable configuration file where critical information stands out # * while maintaining clear and accessible documentation inline. -# ? Ref (Better Comments): https://marketplace.visualstudio.com/items?itemName=aaron-bond.better-comments # ? Ref: https://tronprotocol.github.io/documentation-en/using_javatron/private_network/ +# ! Please note: +# ! despite the "Better Comments" extension enhances the Developer Experience by highlighting comments +# ! in different colors based on their syntax, the extension does not add any other functional value to the file itself. +# ! In case you choose to use the extension, this should not be installed on any node. # * --------------------------------------------- SECTIONS ---------------------------------------- # * 1. net # * 2. storage