pub async fn add_nodes_to_group(
infra: &InfraContext<'_>,
token: &str,
target_hsm_name: &str,
hosts_expression: &str,
) -> Result<(Vec<String>, Vec<String>), Error>Expand description
Resolve hosts_expression and add the resulting nodes to the
existing HSM group target_hsm_name.
The target group must already exist (an explicit NotFound is
returned rather than the backend’s opaque error). An empty
resolution is rejected with BadRequest. Returns the resolved
xnames alongside the group’s sorted, post-update membership.
§Errors
- [
Error::BadRequest] whenhosts_expressionis invalid, resolves to an empty set, or names xnames the caller cannot reach. - [
Error::NotFound] whentarget_hsm_namedoes not exist. - [
Error::NetError] / [Error::CsmError] fromadd_members_to_group.