Module small_peer_info

Module small_peer_info 

Source
Expand description

Use ditto.small_peer_info() to interact with peer metadata.

§Example

use dittolive_ditto::prelude::*;

let small_peer_info = ditto.small_peer_info();

small_peer_info.set_metadata(&serde_json::json!({
    "deviceType": "cashRegister"
}))?;

let metadata: serde_json::Value = small_peer_info.metadata()?;
assert_eq!(metadata["deviceType"].as_str().unwrap(), "cashRegister");

Structs§

SmallPeerInfo
The entrypoint for small peer user info collection. Small peer info consists of information gathered into a system collection on a regular interval and optionally synced to the Big Peer for device dashboard and debugging purposes.

Enums§

DittoSmallPeerInfoSyncScope
Determines which “kind” of peers the small peer info will be replicate to, defaults to DittoSmallPeerInfoSyncScope::BigPeerOnly.