23 releases (15 breaking)

0.16.0 Jan 17, 2024
0.15.0 Nov 21, 2023
0.14.0 Sep 28, 2023
0.13.0 May 24, 2023
0.3.0 Jul 5, 2021

#112 in Profiling

Download history 5082/week @ 2024-01-21 4274/week @ 2024-01-28 5259/week @ 2024-02-04 5996/week @ 2024-02-11 5716/week @ 2024-02-18 6858/week @ 2024-02-25 6520/week @ 2024-03-03 7812/week @ 2024-03-10 9023/week @ 2024-03-17 8932/week @ 2024-03-24 7002/week @ 2024-03-31 8048/week @ 2024-04-07 8793/week @ 2024-04-14 11819/week @ 2024-04-21 8879/week @ 2024-04-28 6671/week @ 2024-05-05

36,529 downloads per month
Used in 45 crates (6 directly)

MIT/Apache

125KB
2.5K SLoC

puffin_http

Embark Embark Crates.io Docs

A HTTP server/client for communicating puffin profiling events.

You can view them using puffin_viewer.

How to use

Add a puffin_http Server to the profiled application When the server is started, puffin_viewer application can connect to it and display profiling information.

fn main() {
    let server_addr = format!("0.0.0.0:{}", puffin_http::DEFAULT_PORT);
    let _puffin_server = puffin_http::Server::new(&server_addr).unwrap();
    eprintln!("Serving demo profile data on {server_addr}. Run `puffin_viewer` to view it.");
    puffin::set_scopes_on(true);

    //
}

You can checkout the examples/server.rs for a more complete example.

Dependencies

~1.8–7.5MB
~55K SLoC