Proxy Stream
proxy.stream – npm
ream0. 1. 2 • Public • Published 6 years ago Readme Explore BETA0 Dependencies0 Dependents3 Versions
It’s a nodejs proxy, implemented steam interface, supports socks4, socks4a, socks5 and.
How to use
Install by $ npm install
Use new Proxy({ type: ‘direct’}) to create a proxy stream.
Example 1: direct access
It start an proxy on port 2000;
var net = require(‘net’);var Proxy = require(”);eateServer(function (s) { var proxy = new Proxy(); (proxy)(s);})(2000, function () { (‘/socks4/socks5 proxy listening on port 2000’);});
Example 2: access throw another proxy
It turns the socks5 proxy [localhost:2000] to another proxy supports /socks4/socks5!
var net = require(‘net’);var Proxy = require(”);eateServer(function (s) { (new Proxy({ type: ‘socks5’, host: ‘localhost’, port: 2000}))(s);})(8080, function () { (‘/socks4/socks5 proxy listening on port 8080’);});
Example 3: qproxy
Proxy based on WebSocket. Source
More
This is a stream, it can be used simply in multiple scenarios.
A Scalable Streaming Proxy Server Based on Cluster Architecture
Conference paper
651
Downloads
Part of the
Lecture Notes in Computer Science
book series (LNCS, volume 3044)AbstractWith the explosive growth of multimedia streaming service, streaming proxy server is deployed to reduce response time, server load and network traffic. Existing single node proxy server has limitation on delivering many simultaneously streams. To solve this problem, in this paper, we propose a scalable streaming proxy server based on cluster architecture. We conduct some simulation experiments, which exhibit high scalability and high performance with our ywordsCache Scheme Cache Replacement Origin Server Multimedia Stream Cluster Architecture
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.
PreviewUnable to display preview. Download preview, S., Rexford, J., Towsley, D. : Proxy prefix caching for multimedia streams. In: Proc. of IEEE INFOCOM (March 1999)Google, S., Rexford, J., Basso, A. : Protocol considerations for a prefix-caching proxy for multimedia streams. 9th International World Wide Web Conference, Amsterdam (2000)Google, K., Yu, P. S., Wolf, J. L. : Segment-based proxy caching of multimedia streams. of the 10th International WWW Conference, Hong Kong (2001)Google, S., Sheng, B., Yan, Y., Basu, S. : Shared running buffer based proxy caching of streaming session, Technical Report HPL-2003-47, Mobile and Media Systems Laboratory, HP Laboratories, Palo Alto (March 2003)Google, S., Bestavros, A. : Accelerating Internet streaming media delivery using networkaware partial caching, Technical Report BUCS-TR-2001-023, Boston University, Computer Science Department (October 2001)Google, S. H., Lim, E., Chung, K. D. : Popularity-based partial caching for VOD systems using a proxy server. of Int. Conf. Parallel and Distributed Processing Symposium, pp. 1164–1168 (2001)Google mmaiah, E., Guo, K., Hofmann, M., Paul, S. : Design and implementation of a caching system for streaming media over the Internet. In: Proceedings of IEEE Real Time Technology and Applications Symposium (May 2002)Google, R., Handley, M., Yu, H., Estrin, D. : Proxy caching mechanism for playback streams in the Internet. In: Proceedings of Fourth International Web Caching Workshop (March 1999)Google, F., Zhang, Q., Zhu, W., Zhang, Y. -Q. : QoS-adaptive proxy caching for multimedia streaming over the Internet. of First IEEE Pacific-Rim Conference on Multimedia, Sydney, Australia (December 2000)Google, X., Mohapatra, P. : Efficient Admission Control Algorithms for Multimedia Servers. Multimedia Systems, 294–304 (1999)Google, J. B., Yeom, H. Y. : An admission control scheme for continuous media servers using caching. In: Proceedings of International Performance, Computing and Communication Conference, IPCCC (1999)Google, Y. W., Baek, K. H., Chung, K. -D. : Proxy caching based on patching scheme and prefetching. of IEEE Pacific Rim Conference on Multimedia, pp. 558–565 (2001)Google, S., Shen, B., Wee, S., Zhang, X. : Adaptive and lazy segmentation based proxy caching for streaming media delivery. In: Proceedings of 13th ACM International Workshop on Network and Operating Systems Support for Design Audio and Video (NOSSDAV 2003), Monterey, California, USA (June 2003)Google, Y., Lang, Z., Du, D., Su, D. : A network conscious approach to end-to-end video delivery over wide area networks using proxy servers. of IEEE Infocomm (1998)Google rscheure, O., Venkatramani, C., Frossard, P., Amini, L. : Joint server scheduling and proxy caching for video delivery. In: Proceedings of Sixth International Workshop on Web Caching and Content Distribution, Boston, MA (May 2001)Google harya, S., Smith, B. : MiddleMan: a video caching proxy server. In: Proceedings of NOSSDAV (June 2000)Google, Sitaram, D. : A generalized interval caching policy for mixed interactive and long video workloads. In: Proceedings of ISWT/SPIE Multimedia Computing and Networking 1996, San Jose, California, January 29-31 (1996)Google Scholar18. Hofmann, M., Ng, E., Guo, K., Paul, S., Zhang, H. : Caching techniques for streaming multimedia over the Internet, Technical Report BL011345-990409-04TM, Bell Laboratories (April 1999)Google, Y., Guo, K., Buddhikot, M., Suri, S., Zegura, E. : Silo, rainbow, and caching token: schemes for scalable fault tolerant stream caching. IEEE Journal on Selected Areas in Communications, Special Issue on Internet Proxy Services (2002)Google, K. O., Kwon, J. : Exploiting caching for realtime multimedia systems. of IEEE International Conference on Multimedia Computing and Systems, Hiroshima, Japan, June 1996, pp. 186–190 (1996)Google pyright information© Springer-Verlag Berlin Heidelberg 2004Authors and AffiliationsHai Jin1Jie Chu1Kaiqin Fan1Zhi Dong1Zhiling uster and Grid Computing Lab HuazhongUniversity of Science and TechnologyWuhanChina
Streaming Media Delivery with NGINX Plus
NGINX is widely used to deliver MP4 and FLV video content using progressive downloads or HTTP pseudo-streaming. Progressive downloads rely on the efficiency of the streaming server to handle disk I/O and concurrent connections, while MP4 or FLV pseudo‑streaming capabilities also allow the clients to use a simple “trick‑play” technique to seek to the desired position in a video stream without needing to download the entire resource.
NGINX Plus extends this capability to support adaptive streaming for video-on-demand (VOD) applications with Apple HLS and Adobe HDS, and Flash‑based services using RTMP. Among other benefits, adaptive streaming allows the video player to select the most appropriate bitrate in real time.
NGINX Plus can also impose smart bandwidth limits on individual MP4 streams to prevent fast clients and download accelerators from using excessive resources, and its enhanced session logging capabilities reduce the overhead of the standard HTTP request logging with HTTP streaming media.
NGINX Plus supports all popular video formats with progressive download, HTTP pseudo‑streaming, and adaptive streaming
HLS Video on Demand
The HLS/VOD module in NGINX Plus provides HTTP Live Streaming (HLS) support for H. 264/AAC‑encoded content packaged in MP4 file containers (filename extensions. mp4,. m4v, and. m4a). With the HLS/VOD module, there’s no need to repackage existing MP4 content when introducing adaptive streaming to users – the content is “transformed” or “transmultiplexed” on the fly from the MP4 file container to HLS. The NGINX Plus module performs real‑time segmentation, packetization, and multiplexing from the MP4 file container to HLS/MPEG‑TS without recoding the content.
Before clients begin downloading media segments, they first request a manifest (filename extension. m3u8). The HLS/VOD module generates the playlist on the fly, so you do not need to manually describe the segment structure.
You can configure NGINX to serve HLS streams from a particular location, as in this example:
location /hls/ {
hls; # Use the HLS handler to manage requests
# Serve content from the following location
alias /var/www/video;
# HLS parameters
hls_fragment 8s;
hls_buffers 10 10m;
hls_mp4_buffer_size 1m;
hls_mp4_max_buffer_size 5m;}
HLS clients first request the. m3u8 manifest for a file in the location, then begin downloading the segments of video specified in the file. Again, NGINX Plus handles the task of segmenting MP4‑packaged content on the fly for HLS streaming.
In addition, the HLS functionality can be used along with the NGINX secure link module to generate authorized, time‑limited links based on unique client data such as a cookie or source IP address. This provides a strong degree of protection against misuse of the video service.
HDS Adaptive Streaming
Adobe’s HTTP Dynamic Streaming (HDS) provides an alternative method for delivering adaptive streaming media to your users. It functions in a similar fashion to Apple’s HLS, but uses different file formats.
Video is first prepared using Adobe’s f4fpackager tool, which generates manifest (filename extension. f4m), fragment (. f4f), and index (. f4x) files. These files are then published to the web server, and NGINX Plus’ f4f handler delivers them.
location /hds/ {
f4f; # Use the HDS handler to manage requests
alias /var/www/video;}
Session Log Aggregation
Video clients that access content using HDS or HLS generally issue a great many HTTP requests for the video fragments. The resulting request log can be very verbose and difficult to analyze.
To make logs of streaming media downloads more useful, NGINX Plus’ session log aggregation feature generates more concise logs that combine multiple HTTP requests into a single log file entry. All of the requests in a single time‑limited session are combined, and the total data transferred is logged. All other parameters are taken from the first request in the session.
You can enable session log aggregation for requests to the media location and use standard logging for all other client requests, to preserve the detail in your request logs.
MP4 Bandwidth Control
To apply limits to HTTP traffic downloads, use the limit_rate and limit_rate_after directives. These directives define limits in terms of bandwidth (bytes per second).
NGINX Plus also offers smart limits for MP4 content. The mp4_limit_rate and mp4_limit_rate_after directives define bandwidth limits in terms of the bitrate of the downloaded file, and the time after which to apply the bandwidth limit.
The following sample configuration allows MP4 files to stream without limit for 15 seconds to let clients read ahead, then limits bandwidth to 120% of the bitrate of the MP4 file.
location /video/ {
mp4;
mp4_limit_rate_after 15s;
mp4_limit_rate 1. 2;}
This helps to avoid excessive waste of bandwidth resources when clients use “trick‑play” capabilities to skip forwards through video files, and it reduces the impact of video download accelerators.
Frequently Asked Questions about proxy stream
What is stream proxy?
With the explosive growth of multimedia streaming service, streaming proxy server is deployed to reduce response time, server load and network traffic. Existing single node proxy server has limitation on delivering many simultaneously streams.
What is Nginx stream?
NGINX is widely used to deliver MP4 and FLV video content using progressive downloads or HTTP pseudo-streaming.
What is RTSP proxy server?
The “LIVE555 Proxy Server” is a unicast RTSP server – built from the “LIVE555 Streaming Media” software – that acts as a ‘proxy’ for one or more ‘back-end’ unicast or multicast RTSP/RTP streams (i.e., served by other server(s)).