sse

package
v0.0.0-...-408e1fa Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 12, 2025 License: BSD-3-Clause Imports: 9 Imported by: 0

Documentation

Overview

Package sse implements sink.Sink using Server-Sent Events.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SSE

type SSE struct {
	// contains filtered or unexported fields
}

SSE implements Sink.

func New

func New(ctx context.Context, local bool, namespace, labelSelector string, changeEventSSERPeerPort int) (*SSE, error)

New returns a new SSE instance.

func (*SSE) GetHandler

func (s *SSE) GetHandler(ctx context.Context) http.Handler

GetHandler returns an http.Handler that should be hooked up to the URL that SSE clients will use to receive events.

func (*SSE) Send

func (s *SSE) Send(ctx context.Context, machineID string) error

Send implement Sink.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL