You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: recevier.rs
    path of file: ./repos/CYFS/src/component/cyfs-debug/src/http_target
    
    the code of the file until where you have to start completion: use super::reporter::{ReportLogItem, CYFS_LOG_SESSION};
use crate::CyfsLogRecord;
use cyfs_base::*;

use futures::future::{self, AbortHandle, Aborted};
use std::error::Error;
use std::future::Future;
use std::sync::{Arc, Mutex};

const CONTENT_TYPE: &str = "Content-Type";
const CONTENT_LENGTH: &str = "Content-Length";


#[derive(Debug)]
pub struct LogRecordMeta {
    // 上报的client的此次session
    session_id: u64,

    // 关注的header字段
    headers: Vec<(String, Option<String>)>,
}

impl LogRecordMeta {
    pub fn headers(&self) -> Vec<(String, Option<String>)>
    
    fn extract_sid<State>(req: &tide::Request<State>) -> BuckyResult<u64> {
        let v = req.header(CYFS_LOG_SESSION);
        if v.is_none() {
            let msg = format!("{} header not found!", CYFS_LOG_SESSION);
            error!("{}", msg);
            return Err(BuckyError::new(BuckyErrorCode::InvalidParam, msg));
        }

        let value = v.unwrap();
        let ret: u64 = value.last().as_str().parse().map_err(|e| {
            let msg = format!(
                "invalid session id header! {}, {}",
                value.last().as_str(),
                e
            );
            error!("{}", msg);
            BuckyError::new(BuckyErrorCode::InvalidParam, msg)
        })?;

        Ok(ret)
    }