pub trait KitsuneHost: 'static + Send + Sync {
    fn get_agent_info_signed(
        &self,
        input: GetAgentInfoSignedEvt
    ) -> MustBoxFuture<'_, Result<Option<AgentInfoSigned>, Box<dyn Error + Sync + Send + 'static, Global>>> ; fn remove_agent_info_signed(
        &self,
        input: GetAgentInfoSignedEvt
    ) -> MustBoxFuture<'_, Result<bool, Box<dyn Error + Sync + Send + 'static, Global>>> ; fn peer_extrapolated_coverage(
        &self,
        space: Arc<KitsuneSpace>,
        dht_arc_set: DhtArcSet
    ) -> MustBoxFuture<'_, Result<Vec<f64, Global>, Box<dyn Error + Sync + Send + 'static, Global>>> ; fn query_region_set(
        &self,
        space: Arc<KitsuneSpace>,
        dht_arc_set: Arc<DhtArcSet>
    ) -> MustBoxFuture<'_, Result<RegionSetLtcs<RegionData>, Box<dyn Error + Sync + Send + 'static, Global>>> ; fn query_size_limited_regions(
        &self,
        space: Arc<KitsuneSpace>,
        size_limit: u32,
        regions: Vec<Region<RegionData>, Global>
    ) -> MustBoxFuture<'_, Result<Vec<Region<RegionData>, Global>, Box<dyn Error + Sync + Send + 'static, Global>>> ; fn query_op_hashes_by_region(
        &self,
        space: Arc<KitsuneSpace>,
        region: RegionCoords
    ) -> MustBoxFuture<'_, Result<Vec<RoughSized<Arc<KitsuneOpHash>>, Global>, Box<dyn Error + Sync + Send + 'static, Global>>> ; fn record_metrics(
        &self,
        space: Arc<KitsuneSpace>,
        records: Vec<MetricRecord, Global>
    ) -> MustBoxFuture<'_, Result<(), Box<dyn Error + Sync + Send + 'static, Global>>> ; fn get_topology(
        &self,
        space: Arc<KitsuneSpace>
    ) -> MustBoxFuture<'_, Result<Topology, Box<dyn Error + Sync + Send + 'static, Global>>> ; fn op_hash(
        &self,
        op_data: Arc<KitsuneOpData>
    ) -> MustBoxFuture<'_, Result<Arc<KitsuneOpHash>, Box<dyn Error + Sync + Send + 'static, Global>>> ; fn check_op_data(
        &self,
        space: Arc<KitsuneSpace>,
        op_hash_list: Vec<Arc<KitsuneOpHash>, Global>,
        _context: Option<FetchContext>
    ) -> MustBoxFuture<'_, Result<Vec<bool, Global>, Box<dyn Error + Sync + Send + 'static, Global>>> { ... } }
Expand description

The interface to be implemented by the host, which handles various requests for data

Required Methods§

We need to get previously stored agent info.

Remove an agent info from storage

Extrapolated Peer Coverage.

Query aggregate dht op data to form an LTCS set of region data.

Given an input list of regions, return a list of equal or greater length such that each region’s size is less than the size_limit, by recursively subdividing regions which are over the size limit.

Get all op hashes within a region

Record a set of metric records.

Get the quantum Topology associated with this Space.

Hashing function to get an op_hash from op_data.

Provided Methods§

Check which hashes we have data for.

Implementors§