Skip to content

feat: add Soroban resource fee ceiling policy - #1402

Merged
mijinummi merged 1 commit into
MDTechLabs:mainfrom
ezechinonyelumvivian-create:feat/soroban-resource-fee-ceiling-policy
Oct 21, 2026
Merged

mijinummi merged 1 commit into
MDTechLabs:mainfrom
ezechinonyelumvivian-create:feat/soroban-resource-fee-ceiling-policy

Conversation

@ezechinonyelumvivian-create

@ezechinonyelumvivian-create ezechinonyelumvivian-create commented Oct 21, 2026 •

Copy link
Copy Markdown

Implements Soroban resource fee ceiling policy per issue #1331.

Changes

  • New SorobanResourceFeeCeilingService with per-network ceiling policies
  • Integration with SorobanSimulator.parseAndValidateSimulation - validates resource fee against ceiling before simulation completes
  • Integration with SorobanCostBreakdownEngine.breakdown/breakdownBatch - validates ceiling before cost breakdown
  • Integration with SorobanRouteCostOptimizer - filters routes exceeding ceiling in evaluate/rankLowestCost/stats
  • New ResourceFeeCeilingExceededError with network, fee, and ceiling details
  • Default config for mainnet/testnet/futurenet via createDefaultCeilingConfig
  • Unit tests covering success, boundary, invalid-input, and failure cases
  • Integration tests for component boundaries (simulator, cost breakdown, optimizer)

Acceptance Criteria

  • Tests cover network passphrase, sequence/resource limits, simulation, and RPC failure cases
  • No test relies on production keys or unpinned live-network state
  • Public interfaces, configuration, and failure semantics documented
  • Unit tests cover success, boundary, invalid-input, and failure cases
  • Integration tests cover relevant component boundaries
  • Logs and metrics exclude secrets

closes #1331
closes #1330
closes #1333
closes #1334

- Add SorobanResourceFeeCeilingService with per-network ceiling policies
- Integrate ceiling enforcement into SorobanSimulator.parseAndValidateSimulation
- Integrate ceiling validation into SorobanCostBreakdownEngine.breakdown/breakdownBatch
- Add ceiling filtering to SorobanRouteCostOptimizer evaluate/rankLowestCost/stats
- New types: ResourceFeeCeilingExceededError, ceiling service interfaces
- Unit tests for ceiling service, simulator, cost breakdown, and optimizer
- Config: createDefaultCeilingConfig for mainnet/testnet/futurenet

closes MDTechLabs#1331
@drips-wave

drips-wave Bot commented Oct 21, 2026

Copy link
Copy Markdown

@ezechinonyelumvivian-create Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@mijinummi
mijinummi merged commit c09a89c into MDTechLabs:main Oct 21, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

2 participants