pub fn get_value(map: &MetadataMap, key: &str) -> Option<String>
Expand description

Retrieve the string value from a request’s metadata map by its key.

Example

let tenant = get_value(request.metadata(), "tenant")
    .expect("Missing tenant info on request metadata");