Commit Graph

531 Commits

Author SHA1 Message Date
Sean McArthur
996538e105 test(header): add tests for tm_from_str 2015-03-23 10:40:51 -07:00
Sean McArthur
5d93a3bd91 Merge tag 'v0.3.2' 2015-03-21 17:12:29 -07:00
Sean McArthur
025c410f78 Merge pull request #386 from pyfisch/sudofalse
chore(build): Enable building hyper in docker containers on travis
2015-03-21 13:12:59 -07:00
Pyfisch
8e3ad9e676 chore(build): Enable building hyper in docker containers on travis
By stating that hyper does not need sudo to build it can be compiled in
a container:
http://blog.travis-ci.com/2014-12-17-faster-builds-with-container-based-infrastructure/
2015-03-21 20:57:15 +01:00
Sean McArthur
4cb6d1ac16 Merge pull request #384 from Byron/master
fix(rustup): 1.0.0-nightly (e2fa53e59 2015-03-20)
2015-03-21 11:35:02 -07:00
Sebastian Thiel
f547080df5 fix(rustup): 1.0.0-nightly (e2fa53e59 2015-03-20)
* replace `char_at()` calls with itertor, as suggested by compiler
* fixed comparison in test
2015-03-21 17:02:13 +01:00
Sean McArthur
db3e8874fd v0.3.2 2015-03-20 17:33:18 -07:00
Sean McArthur
5d7be77e4a feat(server): use SocketAddrs instead of Ipv4Addrs 2015-03-20 17:32:51 -07:00
Sean McArthur
c205144eff Merge pull request #383 from Byron/master
fix(rustup): rustc 1.0.0-nightly (ea8b82e90)
2015-03-20 16:31:27 -07:00
Sebastian Thiel
104d49036f fix(benches): removed unused features
* 'io' and 'net'
2015-03-20 10:43:18 +01:00
Sebastian Thiel
8181de253a fix(rustup): rustc 1.0.0-nightly (ea8b82e90)
This commit fixes `cargo build` and `cargo test`.

Method lookup on traits seems to have changed to force
`impl TraitName` expressions to be more specific. That means that
`method` will not be found anymore on an object of type `&Trait+Send`,
unless you provide an `impl Trait+Send`.

Now `NetworkStream` and `HeaderFormat` trait implementations
are done against `* + Send`, which helps the compiler to find the
respective `downcast*` method implementations once again.
2015-03-20 10:28:35 +01:00
Adrian Heine
1f0bc951c9 fix(rustup): adapt to current rustc
Closes #381.
2015-03-19 09:44:40 +01:00
Sean McArthur
7469e62d1e v0.3.1 2015-03-18 11:05:08 -07:00
Sean McArthur
8c2bae7fc1 Merge pull request #377 from hyperium/check-continue
feat(server): add Expect 100-continue support
2015-03-16 18:13:00 -07:00
Sean McArthur
0b7169432b feat(server): add Expect 100-continue support
Adds a new method to `Handler`, with a default implementation of always
responding with a `100 Continue` when sent an expectation.

Closes #369
2015-03-16 15:59:44 -07:00
Sean McArthur
fe8c6d9914 Merge pull request #376 from hyperium/rustup
fix(rustup): update to latest rustc
2015-03-16 14:37:39 -07:00
Sean McArthur
4fd8a6a9dc fix(rustup): update to latest rustc 2015-03-16 12:01:38 -07:00
Sean McArthur
db8654a370 Merge pull request #375 from fuchsnj/master
fix(headers): Fix overflow with empty cookies
2015-03-15 20:56:01 -07:00
Nathan Fuchs
99baaa1015 fix(headers): Fix overflow with empty cookies 2015-03-15 23:51:08 -04:00
Jonathan Reem
932baac171 Merge pull request #371 from hyperium/cleanup
refactor(client): remove explicit Send implementations from Request/Resp...
2015-03-13 22:47:46 -07:00
Sean McArthur
d28bae3c91 refactor(client): remove explicit Send implementations from Request/Response 2015-03-13 19:54:34 -07:00
Sean McArthur
a2c6c4a25e Merge pull request #370 from hyperium/httparse
perf(http): changes http parsing to use httparse crate
2015-03-13 17:58:41 -07:00
Sean McArthur
b87bb20f0c perf(http): changes http parsing to use httparse crate
httparse is a http1 stateless push parser. This not only speeds up
parsing right now with sync io, but will also be useful for when we get
async io, since it's push based instead of pull.

BREAKING CHANGE: Several public functions and types in the `http` module
  have been removed. They have been replaced with 2 methods that handle
  all of the http1 parsing.
