Commit ec8bfb3
committed
feat: introduce and configure node with tiered KVStore
Introduces TierStore, a KVStore implementation that manages data
across three storage layers:
- Primary: Main/remote data store
- Ephemeral: Secondary store for non-critical, easily-rebuildable
data (e.g., network graph) with fast local access
- Backup: Tertiary store for disaster recovery with async/lazy
operations to avoid blocking primary store
Adds four configuration methods to NodeBuilder:
- set_tier_store_backup: Configure backup data store
- set_tier_store_ephemeral: Configure ephemeral data store
- set_tier_store_retry_config: Configure retry parameters with
exponential backoff
- build_with_tier_store: Build node with primary data store
These methods are exposed to the foreign interface via additions
in ffi/types.rs:
- ffi::SyncAndAsyncKVStore: Composed of KVStore and KVStoreSync
methods to handle the types::SyncAndAsyncKVStore supertrait
across FFI
- ffi::ForeignKVStoreAdapter and ffi::DynStore: Adapt/translate
between foreign language store and native Rust store
- Conditional compilation for DynStore: ffi::DynStore with uniffi,
types::DynStore without, with selection aided by the wrap_store!()
macro1 parent eaad8f5 commit ec8bfb3
File tree
22 files changed
+1970
-49
lines changed- bindings
- src
- chain
- ffi
- io
- payment/asynchronous
- wallet
- tests
- common
22 files changed
+1970
-49
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
| 92 | + | |
92 | 93 | | |
93 | 94 | | |
94 | 95 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
49 | 55 | | |
50 | 56 | | |
51 | 57 | | |
| |||
67 | 73 | | |
68 | 74 | | |
69 | 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 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
70 | 126 | | |
71 | 127 | | |
72 | 128 | | |
| |||
95 | 151 | | |
96 | 152 | | |
97 | 153 | | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
98 | 157 | | |
99 | 158 | | |
100 | 159 | | |
| |||
107 | 166 | | |
108 | 167 | | |
109 | 168 | | |
| 169 | + | |
| 170 | + | |
110 | 171 | | |
111 | 172 | | |
112 | 173 | | |
| |||
0 commit comments