1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

rtmp edge support 302 redirect.

This commit is contained in:
winlin 2016-01-11 15:46:23 +08:00
parent a11ab5ad24
commit 2941328ee8
2 changed files with 95 additions and 19 deletions

View file

@ -97,9 +97,13 @@ public:
class SrsEdgeRtmpUpstream : public SrsEdgeUpstream
{
private:
// for RTMP 302, if not empty,
// use this <ip[:port]> as upstream.
std::string redirect;
SrsSimpleRtmpClient* sdk;
public:
SrsEdgeRtmpUpstream();
// @param rediect, override the server. ignore if empty.
SrsEdgeRtmpUpstream(std::string r);
virtual ~SrsEdgeRtmpUpstream();
public:
virtual int connect(SrsRequest* r, SrsLbRoundRobin* lb);
@ -123,6 +127,8 @@ private:
SrsReusableThread2* pthread;
SrsLbRoundRobin* lb;
SrsEdgeUpstream* upstream;
// for RTMP 302 redirect.
std::string redirect;
public:
SrsEdgeIngester();
virtual ~SrsEdgeIngester();