2015-03-13 16:56:13 -07:00
Sean McArthur
79200ed496 Merge pull request #360 from ctjhoa/master
docs(client): fix #357
2015-03-04 10:50:24 -08:00
Camille TJHOA
602c1e27fd docs(client): fix #357 2015-03-04 13:48:09 +01:00
Sean McArthur
d99a2006bd Merge pull request #359 from SBSTP/fix-charset-bug
fix(header): Fix charset parsing bug.
2015-03-03 23:38:34 -08:00
Simon Bernier St-Pierre
5a6e176f50 fix(header): Fix charset parsing bug. 2015-03-04 00:22:46 -05:00
Sean McArthur
003b6551cf v0.3.0 2015-03-03 21:09:45 -08:00
Sean McArthur
a9887c87f2 test(examples): fix warnings in examples 2015-03-03 21:05:52 -08:00
Sean McArthur
fdc78f8f89 Merge pull request #358 from hyperium/reparsing
feat(headers): adds re-parsing ability when getting typed headers
2015-03-03 20:47:47 -08:00
Hugo Duncan
180d9a92d9 feat(headers): add enum for Charset
Make Charset more strongly typed.
2015-03-03 20:46:41 -08:00
Hugo Duncan
235089a103 feat(headers): add AcceptCharset header
Adds support for the Accept-Charset header.  Encodes the charset as a
string.
2015-03-03 20:38:02 -08:00
Sean McArthur
2d83a79742 Merge pull request #356 from hyperium/q
feat(headers): add `q` function to ease creating Quality values
2015-03-03 19:52:11 -08:00
Sean McArthur
d68773c79f feat(headers): add q function to ease creating Quality values 2015-03-03 19:32:37 -08:00
Sean McArthur
df756871ed feat(headers): adds re-parsing ability when getting typed headers
BREAKING CHANGE: added requirement that all HeaderFormat implementations
  must also be fmt::Debug. This likely as easy as slapping
  #[derive(Debug)] on to any custom headers.
2015-03-03 18:51:29 -08:00
Sean McArthur
9e0770896b Merge pull request #354 from hyperium/new-io
feat(hyper): switch to std::io, std::net, and std::path.
2015-03-03 15:11:57 -08:00
Sean McArthur
0fd6fcd7c7 feat(hyper): switch to std::io, std::net, and std::path.
All instances of `old_io` and `old_path` were switched to use the new
shiny `std::io`, `std::net`, and `std::path` modules. This means that
`Request` and `Response` implement `Read` and `Write` now.

Because of the changes to `TcpListener`, this also takes the opportunity
to correct the method usage of `Server`. As with other
languages/frameworks, the server is first created with a handler, and
then a host/port is passed to a `listen` method. This reverses what
`Server` used to do.

Closes #347

BREAKING CHANGE: Check the docs. Everything was touched.
2015-03-03 14:32:03 -08:00
Sean McArthur
7235d3f74a Merge pull request #332 from pyfisch/improvquality
refactor(headers): Use u16 based newtype for quality value
2015-02-28 23:12:58 -05:00
Pyfisch
8f6ce453de refactor(headers): Use u16 based newtype for quality value
Using floating point numbers is problematic because comparison is inexact.
They also take more space than integral numbers in this case.

Add `FromPrimitve`, `ToPrimitive` and `Default` traits to quality newtype.

Closes: #330

BREAKING_CHANGE: Replace f32 quality values in quality items with a
Quality(u16) newtype. Valid values are from 0 to 1000.
2015-02-28 19:44:34 +01:00
Sean McArthur
b1b8bf1db7 v0.2.1 2015-02-27 06:01:44 -08:00
Sean McArthur
656552bf51 Merge pull request #340 from globin/rustup-4db0b3246-2015-02-25
Update to 4db0b3246 2015-02-25
2015-02-27 08:46:53 -05:00
Robin Gloster
1b6e6a040f fix(rustup): str.split and associated type changes 2015-02-27 13:33:21 +01:00
Jonathan Reem
9998417fe8 docs(README): Fix the example in the README. 2015-02-25 19:57:15 -08:00
Sean McArthur
3606f4aed8 Merge pull request #337 from AaronM04/master
Fixes compilation errors with latest rust
2015-02-25 22:06:17 -05:00
Aaron Miller
63910438c6 docs(client,server): fix compilation errors with latest Rust
Fix compilation errors relating to mutable borrowing the status
code from an immutably borrowed response. Also add the `extern crate
hyper` and appropriate `use` lines.
2015-02-25 13:29:18 -08:00
Jonathan Reem
0185afea91 Merge pull request #331 from filsmick/master
Add remove_raw method and corresponding test
2015-02-22 15:53:25 -08:00
filsmick (Yohaï Berreby)
4f576780c2 feat(headers): add remove_raw method and corresponding test
It was previously impossible to remove a header set by set_raw()

Closes #326
2015-02-22 16:16:39 +01:00
Sean McArthur
41fd8de243 v0.2.0 2015-02-21 15:15:09 -08:00
Sean McArthur
b985d85a5d Merge pull request #329 from hyperium/324
Rustup
2015-02-21 18:12:49 -05:00
Sean McArthur
4f5b97fefc fix(rustup): Send changes 2015-02-21 15:05:51 -08:00