fn remove_instance_by_attrs(instances: Arc<Mutex<Vec<Instance>>>,
                                instance: Instance) {
        let mut instances = instances.lock().unwrap();
        instances.retain(|ref x| **x != instance);
    }
/// Helper function to remote a host by attrs
///
/// We do this because we cannot garuntee the position of the host (as
/// other hosts will have been removed/added since) in disable_instance
Helper function to remote a host by attrs
We do this because we cannot garuntee the position of the host (as
other hosts will have been removed/added since) in disable_instance
Helper function to remote a host by attrs We do this because we cannot garuntee the position of the host ( as other hosts will have been removed / added since ) in disable_instance
fn remove_instance_by_attrs(instances: Arc<Mutex<Vec<Instance>>>,
                                instance: Instance) {
        let mut instances = instances.lock().unwrap();
        instances.retain(|ref x| **x != instance);
    }
fn remove_instance_by_attrs ( instances : Arc < Mutex < Vec < Instance > > > , instance : Instance ) { let mut instances = instances . lock ( ) . unwrap ( ) ; instances . retain ( | ref x | * * x != instance ) ; }
Helper function to remote a host by attrs
We do this because we cannot garuntee the position of the host (as
other hosts will have been removed/added since) in disable_instance
Helper function to remote a host by attrs We do this because we cannot garuntee the position of the host ( as other hosts will have been removed / added since ) in disable_instance
instances
Arc<Mutex<Vec<Instance>>>
instance
Instance
instances
Arc<Mutex<Vec<Instance>>>
instance
Instance