aegis-common-0.1.6 has been yanked.
aegis-common
Common types, utilities, and shared functionality for the Aegis Database Platform.
Overview
aegis-common provides the foundational types and utilities used across all Aegis crates. It ensures consistency and reduces code duplication throughout the platform.
Features
- Configuration Management - TOML-based configuration loading and validation
- Error Handling - Unified error types with
thiserror - Common Types - Shared data structures (IDs, timestamps, results)
- Utilities - Hashing (xxHash), checksums (CRC32), UUID generation
Modules
| Module | Description |
|---|---|
config |
Configuration structures and loading |
error |
Common error types and Result aliases |
types |
Shared type definitions (NodeId, BlockId, etc.) |
utils |
Utility functions (hashing, encoding, time) |
Usage
Add to your Cargo.toml:
[]
= { = "../aegis-common" }
Example
use ;
use AegisConfig;
use ;
// Generate a unique ID
let id = generate_id;
// Hash some data
let hash = hash_bytes;
// Load configuration
let config = from_file?;
Dependencies
serde/serde_json- Serializationthiserror- Error handlingchrono- Date/time utilitiesuuid- Unique identifier generationxxhash-rust- Fast hashingcrc32fast- Checksum computation
Tests
License
Apache-2.0