feat(media-streaming,pubsub): expand helper swarm and chunk scheduler APIs
Hyper-P2P Module Tests / unit-all (push) Failing after 1h20m44s
Hyper-P2P Module Tests / unit-all (push) Failing after 1h20m44s
- helper-swarm-coordinator: autoAssign, rebalance, resetUtilization - chunk-scheduler-media: enqueueBatch, dropBelowPriority, clear - qos-topic: queueDepths, clearQueues - Update routing-advanced category README highlights Co-authored-by: Cursor <[email protected]>
This commit is contained in:
@@ -75,6 +75,19 @@ class HyperP2PQosTopic extends EventEmitter {
|
||||
|
||||
hasHandler (channel) { return this._handlers.has(channel) }
|
||||
|
||||
queueDepths () {
|
||||
return this._queues.map((q, qos) => ({ qos, depth: q.length }))
|
||||
}
|
||||
|
||||
clearQueues () {
|
||||
let n = 0
|
||||
for (const q of this._queues) {
|
||||
n += q.length
|
||||
q.length = 0
|
||||
}
|
||||
return n
|
||||
}
|
||||
|
||||
_onGossip (data) {
|
||||
if (!data || data.type !== 'qos-publish') return
|
||||
this._stats.gossipIn++
|
||||
|
||||
Reference in New Issue
Block a user