subsystem-summary-of-transactions
Transactions Subsystem — Technical Summary
Overview
The transactions subsystem implements the core transaction processing pipeline in stellar-core: parsing transaction envelopes from XDR, validating them, applying them to the ledger, and producing results and metadata. It encompasses the transaction frame hierarchy, all operation types (classic and Soroban), signature verification, offer exchange logic, sponsorship utilities, parallel apply infrastructure, and event/meta generation.
Key Files
- TransactionFrameBase.h/.cpp — Abstract base class for all transaction types.
- TransactionFrame.h/.cpp — Concrete implementation for regular (non-fee-bump) transactions. ~2500 lines; contains the main
apply,checkValid,commonValid,processFeeSeqNum,parallelApply, andapplyOperationslogic. - FeeBumpTransactionFrame.h/.cpp — Wraps a
TransactionFrame(inner tx) for fee bump support. Delegates most operations to the inner tx. - OperationFrame.h/.cpp — Abstract base for all operations. Factory method
makeHelpercreates concrete subclasses from XDROperation. Containsapply,checkValid,parallelApplydispatch. - MutableTransactionResult.h/.cpp — Mutable result objects (
MutableTransactionResult,FeeBumpMutableTransactionResult) that track transaction outcomes and fee refunds viaRefundableFeeTracker. - TransactionMeta.h/.cpp —
TransactionMetaBuilderandOperationMetaBuilderfor buildingTransactionMetaXDR (ledger changes, events, return values). - EventManager.h/.cpp —
DiagnosticEventManager,OpEventManager,TxEventManagerfor emitting contract/diagnostic/fee events during tx processing. - SignatureChecker.h/.cpp — Validates decorated signatures against signers with weight thresholds, caching verification results.
- SignatureUtils.h/.cpp — Low-level signature creation/verification helpers (Ed25519, hash-x, signed payloads).
More from stellar/stellar-core
running-tests
running tests at various levels from smoke tests to full suite to randomized tests
1subsystem-summary-of-test
read this skill for a token-efficient summary of the test subsystem
1subsystem-summary-of-scp
read this skill for a token-efficient summary of the scp subsystem
1running-make-to-build
how to run make correctly to get a good build, and otherwise understand the build system
1subsystem-summary-of-history
read this skill for a token-efficient summary of the history subsystem
1subsystem-summary-of-invariant
read this skill for a token-efficient summary of the invariant subsystem
1