-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy pathlib.rs
More file actions
110 lines (95 loc) · 3.68 KB
/
Copy pathlib.rs
File metadata and controls
110 lines (95 loc) · 3.68 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
//! AimDB Core Database Engine
//!
//! # aimdb-core
//!
//! Type-safe, async in-memory database for data synchronization
//! across MCU → edge → cloud environments.
//!
//! # Architecture
//!
//! - **RecordKey/RecordId**: Stable identifiers for multi-instance records
//! - **Runtime Agnostic**: Works with Tokio (std) or Embassy (embedded)
//! - **Producer-Consumer**: Built-in typed message passing
//!
//! See examples in the repository for usage patterns.
#![cfg_attr(not(feature = "std"), no_std)]
extern crate alloc;
// Must precede the other modules: `macro_rules!` visibility is textual.
#[macro_use]
mod log;
pub mod buffer;
pub mod builder;
#[cfg(feature = "json-serialize")]
pub mod codec;
pub mod connector;
pub mod context;
mod error;
pub mod extensions;
pub mod graph;
#[cfg(feature = "profiling")]
pub mod profiling;
pub mod record_id;
#[cfg(feature = "remote-access")]
pub mod remote;
pub mod router;
#[cfg(feature = "connector-session")]
pub mod session;
pub mod time;
pub mod transform;
pub mod transport;
pub mod typed_api;
pub mod typed_record;
// Public API exports
pub use context::RuntimeContext;
pub use error::{ConfigError, DbError, DbResult};
pub use extensions::Extensions;
// Error/result re-exports from aimdb-executor. The generic runtime trait
// family (`RuntimeAdapter`, `Runtime`, `TimeOps`, `Logger`, `RuntimeInfo`) is
// no longer consumed by core — the runtime travels as
// `Arc<dyn aimdb_executor::RuntimeOps>` (issue #131) — so it is not
// re-exported here; import those traits from `aimdb_executor` directly if an
// adapter still needs them.
pub use aimdb_executor::{ExecutorError, ExecutorResult};
// Producer-Consumer Pattern exports
pub use builder::OutboundRoute;
pub use builder::{AimDb, AimDbBuilder};
pub use connector::ConnectorBuilder;
pub use transport::{Connector, ConnectorConfig, PublishError};
pub use typed_api::{
Consumer, InboundConnectorBuilder, OutboundConnectorBuilder, Producer, RecordRegistrar,
RecordT, StageKind,
};
#[cfg(feature = "remote-access")]
pub use typed_record::JsonRecordAccess;
pub use typed_record::{
AnyRecord, AnyRecordExt, RecordIntrospect, RecordMetricsReset, TypedRecord,
};
// JSON codec (feature `json-serialize`, no_std + alloc compatible)
#[cfg(feature = "json-serialize")]
pub use codec::{JsonCodec, RemoteSerialize, SerdeJsonCodec};
// connector-session contracts (feature `connector-session`, no_std + alloc
// compatible). See docs/design/remote-access-via-connectors.md.
#[cfg(feature = "connector-session")]
pub use session::{
pump_sink, pump_source, AuthError, BoxFut, BoxStream, CodecError, Connection, Dialer, Dispatch,
EnvelopeCodec, Inbound, Listener, Outbound, Payload, PeerInfo, RpcError, SessionCtx,
SessionLimits, Source, TransportError, TransportResult,
};
// Stage profiling exports (feature-gated)
#[cfg(feature = "profiling")]
pub use profiling::{RecordProfilingMetrics, StageMetrics, StageProfilingInfo};
// Connector Infrastructure exports
pub use connector::TopicProvider;
pub use connector::TopicResolverFn;
pub use connector::{ConnectorLink, ConnectorUrl, SerializeError};
pub use connector::{IngestFactoryFn, IngestFn};
pub use connector::{SerializedReader, SerializedSource, SerializedValue, SourceFactoryFn};
// Router exports for connector implementations
pub use router::{Route, Router, RouterBuilder};
// Record identification exports
pub use record_id::{RecordId, RecordKey, StringKey};
// Graph exports (dependency graph for record topology)
pub use graph::{DependencyGraph, EdgeType, GraphEdge, GraphNode, RecordGraphInfo, RecordOrigin};
// Transform API exports
pub use transform::{JoinBuilder, JoinEventRx, JoinPipeline, JoinTrigger};
pub use transform::{TransformBuilder, TransformPipeline};