net: use connection pooling

This commit is contained in:
Sean McArthur 2015-08-05 10:46:13 -07:00 committed by Josh Matthews
parent b7c88dd547
commit a1a9db8ffd
10 changed files with 185 additions and 133 deletions

View file

@ -42,4 +42,3 @@ regex_macros = "0.1.8"
flate2 = "0.2.0"
uuid = "0.1.16"
euclid = "0.1"

View file

@ -8,14 +8,15 @@ use file_loader;
use flate2::read::{DeflateDecoder, GzDecoder};
use hsts::secure_url;
use hyper::Error as HttpError;
use hyper::client::{Request, Response};
use hyper::client::{Request, Response, Pool};
use hyper::error::Result as HttpResult;
use hyper::header::{AcceptEncoding, Accept, ContentLength, ContentType, Host};
use hyper::header::{Location, qitem, StrictTransportSecurity};
use hyper::header::{Quality, QualityItem, Headers, ContentEncoding, Encoding};
use hyper::http::RawStatus;
use hyper::method::Method;
use hyper::mime::{Mime, TopLevel, SubLevel};
use hyper::net::{Fresh, HttpsConnector, Openssl};
use hyper::net::{Fresh, HttpsConnector, HttpStream, Ssl, Openssl};
use hyper::status::{StatusCode, StatusClass};
use ipc_channel::ipc::{self, IpcSender};
use log;
@ -23,6 +24,7 @@ use mime_classifier::MIMEClassifier;
use net_traits::ProgressMsg::{Payload, Done};
use net_traits::hosts::replace_hosts;
use net_traits::{ControlMsg, CookieSource, LoadData, Metadata, LoadConsumer, IncludeSubdomains};
use openssl::ssl::SslStream as OpensslStream;
use openssl::ssl::{SslContext, SslMethod, SSL_VERIFY_PEER};
use resource_task::{start_sending_opt, start_sending_sniffed_opt};
use std::borrow::ToOwned;
@ -37,12 +39,49 @@ use util::resource_files::resources_dir_path;
use util::task::spawn_named;
use uuid;
pub type Connector = HttpsConnector<SslProvider>;
pub enum SslProvider {
None,
Openssl(Openssl)
}
impl Ssl for SslProvider {
type Stream = OpensslStream<HttpStream>;
fn wrap_client(&self, stream: HttpStream, host: &str) -> HttpResult<Self::Stream> {
match *self {
SslProvider::None => Err(HttpError::Ssl("ssl disabled".into())),
SslProvider::Openssl(ref s) => s.wrap_client(stream, host)
}
}
fn wrap_server(&self, _: HttpStream) -> HttpResult<Self::Stream> {
unimplemented!()
}
}
pub fn create_http_connector() -> Arc<Pool<Connector>> {
let mut context = SslContext::new(SslMethod::Sslv23).unwrap();
context.set_verify(SSL_VERIFY_PEER, None);
context.set_CA_file(&resources_dir_path().join("certs")).unwrap();
let connector = HttpsConnector::new(SslProvider::Openssl(Openssl {
context: Arc::new(context)
}));
Arc::new(Pool::with_connector(Default::default(), connector))
}
pub fn factory(resource_mgr_chan: IpcSender<ControlMsg>,
devtools_chan: Option<Sender<DevtoolsControlMsg>>)
devtools_chan: Option<Sender<DevtoolsControlMsg>>,
connector: Arc<Pool<Connector>>)
-> Box<FnBox(LoadData, LoadConsumer, Arc<MIMEClassifier>) + Send> {
box move |load_data: LoadData, senders, classifier| {
spawn_named(format!("http_loader for {}", load_data.url.serialize()),
move || load_for_consumer(load_data, senders, classifier, resource_mgr_chan, devtools_chan))
spawn_named(format!("http_loader for {}", load_data.url.serialize()), move || {
load_for_consumer(load_data, senders, classifier, connector, resource_mgr_chan, devtools_chan)
})
}
}
@ -82,10 +121,14 @@ fn inner_url(url: &Url) -> Url {
fn load_for_consumer(load_data: LoadData,
start_chan: LoadConsumer,
classifier: Arc<MIMEClassifier>,
connector: Arc<Pool<Connector>>,
resource_mgr_chan: IpcSender<ControlMsg>,
devtools_chan: Option<Sender<DevtoolsControlMsg>>) {
match load::<WrappedHttpRequest>(load_data, resource_mgr_chan, devtools_chan, &NetworkHttpRequestFactory) {
let factory = NetworkHttpRequestFactory {
connector: connector,
};
match load::<WrappedHttpRequest>(load_data, resource_mgr_chan, devtools_chan, &factory) {
Err(LoadError::UnsupportedScheme(url)) => {
let s = format!("{} request, but we don't support that scheme", &*url.scheme);
send_error(url, s, start_chan)
@ -111,6 +154,7 @@ fn load_for_consumer(load_data: LoadData,
file_loader::factory(load_data, start_chan, classifier)
}
Err(LoadError::ConnectionAborted(_)) => unreachable!(),
Ok(mut load_response) => {
let metadata = load_response.metadata.clone();
send_data(&mut load_response, start_chan, metadata, classifier)
@ -172,18 +216,15 @@ pub trait HttpRequestFactory {
fn create(&self, url: Url, method: Method) -> Result<Self::R, LoadError>;
}
struct NetworkHttpRequestFactory;
struct NetworkHttpRequestFactory {
connector: Arc<Pool<Connector>>,
}
impl HttpRequestFactory for NetworkHttpRequestFactory {
type R = WrappedHttpRequest;
fn create(&self, url: Url, method: Method) -> Result<WrappedHttpRequest, LoadError> {
let mut context = SslContext::new(SslMethod::Sslv23).unwrap();
context.set_verify(SSL_VERIFY_PEER, None);
context.set_CA_file(&resources_dir_path().join("certs")).unwrap();
let connector = HttpsConnector::new(Openssl { context: Arc::new(context) });
let connection = Request::with_connector(method, url.clone(), &connector);
let connection = Request::with_connector(method, url.clone(), &*self.connector);
let ssl_err_string = "Some(OpenSslErrors([UnknownError { library: \"SSL routines\", \
function: \"SSL3_GET_SERVER_CERTIFICATE\", \
@ -253,6 +294,9 @@ impl HttpRequest for WrappedHttpRequest {
let response = match request_writer.send() {
Ok(w) => w,
Err(HttpError::Io(ref io_error)) if io_error.kind() == io::ErrorKind::ConnectionAborted => {
return Err(LoadError::ConnectionAborted(io_error.description().to_string()));
},
Err(e) => return Err(LoadError::Connection(url, e.description().to_string()))
};
@ -268,7 +312,8 @@ pub enum LoadError {
Ssl(Url, String),
InvalidRedirect(Url, String),
Decoding(Url, String),
MaxRedirects(Url)
MaxRedirects(Url),
ConnectionAborted(String),
}
fn set_default_accept_encoding(headers: &mut Headers) {
@ -428,11 +473,12 @@ fn send_response_to_devtools(devtools_chan: Option<Sender<DevtoolsControlMsg>>,
chan.send(DevtoolsControlMsg::FromChrome(msg)).unwrap();
}
}
pub fn load<A>(load_data: LoadData,
resource_mgr_chan: IpcSender<ControlMsg>,
devtools_chan: Option<Sender<DevtoolsControlMsg>>,
request_factory: &HttpRequestFactory<R=A>)
-> Result<StreamedResponse<A::R>, LoadError> where A: HttpRequest + 'static {
resource_mgr_chan: IpcSender<ControlMsg>,
devtools_chan: Option<Sender<DevtoolsControlMsg>>,
request_factory: &HttpRequestFactory<R=A>)
-> Result<StreamedResponse<A::R>, LoadError> where A: HttpRequest + 'static {
// FIXME: At the time of writing this FIXME, servo didn't have any central
// location for configuration. If you're reading this and such a
// repository DOES exist, please update this constant to use it.
@ -499,53 +545,74 @@ pub fn load<A>(load_data: LoadData,
set_default_accept_encoding(&mut request_headers);
set_request_cookies(doc_url.clone(), &mut request_headers, &resource_mgr_chan);
let mut req = try!(request_factory.create(url.clone(), method.clone()));
*req.headers_mut() = request_headers;
if log_enabled!(log::LogLevel::Info) {
info!("{}", method);
for header in req.headers_mut().iter() {
info!(" - {}", header);
}
info!("{:?}", load_data.data);
}
// Avoid automatically sending request body if a redirect has occurred.
//
// TODO - This is the wrong behaviour according to the RFC. However, I'm not
// sure how much "correctness" vs. real-world is important in this case.
//
// https://tools.ietf.org/html/rfc7231#section-6.4
let is_redirected_request = iters != 1;
let request_id = uuid::Uuid::new_v4().to_simple_string();
let response = match load_data.data {
Some(ref data) if !is_redirected_request => {
req.headers_mut().set(ContentLength(data.len() as u64));
// TODO: Do this only if load_data has some pipeline_id, and send the pipeline_id
// in the message
send_request_to_devtools(
devtools_chan.clone(), request_id.clone(), url.clone(),
method.clone(), load_data.headers.clone(),
load_data.data.clone()
);
let response;
try!(req.send(&load_data.data))
}
_ => {
if load_data.method != Method::Get && load_data.method != Method::Head {
req.headers_mut().set(ContentLength(0))
// loop trying connections in connection pool
// they may have grown stale (disconnected), in which case we'll get
// a ConnectionAborted error. this loop tries again with a new
// connection.
loop {
let mut req = try!(request_factory.create(url.clone(), method.clone()));
*req.headers_mut() = request_headers.clone();
if log_enabled!(log::LogLevel::Info) {
info!("{}", method);
for header in req.headers_mut().iter() {
info!(" - {}", header);
}
send_request_to_devtools(
devtools_chan.clone(), request_id.clone(), url.clone(),
method.clone(), load_data.headers.clone(),
None
);
try!(req.send(&None))
info!("{:?}", load_data.data);
}
};
// Avoid automatically sending request body if a redirect has occurred.
//
// TODO - This is the wrong behaviour according to the RFC. However, I'm not
// sure how much "correctness" vs. real-world is important in this case.
//
// https://tools.ietf.org/html/rfc7231#section-6.4
let is_redirected_request = iters != 1;
let maybe_response = match load_data.data {
Some(ref data) if !is_redirected_request => {
req.headers_mut().set(ContentLength(data.len() as u64));
// TODO: Do this only if load_data has some pipeline_id, and send the pipeline_id
// in the message
send_request_to_devtools(
devtools_chan.clone(), request_id.clone(), url.clone(),
method.clone(), load_data.headers.clone(),
load_data.data.clone()
);
req.send(&load_data.data)
}
_ => {
if load_data.method != Method::Get && load_data.method != Method::Head {
req.headers_mut().set(ContentLength(0))
}
send_request_to_devtools(
devtools_chan.clone(), request_id.clone(), url.clone(),
method.clone(), load_data.headers.clone(),
None
);
req.send(&None)
}
};
response = match maybe_response {
Ok(r) => r,
Err(LoadError::ConnectionAborted(reason)) => {
debug!("connection aborted ({:?}), possibly stale, trying new connection", reason);
continue;
}
Err(e) => return Err(e),
};
// if no ConnectionAborted, break the loop
break;
}
info!("got HTTP response {}, headers:", response.status());
if log_enabled!(log::LogLevel::Info) {

View file

@ -9,7 +9,7 @@ use cookie;
use cookie_storage::CookieStorage;
use data_loader;
use file_loader;
use http_loader;
use http_loader::{self, create_http_connector, Connector};
use mime_classifier::MIMEClassifier;
use net_traits::ProgressMsg::Done;
@ -22,6 +22,7 @@ use util::task::spawn_named;
use hsts::{HSTSList, HSTSEntry, preload_hsts_domains};
use devtools_traits::{DevtoolsControlMsg};
use hyper::client::pool::Pool;
use hyper::header::{ContentType, Header, SetCookie, UserAgent};
use hyper::mime::{Mime, TopLevel, SubLevel};
use ipc_channel::ipc::{self, IpcReceiver, IpcSender};
@ -191,7 +192,8 @@ pub struct ResourceManager {
resource_task: IpcSender<ControlMsg>,
mime_classifier: Arc<MIMEClassifier>,
devtools_chan: Option<Sender<DevtoolsControlMsg>>,
hsts_list: HSTSList
hsts_list: HSTSList,
connector: Arc<Pool<Connector>>,
}
impl ResourceManager {
@ -205,7 +207,8 @@ impl ResourceManager {
resource_task: resource_task,
mime_classifier: Arc::new(MIMEClassifier::new()),
devtools_chan: devtools_channel,
hsts_list: hsts_list
hsts_list: hsts_list,
connector: create_http_connector(),
}
}
}
@ -243,7 +246,9 @@ impl ResourceManager {
let loader = match &*load_data.url.scheme {
"file" => from_factory(file_loader::factory),
"http" | "https" | "view-source" =>
http_loader::factory(self.resource_task.clone(), self.devtools_chan.clone()),
http_loader::factory(self.resource_task.clone(),
self.devtools_chan.clone(),
self.connector.clone()),
"data" => from_factory(data_loader::factory),
"about" => from_factory(about_loader::factory),
_ => {

View file

@ -78,7 +78,7 @@ time = "0.1.12"
bitflags = "0.3"
rustc-serialize = "0.3"
libc = "0.1"
unicase = "0.1"
unicase = "1.0"
num = "0.1.24"
websocket = "0.12.0"
uuid = "0.1.16"

View file

@ -315,7 +315,7 @@ name = "devtools"
version = "0.0.1"
dependencies = [
"devtools_traits 0.0.1",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"log 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
"msg 0.0.1",
@ -332,7 +332,7 @@ name = "devtools_traits"
version = "0.0.1"
dependencies = [
"bitflags 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"msg 0.0.1",
"plugins 0.0.1",
@ -780,7 +780,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "hyper"
version = "0.6.8"
version = "0.6.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"cookie 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
@ -796,7 +796,7 @@ dependencies = [
"time 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)",
"traitobject 0.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"typeable 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"url 0.2.37 (registry+https://github.com/rust-lang/crates.io-index)",
]
@ -1025,7 +1025,7 @@ dependencies = [
"canvas_traits 0.0.1",
"core-foundation 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"io-surface 0.1.0 (git+https://github.com/servo/io-surface-rs)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"layers 0.1.0 (git+https://github.com/servo/rust-layers)",
@ -1048,7 +1048,7 @@ dependencies = [
"devtools_traits 0.0.1",
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"flate2 0.2.7 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"log 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
"net_traits 0.0.1",
@ -1069,7 +1069,7 @@ version = "0.0.1"
dependencies = [
"cookie 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
"flate2 0.2.7 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"net 0.0.1",
"net_traits 0.0.1",
@ -1083,7 +1083,7 @@ name = "net_traits"
version = "0.0.1"
dependencies = [
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"log 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
"msg 0.0.1",
@ -1375,7 +1375,7 @@ dependencies = [
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"js 0.1.0 (git+https://github.com/servo/rust-mozjs)",
"libc 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1397,7 +1397,7 @@ dependencies = [
"style 0.0.1",
"tendril 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
"time 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"url 0.2.37 (registry+https://github.com/rust-lang/crates.io-index)",
"util 0.0.1",
"uuid 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1669,7 +1669,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "unicase"
version = "0.1.0"
version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
@ -1718,7 +1718,7 @@ dependencies = [
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"getopts 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"js 0.1.0 (git+https://github.com/servo/rust-mozjs)",
"layers 0.1.0 (git+https://github.com/servo/rust-layers)",
@ -1800,7 +1800,7 @@ name = "webdriver"
version = "0.2.3"
source = "git+https://github.com/jgraham/webdriver-rust.git#80b3fdf3f7412066268e00df25087200cbb47cca"
dependencies = [
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
"regex 0.1.41 (registry+https://github.com/rust-lang/crates.io-index)",
"rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1829,11 +1829,11 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"bitflags 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"byteorder 0.3.11 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"openssl 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
"rand 0.3.11 (registry+https://github.com/rust-lang/crates.io-index)",
"rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"url 0.2.37 (registry+https://github.com/rust-lang/crates.io-index)",
]

28
ports/cef/Cargo.lock generated
View file

@ -307,7 +307,7 @@ name = "devtools"
version = "0.0.1"
dependencies = [
"devtools_traits 0.0.1",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"log 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
"msg 0.0.1",
@ -324,7 +324,7 @@ name = "devtools_traits"
version = "0.0.1"
dependencies = [
"bitflags 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"msg 0.0.1",
"plugins 0.0.1",
@ -765,7 +765,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "hyper"
version = "0.6.8"
version = "0.6.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"cookie 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
@ -781,7 +781,7 @@ dependencies = [
"time 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)",
"traitobject 0.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"typeable 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"url 0.2.37 (registry+https://github.com/rust-lang/crates.io-index)",
]
@ -1010,7 +1010,7 @@ dependencies = [
"canvas_traits 0.0.1",
"core-foundation 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"io-surface 0.1.0 (git+https://github.com/servo/io-surface-rs)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"layers 0.1.0 (git+https://github.com/servo/rust-layers)",
@ -1033,7 +1033,7 @@ dependencies = [
"devtools_traits 0.0.1",
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"flate2 0.2.7 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"log 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
"net_traits 0.0.1",
@ -1053,7 +1053,7 @@ name = "net_traits"
version = "0.0.1"
dependencies = [
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"log 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
"msg 0.0.1",
@ -1345,7 +1345,7 @@ dependencies = [
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"js 0.1.0 (git+https://github.com/servo/rust-mozjs)",
"libc 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1367,7 +1367,7 @@ dependencies = [
"style 0.0.1",
"tendril 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
"time 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"url 0.2.37 (registry+https://github.com/rust-lang/crates.io-index)",
"util 0.0.1",
"uuid 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1650,7 +1650,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "unicase"
version = "0.1.0"
version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
@ -1699,7 +1699,7 @@ dependencies = [
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"getopts 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"js 0.1.0 (git+https://github.com/servo/rust-mozjs)",
"layers 0.1.0 (git+https://github.com/servo/rust-layers)",
@ -1771,7 +1771,7 @@ name = "webdriver"
version = "0.2.3"
source = "git+https://github.com/jgraham/webdriver-rust.git#80b3fdf3f7412066268e00df25087200cbb47cca"
dependencies = [
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
"regex 0.1.41 (registry+https://github.com/rust-lang/crates.io-index)",
"rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1800,11 +1800,11 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"bitflags 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"byteorder 0.3.11 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"openssl 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
"rand 0.3.11 (registry+https://github.com/rust-lang/crates.io-index)",
"rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"url 0.2.37 (registry+https://github.com/rust-lang/crates.io-index)",
]

26
ports/gonk/Cargo.lock generated
View file

@ -277,7 +277,7 @@ name = "devtools"
version = "0.0.1"
dependencies = [
"devtools_traits 0.0.1",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"log 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
"msg 0.0.1",
@ -294,7 +294,7 @@ name = "devtools_traits"
version = "0.0.1"
dependencies = [
"bitflags 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"msg 0.0.1",
"plugins 0.0.1",
@ -649,7 +649,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "hyper"
version = "0.6.8"
version = "0.6.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"cookie 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)",
@ -665,7 +665,7 @@ dependencies = [
"time 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)",
"traitobject 0.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"typeable 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"url 0.2.37 (registry+https://github.com/rust-lang/crates.io-index)",
]
@ -885,7 +885,7 @@ dependencies = [
"canvas_traits 0.0.1",
"core-foundation 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"io-surface 0.1.0 (git+https://github.com/servo/io-surface-rs)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"layers 0.1.0 (git+https://github.com/servo/rust-layers)",
@ -908,7 +908,7 @@ dependencies = [
"devtools_traits 0.0.1",
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"flate2 0.2.7 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"log 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
"net_traits 0.0.1",
@ -928,7 +928,7 @@ name = "net_traits"
version = "0.0.1"
dependencies = [
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"log 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
"msg 0.0.1",
@ -1211,7 +1211,7 @@ dependencies = [
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"fnv 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"js 0.1.0 (git+https://github.com/servo/rust-mozjs)",
"libc 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1233,7 +1233,7 @@ dependencies = [
"style 0.0.1",
"tendril 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
"time 0.1.32 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"url 0.2.37 (registry+https://github.com/rust-lang/crates.io-index)",
"util 0.0.1",
"uuid 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1485,7 +1485,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "unicase"
version = "0.1.0"
version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
@ -1534,7 +1534,7 @@ dependencies = [
"euclid 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
"getopts 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)",
"js 0.1.0 (git+https://github.com/servo/rust-mozjs)",
"layers 0.1.0 (git+https://github.com/servo/rust-layers)",
@ -1575,11 +1575,11 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"bitflags 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"byteorder 0.3.11 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)",
"openssl 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
"rand 0.3.11 (registry+https://github.com/rust-lang/crates.io-index)",
"rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"unicase 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"url 0.2.37 (registry+https://github.com/rust-lang/crates.io-index)",
]

View file

@ -1,5 +0,0 @@
[response-method.htm]
type: testharness
[HEAD]
expected: FAIL

View file

@ -1,27 +1,8 @@
[status-async.htm]
type: testharness
expected: TIMEOUT
[XMLHttpRequest: status/statusText - various responses 5 (HEAD 401)]
expected: TIMEOUT
[XMLHttpRequest: status/statusText - various responses 7 (GET 402)]
expected: FAIL
[XMLHttpRequest: status/statusText - various responses 8 (HEAD 402)]
expected: TIMEOUT
[XMLHttpRequest: status/statusText - various responses 9 (CHICKEN 402)]
expected: FAIL
[XMLHttpRequest: status/statusText - various responses 11 (HEAD 402)]
expected: TIMEOUT
[XMLHttpRequest: status/statusText - various responses 20 (HEAD 502)]
expected: TIMEOUT
[XMLHttpRequest: status/statusText - various responses 23 (HEAD 503)]
expected: TIMEOUT
[XMLHttpRequest: status/statusText - various responses 26 (HEAD 699)]
expected: TIMEOUT

View file

@ -1,3 +1,8 @@
[status-basic.htm]
type: testharness
expected: TIMEOUT
[XMLHttpRequest: status/statusText - various responses 7 (GET 402)]
expected: FAIL
[XMLHttpRequest: status/statusText - various responses 9 (CHICKEN 402)]
expected: FAIL