mirror of
https://github.com/livekit/livekit.git
synced 2026-05-25 18:34:55 +00:00
Do not treat data publisher as publisher. (#3204)
This commit is contained in:
@@ -1842,7 +1842,6 @@ func (p *ParticipantImpl) onDataMessage(kind livekit.DataPacket_Kind, data []byt
|
||||
shouldForwardData := true
|
||||
shouldForwardMetrics := false
|
||||
overrideSenderIdentity := true
|
||||
isPublisher := true
|
||||
// only forward on user payloads
|
||||
switch payload := dp.Value.(type) {
|
||||
case *livekit.DataPacket_User:
|
||||
@@ -1887,7 +1886,6 @@ func (p *ParticipantImpl) onDataMessage(kind livekit.DataPacket_Kind, data []byt
|
||||
}
|
||||
shouldForwardData = false
|
||||
shouldForwardMetrics = true
|
||||
isPublisher = false
|
||||
// METRICS-TODO-QUESTIONS:
|
||||
// 1. Should this record (and do processing/batching) metrics (i. e. publisher side) rather
|
||||
// than forwarding and recording/processing/batching at every subscriber (in this case
|
||||
@@ -1929,10 +1927,6 @@ func (p *ParticipantImpl) onDataMessage(kind livekit.DataPacket_Kind, data []byt
|
||||
onMetrics(p, dp)
|
||||
}
|
||||
}
|
||||
|
||||
if isPublisher {
|
||||
p.setIsPublisher(true)
|
||||
}
|
||||
}
|
||||
|
||||
func (p *ParticipantImpl) onICECandidate(c *webrtc.ICECandidate, target livekit.SignalTarget) error {
|
||||
|
||||
Reference in New Issue
Block a user