Skip to main content

Crate active_uuid_registry

Crate active_uuid_registry 

Source
Expand description

§Active UUID Registry

A library for managing in-process, system-wide UUIDs for tracking component liveness.

This library provides a thread-safe UUID pool that can be used to track the liveness of UUIDs.

UUIDs are organized in a two-level global registry (namespace -> context -> UUID set), making it straightforward to track running components across logical scopes in dynamic systems.

Strongly encouraged to use proper management and implementation practices for their particular process/use-case, as there is no garbage collection or pool monitoring on the part of this library.

Use at your own (possible but unlikely) risk. You are responsible for managing the pool and its contents.

§Feature Flags

  • Default / single-threaded: Use a single-threaded map for the UUID pool.
    • Uses a parking_lot::Mutex<HashMap<NamespaceKey, HashMap<ContextKey, HashSet<Uuid>>>> for the UUID pool.
  • concurrent-map: Use a concurrent map for the UUID pool.
    • Uses a DashMap<NamespaceKey, DashMap<ContextKey, DashSet<Uuid>>> for the UUID pool.

Modules§

interface
Interface API module for the Active UUID Registry.
registry_uuid
Generate and parse universally unique identifiers (UUIDs).

Enums§

UuidPoolError
Error type for UUID pool operations.

Type Aliases§

ContextString
Represents the name of a context within the registry pool.
NamespaceString
Represents the name of a namespace within the registry pool.