简体   繁体   English

如何在一个Fluorfx网关中运行第二个ApplicationAdapter

[英]How to run a second ApplicationAdapter within one fluorinefx gateway

Im trying to have two ApplicationAdapters within one gateway. 我试图在一个网关中有两个ApplicationAdapters。 My instinct told me to look into config files: remoting-config.xml and services-config.xml. 我的直觉告诉我要研究配置文件:remoting-config.xml和services-config.xml。

There are some channels defined, like: 定义了一些渠道,例如:

<channel-definition id="rtmp-my-channel" class="mx.messaging.channels.RTMPChannel">
  <endpoint uri="rtmp://{server.name}:1935" class="flex.messaging.endpoints.RTMPEndpoint"/>
</channel-definition>

So I can add a channel here. 所以我可以在这里添加频道

Also, I want to add another folder containing app.config to apps folder. 另外,我想将另一个包含app.config的文件夹添加到apps文件夹。

But then: 但是之后:

If a flash client connects to a given endpoint (say port 1935) how would it "know" which applicationAdapter should it access? 如果Flash客户端连接到给定的端点(例如端口1935),它将如何“知道”它应访问哪个applicationAdapter?

Hope i made myself clear:) 希望我能说清楚:)

Ok, I made it work. 好的,我成功了。 There is no need to create a new channel. 无需创建新频道。 All you have to do is: 您要做的就是:

create a folder in apps folder, which is going to contain a app.config file. 在apps文件夹中创建一个文件夹,其中将包含一个app.config文件。

Every folder points an application adapter. 每个文件夹都指向一个应用程序适配器。 So right now I have to folder in apps folder: 所以现在我必须将文件夹放在apps文件夹中:

app1 and app2. app1和app2。

Both folders contain app.config file pointing to an application adapter. 这两个文件夹都包含指向应用程序适配器的app.config文件。 If your flash client wants to connect to the app1 it should connect to something like: 如果您的Flash客户端要连接到app1,则应连接到以下内容:

   rtmp://xx.xx.xx.xx:xx/app1/?someParameters....

while if you want to get the connection to app2: 而如果您想与app2建立连接:

   rtmp://xx.xx.xx.xx:xx/app2/?someParameters....

Maybe someone is going to need that..:) 也许有人会需要那个.. :)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM