Repository navigation
Generate classic transactions in every apply load mode. - #5201
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a new apply-load “model transaction” type based on a custom token contract, and updates apply-load benchmarking to always include a configured number of classic payment transactions per ledger across modes.
Changes:
- Add
ApplyLoadModelTx::CUSTOM_TOKENand config parsing forAPPLY_LOAD_MODEL_TX="custom_token". - Implement custom token contract setup (upload/create/multi_mint) and token transfer tx generation for apply-load.
- Generate
APPLY_LOAD_CLASSIC_TXS_PER_LEDGERclassic payments in benchmark iterations / model-tx benchmarks; update tests and add example config.
Reviewed changes
Copilot reviewed 23 out of 25 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| src/simulation/TxGenerator.h | Adds instruction constant + TxGenerator API for token transfers. |
| src/simulation/TxGenerator.cpp | Implements invokeTokenTransfer() Soroban transaction construction. |
| src/simulation/ApplyLoad.h | Adds token-contract setup + classic payment + token transfer generation helpers; refactors benchmark helper naming. |
| src/simulation/ApplyLoad.cpp | Mode-specific setup; classic+Soroban tx generation in benchmarks; token contract deploy + multi_mint; benchmark logging tweaks. |
| src/simulation/test/LoadGeneratorTests.cpp | Updates apply-load tests to include classic txs; adds custom-token benchmark test. |
| src/main/Config.h | Adds CUSTOM_TOKEN to ApplyLoadModelTx. |
| src/main/Config.cpp | Parses APPLY_LOAD_MODEL_TX=custom_token and updates validation error message. |
| src/rust/src/bridge.rs | Exposes get_apply_load_token_wasm() to C++ via the Rust bridge. |
| src/rust/src/soroban_test_wasm.rs | Adds include_bytes! loader for apply-load-wasm/token.wasm. |
| src/rust/apply-load-wasm/token.wasm | Adds the benchmark token contract Wasm blob. |
| src/rust/apply-load-wasm/README..md | Documents the apply-load Wasm directory (note: filename has README..md). |
| docs/apply-load-benchmark-token.cfg | New example config for benchmarking custom-token transfers. |
| docs/apply-load-benchmark-sac.cfg | Updates SAC benchmark doc wording to reflect current model-tx intent. |
| scripts/apply_load/token/Cargo.toml | New Rust workspace for the token contract source used to build the Wasm. |
| scripts/apply_load/token/Cargo.lock | Lockfile for the token workspace. |
| scripts/apply_load/token/.gitignore | Ignores Rust build output + local config in token workspace. |
| scripts/apply_load/token/contracts/token/Cargo.toml | Token contract crate manifest. |
| scripts/apply_load/token/contracts/token/src/lib.rs | Token contract crate root. |
| scripts/apply_load/token/contracts/token/src/contract.rs | OpenZeppelin-generated token contract with multi_mint. |
| scripts/apply_load/token/contracts/token/src/test.rs | Contract test validating multi_mint and transfer auth + balances. |
| scripts/apply_load/token/contracts/token/test_snapshots/test/initial_state.1.json | Snapshot of contract initial state for the token workspace. |
| scripts/apply_load/token/contracts/token/test_snapshots/test/smoke_multi_mint_and_transfer.1.json | Snapshot for multi-mint + transfer smoke test. |
| Builds/VisualStudio/build_rust.bat | Adjusts Windows Rust build to always invoke cargo rustc for stellar-core and clears RUSTFLAGS. |
| Builds/VisualStudio/stellar-core.vcxproj | Adds SecretManager.cpp/.h to the VS project sources/headers. |
| Builds/VisualStudio/stellar-core.vcxproj.filters | Adds VS filters entries for SecretManager.cpp/.h. |
6 tasks
dmkozh
force-pushed
the
apply_load_classic_bench
branch
from
April 6, 2026 21:23
651a8e0 to
e06c61c
Compare
marta-lokhova
approved these changes
Apr 7, 2026
github-merge-queue Bot
pushed a commit
that referenced
this pull request
Apr 9, 2026
# Description This mode uses the official Soroswap contracts from mainnet. It executes swaps of different token pairs (to allow for parallelism). This is based on #5201 # Checklist - [ ] Reviewed the [contributing](https://github.com/stellar/stellar-core/blob/master/CONTRIBUTING.md#submitting-changes) document - [ ] Rebased on top of master (no merge commits) - [ ] Ran `clang-format` v8.0.0 (via `make format` or the Visual Studio extension) - [ ] Compiles - [ ] Ran all tests - [ ] If change impacts performance, include supporting evidence per the [performance document](https://github.com/stellar/stellar-core/blob/master/performance-eval/performance-eval.md)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Generate classic transactions in every apply load mode.
Based on #5200.
Checklist
clang-formatv8.0.0 (viamake formator the Visual Studio extension)