-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
getLedgerEntries
: optionally use high-performance Core server
#353
Conversation
@2opremio this should probably target a new feature branch e.g. |
c1923f2
to
41dd850
Compare
0e0847c
to
a8c4b29
Compare
a8c4b29
to
372638d
Compare
getLedgerEntries
with high-performance Core servergetLedgerEntries
with high-performance Core server
getLedgerEntries
with high-performance Core servergetLedgerEntries
: optionally use high-performance Core server
63b0d98
to
13d28da
Compare
b78154c
to
1a9e7cb
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks really solid! Coupla questions but otherwise pretty sure this can get a ✔️
captiveCorePort uint16 | ||
|
||
// These only need to be unconflicting ports | ||
captiveCorePort uint16 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
captiveCorePort
is the peer port and not the http port. It should probably be tagged as such for clarity.
What
This introduces
STELLAR_CAPTIVE_CORE_HTTP_QUERY_PORT
, enabling a high-performance HTTP server on the Captive Core subprocess for fetching ledger entries.This new endpoint is plumbed all the way through the
getLedgerEntries
handler, removing those database queries entirely.This also updates the
stellar/go
monorepo reference and its cascading dependencies.If
STELLAR_CAPTIVE_CORE_HTTP_QUERY_PORT
is set to 0 (the default value) RPC will use it's old and proven DB implementation ofgetLedgerEntries
instead of querying Core.Why
With CAP-66 arriving in Protocol 23 and its high-performance
/getledgerentry
endpoint (whose client was implemented in stellar/go#5542), we don't need to store ledger entries in RPC anymore.Today, we still need to provide snapshots to the simulation library, but tomorrow (in the opaque sense) we won't need to, so this is part of the transition work.
Related: #269.
Known limitations
TODO: