HypervisorState (src/hypervisor_persist.rs)

kata-containers · src/runtime-rs/crates/hypervisor/src/hypervisor_persist.rs · rust · Apache-2.0
infra, tag:knn-classified

Rust struct representing hypervisor state with serialization support.

// Source: https://github.com/kata-containers/kata-containers | License: Apache-2.0 | Copyright You must retain, in the Source form of any Derivative Works
// Provided via justclaw.it.com; keep this notice with the code.
// Copyright (c) 2019-2022 Alibaba Cloud
// Copyright (c) 2019-2022 Ant Group
//
// SPDX-License-Identifier: Apache-2.0
//

use crate::HypervisorConfig;
use serde::{Deserialize, Serialize};
use std::collections::HashSet;
#[derive(Serialize, Deserialize, Default, Clone, Debug)]
pub struct HypervisorState {
    // Type of hypervisor, E.g. dragonball/qemu/firecracker.
    pub hypervisor_type: String,
    pub pid: Option<i32>,
    pub uuid: String,
    // clh sepcific: refer to 'virtcontainers/clh.go:CloudHypervisorState'
    pub api_socket: String,
    /// sandbox id
    pub 

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search for more like it.

Get a free API key