Module prelude

Module prelude 

Source
Expand description

Prelude module for convenient imports.

Re-exports§

pub use crate::RingKernel;

Modules§

align
Alignment utilities.
message_flags
Flags for extended H2K messages.
priority
Priority constants for convenient use.

Structs§

Alert
An alert to be routed to sinks.
AlertRouter
Alert router that sends alerts to multiple sinks.
AlertRouterStats
Alert router statistics.
AllocationHandle
Handle to an allocation within an AnalyticsContext.
AnalyticsContext
Context for analytics operations with grouped buffer lifecycle.
AnalyticsContextBuilder
Builder for AnalyticsContext with pre-configuration.
ApiKeyAuth
API key authentication provider.
AppInfo
Application information.
AuditConfig
Configuration for the audit logger.
AuditEvent
A structured audit event.
AuditLogger
The main audit logger.
AuditLoggerBuilder
Builder for AuditLogger.
AuthContext
Authentication context for an authenticated request.
BackgroundTaskStatus
Status of background tasks.
BlockId
Block ID within a grid (0 to grid_size - 1).
BoundedQueue
Bounded queue with blocking operations.
CachedSecretStore
A wrapper that adds caching to any secret store.
CancellationToken
A token that can be used to cancel an operation.
ChainedAuthProvider
Authentication provider that tries multiple providers in order.
ChainedSecretStore
A secret store that chains multiple stores, trying each in order.
CircuitBreaker
Circuit breaker for fault isolation.
CircuitBreakerConfig
Circuit breaker configuration.
CircuitBreakerStats
Circuit breaker statistics.
CircuitGuard
Guard for executing operations with circuit breaker protection.
CloudStorageConfig
Cloud storage configuration for checkpoint persistence.
CloudWatchConfig
Configuration for CloudWatch Logs sink.
CloudWatchSink
CloudWatch Logs sink for AWS-native audit logging.
ComplianceCheck
A single compliance check.
ComplianceReport
A complete compliance report.
ComplianceReporter
Compliance reporter for generating compliance documentation.
ComplianceSummary
Summary statistics for a compliance report.
ConfigBuilder
Fluent builder for RingKernelConfig.
ConsoleSink
Console log sink.
ContextMetrics
Context metrics for monitoring the unified runtime.
ContextMetricsBuffer
Buffer for collecting metrics within a kernel context.
ContextStats
Statistics for an analytics context.
ControlBlock
Kernel control block (128 bytes, cache-line aligned).
ControlBlockStateHelper
Helper for reading/writing state to/from ControlBlock.
CorrelationId
Correlation ID for request-response patterns.
CrossGpuK2KRouter
Routes K2K messages across GPU boundaries.
CrossGpuRouterStatsSnapshot
Snapshot of router statistics.
Deadline
A deadline for an operation.
DeduplicationConfig
Configuration for alert deduplication.
DegradationGuard
Guard for graceful degradation.
DegradationManager
Graceful degradation manager.
DegradationStats
Degradation statistics.
DeviceInfo
Information about a GPU device.
DeviceStatus
Status of a device in the multi-GPU coordinator.
DeviceUnregisterResult
Result of unregistering a device from the coordinator.
Dim3
3D dimension specification.
DispatchTable
Dispatch table mapping handler IDs to functions.
DispatcherBuilder
Builder for creating a KernelDispatcher.
DispatcherConfig
Configuration for the kernel dispatcher.
DispatcherMetrics
Metrics for dispatcher operations.
DomainParseError
Error returned when parsing an invalid domain string.
EncryptedRegion
An encrypted memory region.
EncryptionConfig
Configuration for memory encryption.
EncryptionKey
Represents an encryption key with metadata.
EncryptionStats
Statistics for memory encryption operations.
EnvVarSecretStore
Secret store backed by environment variables.
FileLogSink
File log sink.
FileSink
File-based audit sink.
GeneralConfig
General runtime settings.
GeneralConfigBuilder
Builder for GeneralConfig.
GlobalThreadId
Global thread ID across all blocks.
GpuConnection
Connection between two GPUs.
GpuDeviceMemoryStats
Per-device GPU memory statistics.
GpuMemoryAllocation
A tracked GPU memory allocation.
GpuMemoryDashboard
GPU Memory Dashboard for monitoring and visualization.
GpuMemoryPoolStats
GPU memory pool statistics.
GpuMemoryThresholds
Memory pressure thresholds for alerts.
GpuTopology
GPU topology graph describing all device interconnections.
GrafanaDashboard
Grafana dashboard builder.
GrafanaPanel
A Grafana panel definition.
HandlerRegistration
Handler registration entry for the dispatch table.
HealthCheck
A health check definition.
HealthCheckResult
Result of a health check.
HealthChecker
Health checker that manages multiple health checks.
HealthConfig
Health monitoring settings.
HealthConfigBuilder
Builder for HealthConfig.
HealthCycleResult
Result of a health check cycle run by the runtime context.
HlcClock
Hybrid Logical Clock for generating causally-ordered timestamps.
HlcState
Compact HLC state for GPU-side storage (16 bytes).
HlcTimestamp
Hybrid Logical Clock timestamp.
HotReloadConfig
Configuration for kernel hot reload operations.
HotReloadManager
Manager for kernel hot reload operations.
HotReloadRequest
Request to hot reload a kernel.
HotReloadResult
Result of a completed hot reload.
HotReloadStatsSnapshot
Snapshot of hot reload statistics.
Identity
Identity of an authenticated principal.
InMemorySecretStore
In-memory secret store for testing.
InMemorySink
Alert sink that stores alerts in memory (for testing).
K2KBroker
K2K message broker for routing messages between kernels.
K2KBuilder
Builder for creating K2K infrastructure.
K2KConfig
Configuration for K2K messaging.
K2KEndpoint
K2K endpoint for a single kernel.
K2KMessage
A K2K message with routing information.
K2KMessageRegistration
Registration information for a K2K-routable message type.
K2KTypeRegistry
Registry for discovering K2K-routable message types at runtime.
KernelAlert
An alert emitted from a kernel.
KernelCodeSource
Kernel code source for hot reload.
KernelDispatcher
Routes messages by type_id to registered handler kernels.
KernelHandle
Handle to a launched kernel.
KernelHealth
Kernel health status for watchdog.
KernelId
Unique kernel identifier.
KernelMetrics
Extended metrics for detailed monitoring.
KernelMigrationPlan
Plan for migrating a single kernel during device unregister.
KernelMigrator
Migrator that uses checkpoints for kernel state transfer between GPUs.
KernelSandbox
Kernel sandbox for isolation and resource control.
KernelStatus
Kernel status including state and metrics.
KernelWatchdog
Watchdog for monitoring kernel health.
KeyRotationManager
Manages automatic key rotation for encryption keys.
LatencyHistogram
Histogram for latency distribution.
LaunchOptions
Options for launching a kernel.
LoadSheddingPolicy
Load shedding policy.
LogEntry
A structured log entry.
LogSink
Alert sink that writes to the tracing/log system.
LoggerStats
Logger statistics.
MemoryEncryption
Memory encryption manager for GPU memory protection.
MemoryLogSink
Memory log sink for testing.
MemoryPool
Memory pool for efficient allocation/deallocation.
MemorySink
In-memory audit sink for testing.
MessageEnvelope
Envelope containing header and serialized payload.
MessageHeader
Fixed-size message header (256 bytes, cache-line aligned).
MessageId
Unique message identifier.
MetricsCollector
Metrics collector that aggregates metrics from multiple kernels.
MetricsEntry
A single metrics entry recorded by the kernel.
MetricsSnapshot
A snapshot of metrics at a point in time.
MigrationConfig
Kernel migration settings.
MigrationConfigBuilder
Builder for MigrationConfig.
MigrationRequest
Request to migrate a kernel between devices.
MigrationResult
Result of a completed migration.
MigrationStatsSnapshot
Snapshot of migration statistics.
MonitoringConfig
Configuration for background monitoring loops.
MonitoringHandles
Handles for background monitoring tasks.
MpscQueue
Multi-producer single-consumer lock-free queue.
MultiGpuBuilder
Builder for multi-GPU coordinator.
MultiGpuConfig
Multi-GPU coordination settings.
MultiGpuConfigBuilder
Builder for MultiGpuConfig.
MultiGpuCoordinator
Multi-GPU coordinator for managing kernels across devices.
ObservabilityConfig
Observability settings.
ObservabilityConfigBuilder
Builder for ObservabilityConfig.
ObservabilityContext
Global observability context for managing spans and metrics.
OperationContext
Context for tracking operation state including deadlines and cancellation.
OtlpConfig
Configuration for OTLP exporter.
OtlpExportResult
OTLP export result.
OtlpExporter
OTLP span exporter for sending traces to OTLP-compatible backends.
OtlpExporterStats
Statistics for the OTLP exporter.
PendingK2KMessage
A pending cross-GPU K2K message.
PinnedMemory
Pinned (page-locked) host memory for efficient DMA transfers.
PolicyEvaluator
RBAC policy evaluator.
PooledBuffer
A buffer from a memory pool.
PressureHandler
Memory pressure handler for stratified pools.
PrometheusExporter
Prometheus metrics exporter.
PubSubBroker
Pub/sub message broker.
PubSubBuilder
Builder for creating pub/sub infrastructure.
Publication
A published message on a topic.
QueueFactory
Factory for creating appropriately-sized message queues.
QueueMetrics
Comprehensive queue metrics snapshot.
QueueMonitor
Monitor for queue health and utilization.
QueueStats
Statistics for a message queue.
QuotaUtilization
Quota utilization percentages.
RateLimitConfig
Configuration for rate limiting.
RateLimitGuard
RAII guard for rate-limited operations.
RateLimiter
Global rate limiter.
RateLimiterBuilder
Builder for creating rate limiters.
RateLimiterStatsSnapshot
Snapshot of rate limiter statistics.
RbacPolicy
RBAC policy definition.
RecoveryAction
A recovery action to be taken.
RecoveryConfig
Configuration for automatic recovery.
RecoveryConfigBuilder
Builder for recovery configuration.
RecoveryManager
Manager for automatic kernel recovery.
RecoveryResult
Result of a recovery action.
RecoveryStatsSnapshot
Snapshot of recovery statistics.
ReductionConfig
Configuration for reduction operations.
ResourceLimits
Resource limits for sandboxed kernels.
ResourceQuota
Resource quotas for a tenant.
ResourceRule
A rule for specific resources.
ResourceUsage
Current resource usage for a tenant.
RetryConfig
Retry configuration.
RetryPolicy
Retry policy configuration.
RingContext
GPU intrinsics facade for kernel handlers.
RingKernelCollector
Prometheus collector for RingKernel metrics.
RingKernelConfig
Unified configuration for RingKernel.
RingKernelContext
Unified runtime context managing all enterprise features.
Role
A role with a set of permissions.
RuntimeBuilder
Builder for RingKernelContext.
RuntimeMetrics
Runtime-level metrics.
RuntimeStatsSnapshot
Snapshot of runtime statistics.
SandboxPolicy
Sandbox policy defining what a kernel can access.
SandboxStats
Statistics for sandbox enforcement.
SandboxViolation
A recorded sandbox violation.
SecretKey
A key identifying a secret in the store.
SecretValue
A secret value retrieved from the store.
ShutdownReport
Report generated after shutdown completes.
Span
An OpenTelemetry-compatible span.
SpanBuilder
Builder for creating spans with fluent API.
SpanEvent
An event that occurred during a span.
SpanId
A span ID compatible with OpenTelemetry W3C Trace Context.
SpscQueue
Single-producer single-consumer lock-free ring buffer.
StateDescriptor
Descriptor stored in _reserved when using external state.
StateSnapshot
Snapshot of kernel state for checkpointing.
StratifiedBuffer
A buffer from a stratified memory pool.
StratifiedMemoryPool
Multi-size memory pool with automatic bucket selection.
StratifiedPoolStats
Statistics for a stratified memory pool.
StructuredLogConfig
Configuration for structured logging.
StructuredLogConfigBuilder
Builder for log configuration.
StructuredLogSinkError
Log sink error.
StructuredLogger
Structured logger with trace correlation.
Subject
Subject for RBAC evaluation (who is making the request).
Subscription
A subscription to a topic.
SyslogConfig
Configuration for syslog sink.
SyslogSink
RFC 5424 syslog sink for remote audit log forwarding.
TelemetryAlert
An alert when telemetry thresholds are exceeded.
TelemetryBuffer
Telemetry buffer (64 bytes, cache-line aligned).
TelemetryConfig
Configuration for the telemetry pipeline.
TelemetryPipeline
Real-time telemetry pipeline.
TenantContext
Context for tenant-scoped operations.
TenantRegistry
Registry for managing tenants.
ThreadId
Thread ID within a block (0 to block_size - 1).
Timeout
Future that wraps another future with a timeout.
TimeoutError
Error returned when an operation times out.
TimeoutStats
Statistics for timeout tracking.
TimeoutStatsSnapshot
Snapshot of timeout statistics.
Topic
A topic name for pub/sub messaging.
TraceContext
Thread-local trace context for correlation.
TraceId
A trace ID compatible with OpenTelemetry W3C Trace Context.
WarpId
Warp ID within a block.
WatchdogResult
Result of a watchdog scan cycle.

