crtmpserver的协议架构
来源:互联网 发布:宏程序编程入门自学 编辑:程序博客网 时间:2024/05/22 07:48
I/O模型如下:
+---+ +----+ +----+ +----+ +----+ +----+
| T |<--->| P1 |<--->| P2 |<--->| P3 |<---> ** <--->| Pn |<--->| CS |
*---+ *----+ *----+ *----+ *----+ *----+
T - Transport level. At this level we store the inbound data into a buffer
or send the data from the output buffer. This layer may or may not
have a IOHandler attached. This give us the possibility of having
stateless communication like a chain of protocols in which HTTP is
the edge protocol with the outside world. Basically, this layer
will do I/O whenever a carrier is available.
T - 传输层。
在这一层中,我们将流入的数据存储到一个buffer中,或将输出buffer中的数据发送出去。
这一层,可以有,也可以没有附带的IOHandler,
这样可以在处理无状态连接,如以HTTP为对外服务的边缘协议的协议链时很有用。
基本上,无论一个载体是否有效,这一层都可以用做I/O.
P1 to Pn - Protocol levels. At this levels we do packing/unpacking of the
data provided either by the transport level or by the previous
protocol. This way we can stack multiple protocol on top of each
other. For example we could have RTMP over HTTP, or RTMP over some
kind of compressing protocol over base64 over HTTP
P1 to Pn - 协议层。
在这一层中,将会封装/拆封闭由传输层或前一个协议提供的数据。
依据这样的方式,我们可以实现将协议间的堆叠。
例如,可以将RTMP堆叠在HTTP上,或将RTMP堆叠在某些压缩协议之上后再堆叠base64,再堆叠HTTP。
CS - Connection state. At this level we do the business logic of the connection.
All the data passed in and out of this level is translated relative to the
business logic of the connection. For example in a RTMP connection this
layer will receive only RTMP messages.
CS - 连接状态
在这一层中,我们需要处理连接的业务逻辑。
所有输入或输出这一层的数据都会被转换与连接相关的业务逻辑。
例如,RTMP连接在这一层中只会收到RTMP消息。
下面是一些可能协议链:
1. TCP <--> HTTP <--> XMLRPC <--> Application Server State
2. TCP <--> RTMP <--> RTMP Connection State
3. TCP <--> HTTP <--> RTMP <--> RTMP Connection State
4. TCP <--> Encription <--> RTMP <--> RTMP Connection State
5. TCP <--> HTTP <--> Encription <--> RTMP <--> RTMP Connection State
...
很显然,在实际使用中,上面的协议链并不会都有用,这些只是示例而已。
+---+ +----+ +----+ +----+ +----+ +----+
| T |<--->| P1 |<--->| P2 |<--->| P3 |<---> ** <--->| Pn |<--->| CS |
*---+ *----+ *----+ *----+ *----+ *----+
T - Transport level. At this level we store the inbound data into a buffer
or send the data from the output buffer. This layer may or may not
have a IOHandler attached. This give us the possibility of having
stateless communication like a chain of protocols in which HTTP is
the edge protocol with the outside world. Basically, this layer
will do I/O whenever a carrier is available.
T - 传输层。
在这一层中,我们将流入的数据存储到一个buffer中,或将输出buffer中的数据发送出去。
这一层,可以有,也可以没有附带的IOHandler,
这样可以在处理无状态连接,如以HTTP为对外服务的边缘协议的协议链时很有用。
基本上,无论一个载体是否有效,这一层都可以用做I/O.
P1 to Pn - Protocol levels. At this levels we do packing/unpacking of the
data provided either by the transport level or by the previous
protocol. This way we can stack multiple protocol on top of each
other. For example we could have RTMP over HTTP, or RTMP over some
kind of compressing protocol over base64 over HTTP
P1 to Pn - 协议层。
在这一层中,将会封装/拆封闭由传输层或前一个协议提供的数据。
依据这样的方式,我们可以实现将协议间的堆叠。
例如,可以将RTMP堆叠在HTTP上,或将RTMP堆叠在某些压缩协议之上后再堆叠base64,再堆叠HTTP。
CS - Connection state. At this level we do the business logic of the connection.
All the data passed in and out of this level is translated relative to the
business logic of the connection. For example in a RTMP connection this
layer will receive only RTMP messages.
CS - 连接状态
在这一层中,我们需要处理连接的业务逻辑。
所有输入或输出这一层的数据都会被转换与连接相关的业务逻辑。
例如,RTMP连接在这一层中只会收到RTMP消息。
下面是一些可能协议链:
1. TCP <--> HTTP <--> XMLRPC <--> Application Server State
2. TCP <--> RTMP <--> RTMP Connection State
3. TCP <--> HTTP <--> RTMP <--> RTMP Connection State
4. TCP <--> Encription <--> RTMP <--> RTMP Connection State
5. TCP <--> HTTP <--> Encription <--> RTMP <--> RTMP Connection State
...
很显然,在实际使用中,上面的协议链并不会都有用,这些只是示例而已。
0 0
- crtmpserver的协议架构
- crtmpserver的架构简介
- crtmpserver基本架构(协议和服务对应关系)
- 从crtmpserver中看具体处理rtmp协议的流程1
- 从crtmpserver中看具体处理rtmp协议的流程2
- 从crtmpserver中看具体处理rtmp协议的流程3
- 从crtmpserver中看具体处理rtmp协议的流程4
- 从crtmpserver中看具体处理rtmp协议的流程5
- 从crtmpserver中看具体处理rtmp协议的流程
- CRtmpserver协议链(protocol)
- crtmpserver的安装
- crtmpserver的部署方案
- crtmpserver的安装
- crtmpserver的一个bug
- crtmpserver
- crtmpserver
- 关于CrtmpServer中的RTMP协议头处理
- crtmpserver流媒体服务器的介绍与搭建
- git log常用命令以及技巧
- 带有一个UITextView的AlertView
- 伸展树uva11996
- AlphaBeta剪枝算法
- 遇到QT信号不能在派生类定义的问题 undefined referenc signals
- crtmpserver的协议架构
- c之将数组传进函数中的方法
- Xcode中使用method_invoke或者objc_msgSend()报错Too many arguments to function call ,expected 0,have3
- 如何让文本框背景色透明
- error: exception handling disabled, use -fexceptions to enable under Android NDK enviroement
- URL重写
- hdu 3001 Travelling
- 创建SQL作业错误的解决方法(不能将值 NULL 插入列 'owner_sid',表 'msdb.dbo.sysjobs';列不允许有空值。)
- Objective-c中的@property 简单介绍与使用