MCPcopy Create free account
hub / github.com/NodeDB-Lab/nodedb / add_node

Method add_node

nodedb-cluster/src/topology.rs:201–204  ·  view source on GitHub ↗

Add or update a node. Bumps the version.

(&mut self, info: NodeInfo)

Source from the content-addressed store, hash-verified

199
200 /// Add or update a node. Bumps the version.
201 pub fn add_node(&mut self, info: NodeInfo) {
202 self.nodes.insert(info.node_id, info);
203 self.version += 1;
204 }
205
206 /// Remove a node. Bumps the version.
207 pub fn remove_node(&mut self, node_id: u64) -> Option<NodeInfo> {

Callers 15

handle_topology_updateFunction · 0.45
pong_recovers_nodeFunction · 0.45
add_and_lookupFunction · 0.45
remove_nodeFunction · 0.45
set_stateFunction · 0.45
serde_roundtripFunction · 0.45
make_observerFunction · 0.45
make_topologyFunction · 0.45
hot_split_planFunction · 0.45

Calls 1

insertMethod · 0.45