Enums§

AccessLevel
Access control for kernel operations.
AlertRouting
Routing destination for alerts.
AlertSeverity
Alert severity levels.
AlertSinkError
Error type for alert sink operations.
AuditEventType
Types of audit events.
AuditLevel
Audit event severity levels.
AuthError
Error type for authentication operations.
Backend
GPU backend type.
BackoffStrategy
Backoff strategy for retries.
CheckpointStorageType
Checkpoint storage type.
CircuitState
Circuit breaker state.
ComplianceStandard
Compliance standard for reporting.
ComplianceStatus
Compliance check result.
ContextBackend
Backend-specific context implementation.
ControlError
Error codes for control block.
Credentials
Credentials provided by a client for authentication.
DegradationLevel
Degradation level for system operation.
DeliveryStatus
Status of message delivery.
Domain
Business domain classification for kernel messages.
EncryptionAlgorithm
Encryption algorithm for GPU memory protection.
Environment
Runtime environment.
FailureType
Types of kernel failures.
FenceScope
Memory fence scope for synchronization operations.
GpuMemoryType
GPU memory allocation type.
HealthStatus
Health status of a component.
HotReloadState
State of a hot reload operation.
InterconnectType
Type of interconnect between GPUs.
KernelAlertType
Type of kernel alert.
KernelCodeFormat
Kernel code format.
KernelMode
Kernel execution mode.
KernelState
Kernel lifecycle state.
KeyDerivation
Key derivation function for encryption keys.
LifecycleState
State of the runtime lifecycle.
LoadBalancingStrategy
Strategy for balancing load across devices.
LogLevel
Log level configuration.
LogOutput
Log output format.
LogValue
Log field value types.
MemoryOrder
Memory ordering for atomic operations.
MemoryPressureLevel
Memory pressure level.
MetricType
Type of metric entry.
MigrationPriority
Priority for kernel migration.
MigrationState
State of a kernel migration.
OperationPriority
Operation priority for load shedding decisions.
OtlpTransport
OTLP transport protocol.
PanelType
Grafana panel type.
Permission
Fine-grained permissions for kernel operations.
PressureReaction
Reaction to memory pressure events.
Priority
Message priority levels.
QoS
Quality of Service level for message delivery.
QueueHealth
Queue health status from monitoring.
QueueTier
Queue capacity tiers for dynamic queue allocation.
RateLimitAlgorithm
Rate limiting algorithm to use.
RateLimitError
Errors that can occur during rate limiting.
RbacError
Error type for RBAC evaluation.
RecoveryPolicy
Recovery policy for handling kernel failures.
ReductionOp
Reduction operation types.
ReportFormat
Report output format.
RingKernelError
Comprehensive error type for RingKernel operations.
RoutingDecision
Decision for how to route a K2K message.
SecretError
Error type for secret store operations.
SizeBucket
Size bucket for stratified pooling.
SpanKind
Span kind (OpenTelemetry compatible).
SpanStatus
Span status (OpenTelemetry compatible).
StructuredLogLevel
Log severity levels.
SyslogFacility
Syslog facility codes (RFC 5424).
SyslogSeverity
Syslog severity codes (RFC 5424).
TelemetryEvent
A telemetry event that is broadcast to subscribers.
TenantError
Error type for tenant operations.
ViolationType
Sandbox violation type.

