remove outdated content from 'resources limits & fee'#2277
remove outdated content from 'resources limits & fee'#2277jeesunikim wants to merge 2 commits intomainfrom
Conversation
|
Preview is available here: |
Co-authored-by: Leigh <351529+leighmcculloch@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
This PR addresses issue #2271 by removing outdated resource limits and fees data from the documentation. The PR replaces detailed, static tables with references to Stellar Lab's live Network Limits page and the Stellar CLI command for querying current settings.
Changes:
- Removed all static resource limits tables (per-transaction limits, TTL parameters, ledger-wide limits)
- Removed static resource fees tables
- Added a reference to Stellar Lab's Network Limits page for live data
- Added CLI command example for querying network settings
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| For the latest live network limits and fees, see Stellar Lab's [Network Limits](https://lab.stellar.org/network-limits). | ||
|
|
||
| The values below are for reference. For current resource limits and fees on the live network, see Stellar Lab's [Network Limits](https://lab.stellar.org/network-limits) page. | ||
| You can also query current settings from the CLI: | ||
|
|
||
| ::: | ||
|
|
||
| ## Resource Limits | ||
|
|
||
| :::note | ||
|
|
||
| Resource limitations and fees only apply to smart contract transactions. Read more about the inner workings of fees on Stellar in the [Fees section](../learn/fundamentals/fees-resource-limits-metering.mdx). | ||
|
|
||
| ::: | ||
|
|
||
| ### Per-transaction limits | ||
|
|
||
| These define the maximum amount of work a single Smart contract transaction can do. | ||
|
|
||
| | Network Setting | Value | | ||
| | ----------------------------------------------------- | ------------------ | | ||
| | Max CPU instructions | 100 million | | ||
| | Max memory (RAM) | 40 MB | | ||
| | Max number of keys in the footprint | 100 | | ||
| | Disk reads\* | 100 entries/200 KB | | ||
| | Disk writes | 50 entries/132 KB | | ||
| | Transaction size | 132 KB | | ||
| | Events+return value size bytes | 16 KB | | ||
| | Individual ledger key size (contract storage key) | 250 bytes | | ||
| | Individual ledger entry size (including Wasm entries) | 128 KiB | | ||
|
|
||
| \* Most transactions don't perform any disk reads, as only archived entries and 'classic' entries (G-accounts, trustlines) are considered to be disk reads. Live smart contract state is in-memory and is not counted towards this limit. | ||
|
|
||
| ### TTL extension parameters | ||
|
|
||
| These define TTL extension parameters. | ||
|
|
||
| | Network Setting | Value | | ||
| | -------------------------------- | -------- | | ||
| | Persistent entry TTL on creation | 120 days | | ||
| | Temporary entry TTL on creation | 1 day | | ||
| | Max ledger entry TTL extension | 6 months | | ||
|
|
||
| ### Ledger-wide limits | ||
|
|
||
| These define the maximum amount of work done by all the transactions in a single ledger (single block). | ||
|
|
||
| | Network Setting | Value | | ||
| | ----------------------------------- | ------------------ | | ||
| | Max CPU instructions | 600 million | | ||
| | Max memory (RAM) | no explicit limit | | ||
| | Max number of keys in the footprint | no explicit limit | | ||
| | Disk reads | 1000 entries/7 MB | | ||
| | Disk writes | 500 entries/143 KB | | ||
| | Transactions size | 133 KB | | ||
| | Events+return value size bytes | no explicit limit | | ||
|
|
||
| ## Resource Fees | ||
|
|
||
| | Network Setting | Cost (stroops) | | ||
| | :--------------------------------------------- | :------------------------ | | ||
| | 10,000 CPU instructions | 25 (250,000/max tx) | | ||
| | Read 1 ledger entry from disk | 6,250 (625,000/max tx) | | ||
| | Read 1KB from disk | 1,786 (357,200/max tx) | | ||
| | Write 1 ledger entry | 10,000 (500,000/max tx) | | ||
| | Write 1KB to disk | 3,500 (462'000/max tx) | | ||
| | 1KB of transaction size (bandwidth) | 1,624 (214,368/max tx) | | ||
| | 1KB of transaction size (history) | 16,235 (2,143,020/max tx) | | ||
| | 1KB of Events/return value | 10,000 (160,000/max tx) | | ||
| | 30 days of rent for 1 KB of persistent storage | ~427,000 | | ||
| | 30 days of rent for 1 KB of temporary storage | ~213,500 | | ||
|
|
||
| Note, that the rent fees provided here may go up in case if a lot of contract data is written to the ledger within a short time period. This happens because the rent fees are designed in such a way that the closer the state size to some validator-defined threshold, the more expensive it gets to write new data or extend the TTLs. | ||
| ```bash | ||
| stellar network settings | ||
| ``` |
There was a problem hiding this comment.
This change breaks multiple internal documentation links. The file docs/networks/software-versions.mdx contains anchor links to sections #resource-limits and #resource-fees (lines 461, 462, 524, 525, 588, 589) that no longer exist after removing the detailed content. Additionally, docs/build/guides/archival/test-ttl-extension.mdx links to #resource-fees (line 78). These broken links will result in 404 errors for users navigating the documentation. Consider either keeping the section headers as anchors with redirects to the Stellar Lab URL, or updating all referring pages to link directly to the Stellar Lab.
| For the latest live network limits and fees, see Stellar Lab's [Network Limits](https://lab.stellar.org/network-limits). | ||
|
|
||
| The values below are for reference. For current resource limits and fees on the live network, see Stellar Lab's [Network Limits](https://lab.stellar.org/network-limits) page. | ||
| You can also query current settings from the CLI: | ||
|
|
||
| ::: | ||
|
|
||
| ## Resource Limits | ||
|
|
||
| :::note | ||
|
|
||
| Resource limitations and fees only apply to smart contract transactions. Read more about the inner workings of fees on Stellar in the [Fees section](../learn/fundamentals/fees-resource-limits-metering.mdx). | ||
|
|
||
| ::: | ||
|
|
||
| ### Per-transaction limits | ||
|
|
||
| These define the maximum amount of work a single Smart contract transaction can do. | ||
|
|
||
| | Network Setting | Value | | ||
| | ----------------------------------------------------- | ------------------ | | ||
| | Max CPU instructions | 100 million | | ||
| | Max memory (RAM) | 40 MB | | ||
| | Max number of keys in the footprint | 100 | | ||
| | Disk reads\* | 100 entries/200 KB | | ||
| | Disk writes | 50 entries/132 KB | | ||
| | Transaction size | 132 KB | | ||
| | Events+return value size bytes | 16 KB | | ||
| | Individual ledger key size (contract storage key) | 250 bytes | | ||
| | Individual ledger entry size (including Wasm entries) | 128 KiB | | ||
|
|
||
| \* Most transactions don't perform any disk reads, as only archived entries and 'classic' entries (G-accounts, trustlines) are considered to be disk reads. Live smart contract state is in-memory and is not counted towards this limit. | ||
|
|
||
| ### TTL extension parameters | ||
|
|
||
| These define TTL extension parameters. | ||
|
|
||
| | Network Setting | Value | | ||
| | -------------------------------- | -------- | | ||
| | Persistent entry TTL on creation | 120 days | | ||
| | Temporary entry TTL on creation | 1 day | | ||
| | Max ledger entry TTL extension | 6 months | | ||
|
|
||
| ### Ledger-wide limits | ||
|
|
||
| These define the maximum amount of work done by all the transactions in a single ledger (single block). | ||
|
|
||
| | Network Setting | Value | | ||
| | ----------------------------------- | ------------------ | | ||
| | Max CPU instructions | 600 million | | ||
| | Max memory (RAM) | no explicit limit | | ||
| | Max number of keys in the footprint | no explicit limit | | ||
| | Disk reads | 1000 entries/7 MB | | ||
| | Disk writes | 500 entries/143 KB | | ||
| | Transactions size | 133 KB | | ||
| | Events+return value size bytes | no explicit limit | | ||
|
|
||
| ## Resource Fees | ||
|
|
||
| | Network Setting | Cost (stroops) | | ||
| | :--------------------------------------------- | :------------------------ | | ||
| | 10,000 CPU instructions | 25 (250,000/max tx) | | ||
| | Read 1 ledger entry from disk | 6,250 (625,000/max tx) | | ||
| | Read 1KB from disk | 1,786 (357,200/max tx) | | ||
| | Write 1 ledger entry | 10,000 (500,000/max tx) | | ||
| | Write 1KB to disk | 3,500 (462'000/max tx) | | ||
| | 1KB of transaction size (bandwidth) | 1,624 (214,368/max tx) | | ||
| | 1KB of transaction size (history) | 16,235 (2,143,020/max tx) | | ||
| | 1KB of Events/return value | 10,000 (160,000/max tx) | | ||
| | 30 days of rent for 1 KB of persistent storage | ~427,000 | | ||
| | 30 days of rent for 1 KB of temporary storage | ~213,500 | | ||
|
|
||
| Note, that the rent fees provided here may go up in case if a lot of contract data is written to the ledger within a short time period. This happens because the rent fees are designed in such a way that the closer the state size to some validator-defined threshold, the more expensive it gets to write new data or extend the TTLs. | ||
| ```bash | ||
| stellar network settings | ||
| ``` |
There was a problem hiding this comment.
While redirecting to Stellar Lab for live data is appropriate, the removed content provided valuable context that users might find helpful, such as:
- A note explaining that resource limitations only apply to smart contract transactions
- Explanations of TTL extension parameters
- Distinction between per-transaction and ledger-wide limits
- Important footnotes about disk reads and rent fee calculations
Consider keeping a brief overview section that explains what resource limits and fees are (with a link to the fundamentals page at docs/learn/fundamentals/fees-resource-limits-metering.mdx for detailed explanations), before redirecting users to Stellar Lab for current values. This would provide educational context while still solving the outdated data problem.
| ```bash | ||
| stellar network settings | ||
| ``` |
There was a problem hiding this comment.
The CLI command example could benefit from additional context to be more helpful. Consider adding:
- A brief explanation of what the command returns (e.g., "This returns JSON output with current network configuration values")
- Optionally, an example of how to parse specific values from the output (similar to the example in the linked issue using
jqto extract specific settings) - A note that users need to have the Stellar CLI installed and configured for their target network
This would make the page more actionable for users who aren't already familiar with the Stellar CLI.
|
Preview is available here: |
#2271