Crate moq_transfork

Source
Expand description

An fork of the MoQ Transport protocol.

MoQ Transfork is a pub/sub protocol over QUIC. While originally designed for live media, MoQ Transfork is generic and can be used for other live applications. The specification is a work in progress and will change. See the specification and github for any updates.

The core of this crate is Session, established with Session::connect (client) or Session::accept (server). Once you have a session, you can Session::publish or Session::subscribe.

§Producing

There can be only 1 publisher.

All methods are synchronous and will NOT block. If there are no subscribers, then no data will flow over the network but it will remain in cache. If the session is dropped, then any future writes will error.

§Consuming

There can be N consumers (via Clone), each getting a copy of any requested data.

All methods are asynchronous and will block until data is available. If the publisher disconnects, then the consumer will error. If the publisher is dropped (clean FIN), then the above methods will return None.

Re-exports§

pub use crate::message::GroupOrder;
pub use web_transport;

Modules§

coding
This module contains encoding and decoding helpers.
message
Low-level message sent over the wire, as defined in the specification.

Structs§

AnnouncedConsumer
Consumes announced tracks over the network matching an optional prefix.
AnnouncedProducer
Announces tracks to consumers over the network.
Frame
A frame of data with an upfront size.
FrameConsumer
Used to consume a frame’s worth of data in chunks.
FrameProducer
Used to write a frame’s worth of data in chunks.
Group
An independent group of frames.
GroupConsumer
Consume a group, frame-by-frame.
GroupProducer
Create a group, frame-by-frame.
Path
Router
Used to respond to arbitrary track requests.
RouterConsumer
Subscribe to abitrary broadcast/tracks.
RouterProducer
Receive broadcast/track requests and return if we can fulfill them.
RouterRequest
An outstanding request for a path.
Session
A MoqTransfork session, used to publish and/or subscribe to broadcasts.
Track
A track, a collection of indepedent groups (streams) with a specified order/priority.
TrackBuilder
Build a track with optional parameters.
TrackConsumer
A consumer for a track, used to read groups.
TrackProducer
A producer for a track, used to create new groups.

Enums§

Announced
The suffix of each announced track.
Error
A list of possible errors that can occur during the session.

Constants§

ALPN
The ALPN used when connecting via QUIC directly.

Type Aliases§

Result