Skip to content

Conversation

iFoggz
Copy link
Member

@iFoggz iFoggz commented Sep 30, 2019

Changed:

  • Clean up inactivity checks and crowding.
  • Remove double checks on lack of socket message response of 24 seconds
  • Fix incorrect -timeout default value to what is specified in args help
  • PEER_TIMEOUT is default 45 seconds
  • Add PEER_TIMEOUT defaults to 45 however can be set to user-defined -peertimeout arg.
  • Remove banscore of 1 for no socket message within 24 seconds
  • Add continues where appropriate when pnode->fdisconnect is set to reduce wasted cycles

Previous:

  • if the node did not send a socket message within the 24 seconds it would be set to disconnect and then do various other checks that could/would result in the same end result. We would also check > 24 seconds twice as well.

Notes:

  • 24 seconds could not necessarily be long enough. net code is dated and we have slow downs.
  • bitcoin does 60 seconds with a maparg to set peertimeout if a user chooses a custom number.
  • bitcoin does not misbehave in this area for a socket not replying in time.
  • bitcoin also does not disconnect a node after 2 hours if 75% of max connections is reached. We should review that portion of code. If a node is connected more then 2 hours and has not been banned then disconnecting a well behaved node might not be so supportive network wise.
  • Added some spacing as it was a little clogged up imo.

Add a milestone for a complete refactor of ThreadSocketHandler2() for now this should improve in this area some

@iFoggz
Copy link
Member Author

iFoggz commented Sep 30, 2019

this will conflict with #1537 for peer timeout. i think @jamescowens you should rebase/push this commit into your PR.

@jamescowens jamescowens added this to the Fern milestone Sep 30, 2019
@jamescowens jamescowens self-requested a review September 30, 2019 17:32
Copy link
Member

@jamescowens jamescowens left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks pretty good to me. I would like a double check by @denravonska.

@jamescowens jamescowens merged commit ddd2265 into gridcoin-community:development Oct 1, 2019
@jamescowens jamescowens removed the request for review from denravonska October 1, 2019 16:32
jamescowens added a commit that referenced this pull request Oct 22, 2019
Added
 - Add testnet desktop launcher action for Linux #1516 (@caraka)
 - Shuffle vSideStakeAlloc if necessary to support sidestaking to more than 6 destinations #1532 (@jamescowens)
 - New Superblock format preparations for Fern #1526, #1542 (@jamescowens, @cyrossignol)
 - Multisigtools
   - Consolidate multisig unspent #1529 (@iFoggz)
   - Scanforunspent #1547 (@iFoggz)
   - consolidatemsunspent and scanforunspent bug fix #1561 (@iFoggz)
 - New banning misbehavior handling and Peers Tab on Debug Console #1537 (@jamescowens)
 - Reimplement getunconfirmedbalance rpc #1548 (@jamescowens)
 - Add CLI switch to display binary version #1553 (@cyrossignol)

Changed
 - Select smallest coins for contracts #1519 (@iFoggz)
 - Move some functionality from miner to SelectCoinsForStaking + Respect the coin reserve setting + Randomize UTXO order #1525 (@iFoggz)
 - For voting - if url does not contain http then add it #1531 (@iFoggz)
 - Backport newer serialization facilities from Bitcoin #1535 (@cyrossignol)
 - Refactor ThreadSocketHandler2() Inactivity checks #1538 (@iFoggz)
 - Update outdated checkpoints #1539 (@barton2526)
 - Change needed to build Gridcoin for OSX using homebrew #1540 (@Git-Jiro)
 - Optimize scraper traffic for expiring manifests #1542 (@jamescowens)
 - Move legacy neural vote warnings to debug log level #1560 (@cyrossignol)
 - Change banlist save interval to 5 minutes #1564 (@jamescowens)
 - Change default rpcconsole.ui window size to better support new Peers tab #1566 (@jamescowens)

Removed
 - Remove deprecated RSA weight and legacy kernel #1507 (@cyrossignol)

Fixed
 - Clean up compiler warnings #1521 (@cyrossignol)
 - Handle missing external CPID in client_state.xml #1530 (@cyrossignol)
 - Support boost 1.70+ #1533 (@iFoggz)
 - Fix diagnostics failed to make connection to NTP server #1545 (@Git-Jiro)
 - Install manpages in correct system location #1546 (@Git-Jiro)
 - Fix ability to show help and version without a config file #1553 (@cyrossignol)
 - Refactor QT UI variable names to be more consistent, Fix Difficulty default #1563 (@barton2526)
 - Fix two regressions in previous UI refactor #1565 (@barton2526)
 - Fix "Owed" amount in output of "magnitude" RPC method #1569 (@cyrossignol)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants