Documentation
¶
Index ¶
- Constants
- Variables
- func AICurrentLiveSessions(currentPipelines int)
- func AIFirstSegmentDelay(delayMs int64, orchInfo *lpnet.OrchestratorInfo)
- func AIJobProcessed(ctx context.Context, pipeline string, model string, jobInfo AIJobInfo)
- func AILiveVideoAttempt()
- func AIProcessingError(code string, pipeline string, model string, sender string)
- func AIRequestError(code string, pipeline string, model string, orchInfo *lpnet.OrchestratorInfo)
- func AIRequestFinished(ctx context.Context, pipeline string, model string, jobInfo AIJobInfo, ...)
- func AIResultDownloaded(ctx context.Context, pipeline string, model string, downloadDur time.Duration)
- func AIResultSaveError(ctx context.Context, pipeline, model, code string)
- func AIResultUploaded(ctx context.Context, uploadDur time.Duration, pipeline, model, uri string)
- func AuthWebhookFinished(dur time.Duration)
- func CurrentSessions(currentSessions int)
- func Deposit(sender string, deposit *big.Int)
- func FastVerificationDone(ctx context.Context, uri string)
- func FastVerificationEnabledAndUsingCurrentSessions(enabled, using int)
- func FastVerificationFailed(ctx context.Context, uri string, errtype int)
- func HTTPClientTimedOut1(ctx context.Context)
- func HTTPClientTimedOut2(ctx context.Context)
- func InitCensus(nodeType NodeType, version string)
- func InitKafkaProducer(bootstrapServers, user, password, topic, gatewayAddress string) error
- func LogDiscoveryError(ctx context.Context, uri, code string)
- func MaxGasPrice(maxGasPrice *big.Int)
- func MaxPriceForCapability(pipeline string, modelName string, maxPrice *big.Rat)
- func MaxSessions(maxSessions int)
- func MaxTranscodingPrice(maxPrice *big.Rat)
- func MilPixelsProcessed(ctx context.Context, milPixels float64)
- func MinGasPrice(minGasPrice *big.Int)
- func OrchestratorSwapped(ctx context.Context)
- func PaymentCreateError(ctx context.Context)
- func PaymentRecvError(ctx context.Context, sender string, errStr string)
- func RecordingPlaylistSaved(dur time.Duration, err error)
- func RecordingSegmentSaved(dur time.Duration, err error)
- func Reserve(sender string, reserve *big.Int)
- func RewardCallError(sender string)
- func SegSceneClassificationDone(ctx context.Context, seqNo uint64)
- func SegSceneClassificationResult(ctx context.Context, seqNo uint64, class string, prob float64)
- func SegmentDownloaded(ctx context.Context, nonce, seqNo uint64, downloadDur time.Duration)
- func SegmentEmerged(ctx context.Context, nonce, seqNo uint64, profilesNum int, dur float64)
- func SegmentFullyProcessed(ctx context.Context, segDur, processDur float64)
- func SegmentFullyTranscoded(ctx context.Context, nonce, seqNo uint64, profiles string, ...)
- func SegmentTranscodeFailed(ctx context.Context, subType SegmentTranscodeError, nonce, seqNo uint64, ...)
- func SegmentTranscoded(ctx context.Context, nonce, seqNo uint64, sourceDur time.Duration, ...)
- func SegmentUploadFailed(ctx context.Context, nonce, seqNo uint64, code SegmentUploadError, err error, ...)
- func SegmentUploaded(ctx context.Context, nonce, seqNo uint64, uploadDur time.Duration, uri string)
- func SendQueueEventAsync(eventType string, data interface{})
- func SetTranscodersNumberAndLoad(load, capacity, number int)
- func SourceSegmentAppeared(ctx context.Context, nonce, seqNo uint64, manifestID, profile string, ...)
- func StreamCreated(manifestID string, nonce uint64)
- func StreamEnded(ctx context.Context, nonce uint64)
- func StreamStarted(nonce uint64)
- func SuggestedGasPrice(gasPrice *big.Int)
- func TicketRedemptionError(sender string)
- func TicketValueRecv(ctx context.Context, sender string, value *big.Rat)
- func TicketValueSent(ctx context.Context, value *big.Rat)
- func TicketsRecv(ctx context.Context, sender string, numTickets int)
- func TicketsSent(ctx context.Context, numTickets int)
- func ToPipeline(cap string) string
- func TranscodeTry(ctx context.Context, nonce, seqNo uint64)
- func TranscodingPrice(sender string, price *big.Rat)
- func ValueRedeemed(sender string, value *big.Int)
- func WinningTicketsRecv(ctx context.Context, sender string, numTickets int)
- type AIJobInfo
- type GatewayEvent
- type KafkaProducer
- type NodeType
- type PipelineStatus
- type SegmentTranscodeError
- type SegmentUploadError
Constants ¶
const ( SegmentUploadErrorUnknown SegmentUploadError = "Unknown" SegmentUploadErrorGenCreds SegmentUploadError = "GenCreds" SegmentUploadErrorOS SegmentUploadError = "ObjectStorage" SegmentUploadErrorSessionEnded SegmentUploadError = "SessionEnded" SegmentUploadErrorInsufficientBalance SegmentUploadError = "InsufficientBalance" SegmentUploadErrorTimeout SegmentUploadError = "Timeout" SegmentUploadErrorDuplicateSegment SegmentUploadError = "DuplicateSegment" SegmentUploadErrorOrchestratorCapped SegmentUploadError = "OrchestratorCapped" SegmentTranscodeErrorUnknown SegmentTranscodeError = "Unknown" SegmentTranscodeErrorUnknownResponse SegmentTranscodeError = "UnknownResponse" SegmentTranscodeErrorTranscode SegmentTranscodeError = "Transcode" SegmentTranscodeErrorOrchestratorBusy SegmentTranscodeError = "OrchestratorBusy" SegmentTranscodeErrorOrchestratorCapped SegmentTranscodeError = "OrchestratorCapped" SegmentTranscodeErrorParseResponse SegmentTranscodeError = "ParseResponse" SegmentTranscodeErrorReadBody SegmentTranscodeError = "ReadBody" SegmentTranscodeErrorNoOrchestrators SegmentTranscodeError = "NoOrchestrators" SegmentTranscodeErrorDownload SegmentTranscodeError = "Download" SegmentTranscodeErrorSaveData SegmentTranscodeError = "SaveData" SegmentTranscodeErrorSessionEnded SegmentTranscodeError = "SessionEnded" SegmentTranscodeErrorDuplicateSegment SegmentTranscodeError = "DuplicateSegment" SegmentTranscodeErrorMaxAttempts SegmentTranscodeError = "MaxAttempts" SegmentTranscodeErrorNonRetryable SegmentTranscodeError = "NonRetryable" SegmentTranscodeErrorCtxCancelled SegmentTranscodeError = "CtxCancelled" )
const ( //mpeg7-sign comparison fail of fast verification FVType1Error = 1 //video comparison fail of fast verification FVType2Error = 2 )
const ( KafkaBatchInterval = 1 * time.Second KafkaRequestTimeout = 60 * time.Second KafkaBatchSize = 100 KafkaChannelSize = 100 )
Variables ¶
var Enabled bool
Enabled true if metrics was enabled in command line
var Exporter *prometheus.Exporter
Exporter Prometheus exporter that handles `/metrics` endpoint
var ExposeClientIP bool
ExposeClientIP if true then Orchestrator exposes Broadcaster's IP address in metrics
var NodeID string
var PerStreamMetrics bool
Functions ¶
func AICurrentLiveSessions ¶ added in v0.8.2
func AICurrentLiveSessions(currentPipelines int)
func AIFirstSegmentDelay ¶ added in v0.8.2
func AIFirstSegmentDelay(delayMs int64, orchInfo *lpnet.OrchestratorInfo)
func AIJobProcessed ¶ added in v0.8.0
AIJobProcessed records orchestrator AI job processing metrics.
func AILiveVideoAttempt ¶ added in v0.8.2
func AILiveVideoAttempt()
func AIProcessingError ¶ added in v0.8.0
AIProcessingError logs errors in orchestrator AI job processing.
func AIRequestError ¶ added in v0.8.0
func AIRequestError(code string, pipeline string, model string, orchInfo *lpnet.OrchestratorInfo)
AIRequestError logs an error in a gateway AI job request.
func AIRequestFinished ¶ added in v0.8.0
func AIRequestFinished(ctx context.Context, pipeline string, model string, jobInfo AIJobInfo, orchInfo *lpnet.OrchestratorInfo)
AIRequestFinished records gateway AI job request metrics.
func AIResultDownloaded ¶ added in v0.8.0
func AIResultDownloaded(ctx context.Context, pipeline string, model string, downloadDur time.Duration)
AIResultDownloaded logs the successful download of an AI job result.
func AIResultSaveError ¶ added in v0.8.0
AIResultSaveError logs an error in saving an AI job result to storage.
func AIResultUploaded ¶ added in v0.8.0
AIResultUploaded logs the successful upload of an AI job result.
func AuthWebhookFinished ¶ added in v0.5.5
func CurrentSessions ¶ added in v0.5.0
func CurrentSessions(currentSessions int)
func FastVerificationDone ¶ added in v0.5.23
func FastVerificationEnabledAndUsingCurrentSessions ¶ added in v0.5.23
func FastVerificationEnabledAndUsingCurrentSessions(enabled, using int)
func FastVerificationFailed ¶ added in v0.5.23
func HTTPClientTimedOut1 ¶ added in v0.5.11
func HTTPClientTimedOut2 ¶ added in v0.5.11
func InitCensus ¶ added in v0.5.0
func InitKafkaProducer ¶ added in v0.8.1
func LogDiscoveryError ¶ added in v0.5.0
LogDiscoveryError records discovery error
func MaxGasPrice ¶ added in v0.5.19
func MaxPriceForCapability ¶ added in v0.8.0
func MaxSessions ¶ added in v0.5.0
func MaxSessions(maxSessions int)
func MaxTranscodingPrice ¶ added in v0.5.19
func MilPixelsProcessed ¶ added in v0.5.19
func MinGasPrice ¶ added in v0.5.19
func OrchestratorSwapped ¶ added in v0.5.14
func PaymentCreateError ¶ added in v0.5.0
PaymentCreateError records a error from payment creation
func PaymentRecvError ¶ added in v0.5.0
PaymentRecvError records an error from receiving a payment
func RecordingPlaylistSaved ¶ added in v0.5.14
func RecordingSegmentSaved ¶ added in v0.5.14
func RewardCallError ¶ added in v0.7.2
func RewardCallError(sender string)
RewardCallError records an error from reward calling
func SegSceneClassificationDone ¶ added in v0.5.36
func SegSceneClassificationResult ¶ added in v0.5.36
func SegmentDownloaded ¶ added in v0.5.13
func SegmentEmerged ¶ added in v0.5.0
func SegmentFullyProcessed ¶ added in v0.5.11
func SegmentFullyTranscoded ¶ added in v0.5.0
func SegmentFullyTranscoded(ctx context.Context, nonce, seqNo uint64, profiles string, errCode SegmentTranscodeError, orchInfo *lpnet.OrchestratorInfo)
func SegmentTranscodeFailed ¶ added in v0.5.0
func SegmentTranscoded ¶ added in v0.5.0
func SegmentUploadFailed ¶ added in v0.5.0
func SegmentUploaded ¶ added in v0.5.0
func SendQueueEventAsync ¶ added in v0.8.1
func SendQueueEventAsync(eventType string, data interface{})
func SetTranscodersNumberAndLoad ¶ added in v0.5.0
func SetTranscodersNumberAndLoad(load, capacity, number int)
func SourceSegmentAppeared ¶ added in v0.5.0
func StreamCreated ¶ added in v0.5.0
func StreamEnded ¶ added in v0.5.0
func StreamStarted ¶ added in v0.5.0
func StreamStarted(nonce uint64)
func SuggestedGasPrice ¶ added in v0.5.0
SuggestedGasPrice records the last suggested gas price
func TicketRedemptionError ¶ added in v0.5.0
func TicketRedemptionError(sender string)
TicketRedemptionError records an error from redeeming a ticket
func TicketValueRecv ¶ added in v0.5.0
TicketValueRecv records the ticket value received from a sender for a manifestID
func TicketValueSent ¶ added in v0.5.0
TicketValueSent records the ticket value sent
func TicketsRecv ¶ added in v0.5.0
TicketsRecv records the number of tickets received from a sender for a manifestID
func TicketsSent ¶ added in v0.5.0
TicketsSent records the number of tickets sent
func ToPipeline ¶ added in v0.8.0
ToPipeline converts capability name into pipeline name
func TranscodeTry ¶ added in v0.5.0
func TranscodingPrice ¶ added in v0.5.0
TranscodingPrice records the last transcoding price
func ValueRedeemed ¶ added in v0.5.0
ValueRedeemed records the value from redeeming winning tickets
Types ¶
type GatewayEvent ¶ added in v0.8.1
type KafkaProducer ¶ added in v0.8.1
type KafkaProducer struct {
// contains filtered or unexported fields
}
type PipelineStatus ¶ added in v0.8.2
type PipelineStatus struct { Pipeline string `json:"pipeline"` StartTime float64 `json:"start_time"` LastParamsUpdateTime float64 `json:"last_params_update_time"` LastParams interface{} `json:"last_params"` LastParamsHash string `json:"last_params_hash"` InputFPS float64 `json:"input_fps"` OutputFPS float64 `json:"output_fps"` LastInputTime float64 `json:"last_input_time"` LastOutputTime float64 `json:"last_output_time"` RestartCount int `json:"restart_count"` LastRestartTime float64 `json:"last_restart_time"` LastRestartLogs []string `json:"last_restart_logs"` LastError *string `json:"last_error"` StreamID *string `json:"stream_id"` }
type SegmentTranscodeError ¶ added in v0.5.0
type SegmentTranscodeError string
type SegmentUploadError ¶ added in v0.5.0
type SegmentUploadError string