pub fn serialize<S>(
    connection_info: &ConnectionInfo,
    serializer: S
) -> Result<S::Ok, S::Error> where
    S: Serializer