Documentation
¶
Index ¶
- func DeregisterIngressRpcHandlers(server rpc.IngressHandlerServer, info *livekit.IngressInfo)
- func DeserializeMediaForRelay(r io.Reader) ([]byte, time.Duration, error)
- func RegisterIngressRpcHandlers(server rpc.IngressHandlerServer, info *livekit.IngressInfo) error
- func SerializeMediaForRelay(w io.Writer, data []byte, ts time.Duration) error
- type BlockingQueue
- type HandlerLogger
- type OutputSynchronizer
- type PrerollBuffer
- type StateNotifier
- type TrackOutputSynchronizer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DeregisterIngressRpcHandlers ¶ added in v1.5.0
func DeregisterIngressRpcHandlers(server rpc.IngressHandlerServer, info *livekit.IngressInfo)
func RegisterIngressRpcHandlers ¶ added in v1.5.0
func RegisterIngressRpcHandlers(server rpc.IngressHandlerServer, info *livekit.IngressInfo) error
Types ¶
type BlockingQueue ¶ added in v1.5.0
type BlockingQueue[T any] struct { // contains filtered or unexported fields }
func NewBlockingQueue ¶ added in v1.5.0
func NewBlockingQueue[T any](capacity int) *BlockingQueue[T]
func (*BlockingQueue[T]) Close ¶ added in v1.5.0
func (b *BlockingQueue[T]) Close()
func (*BlockingQueue[T]) PopFront ¶ added in v1.5.0
func (b *BlockingQueue[T]) PopFront() (T, error)
func (*BlockingQueue[T]) PushBack ¶ added in v1.5.0
func (b *BlockingQueue[T]) PushBack(item T)
func (*BlockingQueue[T]) QueueLength ¶ added in v1.5.0
func (b *BlockingQueue[T]) QueueLength() int
type HandlerLogger ¶ added in v1.6.0
type HandlerLogger struct {
// contains filtered or unexported fields
}
HandlerLogger routes the handler process output line by line. A line split across Write calls is held until its newline arrives or Close is called.
func NewHandlerLogger ¶ added in v1.5.0
func NewHandlerLogger(resourceID, ingressID string) *HandlerLogger
func NewHandlerLoggerWithSink ¶ added in v1.6.0
func NewHandlerLoggerWithSink(resourceID, ingressID string, sink func(line []byte)) *HandlerLogger
NewHandlerLoggerWithSink sends the handler's own structured lines to sink. A nil sink writes them to stdout. line is only valid until sink returns.
func (*HandlerLogger) Close ¶ added in v1.6.0
func (h *HandlerLogger) Close() error
Close processes any trailing line that has no newline.
type OutputSynchronizer ¶ added in v1.2.0
type OutputSynchronizer struct {
// contains filtered or unexported fields
}
func NewOutputSynchronizer ¶ added in v1.2.0
func NewOutputSynchronizer() *OutputSynchronizer
func (*OutputSynchronizer) AddTrack ¶ added in v1.2.0
func (os *OutputSynchronizer) AddTrack() *TrackOutputSynchronizer
func (*OutputSynchronizer) ScheduleEvent ¶ added in v1.5.0
func (os *OutputSynchronizer) ScheduleEvent(ctx context.Context, pts time.Duration, event func()) error
ScheduleEvent TODO adjust timer deadline when zeroTime is adjusted
type PrerollBuffer ¶
type PrerollBuffer struct {
// contains filtered or unexported fields
}
func NewPrerollBuffer ¶
func NewPrerollBuffer(onBufferReset func() error) *PrerollBuffer
func (*PrerollBuffer) Close ¶
func (pb *PrerollBuffer) Close() error
func (*PrerollBuffer) SetWriter ¶
func (pb *PrerollBuffer) SetWriter(w io.WriteCloser) error
type StateNotifier ¶ added in v1.5.0
type StateNotifier interface {
// IngressCreated announces a URL pull session whose ingress was just
// created with its first state, as that state's update would.
IngressCreated(ctx context.Context, projectID string, info *livekit.IngressInfo) error
UpdateIngressState(ctx context.Context, projectID string, info *livekit.IngressInfo) error
// SessionStarted reports that a session is running. It does not mark the
// first the notifier hears of one: a session is announced by IngressCreated
// or its first state update, which carry ENDPOINT_BUFFERING and are sent
// before this call on every path. What this marks is the point from which the session
// is live, so anything an implementation meters belongs between here and
// SessionEnded rather than from whenever an update first arrived.
SessionStarted(ctx context.Context, projectID string, info *livekit.IngressInfo)
// SessionEnded reports that a session is over and that nothing more will be
// reported for it. It is called wherever a session stops running, whether
// it ended, failed to start, or had its handler killed, so an
// implementation can release whatever it holds without waiting for a
// terminal update that may never arrive.
SessionEnded(ctx context.Context, resourceID string)
}
func NewHandlerStateNotifier ¶ added in v1.5.0
func NewHandlerStateNotifier(ipcClient ipc.IngressServiceClient) StateNotifier
func NewNoopStateNotifier ¶ added in v1.5.0
func NewNoopStateNotifier() StateNotifier
func NewServiceStateNotifier ¶ added in v1.5.0
func NewServiceStateNotifier(psrpcClient rpc.IOInfoClient) StateNotifier
type TrackOutputSynchronizer ¶ added in v1.2.0
type TrackOutputSynchronizer struct {
// contains filtered or unexported fields
}
func (*TrackOutputSynchronizer) Close ¶ added in v1.2.0
func (ost *TrackOutputSynchronizer) Close()