finchers

Crates.iofinchers
lib.rsfinchers
version0.13.5
sourcesrc
created_at2017-08-19 18:00:27.231342
updated_at2018-10-16 16:11:09.806574
descriptionA combinator library for builidng asynchronous HTTP services
homepagehttps://finchers-rs.github.io
repositoryhttps://github.com/finchers-rs/finchers.git
max_upload_size
id28136
size277,739
Yusuke Sasaki (ubnt-intrepid)

documentation

README

finchers

Crates.io Crates.io (Downloads) Docs.rs Master doc Rustc Version dependency status Gitter

finchers is a combinator library for building asynchronous HTTP services.

The concept and design was highly inspired by finch.

Features

  • Asynchronous handling powerd by futures and Tokio
  • Building an HTTP service by combining the primitive components
  • Type-safe routing without (unstable) procedural macros

Usage

Add this item to Cargo.toml in your project:

[dependencies]
finchers = "0.13.5"

Example

#[macro_use]
extern crate finchers;
use finchers::prelude::*;

fn main() {
    let endpoint = path!(@get / "greeting" / String)
        .map(|name: String| {
            format!("Hello, {}!\n", name)
        });

    finchers::server::start(endpoint)
        .serve("127.0.0.1:4000")
        .expect("failed to start the server");
}

Resources

Contributed Features

Status

Travis CI Appveyor CircleCI Codecov
Travis CI Appveyor CircleCI Codecov

License

This project is licensed under either of

at your option.

Commit count: 1286

cargo fmt