mirror of
https://github.com/livekit/livekit.git
synced 2026-05-25 14:15:15 +00:00
reduce log level of signal close errors (#1675)
* reduce log level of signal close errors * update psrpc * cleanup * cleanup
This commit is contained in:
@@ -1,12 +1,14 @@
|
||||
package rtc
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"time"
|
||||
|
||||
"github.com/pion/webrtc/v3"
|
||||
|
||||
"github.com/livekit/protocol/livekit"
|
||||
"github.com/livekit/psrpc"
|
||||
|
||||
"github.com/livekit/livekit-server/pkg/routing"
|
||||
)
|
||||
@@ -265,7 +267,11 @@ func (p *ParticipantImpl) writeMessage(msg *livekit.SignalResponse) error {
|
||||
}
|
||||
|
||||
err := sink.WriteMessage(msg)
|
||||
if err != nil {
|
||||
if errors.Is(err, psrpc.Canceled) {
|
||||
p.params.Logger.Debugw("could not send message to participant",
|
||||
"error", err, "messageType", fmt.Sprintf("%T", msg.Message))
|
||||
return nil
|
||||
} else if err != nil {
|
||||
p.params.Logger.Warnw("could not send message to participant", err,
|
||||
"messageType", fmt.Sprintf("%T", msg.Message))
|
||||
return err
|
||||
|
||||
Reference in New Issue
Block a user