<p>First note that Ripple uses the term <a href="https://ripple.com/wiki/Ledger" rel="noreferrer">ledger</a> slightly differently than <a href="https://en.wikipedia.org/wiki/Ledger" rel="noreferrer">general use</a>.</p>

<p>In Ripple a ledger is the set of all Ripple accounts, all their <em>current</em> balances, all open trade offers, and only the transaction details that justify the changes in this ledger from the previous ledger. A <a href="https://ripple.com/wiki/JSON_Messages#Specifying_the_ledger" rel="noreferrer">specific Ripple ledger</a> does <em>not</em> contain any other past history of transactions.</p>

<p>Even so, a Ripple ledger can still be somewhat large due to implementation details of it's binary representation. The implementation values lookup speed, syncing efficiency, hashing of sub-parts, and other features over absolute size.</p>

<p>Transaction history in Ripple is stored by servers keeping multiple past ledgers, as many as desired, that form a chain similar to Bitcoin's block chain. However, unlike Bitcoin, it's possible for new transactions to be processed by a Ripple server that only has the last validated ledger. Such servers (validators) are free to discard all older ledgers (and their transactions).</p>

<p>Currently most public facing Ripple servers (that accept transaction submissions and state queries) maintain a <a href="https://ripple.com/wiki/Genesis_ledger" rel="noreferrer">near fully history</a> of all past ledgers and can therefore answer queries relating to historical information (e.g. a list of past transactions that effected a specific account via the <a href="https://ripple.com/wiki/JSON_Messages#account_tx" rel="noreferrer">account_tx</a> API), but there is no requirement for any given Ripple server to make such history available (servers inform clients of the range or ledgers they have available).</p>

<p>It's desirable to have at least a few Ripple servers making as much past history as possible publicly available so that anyone interested can query information about past transactions. For example, it is expected that gateways will run Ripple servers for their customers and would configure at least some of those to store the full history since the gateway's inception (at least).</p>

<p>As the storage requirements for full history increase it may become more common to have "slim" Ripple servers that only store a fixed history (perhaps a few weeks worth) for cost reasons. Ripple clients could use these for faster day-to-day operation (for example if their were more of these or if they were located closer to the client) and only need to query the potentially slower (for example if they're fewer and more overloaded or farther away from the client) servers when more ancient history is required.</p>

CC BY-SA 3.0
2014-05-06T16:58:42.027Z
2014-05-06T17:04:30.730Z
2014-05-06T17:04:30.730Z
dchapes
<p>Why does ripple need to maintain a long ledger? Why is it not enough to maintain only the most previous transaction details? What is the purpose of having a long history ledger?</p>

CC BY-SA 3.0
2014-05-06T13:04:42.627Z
Don't you want to be able to trace all transactions, from the [beginning](https://ripple.com/wiki/Genesis_ledger) until the current time?
Nik Bougalis
<protocol><ripple><architecture><consensus>
Why does Ripple needs to have a long ledger?
tdumidu
# Why does Ripple needs to have a long ledger?

(Asked by: username_0 on 2014-05-06)

Why does ripple need to maintain a long ledger? Why is it not enough to maintain only the most previous transaction details? What is the purpose of having a long history ledger?

**Tags:** protocol, ripple, architecture, consensus

> **Comments:**
> **username_1**: Don't you want to be able to trace all transactions, from the [beginning](https://ripple.com/wiki/Genesis_ledger) until the current time?  

---

## 1 answers

### Answer by username_2 on 2014-05-06. Score: 5 | Accepted answer

First note that Ripple uses the term [ledger](https://ripple.com/wiki/Ledger) slightly differently than [general use](https://en.wikipedia.org/wiki/Ledger).

In Ripple a ledger is the set of all Ripple accounts, all their *current* balances, all open trade offers, and only the transaction details that justify the changes in this ledger from the previous ledger. A [specific Ripple ledger](https://ripple.com/wiki/JSON_Messages#Specifying_the_ledger) does *not* contain any other past history of transactions.

Even so, a Ripple ledger can still be somewhat large due to implementation details of it's binary representation. The implementation values lookup speed, syncing efficiency, hashing of sub-parts, and other features over absolute size.

Transaction history in Ripple is stored by servers keeping multiple past ledgers, as many as desired, that form a chain similar to Bitcoin's block chain. However, unlike Bitcoin, it's possible for new transactions to be processed by a Ripple server that only has the last validated ledger. Such servers (validators) are free to discard all older ledgers (and their transactions).

Currently most public facing Ripple servers (that accept transaction submissions and state queries) maintain a [near fully history](https://ripple.com/wiki/Genesis_ledger) of all past ledgers and can therefore answer queries relating to historical information (e.g. a list of past transactions that effected a specific account via the [account\_tx](https://ripple.com/wiki/JSON_Messages#account_tx) API), but there is no requirement for any given Ripple server to make such history available (servers inform clients of the range or ledgers they have available).

It's desirable to have at least a few Ripple servers making as much past history as possible publicly available so that anyone interested can query information about past transactions. For example, it is expected that gateways will run Ripple servers for their customers and would configure at least some of those to store the full history since the gateway's inception (at least).

As the storage requirements for full history increase it may become more common to have "slim" Ripple servers that only store a fixed history (perhaps a few weeks worth) for cost reasons. Ripple clients could use these for faster day-to-day operation (for example if their were more of these or if they were located closer to the client) and only need to query the potentially slower (for example if they're fewer and more overloaded or farther away from the client) servers when more ancient history is required.


---

