Crate hyperactor_config

Crate hyperactor_config 

Source
Expand description

Core configuration and attribute infrastructure for Hyperactor.

This crate provides the core infrastructure for type-safe configuration management including:

  • ConfigAttr: Metadata for configuration keys
  • Helper functions to load/save Attrs (from env via from_env, from YAML via from_yaml, and to_yaml)
  • Global layered configuration store under crate::global

Individual crates should declare their own config keys using declare_attrs! and import ConfigAttr, CONFIG, and other infrastructure from this crate.

Re-exports§

pub use attrs::AttrValue;
pub use attrs::Attrs;
pub use attrs::Key;

Modules§

attrs
Attribute dictionary for type-safe, heterogeneous key-value storage with serde support.
global
Global layered configuration for Hyperactor.

Macros§

declare_attrs
Declares attribute keys using a lazy_static! style syntax.
impl_attrvalue
Macro to implement AttrValue for types that implement ToString and FromStr.
paste
submit
Enter an element into the plugin registry corresponding to its type.

Structs§

ConfigAttr
Metadata describing how a configuration key is exposed across environments.

Statics§

CONFIG
This is a meta-attribute marking a configuration key.

Functions§

from_env
Load configuration from environment variables
from_yaml
Load configuration from a YAML file
to_yaml
Save configuration to a YAML file

Derive Macros§

AttrValue
Derive the [hyperactor_config::attrs::AttrValue] trait for a struct or enum.