pub async fn update_status<T: serde::Serialize>(
    client: kube::Client,
    ns: &str,
    pod_name: &str,
    data: &T,
) -> anyhow::Result<()> {
    let data = serde_json::to_vec(data)?;
    let pod_client: Api<Pod> = Api::namespaced(client, ns);
    if let Err(e) = pod_client
        .patch_status(pod_name, &PatchParams::default(), data)
        .await
    {
        return Err(e.into());
    }
    Ok(())
}
/// A helper for updating pod status. The given data should be a pod status object and be
/// serializable by serde
A helper for updating pod status. The given data should be a pod status object and be
serializable by serde
A helper for updating pod status . The given data should be a pod status object and be serializable by serde
pub async fn update_status<T: serde::Serialize>(
    client: kube::Client,
    ns: &str,
    pod_name: &str,
    data: &T,
) -> anyhow::Result<()> {
    let data = serde_json::to_vec(data)?;
    let pod_client: Api<Pod> = Api::namespaced(client, ns);
    if let Err(e) = pod_client
        .patch_status(pod_name, &PatchParams::default(), data)
        .await
    {
        return Err(e.into());
    }
    Ok(())
}
pub async fn update_status < T : serde :: Serialize > ( client : kube :: Client , ns : & str , pod_name : & str , data : & T , ) -> anyhow :: Result < ( ) > { let data = serde_json :: to_vec ( data ) ? ; let pod_client : Api < Pod > = Api :: namespaced ( client , ns ) ; if let Err ( e ) = pod_client . patch_status ( pod_name , & PatchParams :: default ( ) , data ) . await { return Err ( e . into ( ) ) ; } Ok ( ( ) ) }
A helper for updating pod status.
A helper for updating pod status .
client
kube::Client
ns
&str
pod_name
&str
data
&T
client
kube::Client
ns
&str
pod_name
&str
data
&T