简体   繁体   English

如果流名足够大,则red5 RTMPClient不会发布流

[英]red5 RTMPClient is not publishing stream if streamname is big enough

I have a Red5 client implementation which publishes streams, loaded from video file to our wowza media server. 我有一个Red5客户端实现,该实现发布从视频文件加载到我们wowza媒体服务器的流。 The problem is that if stream name is to big - approximately more than 90 symbols - the client is not publishing it and fails silently. 问题是,如果流名称很大(大约超过90个符号),则客户端不会发布它,并且会静默失败。 All others actions expected from client are fulfilled: it connects to server and creates a stream. 客户端期望的所有其他操作都已实现:它连接到服务器并创建一个流。 But never publishes the stream. 但是永远不会发布信息流。 I dont see a corresponding RTMP message and I dont see a resulting reaction in the logs of wowza. 我没有在wowza的日志中看到相应的RTMP消息,也没有看到结果。

I tried to debug the client and tracked the execution until it starts to write to SocketChannel. 我尝试调试客户端并跟踪执行情况,直到它开始写入SocketChannel。 Everything is the same for the cases of execution of shorter named stream (which publishes ok), and stream with the long name, which RTMP command "to publish" is never sent. 对于执行较短名称的流(发布确定)和使用长名称的流(永远不会发送RTMP命令“发布”)的情况,一切都是相同的。

A questions are: 问题是:

  1. whats up? 这是怎么回事?

  2. if I have written some bytes to SocketChannel without any exceptions thrown - does it guarantees that the corresponding message was sent? 如果我已经向SocketChannel写了一些字节而没有引发任何异常-是否可以保证发送了相应的消息?

  3. if I have written some bytes to SocketChannel without any exceptions thrown - can I check by the means of my OS (MACOS in my case) whether the bytes were really written somewhere? 如果我已经向SocketChannel写了一些字节而没有引发任何异常-我可以通过操作系统(在我的情况下为MACOS)检查字节是否真的写在某个地方吗? Although I know, by the means of WireShark, that this piece of data was never sent. 尽管我知道通过WireShark的方式从未发送过该数据。

UPDATE ...and which is even more strange - after sending "the big" packet sending a smaller one doesn't help. 更新...这更奇怪-在发送“大”数据包之后,发送较小的数据包无济于事。 No packets can be sent after a packet of bigger length have been submitted to the socket. 在将较大长度的数据包提交到套接字后,无法再发送任何数据包。

If I have written some bytes to SocketChannel without any exceptions thrown - does it guarantees that the corresponding message was sent? 如果我已向SocketChannel写了一些字节而没有引发任何异常-是否可以保证发送了相应的消息?

It guarantees that the data has been buffered locally in the socket send buffer, up to the count returned by write(). 它保证数据已在套接字发送缓冲区中本地缓冲,直到write()返回的计数为止。 Nothing more. 而已。

As you can't send further data, it sounds to me as though the receiver isn't reading the large piece of data. 由于您无法发送更多数据,因此听起来好像接收机没有读取大量数据。 Is it possibly failing with an exception and ceasing to read altogether? 是否可能会因异常而失败并完全停止阅读?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM