Nginx's rewrite module is a module that rewrites the path. You can see that nginx is in the configuration. In addition to using PCRE to support regular expressions, you can also configure more complicated processes. For example, if can rewrite the path under different conditions: This is equivalent to parsing part of the logic. In addition to openresty supporting the Lua extension language, Nginx also supports njs, which is javascript. SRS will not support scripting languages. Currently, HTTP (S) is a common language between systems. I think HTTP integration is a more appropriate method. Of course, Nginx has done a very good job in configuration and script extension language, which is worthy of admiration and learning. |
Nginx can support WebSocket proxy, please refer to WebSocket proxying . As a chestnut, convert the live HTTP-FLV stream The SRS configuration is as follows: Start videojs-flow / demo / mse.go and convert HTTP-FLV to WS-FLV: Configure Nginx, reverse proxy WS-FLV is as follows: Use bilibili / flv.js to play the stream address: |
In the nginx.org document, an excerpt from nginx's article, Chapter "nginx" in "The Architecture of Open Source Applications" , is excerpted . This article is very good. Read it together:
there is always room for improvement
, the wheel of history always moves forward and never stops.