-
Notifications
You must be signed in to change notification settings - Fork 38.7k
[WIP] Make arguments reconfigurable at runtime via RPC #7289
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
Conversation
|
Concept ACK. Clearly makes sense for some args. (c.f. Not sure if this should be enabled for all args. (Setting minRelayTxFee may result in unexpected behavior.) |
|
Rough concept ACK. To speak generally and scope the problem, each setting has been written with the idea that it is largely static throughout program runtime. At an engineering level, you have to revisit each setting in the context of thread safety, as well as wider impacts such as, e.g. changing min-relay-tx-fee and then running with a mempool temporarily disjoint from that value (or, alternately, adding setting-specific trigger code to be executed when setting A or B is changed at runtime). tl;dr Good goal, but requires per-setting analysis, and possibly per-setting runtime reconfiguration code. |
|
Concept ACK. Currently, your new Conceptual, when supporting a |
|
This would be great! |
|
Yes, I intentionally designed this to require explicit opt-in from each setting. Having a getter/setter for each item would IMO bloat the code and discourage making options configurable instead of making it trivial to do. If we're replacing settings with classes (is that really low-overhead enough for some settings?), however, that might solve all the concerns at once - it could manage the correct locks only, and refuse assignment after being read (for arguments that's appropriate for). |
|
Concept ACK. I know this could save me from a few restarts here and there :). |
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.
Could you keep the hypen, so it is possible to grep for it?
Nit: Also, could you make it the first arg so it is easier to fix
bitcoin/contrib/devtools/check-doc.py
Line 19 in 668906f
| CMD_GREP_ARGS = r"egrep -r -I '(map(Multi)?Args(\.count\(|\[)|Get(Bool)?Arg\()\"\-[^\"]+?\"' %s | grep -v '%s'" % (CMD_ROOT_DIR, FOLDER_TEST) |
|
Having a getter function too would be helpful. In JoinMarket sometimes people misconfigure -walletnotify, the getter options would be a way to detect this and display a helpful error message. |
|
This sounds like it could cause havoc in some places, especially where the assumption of constants has been made. Otherwise, concept ACK. |
|
concept ACK - will the changed values be remembered so that if bitcoind is restarted it will continue with the last-used values? |
|
No, for that we'd need to combine this with #7510. |
|
As #7510 is too controversial, let's continue with this. Needs rebase. Dumping memory pool slightly shifted the priority here, because one can easily restart the node, but still looses connections etc. So still concept ACK from me. |
|
@luke-jr, this pull request has had many Concept ACK. I think that it is worth the rebase, and a second look. |
|
Not a priority for me right now. |
Just looking for concept ACK/NACK on this before proceeding. (Currently untested, but compiles.)
Maybe tips on how to avoid void* and ugly casting too...