1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
//! # polyoxide-ws
//!
//! The WebSocket kit the polyoxide socket clients share. Each block here was
//! carried as a copy by every socket crate (clob, perps, Binance, rtds and
//! sports); this crate holds the one copy, and each venue keeps only what is
//! its own.
//!
//! - [`ensure_crypto_provider`] installs the process-default rustls provider
//! a `tokio-tungstenite` connect needs.
//! - [`Backoff`] is the reconnect delay schedule.
//! - [`Timing`] holds a supervised connection's ping, staleness, backoff,
//! connect and rotation timings, [`timing_setters!`] gives a builder its
//! setters, and [`next_wait`] is the wait until the first deadline.
//! - [`WsError`] is the one socket error, read through its [`Kind`].
//! `polyoxide_venue::impl_ws_classification!` classifies it in the venue
//! crate that wraps it.
//! - [`connect`] opens a connection within a timeout, [`connect_over`]
//! upgrades a TCP connection a venue opened itself, [`with_timeout`] bounds
//! a venue's own connect, and [`retrying_can_fix`] says whether a
//! reconnect can help after one failed.
//! - [`Connection`] is the bare tier: one connection as a `Stream` of its
//! frames in a [`Mode`], with the server's close captured, and requests
//! correlated with their answers through [`Correlated`].
//! - [`Supervisor`] runs one supervised connection for a venue's
//! [`Protocol`]: pings on the wall clock, staleness, reconnect with backoff
//! and a replay of the membership, rotation, outage markers, and membership
//! changes through a [`MembershipHandle`], yielding a [`Supervised`] stream.
//!
//! [`tungstenite`] is re-exported, so a venue names `Message` and
//! `CloseFrame` through this crate rather than depending on it.
//!
//! Behind the `test-server` feature, the doc-hidden `test_server` module holds
//! the scripted local server and the helpers the offline suites share. It is
//! for tests, not consumers.
//!
//! The crate depends on neither `polyoxide-core` nor `polyoxide-venue`, and
//! builds no HTTP or signing stack, so a credential-free feed built on it
//! stays light (AD-2). It logs under the `polyoxide_ws` target and never
//! installs a subscriber.
;
pub use ;
pub use ;
pub use ;
pub use ;
pub use Correlated;
pub use ;
pub use ;
pub use ensure_crypto_provider;
/// The WebSocket library the kit is built on, re-exported so a venue names
/// its types (`Message`, `CloseFrame`, `http`) through this crate.
pub use tungstenite;