XRPLF / rippled

Decentralized cryptocurrency blockchain daemon implementing the XRP Ledger protocol in C++
https://xrpl.org
ISC License
4.52k stars 1.46k forks source link

Send manifests from memory in manifest stream (Version: [1.7.0]) #3690

Open mayurbhandary opened 3 years ago

mayurbhandary commented 3 years ago

Motivation

The manifests stream is sparse because rippled does not send the previously encountered manifests that are stored in memory. Having a rich manifest stream is important for decentralized domain verification via domains found in manifests. By sending those manifests at the beginning of the connection, more domains will be found.

Solution

Send the manifests that are stored in rippled's memory upon first connecting to the manifest stream.

intelliot commented 3 years ago

Another option might be to add a mode to the manifest method where it returns all of the manifests stored in memory. For example, I think it makes sense to return all manifests if public_key is not specified.

jscottbranson commented 1 year ago

I think both of these approaches would be beneficial, and I would advocate for both to be implemented, since it would be ideal to avoid sending a one off query to retrieve manifests stored in memory before subscribing to changes. This convenience can already be found in the server subscription method, which provides additional data in the initial response. Although those data can also be queried using other methods, it is arguably convenient to retrieve this information with a single subscription, rather than a one off command followed by subscribing.