pub async fn combined_token_info(
    write_tokens: Vec<String>,
    ingester_connections: Vec<Connection>,
) -> Result<GetWriteInfoResponse, influxdb_iox_client::error::Error> {
    let responses = write_tokens
        .into_iter()
        .flat_map(|write_token| {
            ingester_connections
                .clone()
                .into_iter()
                .map(move |ingester_connection| {
                    token_info(write_token.clone(), ingester_connection)
                })
        })
        .collect::<FuturesUnordered<_>>()
        .collect::<Vec<_>>()
        .await
        // check for errors
        .into_iter()
        .collect::<Result<Vec<_>, _>>()?;

    info!("combining response: {:#?}", responses);

    // merge them together
    Ok(merge_responses(responses))
}
/// returns a combined write info that contains the combined
/// information across all ingester_connections for all the specified
/// tokens
returns a combined write info that contains the combined
information across all ingester_connections for all the specified
tokens
returns a combined write info that contains the combined information across all ingester_connections for all the specified tokens
pub async fn combined_token_info(
    write_tokens: Vec<String>,
    ingester_connections: Vec<Connection>,
) -> Result<GetWriteInfoResponse, influxdb_iox_client::error::Error> {
    let responses = write_tokens
        .into_iter()
        .flat_map(|write_token| {
            ingester_connections
                .clone()
                .into_iter()
                .map(move |ingester_connection| {
                    token_info(write_token.clone(), ingester_connection)
                })
        })
        .collect::<FuturesUnordered<_>>()
        .collect::<Vec<_>>()
        .await
        // check for errors
        .into_iter()
        .collect::<Result<Vec<_>, _>>()?;
    info!("combining response: {:#?}", responses);
    // merge them together
    Ok(merge_responses(responses))
}
pub async fn combined_token_info ( write_tokens : Vec < String > , ingester_connections : Vec < Connection > , ) -> Result < GetWriteInfoResponse , influxdb_iox_client :: error :: Error > { let responses = write_tokens . into_iter ( ) . flat_map ( | write_token | { ingester_connections . clone ( ) . into_iter ( ) . map ( move | ingester_connection | { token_info ( write_token . clone ( ) , ingester_connection ) } ) } ) . collect :: < FuturesUnordered < _ > > ( ) . collect :: < Vec < _ > > ( ) . await // check for errors . into_iter ( ) . collect :: < Result < Vec < _ > , _ > > ( ) ? ; info ! ( " " responses ) ; // merge them together Ok ( merge_responses ( responses ) ) }
returns a combined write info that contains the combined
information across all ingester_connections for all the specified
tokens
returns a combined write info that contains the combined information across all ingester_connections for all the specified tokens
write_tokens
Vec<String>
ingester_connections
Vec<Connection>
write_tokens
Vec<String>
ingester_connections
Vec<Connection>