@@ -2,10 +2,11 @@ Redbit reads struct annotations and derives code necessary for persisting and qu
22[ Redb] ( https://github.com/cberner/redb ) using secondary indexes and dictionaries, served by [ axum] ( https://github.com/tokio-rs/axum )
33through auto-generated REST API.
44
5- ### Main motivations
6- - ✅ Achieving more advanced querying capabilities with embedded KV stores is non-trivial
7- - ✅ Absence of any existing db & http higher-level layer for structured data in embedded KV stores
8- - ✅ Handwriting custom codecs on byte-level is tedious and painful
5+ ### Main motivation is a research
6+
7+ - ✅ Rust type and macro system and db engines at the byte level
8+ - ✅ decentralized persistence options to maximize indexing speed and minimize data size
9+ - ✅ meta space : self-tested and self-documented db & http layers of code derived from annotated structs
910
1011### Major Out-of-the-Box Features
1112
@@ -183,7 +184,7 @@ And R/W entire instances efficiently using indexes and dictionaries `examples/ut
183184
184185 println! (" Persisting blocks:" );
185186 for block in blocks . iter () {
186- Block :: store_and_commit (& db , block )?
187+ Block :: store_unsafe_and_commit (& db , block )?
187188 }
188189
189190 let read_tx = db . begin_read ()? ;
@@ -302,3 +303,66 @@ Block__get_header 277993
302303BlockHeader__get 280582
303304```
304305<!-- END_BENCH -->
306+
307+ ### Http Endpoints generated
308+ ```
309+ Endpoint /block/id/{value}
310+ Endpoint /block?take=
311+ Endpoint /block?first=
312+ Endpoint /block?last=
313+ Endpoint /block/id/{value}
314+ Endpoint /block/id?from=&until=
315+ Endpoint /block/{value}/header
316+ Endpoint /block/{value}/transactions
317+
318+ Endpoint /blockheader/id/{value}
319+ Endpoint /blockheader?take=
320+ Endpoint /blockheader?first=
321+ Endpoint /blockheader?last=
322+ Endpoint /blockheader/id/{value}
323+ Endpoint /blockheader/id?from=&until=
324+ Endpoint /blockheader/hash/{value}
325+ Endpoint /blockheader/timestamp/{value}
326+ Endpoint /blockheader/timestamp?from=&until=
327+ Endpoint /blockheader/merkle_root/{value}
328+
329+ Endpoint /transaction/id/{value}
330+ Endpoint /transaction?take=
331+ Endpoint /transaction?first=
332+ Endpoint /transaction?last=
333+ Endpoint /transaction/id/{value}
334+ Endpoint /transaction/id/{value}/parent_pk
335+ Endpoint /transaction/id?from=&until=
336+ Endpoint /transaction/hash/{value}
337+ Endpoint /transaction/{value}/utxos
338+ Endpoint /transaction/{value}/inputs
339+
340+ Endpoint /utxo/id/{value}
341+ Endpoint /utxo?take=
342+ Endpoint /utxo?first=
343+ Endpoint /utxo?last=
344+ Endpoint /utxo/id/{value}
345+ Endpoint /utxo/id/{value}/parent_pk
346+ Endpoint /utxo/id?from=&until=
347+ Endpoint /utxo/datum/{value}
348+ Endpoint /utxo/address/{value}
349+ Endpoint /utxo/{value}/assets
350+
351+ Endpoint /inputref/id/{value}
352+ Endpoint /inputref?take=
353+ Endpoint /inputref?first=
354+ Endpoint /inputref?last=
355+ Endpoint /inputref/id/{value}
356+ Endpoint /inputref/id/{value}/parent_pk
357+ Endpoint /inputref/id?from=&until=
358+
359+ Endpoint /asset/id/{value}
360+ Endpoint /asset?take=
361+ Endpoint /asset?first=
362+ Endpoint /asset?last=
363+ Endpoint /asset/id/{value}
364+ Endpoint /asset/id/{value}/parent_pk
365+ Endpoint /asset/id?from=&until=
366+ Endpoint /asset/name/{value}
367+ Endpoint /asset/policy_id/{value}
368+ ```
0 commit comments