mirror of
https://github.com/ZeroTier/ZeroTierOne
synced 2025-08-20 05:13:58 -07:00
Deferred decode for HELLO to prevent HELLOcalypse under high load of new peers.
This commit is contained in:
parent
a95ff21aaf
commit
8ef4edebbf
12 changed files with 463 additions and 73 deletions
|
@ -1511,6 +1511,27 @@ void ZT_Node_clusterHandleIncomingMessage(ZT_Node *node,const void *msg,unsigned
|
|||
*/
|
||||
void ZT_Node_clusterStatus(ZT_Node *node,ZT_ClusterStatus *cs);
|
||||
|
||||
/**
|
||||
* Do things in the background until Node dies
|
||||
*
|
||||
* This function can be called from one or more background threads to process
|
||||
* certain tasks in the background to improve foreground performance. It will
|
||||
* not return until the Node is shut down. If threading is not enabled in
|
||||
* this build it will return immediately and will do nothing.
|
||||
*
|
||||
* This is completely optional. If this is never called, all processing is
|
||||
* done in the foreground in the various processXXXX() methods.
|
||||
*
|
||||
* This does NOT replace or eliminate the need to call the normal
|
||||
* processBackgroundTasks() function in your main loop. This mechanism is
|
||||
* used to offload the processing of expensive mssages onto background
|
||||
* handler threads to prevent foreground performance degradation under
|
||||
* high load.
|
||||
*
|
||||
* @param node Node instance
|
||||
*/
|
||||
void ZT_Node_backgroundThreadMain(ZT_Node *node);
|
||||
|
||||
/**
|
||||
* Get ZeroTier One version
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue