brane_reg::check

Function check_data

Source
pub async fn check_data(
    name: String,
    body: CheckTransferRequest,
    context: Arc<Context>,
) -> Result<impl Reply, Rejection>
Expand description

Handles a GET that checks if a dataset is allowed to be downloaded.

§Arguments

  • name: The name of the dataset to check.
  • body: The body given with the request.
  • context: The context that carries options and some shared structures between the warp paths.

§Returns

The response that can be sent back to the client, effectively encoding the checker’s response.

§Errors

This function may error (i.e., reject) if we didn’t know the given name or we failed to serialize the relevant AssetInfo.