-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Do not attempt to acquire missing data from peer network in #4458
Conversation
a5a2f6b
to
2b5f18d
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.
It looks like the key part is the conditional throw added at line 73 in src/ripple/shamap/impl/NodeFamily.cpp
. Can we just make that a std::runtime_error
with the information available, without adding any new parameters, enumerations, or constructors?
@thejohnfreeman Unfortunately, I discarded the original stack trace I was looking at when I made this patch, so i forget the exact code path being traversed. But assumedly it had to do with an RPC request based on a particular ledger, which then goes into the cassandra-backed nodestore. |
@thejohnfreeman
So the way I implemented this was when I saw that SHAMap::fetchNode throws SHAMapMissingNode if it can't find something, I then decided to make the lower-level call of missingNode throw the same thing. This is in hopes that as it the exception bubbles up, it gets handled sensibly. But I didn't look at all the possible ways it bubbles up, because there are lots of callers for this code path. |
@thejohnfreeman I found a good place to catch this error, and simplified things so all your concerns should be addressed. |
We're getting closer, and I appreciate the change. Now notice this: We've changed the signature of |
Yeah, it's all down to that. In general, I think singletons like Application, Config, Journal, should be globals. But that's for another patch. |
reporting mode.
* upstream/develop: Rectify the import paths of boost/iterator: (XRPLF#4293) Allow port numbers be be specified with a colon: (XRPLF#4328) Use <=> operator for base_uint, Issue, and Book: (XRPLF#4411) Reporting Mode: Do not attempt to acquire missing data from peer network (XRPLF#4458)
* upstream/develop: Rectify the import paths of boost/iterator: (XRPLF#4293) Allow port numbers be be specified with a colon: (XRPLF#4328) Use <=> operator for base_uint, Issue, and Book: (XRPLF#4411) Reporting Mode: Do not attempt to acquire missing data from peer network (XRPLF#4458)
* upstream/develop: Rectify the import paths of boost/iterator: (XRPLF#4293) Allow port numbers be be specified with a colon: (XRPLF#4328) Use <=> operator for base_uint, Issue, and Book: (XRPLF#4411) Reporting Mode: Do not attempt to acquire missing data from peer network (XRPLF#4458)
* upstream/develop: Rectify the import paths of boost/iterator: (XRPLF#4293) Allow port numbers be be specified with a colon: (XRPLF#4328) Use <=> operator for base_uint, Issue, and Book: (XRPLF#4411) Reporting Mode: Do not attempt to acquire missing data from peer network (XRPLF#4458)
* upstream/develop: Rectify the import paths of boost/iterator: (XRPLF#4293) Allow port numbers be be specified with a colon: (XRPLF#4328) Use <=> operator for base_uint, Issue, and Book: (XRPLF#4411) Reporting Mode: Do not attempt to acquire missing data from peer network (XRPLF#4458)
…ctionality * upstream/develop: Rectify the import paths of boost/iterator: (XRPLF#4293) Allow port numbers be be specified with a colon: (XRPLF#4328) Use <=> operator for base_uint, Issue, and Book: (XRPLF#4411) Reporting Mode: Do not attempt to acquire missing data from peer network (XRPLF#4458)
…tpage * upstream/develop: Rectify the import paths of boost/iterator: (XRPLF#4293) Allow port numbers be be specified with a colon: (XRPLF#4328) Use <=> operator for base_uint, Issue, and Book: (XRPLF#4411) Reporting Mode: Do not attempt to acquire missing data from peer network (XRPLF#4458)
reporting mode.
High Level Overview of Change
This should fix a problem of dumping core when Cassandra is down for reporting mode servers.
Context of Change
Type of Change