MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / platform_event

Function platform_event

crates/openshell-driver-docker/src/lib.rs:1615–1629  ·  view source on GitHub ↗
(
    source: &str,
    event_type: &str,
    reason: &str,
    message: String,
)

Source from the content-addressed store, hash-verified

1613}
1614
1615fn platform_event(
1616 source: &str,
1617 event_type: &str,
1618 reason: &str,
1619 message: String,
1620) -> DriverPlatformEvent {
1621 DriverPlatformEvent {
1622 timestamp_ms: openshell_core::time::now_ms(),
1623 source: source.to_string(),
1624 r#type: event_type.to_string(),
1625 reason: reason.to_string(),
1626 message,
1627 metadata: HashMap::new(),
1628 }
1629}
1630
1631fn docker_pull_progress_event(image: &str, info: &CreateImageInfo) -> Option<DriverPlatformEvent> {
1632 let status = info.status.as_deref().map(str::trim)?;

Callers 1

fail_pending_sandboxMethod · 0.70

Calls 1

now_msFunction · 0.85

Tested by

no test coverage detected