Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrProcessExists = errors.New("process already exists")
View Source
var ErrUnknownProcess = errors.New("unknown process")
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { ID string Name string Store store.Store DiskFS fs.Filesystem MemFS fs.Filesystem Replace replace.Replacer FFmpeg ffmpeg.FFmpeg MaxProcesses int64 Logger log.Logger }
Config is the required configuration for a new restreamer instance.
type Restreamer ¶
type Restreamer interface { ID() string // ID of this instance Name() string // Arbitrary name of this instance CreatedAt() time.Time // time of when this instance has been created Start() // start all processes that have a "start" order Stop() // stop all running process but keep their "start" order AddProcess(config *app.Config) error // add a new process GetProcessIDs() []string // get a list of all process IDs DeleteProcess(id string) error // delete a process UpdateProcess(id string, config *app.Config) error // update a process StartProcess(id string) error // start a process StopProcess(id string) error // stop a process RestartProcess(id string) error // restart a process ReloadProcess(id string) error // reload a process GetProcess(id string) (*app.Process, error) // get a process GetProcessState(id string) (*app.State, error) // get the state of a process GetProcessLog(id string) (*app.Log, error) // get the logs of a process GetPlayout(id, inputid string) (string, error) // get the URL of the playout API for a process Probe(id string) app.Probe // probe a process Skills() skills.Skills // get the ffmpeg skills ReloadSkills() error // reload the ffmpeg skills SetProcessMetadata(id, key string, data interface{}) error // set metatdata to a process GetProcessMetadata(id, key string) (interface{}, error) // get previously set metadata from a process SetMetadata(key string, data interface{}) error // set general metadata GetMetadata(key string) (interface{}, error) // get previously set general metadata }
The Restreamer interface
func New ¶
func New(config Config) (Restreamer, error)
New returns a new instance that implements the Restreamer interface
Click to show internal directories.
Click to hide internal directories.