如何通过 SOAP 公开 Red5 的 SharedObjects
编辑:显然我的第一个问题并不是很容易理解,我希望答案是有用的:)
我已经尝试在Red5服务器上安装Axis2并且一切正常,我使用Red5的RTMPClient从自定义Web服务访问了Red5应用程序属性并且通过 Axis2 暴露它们。
问题是,这样做我有一个 2 级服务器,并且我实际上无法直接从 Web 服务访问共享对象等...我想做的是能够访问一些 Red5 应用程序功能直接通过 SOAP 服务类。
我想我必须自己创建 SOAP 服务器(也许使用 Axis 的 SimpleHTTPServer 或 SimpleAxis2Server??)
有什么想法吗?
我希望我能解释一下自己......并提前致谢
Edit: Obviously my first question was not really easy to understand, I hope the answer is usefull :)
I have tried installing Axis2 on the Red5 server and everything went ok, I accessed the Red5 app properties from a custom Web Service using Red5's RTMPClient and exposed them through Axis2.
The problem is that doing it that way I have a 2 levels server and I don't really have direct access from the webservice to the sharedobjects, etc... What I would like to do is to be able to access some Red5 apps functions directly through the SOAP service class.
I suppose I will have to create the SOAP server on my own (maybe using Axis's SimpleHTTPServer or SimpleAxis2Server??)
Any ideas??
I hope I explained myself... And thanks in advance
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
解决!!!
我没有使用 Axis2,而是使用了 JAX-WS,这是我真正需要的。
我创建了一个类用作 WebService 并公开我的 SharedObjects
然后我在 MyApplications appStart 函数上添加了对 Endpoint.publish() 的调用,以便在应用程序运行后立即运行 WebService。 我将其作为参数传递给 Red5WS 构造函数,以便能够从 Web 服务访问应用程序范围:
编译 Red5 应用程序后,必须使用 wsgen 创建所需的 WS 类。
重新启动 Red5 应用程序后,您应该能够通过以下方式访问 Web 服务的 WSDL 文件:
Resolved!!!
Instead of using Axis2, I have used JAX-WS which is what I really needed.
I have created a class to use as WebService and expose my SharedObjects
Then I added a call to Endpoint.publish() on MyApplications appStart function to run the WebService as soon as the application is run. I pass this as a parameter to the Red5WS constructor to be able to access applications scope from the web service:
After compiling the Red5 app it's a must to use the wsgen to create the needed WS classes.
Once restarted the Red5 app you should be able to acces web service's WSDL file through: