Skip to main content

Crate pim_plugin

Crate pim_plugin 

Source
Expand description

Plugin extensibility for pim-daemon.

A plugin runs in-process under the daemon’s tokio runtime. The daemon owns mesh-essential state (identity broadcast, routing, the peer keystore); plugins consume those services through the ports defined here and contribute:

JSON-RPC method registration is intentionally NOT routed through this trait: methods are wired into the daemon’s RPC dispatcher at compile time behind a Cargo feature, so the daemon can be built entirely without a given plugin.

Structs§

PluginContext
Snapshot of services + scratch space handed to a plugin at startup.

Enums§

PeerDirectoryEvent
Event published by the daemon’s PeerDirectory when its peer keystore mutates. Plugins subscribe to react to identity changes without polling.
PeerInfoSource
Origin of an inbound PeerInfo frame.

Traits§

ControlSender
Send a ControlFrame toward a peer, either over a direct connected session or via the multi-hop routing table.
DaemonPlugin
In-process plugin contract.
IdentitySecrets
Local identity material a plugin may need (typically for ECIES decrypt of messages addressed to us).
PeerDirectory
Read-mostly access to the daemon’s keystore of known peers.