Constants§

CONTROL_BLOCK_STATE_SIZE
Size of the reserved field in ControlBlock available for state storage.
MAX_CLOCK_SKEW_MS
Maximum allowed clock skew in milliseconds.
MAX_INLINE_PAYLOAD_SIZE
Maximum size for inline payload in extended messages. Messages larger than this must use external buffer references.
STATE_DESCRIPTOR_MAGIC
Magic number for state descriptor (“STAT” in little-endian).

Traits§

AlertSink
Trait for pluggable alert destinations.
AuditSink
Trait for audit log output sinks.
AuthProvider
Trait for pluggable authentication providers.
DeviceMemory
Trait for device memory allocation.
DomainMessage
Trait for messages that belong to a specific business domain.
EmbeddedState
Trait for state types that can be embedded directly in ControlBlock.
EmbeddedStateSize
Marker trait to verify state fits in 24 bytes at compile time.
GlobalReduction
Trait for GPU runtimes that support global reduction operations.
GpuBuffer
Trait for GPU buffer operations.
GpuState
Trait for GPU-compatible state types that may be stored externally.
HotReloadableKernel
Trait for kernels that support hot reload.
KernelHandleInner
Inner trait for kernel handle implementation.
MessageQueue
Trait for message queue implementations.
MigratableKernel
Trait for kernels that support live migration.
PersistentMessage
Trait for messages that can be dispatched within a persistent GPU kernel.
PressureAwarePool
Extension trait for pressure-aware memory pools.
PrometheusCollector
Trait for collecting Prometheus metrics.
RateLimiterExt
Extension trait for acquiring guards.
ReductionHandle
Handle to a reduction buffer for streaming operations.
ReductionScalar
Trait for scalar types that support reduction operations.
RingKernelRuntime
Backend-agnostic runtime trait for kernel management.
RingMessage
Trait for types that can be sent as kernel messages.
SecretStore
Trait for pluggable secret storage backends.
StructuredLogSink
Trait for log output destinations.

