From afccd0b4cd32c2ad56d10f22401bc9590358dade Mon Sep 17 00:00:00 2001 From: marta-lokhova Date: Wed, 7 Jun 2023 16:39:28 -0700 Subject: [PATCH 1/2] Add max tx count for Soroban network settings --- src/ledger/NetworkConfig.cpp | 57 ++++++++++++++++--- src/ledger/NetworkConfig.h | 8 +++ .../test/LedgerCloseMetaStreamTests.cpp | 6 +- src/main/Config.cpp | 1 + src/main/Config.h | 2 + 5 files changed, 62 insertions(+), 12 deletions(-) diff --git a/src/ledger/NetworkConfig.cpp b/src/ledger/NetworkConfig.cpp index 8587023fcc..a952cf2988 100644 --- a/src/ledger/NetworkConfig.cpp +++ b/src/ledger/NetworkConfig.cpp @@ -61,7 +61,7 @@ initialContractComputeSettingsEntry(Config const& cfg) ConfigSettingEntry entry(CONFIG_SETTING_CONTRACT_COMPUTE_V0); auto& e = entry.contractCompute(); - if (cfg.TESTING_LEDGER_MAX_INSTRUCTIONS && cfg.USE_CONFIG_FOR_GENESIS) + if (cfg.USE_CONFIG_FOR_GENESIS) { e.ledgerMaxInstructions = cfg.TESTING_LEDGER_MAX_INSTRUCTIONS; } @@ -84,8 +84,7 @@ initialContractLedgerAccessSettingsEntry(Config const& cfg) ConfigSettingEntry entry(CONFIG_SETTING_CONTRACT_LEDGER_COST_V0); auto& e = entry.contractLedgerCost(); - if (cfg.TESTING_LEDGER_MAX_READ_LEDGER_ENTRIES && - cfg.USE_CONFIG_FOR_GENESIS) + if (cfg.USE_CONFIG_FOR_GENESIS) { e.ledgerMaxReadLedgerEntries = cfg.TESTING_LEDGER_MAX_READ_LEDGER_ENTRIES; @@ -95,7 +94,7 @@ initialContractLedgerAccessSettingsEntry(Config const& cfg) e.ledgerMaxReadLedgerEntries = InitialSorobanNetworkConfig::LEDGER_MAX_READ_LEDGER_ENTRIES; } - if (cfg.TESTING_LEDGER_MAX_READ_BYTES && cfg.USE_CONFIG_FOR_GENESIS) + if (cfg.USE_CONFIG_FOR_GENESIS) { e.ledgerMaxReadBytes = cfg.TESTING_LEDGER_MAX_READ_BYTES; } @@ -104,8 +103,7 @@ initialContractLedgerAccessSettingsEntry(Config const& cfg) e.ledgerMaxReadBytes = InitialSorobanNetworkConfig::LEDGER_MAX_READ_BYTES; } - if (cfg.TESTING_LEDGER_MAX_WRITE_LEDGER_ENTRIES && - cfg.USE_CONFIG_FOR_GENESIS) + if (cfg.USE_CONFIG_FOR_GENESIS) { e.ledgerMaxWriteLedgerEntries = cfg.TESTING_LEDGER_MAX_WRITE_LEDGER_ENTRIES; @@ -115,7 +113,7 @@ initialContractLedgerAccessSettingsEntry(Config const& cfg) e.ledgerMaxWriteLedgerEntries = InitialSorobanNetworkConfig::LEDGER_MAX_WRITE_LEDGER_ENTRIES; } - if (cfg.TESTING_LEDGER_MAX_WRITE_BYTES && cfg.USE_CONFIG_FOR_GENESIS) + if (cfg.USE_CONFIG_FOR_GENESIS) { e.ledgerMaxWriteBytes = cfg.TESTING_LEDGER_MAX_WRITE_BYTES; } @@ -176,8 +174,7 @@ initialContractBandwidthSettingsEntry(Config const& cfg) ConfigSettingEntry entry(CONFIG_SETTING_CONTRACT_BANDWIDTH_V0); auto& e = entry.contractBandwidth(); - if (cfg.TESTING_LEDGER_MAX_PROPAGATE_SIZE_BYTES && - cfg.USE_CONFIG_FOR_GENESIS) + if (cfg.USE_CONFIG_FOR_GENESIS) { e.ledgerMaxPropagateSizeBytes = cfg.TESTING_LEDGER_MAX_PROPAGATE_SIZE_BYTES; @@ -193,6 +190,24 @@ initialContractBandwidthSettingsEntry(Config const& cfg) return entry; } +ConfigSettingEntry +initialContractExecutionLanesSettingsEntry(Config const& cfg) +{ + ConfigSettingEntry entry(CONFIG_SETTING_CONTRACT_EXECUTION_LANES); + auto& e = entry.contractExecutionLanes(); + + if (cfg.USE_CONFIG_FOR_GENESIS) + { + e.ledgerMaxTxCount = cfg.TESTING_LEDGER_MAX_SOROBAN_TX_COUNT; + } + else + { + e.ledgerMaxTxCount = InitialSorobanNetworkConfig::LEDGER_MAX_TX_COUNT; + } + + return entry; +} + ConfigSettingEntry initialCpuCostParamsEntry(Config const& cfg) { @@ -393,6 +408,8 @@ SorobanNetworkConfig::createLedgerEntriesForV20(AbstractLedgerTxn& ltx, ltx); createConfigSettingEntry(initialContractMetaDataSettingsEntry(cfg), ltx); createConfigSettingEntry(initialContractBandwidthSettingsEntry(cfg), ltx); + createConfigSettingEntry(initialContractExecutionLanesSettingsEntry(cfg), + ltx); createConfigSettingEntry(initialCpuCostParamsEntry(cfg), ltx); createConfigSettingEntry(initialMemCostParamsEntry(cfg), ltx); createConfigSettingEntry(initialStateExpirationSettings(), ltx); @@ -424,6 +441,7 @@ SorobanNetworkConfig::loadFromLedger(AbstractLedgerTxn& ltxRoot) loadCpuCostParams(ltx); loadMemCostParams(ltx); loadStateExpirationSettings(ltx); + loadExecutionLanesSettings(ltx); } void @@ -577,6 +595,20 @@ SorobanNetworkConfig::loadMemCostParams(AbstractLedgerTxn& ltx) #endif } +void +SorobanNetworkConfig::loadExecutionLanesSettings(AbstractLedgerTxn& ltx) +{ +#ifdef ENABLE_NEXT_PROTOCOL_VERSION_UNSAFE_FOR_PRODUCTION + LedgerKey key(CONFIG_SETTING); + key.configSetting().configSettingID = + ConfigSettingID::CONFIG_SETTING_CONTRACT_EXECUTION_LANES; + auto le = ltx.loadWithoutRecord(key).current(); + auto const& configSetting = + le.data.configSetting().contractExecutionLanes(); + mLedgerMaxTxCount = configSetting.ledgerMaxTxCount; +#endif +} + uint32_t SorobanNetworkConfig::maxContractSizeBytes() const { @@ -769,6 +801,13 @@ SorobanNetworkConfig::feePropagateData1KB() const return mFeePropagateData1KB; } +// General execution lanes settings for contracts +uint32_t +SorobanNetworkConfig::ledgerMaxTxCount() const +{ + return mLedgerMaxTxCount; +} + #ifdef BUILD_TESTS uint32_t& SorobanNetworkConfig::maxContractDataKeySizeBytes() diff --git a/src/ledger/NetworkConfig.h b/src/ledger/NetworkConfig.h index 712c4953d0..71c7a4612e 100644 --- a/src/ledger/NetworkConfig.h +++ b/src/ledger/NetworkConfig.h @@ -78,6 +78,9 @@ struct InitialSorobanNetworkConfig static constexpr uint32_t MINIMUM_TEMP_ENTRY_LIFETIME = 16; static constexpr uint32_t AUTO_BUMP_NUM_LEDGERS = 10; + + // General execution settings + static constexpr uint32_t LEDGER_MAX_TX_COUNT = 10; }; // Wrapper for the contract-related network configuration. @@ -169,6 +172,9 @@ class SorobanNetworkConfig // Fee for propagating 1KB of data int64_t feePropagateData1KB() const; + // General execution ledger settings + uint32_t ledgerMaxTxCount() const; + #ifdef BUILD_TESTS uint32_t& maxContractDataKeySizeBytes(); uint32_t& maxContractDataEntrySizeBytes(); @@ -199,6 +205,7 @@ class SorobanNetworkConfig void loadCpuCostParams(AbstractLedgerTxn& ltx); void loadMemCostParams(AbstractLedgerTxn& ltx); void loadStateExpirationSettings(AbstractLedgerTxn& ltx); + void loadExecutionLanesSettings(AbstractLedgerTxn& ltx); uint32_t mMaxContractSizeBytes{}; uint32_t mMaxContractDataKeySizeBytes{}; @@ -215,6 +222,7 @@ class SorobanNetworkConfig uint32_t mLedgerMaxReadBytes{}; uint32_t mLedgerMaxWriteLedgerEntries{}; uint32_t mLedgerMaxWriteBytes{}; + uint32_t mLedgerMaxTxCount{}; uint32_t mTxMaxReadLedgerEntries{}; uint32_t mTxMaxReadBytes{}; uint32_t mTxMaxWriteLedgerEntries{}; diff --git a/src/ledger/test/LedgerCloseMetaStreamTests.cpp b/src/ledger/test/LedgerCloseMetaStreamTests.cpp index e4ed70bf4b..7af296d513 100644 --- a/src/ledger/test/LedgerCloseMetaStreamTests.cpp +++ b/src/ledger/test/LedgerCloseMetaStreamTests.cpp @@ -448,7 +448,8 @@ TEST_CASE_VERSIONS("meta stream contains reasonable meta", "[ledgerclosemeta]") VirtualClock clock; cfg.METADATA_OUTPUT_STREAM = metaPath; // TODO: later when network configs per ledger are settled, regenerate - // meta and remove the 6 lines below + // meta and remove the 7 lines below + cfg.TESTING_LEDGER_MAX_SOROBAN_TX_COUNT = 1; cfg.TESTING_LEDGER_MAX_PROPAGATE_SIZE_BYTES = 1; cfg.TESTING_LEDGER_MAX_INSTRUCTIONS = 1; cfg.TESTING_LEDGER_MAX_READ_LEDGER_ENTRIES = 1; @@ -474,8 +475,7 @@ TEST_CASE_VERSIONS("meta stream contains reasonable meta", "[ledgerclosemeta]") auto cur1 = issuer.asset("CUR1"); // Ledger #5 sets up a trustline which has to happen before we can - // use - // it. + // use it. acc1.changeTrust(cur1, 100); // Ledger #6 uses closeLedger so emits interesting meta. diff --git a/src/main/Config.cpp b/src/main/Config.cpp index 9202ca9602..3005bea4c0 100644 --- a/src/main/Config.cpp +++ b/src/main/Config.cpp @@ -210,6 +210,7 @@ Config::Config() : NODE_SEED(SecretKey::random()) 1 * InitialSorobanNetworkConfig::TX_MAX_WRITE_LEDGER_ENTRIES; TESTING_LEDGER_MAX_WRITE_BYTES = 1 * InitialSorobanNetworkConfig::TX_MAX_WRITE_BYTES; + TESTING_LEDGER_MAX_SOROBAN_TX_COUNT = 1; HTTP_PORT = DEFAULT_PEER_PORT + 1; PUBLIC_HTTP_PORT = false; diff --git a/src/main/Config.h b/src/main/Config.h index 95fc88960a..3d4088cff0 100644 --- a/src/main/Config.h +++ b/src/main/Config.h @@ -444,6 +444,8 @@ class Config : public std::enable_shared_from_this uint32_t TESTING_LEDGER_MAX_READ_BYTES; uint32_t TESTING_LEDGER_MAX_WRITE_LEDGER_ENTRIES; uint32_t TESTING_LEDGER_MAX_WRITE_BYTES; + uint32_t TESTING_LEDGER_MAX_SOROBAN_TX_COUNT; + unsigned short HTTP_PORT; // what port to listen for commands bool PUBLIC_HTTP_PORT; // if you accept commands from not localhost int HTTP_MAX_CLIENT; // maximum number of http clients, i.e backlog From ea945454fa009f4f7e2615e70a15dd5c92267175 Mon Sep 17 00:00:00 2001 From: marta-lokhova Date: Tue, 13 Jun 2023 17:22:06 -0700 Subject: [PATCH 2/2] Update tx meta --- .../ledger-close-meta-v1-protocol-20.json | 804 +++++++++--------- 1 file changed, 402 insertions(+), 402 deletions(-) diff --git a/src/testdata/ledger-close-meta-v1-protocol-20.json b/src/testdata/ledger-close-meta-v1-protocol-20.json index 8b6e8f0976..fa6512fb2d 100644 --- a/src/testdata/ledger-close-meta-v1-protocol-20.json +++ b/src/testdata/ledger-close-meta-v1-protocol-20.json @@ -3,24 +3,24 @@ "v": 1, "v1": { "ledgerHeader": { - "hash": "af6a782c32afcdd55766296f66754475699dc7e9acda3a5863c252da74f7e0d2", + "hash": "1b0a8a706401efeb11546b00c29aaf21399d0575121e37e3da7e38f6b9d5c9f3", "header": { "ledgerVersion": 20, - "previousLedgerHash": "dd7390fc365d41be1ff9bec61257fb5ecfc16f456a8766de311a8160c9e5d976", + "previousLedgerHash": "1b9920675aa4a36c4f3d094d56d2e74bf854916f2f4496d199aa35892a21d322", "scpValue": { - "txSetHash": "9ede256adfece7f6d18bc79c3b7235b717f0dfa72541ac819a719e4897be6b8b", + "txSetHash": "2f4b78f0ed239aa96d25d7fb14e4804be9d77df54115f262271a6b756903c40a", "closeTime": 0, "upgrades": [], "ext": { "v": "STELLAR_VALUE_SIGNED", "lcValueSignature": { "nodeID": "GDDOUW25MRFLNXQMN3OODP6JQEXSGLMHAFZV4XPQ2D3GA4QFIDMEJG2O", - "signature": "19d53e24d8f2313c6e7db51c192eb591c9e996f35f50facc8dd834e5acc2e924330753a98849da13b0e2e77a2dbbc5f87cb1a2747852c45b591f3d1c5a65d701" + "signature": "96116fb57c31643145c7c64caa4c02001fcd0c09ee1c4b78d8ac56b9dfbbf8e24af2d6c303b9332af50c7f255cb90ce2726b01470c6e214b60a1235d77fbc40d" } } }, - "txSetResultHash": "cd1398cda325d4eada631301e6501421cda30fd0b43da3e5d0ffb26caf073b0a", - "bucketListHash": "fba2eb2e07bf5c4c4b37e375b592ccddc535bf21b4c5ddf5ec4d1bcd813712dc", + "txSetResultHash": "cf65fee29665ff0c2a6910b24c420a487a7416ccd79c683b48aac1d45ad21faa", + "bucketListHash": "0a20a445cdeff7b2e95a1f4efcd9093641c3e97bff19de239551ab1e8712ad4f", "ledgerSeq": 6, "totalCoins": 1000000000000000000, "feePool": 800, @@ -46,7 +46,7 @@ "txSet": { "v": 1, "v1TxSet": { - "previousLedgerHash": "dd7390fc365d41be1ff9bec61257fb5ecfc16f456a8766de311a8160c9e5d976", + "previousLedgerHash": "1b9920675aa4a36c4f3d094d56d2e74bf854916f2f4496d199aa35892a21d322", "phases": [ { "v": 0, @@ -182,43 +182,22 @@ "txProcessing": [ { "result": { - "transactionHash": "66efe325ead9f52082c8908b7813bd96793fd5ff0f1e50fdc50b23f68938dd4d", + "transactionHash": "0db2322d85e9d8ea2421559922bb6107429650ebdad304c907480853d465c10d", "result": { - "feeCharged": 300, + "feeCharged": 100, "result": { - "code": "txFEE_BUMP_INNER_SUCCESS", - "innerResultPair": { - "transactionHash": "5ab197acffd4b32d320df39b2b1f76246e2279fa8070c6c690cca1343e5e7e0b", - "result": { - "feeCharged": 200, - "result": { - "code": "txSUCCESS", - "results": [ - { - "code": "opINNER", - "tr": { - "type": "PAYMENT", - "paymentResult": { - "code": "PAYMENT_SUCCESS" - } - } - }, - { - "code": "opINNER", - "tr": { - "type": "PAYMENT", - "paymentResult": { - "code": "PAYMENT_SUCCESS" - } - } - } - ] - }, - "ext": { - "v": 0 + "code": "txSUCCESS", + "results": [ + { + "code": "opINNER", + "tr": { + "type": "PAYMENT", + "paymentResult": { + "code": "PAYMENT_SUCCESS" + } } } - } + ] }, "ext": { "v": 0 @@ -229,13 +208,13 @@ { "type": "LEDGER_ENTRY_STATE", "state": { - "lastModifiedLedgerSeq": 3, + "lastModifiedLedgerSeq": 4, "data": { "type": "ACCOUNT", "account": { - "accountID": "GCAEBM3GKNR6SV6N73FSGBXU6NSMZ2URQVMJQHXFQFY2PJPX6YBCSAKZ", - "balance": 400000000, - "seqNum": 12884901888, + "accountID": "GC4EFXBN6BEENDAX7PBW5PGIIIVH3INMD3OEPQASXOLGOHVVP7ZEMG7X", + "balance": 999999998999989700, + "seqNum": 3, "numSubEntries": 0, "inflationDest": null, "flags": 0, @@ -243,7 +222,31 @@ "thresholds": "01000000", "signers": [], "ext": { - "v": 0 + "v": 1, + "v1": { + "liabilities": { + "buying": 0, + "selling": 0 + }, + "ext": { + "v": 2, + "v2": { + "numSponsored": 0, + "numSponsoring": 0, + "signerSponsoringIDs": [], + "ext": { + "v": 3, + "v3": { + "ext": { + "v": 0 + }, + "seqLedger": 4, + "seqTime": 0 + } + } + } + } + } } } }, @@ -259,9 +262,9 @@ "data": { "type": "ACCOUNT", "account": { - "accountID": "GCAEBM3GKNR6SV6N73FSGBXU6NSMZ2URQVMJQHXFQFY2PJPX6YBCSAKZ", - "balance": 399999700, - "seqNum": 12884901888, + "accountID": "GC4EFXBN6BEENDAX7PBW5PGIIIVH3INMD3OEPQASXOLGOHVVP7ZEMG7X", + "balance": 999999998999989600, + "seqNum": 3, "numSubEntries": 0, "inflationDest": null, "flags": 0, @@ -269,7 +272,31 @@ "thresholds": "01000000", "signers": [], "ext": { - "v": 0 + "v": 1, + "v1": { + "liabilities": { + "buying": 0, + "selling": 0 + }, + "ext": { + "v": 2, + "v2": { + "numSponsored": 0, + "numSponsoring": 0, + "signerSponsoringIDs": [], + "ext": { + "v": 3, + "v3": { + "ext": { + "v": 0 + }, + "seqLedger": 4, + "seqTime": 0 + } + } + } + } + } } } }, @@ -293,61 +320,9 @@ "data": { "type": "ACCOUNT", "account": { - "accountID": "GCAEBM3GKNR6SV6N73FSGBXU6NSMZ2URQVMJQHXFQFY2PJPX6YBCSAKZ", - "balance": 399999700, - "seqNum": 12884901888, - "numSubEntries": 0, - "inflationDest": null, - "flags": 0, - "homeDomain": "", - "thresholds": "01000000", - "signers": [], - "ext": { - "v": 0 - } - } - }, - "ext": { - "v": 0 - } - } - }, - { - "type": "LEDGER_ENTRY_UPDATED", - "updated": { - "lastModifiedLedgerSeq": 6, - "data": { - "type": "ACCOUNT", - "account": { - "accountID": "GCAEBM3GKNR6SV6N73FSGBXU6NSMZ2URQVMJQHXFQFY2PJPX6YBCSAKZ", - "balance": 399999700, - "seqNum": 12884901888, - "numSubEntries": 0, - "inflationDest": null, - "flags": 0, - "homeDomain": "", - "thresholds": "01000000", - "signers": [], - "ext": { - "v": 0 - } - } - }, - "ext": { - "v": 0 - } - } - }, - { - "type": "LEDGER_ENTRY_STATE", - "state": { - "lastModifiedLedgerSeq": 4, - "data": { - "type": "ACCOUNT", - "account": { - "accountID": "GCGE27HU2VYQANKL2VZWLCAOJYMEFST5DXPBWQ7BRRPOHUPK626DNG4Q", - "balance": 200010000, - "seqNum": 17179869184, + "accountID": "GC4EFXBN6BEENDAX7PBW5PGIIIVH3INMD3OEPQASXOLGOHVVP7ZEMG7X", + "balance": 999999998999989600, + "seqNum": 3, "numSubEntries": 0, "inflationDest": null, "flags": 0, @@ -355,7 +330,31 @@ "thresholds": "01000000", "signers": [], "ext": { - "v": 0 + "v": 1, + "v1": { + "liabilities": { + "buying": 0, + "selling": 0 + }, + "ext": { + "v": 2, + "v2": { + "numSponsored": 0, + "numSponsoring": 0, + "signerSponsoringIDs": [], + "ext": { + "v": 3, + "v3": { + "ext": { + "v": 0 + }, + "seqLedger": 4, + "seqTime": 0 + } + } + } + } + } } } }, @@ -371,9 +370,9 @@ "data": { "type": "ACCOUNT", "account": { - "accountID": "GCGE27HU2VYQANKL2VZWLCAOJYMEFST5DXPBWQ7BRRPOHUPK626DNG4Q", - "balance": 200010000, - "seqNum": 17179869185, + "accountID": "GC4EFXBN6BEENDAX7PBW5PGIIIVH3INMD3OEPQASXOLGOHVVP7ZEMG7X", + "balance": 999999998999989600, + "seqNum": 4, "numSubEntries": 0, "inflationDest": null, "flags": 0, @@ -421,20 +420,45 @@ { "type": "LEDGER_ENTRY_STATE", "state": { - "lastModifiedLedgerSeq": 5, + "lastModifiedLedgerSeq": 6, "data": { - "type": "TRUSTLINE", - "trustLine": { - "accountID": "GB6MXQ5262ZJGDQNA6BL4TWE5SADVZXIKLPELFXKUE27X4SQTGQS44ZB", - "asset": { - "assetCode": "CUR1", - "issuer": "GCGE27HU2VYQANKL2VZWLCAOJYMEFST5DXPBWQ7BRRPOHUPK626DNG4Q" - }, - "balance": 0, - "limit": 100, - "flags": 1, + "type": "ACCOUNT", + "account": { + "accountID": "GC4EFXBN6BEENDAX7PBW5PGIIIVH3INMD3OEPQASXOLGOHVVP7ZEMG7X", + "balance": 999999998999989600, + "seqNum": 4, + "numSubEntries": 0, + "inflationDest": null, + "flags": 0, + "homeDomain": "", + "thresholds": "01000000", + "signers": [], "ext": { - "v": 0 + "v": 1, + "v1": { + "liabilities": { + "buying": 0, + "selling": 0 + }, + "ext": { + "v": 2, + "v2": { + "numSponsored": 0, + "numSponsoring": 0, + "signerSponsoringIDs": [], + "ext": { + "v": 3, + "v3": { + "ext": { + "v": 0 + }, + "seqLedger": 6, + "seqTime": 0 + } + } + } + } + } } } }, @@ -448,18 +472,43 @@ "updated": { "lastModifiedLedgerSeq": 6, "data": { - "type": "TRUSTLINE", - "trustLine": { - "accountID": "GB6MXQ5262ZJGDQNA6BL4TWE5SADVZXIKLPELFXKUE27X4SQTGQS44ZB", - "asset": { - "assetCode": "CUR1", - "issuer": "GCGE27HU2VYQANKL2VZWLCAOJYMEFST5DXPBWQ7BRRPOHUPK626DNG4Q" - }, - "balance": 50, - "limit": 100, - "flags": 1, + "type": "ACCOUNT", + "account": { + "accountID": "GC4EFXBN6BEENDAX7PBW5PGIIIVH3INMD3OEPQASXOLGOHVVP7ZEMG7X", + "balance": 999999998999988600, + "seqNum": 4, + "numSubEntries": 0, + "inflationDest": null, + "flags": 0, + "homeDomain": "", + "thresholds": "01000000", + "signers": [], "ext": { - "v": 0 + "v": 1, + "v1": { + "liabilities": { + "buying": 0, + "selling": 0 + }, + "ext": { + "v": 2, + "v2": { + "numSponsored": 0, + "numSponsoring": 0, + "signerSponsoringIDs": [], + "ext": { + "v": 3, + "v3": { + "ext": { + "v": 0 + }, + "seqLedger": 6, + "seqTime": 0 + } + } + } + } + } } } }, @@ -467,28 +516,49 @@ "v": 0 } } - } - ] - }, - { - "changes": [ + }, { "type": "LEDGER_ENTRY_STATE", "state": { - "lastModifiedLedgerSeq": 6, + "lastModifiedLedgerSeq": 5, "data": { - "type": "TRUSTLINE", - "trustLine": { + "type": "ACCOUNT", + "account": { "accountID": "GB6MXQ5262ZJGDQNA6BL4TWE5SADVZXIKLPELFXKUE27X4SQTGQS44ZB", - "asset": { - "assetCode": "CUR1", - "issuer": "GCGE27HU2VYQANKL2VZWLCAOJYMEFST5DXPBWQ7BRRPOHUPK626DNG4Q" - }, - "balance": 50, - "limit": 100, - "flags": 1, + "balance": 399999900, + "seqNum": 8589934593, + "numSubEntries": 1, + "inflationDest": null, + "flags": 0, + "homeDomain": "", + "thresholds": "01000000", + "signers": [], "ext": { - "v": 0 + "v": 1, + "v1": { + "liabilities": { + "buying": 0, + "selling": 0 + }, + "ext": { + "v": 2, + "v2": { + "numSponsored": 0, + "numSponsoring": 0, + "signerSponsoringIDs": [], + "ext": { + "v": 3, + "v3": { + "ext": { + "v": 0 + }, + "seqLedger": 5, + "seqTime": 0 + } + } + } + } + } } } }, @@ -502,18 +572,43 @@ "updated": { "lastModifiedLedgerSeq": 6, "data": { - "type": "TRUSTLINE", - "trustLine": { + "type": "ACCOUNT", + "account": { "accountID": "GB6MXQ5262ZJGDQNA6BL4TWE5SADVZXIKLPELFXKUE27X4SQTGQS44ZB", - "asset": { - "assetCode": "CUR1", - "issuer": "GCGE27HU2VYQANKL2VZWLCAOJYMEFST5DXPBWQ7BRRPOHUPK626DNG4Q" - }, - "balance": 100, - "limit": 100, - "flags": 1, + "balance": 400000900, + "seqNum": 8589934593, + "numSubEntries": 1, + "inflationDest": null, + "flags": 0, + "homeDomain": "", + "thresholds": "01000000", + "signers": [], "ext": { - "v": 0 + "v": 1, + "v1": { + "liabilities": { + "buying": 0, + "selling": 0 + }, + "ext": { + "v": 2, + "v2": { + "numSponsored": 0, + "numSponsoring": 0, + "signerSponsoringIDs": [], + "ext": { + "v": 3, + "v3": { + "ext": { + "v": 0 + }, + "seqLedger": 5, + "seqTime": 0 + } + } + } + } + } } } }, @@ -542,22 +637,43 @@ }, { "result": { - "transactionHash": "0db2322d85e9d8ea2421559922bb6107429650ebdad304c907480853d465c10d", + "transactionHash": "66efe325ead9f52082c8908b7813bd96793fd5ff0f1e50fdc50b23f68938dd4d", "result": { - "feeCharged": 100, + "feeCharged": 300, "result": { - "code": "txSUCCESS", - "results": [ - { - "code": "opINNER", - "tr": { - "type": "PAYMENT", - "paymentResult": { - "code": "PAYMENT_SUCCESS" - } + "code": "txFEE_BUMP_INNER_SUCCESS", + "innerResultPair": { + "transactionHash": "5ab197acffd4b32d320df39b2b1f76246e2279fa8070c6c690cca1343e5e7e0b", + "result": { + "feeCharged": 200, + "result": { + "code": "txSUCCESS", + "results": [ + { + "code": "opINNER", + "tr": { + "type": "PAYMENT", + "paymentResult": { + "code": "PAYMENT_SUCCESS" + } + } + }, + { + "code": "opINNER", + "tr": { + "type": "PAYMENT", + "paymentResult": { + "code": "PAYMENT_SUCCESS" + } + } + } + ] + }, + "ext": { + "v": 0 } } - ] + } }, "ext": { "v": 0 @@ -568,13 +684,13 @@ { "type": "LEDGER_ENTRY_STATE", "state": { - "lastModifiedLedgerSeq": 4, + "lastModifiedLedgerSeq": 3, "data": { "type": "ACCOUNT", "account": { - "accountID": "GC4EFXBN6BEENDAX7PBW5PGIIIVH3INMD3OEPQASXOLGOHVVP7ZEMG7X", - "balance": 999999998999989700, - "seqNum": 3, + "accountID": "GCAEBM3GKNR6SV6N73FSGBXU6NSMZ2URQVMJQHXFQFY2PJPX6YBCSAKZ", + "balance": 400000000, + "seqNum": 12884901888, "numSubEntries": 0, "inflationDest": null, "flags": 0, @@ -582,31 +698,7 @@ "thresholds": "01000000", "signers": [], "ext": { - "v": 1, - "v1": { - "liabilities": { - "buying": 0, - "selling": 0 - }, - "ext": { - "v": 2, - "v2": { - "numSponsored": 0, - "numSponsoring": 0, - "signerSponsoringIDs": [], - "ext": { - "v": 3, - "v3": { - "ext": { - "v": 0 - }, - "seqLedger": 4, - "seqTime": 0 - } - } - } - } - } + "v": 0 } } }, @@ -622,9 +714,9 @@ "data": { "type": "ACCOUNT", "account": { - "accountID": "GC4EFXBN6BEENDAX7PBW5PGIIIVH3INMD3OEPQASXOLGOHVVP7ZEMG7X", - "balance": 999999998999989600, - "seqNum": 3, + "accountID": "GCAEBM3GKNR6SV6N73FSGBXU6NSMZ2URQVMJQHXFQFY2PJPX6YBCSAKZ", + "balance": 399999700, + "seqNum": 12884901888, "numSubEntries": 0, "inflationDest": null, "flags": 0, @@ -632,31 +724,7 @@ "thresholds": "01000000", "signers": [], "ext": { - "v": 1, - "v1": { - "liabilities": { - "buying": 0, - "selling": 0 - }, - "ext": { - "v": 2, - "v2": { - "numSponsored": 0, - "numSponsoring": 0, - "signerSponsoringIDs": [], - "ext": { - "v": 3, - "v3": { - "ext": { - "v": 0 - }, - "seqLedger": 4, - "seqTime": 0 - } - } - } - } - } + "v": 0 } } }, @@ -680,9 +748,9 @@ "data": { "type": "ACCOUNT", "account": { - "accountID": "GC4EFXBN6BEENDAX7PBW5PGIIIVH3INMD3OEPQASXOLGOHVVP7ZEMG7X", - "balance": 999999998999989600, - "seqNum": 3, + "accountID": "GCAEBM3GKNR6SV6N73FSGBXU6NSMZ2URQVMJQHXFQFY2PJPX6YBCSAKZ", + "balance": 399999700, + "seqNum": 12884901888, "numSubEntries": 0, "inflationDest": null, "flags": 0, @@ -690,31 +758,7 @@ "thresholds": "01000000", "signers": [], "ext": { - "v": 1, - "v1": { - "liabilities": { - "buying": 0, - "selling": 0 - }, - "ext": { - "v": 2, - "v2": { - "numSponsored": 0, - "numSponsoring": 0, - "signerSponsoringIDs": [], - "ext": { - "v": 3, - "v3": { - "ext": { - "v": 0 - }, - "seqLedger": 4, - "seqTime": 0 - } - } - } - } - } + "v": 0 } } }, @@ -730,9 +774,61 @@ "data": { "type": "ACCOUNT", "account": { - "accountID": "GC4EFXBN6BEENDAX7PBW5PGIIIVH3INMD3OEPQASXOLGOHVVP7ZEMG7X", - "balance": 999999998999989600, - "seqNum": 4, + "accountID": "GCAEBM3GKNR6SV6N73FSGBXU6NSMZ2URQVMJQHXFQFY2PJPX6YBCSAKZ", + "balance": 399999700, + "seqNum": 12884901888, + "numSubEntries": 0, + "inflationDest": null, + "flags": 0, + "homeDomain": "", + "thresholds": "01000000", + "signers": [], + "ext": { + "v": 0 + } + } + }, + "ext": { + "v": 0 + } + } + }, + { + "type": "LEDGER_ENTRY_STATE", + "state": { + "lastModifiedLedgerSeq": 4, + "data": { + "type": "ACCOUNT", + "account": { + "accountID": "GCGE27HU2VYQANKL2VZWLCAOJYMEFST5DXPBWQ7BRRPOHUPK626DNG4Q", + "balance": 200010000, + "seqNum": 17179869184, + "numSubEntries": 0, + "inflationDest": null, + "flags": 0, + "homeDomain": "", + "thresholds": "01000000", + "signers": [], + "ext": { + "v": 0 + } + } + }, + "ext": { + "v": 0 + } + } + }, + { + "type": "LEDGER_ENTRY_UPDATED", + "updated": { + "lastModifiedLedgerSeq": 6, + "data": { + "type": "ACCOUNT", + "account": { + "accountID": "GCGE27HU2VYQANKL2VZWLCAOJYMEFST5DXPBWQ7BRRPOHUPK626DNG4Q", + "balance": 200010000, + "seqNum": 17179869185, "numSubEntries": 0, "inflationDest": null, "flags": 0, @@ -780,45 +876,20 @@ { "type": "LEDGER_ENTRY_STATE", "state": { - "lastModifiedLedgerSeq": 6, + "lastModifiedLedgerSeq": 5, "data": { - "type": "ACCOUNT", - "account": { - "accountID": "GC4EFXBN6BEENDAX7PBW5PGIIIVH3INMD3OEPQASXOLGOHVVP7ZEMG7X", - "balance": 999999998999989600, - "seqNum": 4, - "numSubEntries": 0, - "inflationDest": null, - "flags": 0, - "homeDomain": "", - "thresholds": "01000000", - "signers": [], + "type": "TRUSTLINE", + "trustLine": { + "accountID": "GB6MXQ5262ZJGDQNA6BL4TWE5SADVZXIKLPELFXKUE27X4SQTGQS44ZB", + "asset": { + "assetCode": "CUR1", + "issuer": "GCGE27HU2VYQANKL2VZWLCAOJYMEFST5DXPBWQ7BRRPOHUPK626DNG4Q" + }, + "balance": 0, + "limit": 100, + "flags": 1, "ext": { - "v": 1, - "v1": { - "liabilities": { - "buying": 0, - "selling": 0 - }, - "ext": { - "v": 2, - "v2": { - "numSponsored": 0, - "numSponsoring": 0, - "signerSponsoringIDs": [], - "ext": { - "v": 3, - "v3": { - "ext": { - "v": 0 - }, - "seqLedger": 6, - "seqTime": 0 - } - } - } - } - } + "v": 0 } } }, @@ -832,43 +903,18 @@ "updated": { "lastModifiedLedgerSeq": 6, "data": { - "type": "ACCOUNT", - "account": { - "accountID": "GC4EFXBN6BEENDAX7PBW5PGIIIVH3INMD3OEPQASXOLGOHVVP7ZEMG7X", - "balance": 999999998999988600, - "seqNum": 4, - "numSubEntries": 0, - "inflationDest": null, - "flags": 0, - "homeDomain": "", - "thresholds": "01000000", - "signers": [], + "type": "TRUSTLINE", + "trustLine": { + "accountID": "GB6MXQ5262ZJGDQNA6BL4TWE5SADVZXIKLPELFXKUE27X4SQTGQS44ZB", + "asset": { + "assetCode": "CUR1", + "issuer": "GCGE27HU2VYQANKL2VZWLCAOJYMEFST5DXPBWQ7BRRPOHUPK626DNG4Q" + }, + "balance": 50, + "limit": 100, + "flags": 1, "ext": { - "v": 1, - "v1": { - "liabilities": { - "buying": 0, - "selling": 0 - }, - "ext": { - "v": 2, - "v2": { - "numSponsored": 0, - "numSponsoring": 0, - "signerSponsoringIDs": [], - "ext": { - "v": 3, - "v3": { - "ext": { - "v": 0 - }, - "seqLedger": 6, - "seqTime": 0 - } - } - } - } - } + "v": 0 } } }, @@ -876,49 +922,28 @@ "v": 0 } } - }, + } + ] + }, + { + "changes": [ { "type": "LEDGER_ENTRY_STATE", "state": { - "lastModifiedLedgerSeq": 5, + "lastModifiedLedgerSeq": 6, "data": { - "type": "ACCOUNT", - "account": { + "type": "TRUSTLINE", + "trustLine": { "accountID": "GB6MXQ5262ZJGDQNA6BL4TWE5SADVZXIKLPELFXKUE27X4SQTGQS44ZB", - "balance": 399999900, - "seqNum": 8589934593, - "numSubEntries": 1, - "inflationDest": null, - "flags": 0, - "homeDomain": "", - "thresholds": "01000000", - "signers": [], + "asset": { + "assetCode": "CUR1", + "issuer": "GCGE27HU2VYQANKL2VZWLCAOJYMEFST5DXPBWQ7BRRPOHUPK626DNG4Q" + }, + "balance": 50, + "limit": 100, + "flags": 1, "ext": { - "v": 1, - "v1": { - "liabilities": { - "buying": 0, - "selling": 0 - }, - "ext": { - "v": 2, - "v2": { - "numSponsored": 0, - "numSponsoring": 0, - "signerSponsoringIDs": [], - "ext": { - "v": 3, - "v3": { - "ext": { - "v": 0 - }, - "seqLedger": 5, - "seqTime": 0 - } - } - } - } - } + "v": 0 } } }, @@ -932,43 +957,18 @@ "updated": { "lastModifiedLedgerSeq": 6, "data": { - "type": "ACCOUNT", - "account": { + "type": "TRUSTLINE", + "trustLine": { "accountID": "GB6MXQ5262ZJGDQNA6BL4TWE5SADVZXIKLPELFXKUE27X4SQTGQS44ZB", - "balance": 400000900, - "seqNum": 8589934593, - "numSubEntries": 1, - "inflationDest": null, - "flags": 0, - "homeDomain": "", - "thresholds": "01000000", - "signers": [], + "asset": { + "assetCode": "CUR1", + "issuer": "GCGE27HU2VYQANKL2VZWLCAOJYMEFST5DXPBWQ7BRRPOHUPK626DNG4Q" + }, + "balance": 100, + "limit": 100, + "flags": 1, "ext": { - "v": 1, - "v1": { - "liabilities": { - "buying": 0, - "selling": 0 - }, - "ext": { - "v": 2, - "v2": { - "numSponsored": 0, - "numSponsoring": 0, - "signerSponsoringIDs": [], - "ext": { - "v": 3, - "v3": { - "ext": { - "v": 0 - }, - "seqLedger": 5, - "seqTime": 0 - } - } - } - } - } + "v": 0 } } },