SignalR WebRTC WebSocket已处于CLOSING或CLOSED状态 [英] SignalR WebRTC WebSocket is already in CLOSING or CLOSED state

查看:1289
本文介绍了SignalR WebRTC WebSocket已处于CLOSING或CLOSED状态的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想尝试一下SignalR和WebRTC最简单的实现。我在

解决方案

邮件大小似乎是这里的关键问题。



在您的项目中,每帧视频大约为40k,但每帧凸轮超过140K。
实际上,在index.html播放视频时,大约20秒后,会有几个大于70k的帧,这也会给你带来同样的错误。



<我尝试发送一些长字符串消息作为测试,当消息长于某个值时,我确实会收到错误。但是,我无法在文档中找到消息长度或消息密度的明确限制。


I wanted to take a test run of the simplest implementation of SignalR and WebRTC. I hosted the code in https://github.com/foyzulkarim/WebRtc

I made two different files "index.html" and "index1.html". In index.html I broadcasted a video file through signalr and it went very well. But when I just replace existing video file with WebCam's feed, it started getting error.

After running couple of second I start getting this error "WebSocket is already in CLOSING or CLOSED state." I tried to throttle but no change, still get the error. Any idea why it might happening?

Error image

You can check the video i http://1drv.ms/1meM1OI

解决方案

The message size seems to be the key problem here.

In your project, every frame of video is about 40k but every frame of cam is more than 140K. Actually, in index.html when you broadcast the video, after about 20s, there will be several frames larger than 70k which will also give you the same error.

I tried sending some long string messages as a test, and I do get errors when the message is longer than a certain value. However, I was not able to find in the documentation a definite limitation of message length or message density.

这篇关于SignalR WebRTC WebSocket已处于CLOSING或CLOSED状态的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