gpt4 book ai didi

java - tomcat 或 glassfish 作为 cometd 服务器?

转载 作者:塔克拉玛干 更新时间:2023-11-01 22:18:30 24 4
gpt4 key购买 nike

它们都是免费的,但我认为 glassfish 有一些限制,或者当您达到一定数量的用户( cometd )时,您必须付费吗?对吗?

如果为真,你可以使用 tomcat 作为 comet 服务器吗?

如果没有,那么有哪些免费的 Comet 服务器支持长轮询和 iframe?

最佳答案

They are both free but i think glassfish has some limitation or when you reach up to a certain nr of users (comet) then you have to pay? is that correct?

不,GlassFish 没有这样的限制(您从哪里听说的?)。仅当您希望通过订阅获得官方支持时才需要付费。

if not, then which free comet servers are there supporting long polling and iframe?

Jetty支持 cometd 式编程。 Tomcat 有一个 Comet Implementation (但我发现 complains 比在 Google 上对它的正面反馈还多)。您还可以嵌入 StreamHub .但我不确定他们到底支持什么。

就个人而言,我会选择 GlassFish v3/Grizzly。主要原因是您会发现大量示例、教程等(更不用说您已经下载了 GlassFish 和 NetBeans)。例如this one .

更新:在谷歌搜索更多关于这个话题的时候,我发现了 Atmosphere一个适用于所有人的可移植 AjaxPush/Comet 框架(之前不知道这个框架,但想提一下)。引用其网站:

Atmosphere is a POJO based framework using Inversion of Control (IoC) to bring push/Comet to the masses! Finally a framework which can run on any Java based Web Server, including Google App Engine, Tomcat,Jetty, GlassFish,Weblogic, Grizzly, JBossWeb and JBoss,Resin, etc. without having to wait for Servlet 3.0 Async support or without the needs to learn how Comet support has been differently implemented by all those Containers.

但我仍然会采用 GlassFish v3/Grizzly 方式(并让 Atmosphere 成熟一点)。

关于java - tomcat 或 glassfish 作为 cometd 服务器?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2023076/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com