rpc: persist the latest setgenerate state with ForceSetArg (#448)#454
Open
JSanchezFDZ wants to merge 1 commit into
Open
rpc: persist the latest setgenerate state with ForceSetArg (#448)#454JSanchezFDZ wants to merge 1 commit into
JSanchezFDZ wants to merge 1 commit into
Conversation
…#448) setgenerate stored -gen/-genproclimit with SoftSetArg(), which only writes an arg when it is currently unset. After the first call the values were locked in, so a later "setgenerate true 20" (or "setgenerate false") could not update the stored thread count and the node kept reporting/using the count from the first invocation. setgenerate is an explicit runtime command and must win, so force the values instead. This complements PR Raptor3um#449, which fixes the response text; together they fully resolve the stale thread count in Raptor3um#448.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up to #448 / #449.
setgeneratestored-genand-genproclimitwithSoftSetArg(), whichonly writes an arg when it is currently unset. Once the first
setgeneratecall ran, those values were locked in: a latersetgenerate true 20orsetgenerate falsecould no longer update thestored thread count, so the node kept reporting/using the count from the
very first invocation.
Since
setgenerateis an explicit runtime command it must overwrite theprevious state, so this switches the two calls to
ForceSetArg().This is orthogonal to #449 (which corrects the response text) and touches
different lines — together they fully resolve the stale thread count
reported in #448.