| Crates.io | http-longpoll |
| lib.rs | http-longpoll |
| version | 0.1.0-rc.2 |
| created_at | 2025-08-08 21:27:36.328284+00 |
| updated_at | 2025-09-03 10:10:19.49701+00 |
| description | Idiomatic stream + sink interface for http longpoll |
| homepage | |
| repository | https://github.com/ash30/http-longpoll |
| max_upload_size | |
| id | 1787352 |
| size | 46,599 |
HTTP Long Polling implementation with a simple idiomatic stream/sink API, making long polling as convenient as working with WebSockets.
use http_longpoll::{Session, Config};
let (handle, session) = Session::connect(Config::Default());
// simple echo
tokio::spawn(async move {
let (mut tx, rx) = session.split();
while let Some(message) = rx.next().await {
println!("Received: {:?}", message);
tx.send(message).await;
}
});
This project is under active development. While the core functionality is implemented, API changes may occur.