开发者

Icecast server status

开发者 https://www.devze.com 2022-12-22 10:30 出处:网络
Does anybody know, how to check if broadcast is online or offline in Ice开发者_如何学Pythoncast2 server?

Does anybody know, how to check if broadcast is online or offline in Ice开发者_如何学Pythoncast2 server? Ruby preferred.


I guess you can make a TCP (HTTP) connection to specified server. Icecast server works as a regular HTTP server but data transfers are actually streams. So, all you need is to make regular Socket connection and send request (you can grab it from live http headers extension in firefox). Also, you might want to set timeout in case that server is down. And if server responds with HTTP/OK (200) code then its live.

0

精彩评论

暂无评论...
验证码 换一张
取 消