Functions§

create_pool
Create a shared memory pool.
create_stratified_pool
Create a shared stratified memory pool.
create_stratified_pool_with_capacity
Create a shared stratified memory pool with custom capacity.
shared_rate_limiter
Create a shared rate limiter.
timeout
Wrap a future with a timeout.
timeout_named
Wrap a future with a timeout and operation name.
with_timeout
Execute an async operation with timeout using tokio.
with_timeout_named
Execute an async operation with timeout and operation name.

Type Aliases§

AlertSinkResult
Result type for alert sink operations.
AuthResult
Result type for authentication operations.
BoxFuture
Type-erased future for async operations.
PressureCallback
Callback type for memory pressure changes.
RateLimitResult
Result type for rate limiting operations.
RbacResult
Result type for RBAC evaluation.
Result
Result type alias for RingKernel operations.
SecretResult
Result type for secret store operations.
SharedMemoryPool
Shared memory pool that can be cloned.
SharedRateLimiter
Thread-safe, shareable rate limiter.
SharedStratifiedPool
Shared stratified memory pool.
TenantResult
Result type for tenant operations.

Attribute Macros§

gpu_kernel
Attribute macro for defining multi-backend GPU kernels.
ring_kernel
Attribute macro for defining ring kernel handlers.
stencil_kernel
Attribute macro for defining stencil kernels that transpile to CUDA.

Derive Macros§

ControlBlockState
Derive macro for implementing EmbeddedState trait.
GpuType
Derive macro for GPU-compatible types.
PersistentMessage
Derive macro for implementing the PersistentMessage trait.
RingMessage
Derive macro for implementing the RingMessage trait.