对于订阅C#的客户端库/出版MQTT(非常小的Message Broker)客户端、MQTT、Broker、Message

2023-09-05 07:29:50 作者:感情终抵不过时光怂恿

我需要实现Android的推送通知,但不会有互联网接入,只有内网连接。 所以我觉得我不能使用C2DM而像UrbanAirship第三方API。所以,我想使用MQTT RSMB(非常小的Message Broker),C#.net为发布到代理和wMqtt.jar为Android作为subcriber的经纪人。

I need to implement the push notification for Android but there will not be internet access and only intranet access is available. So I think I cannot use C2DM and third party API like UrbanAirship. So I am thinking of using MQTT RSMB(Really Small Message Broker), C# .net as Publisher to the broker and wMqtt.jar for Android as subcriber to the broker.

我已经下载了RSMB,发现如下exe文件: -broker.exe -stdinpub.exe -stdoutsub.exe

I have downloaded the RSMB and found the followings exe: -broker.exe -stdinpub.exe -stdoutsub.exe

我已经成功地从Android的订阅和发布了使用stdinpub.exe与主题的消息。

I have successfully subscribed from Android and published messages using stdinpub.exe with topic.

我希望得到一些建议,从你们在以下几个方面:

I would like to get some advice from you guys on the followings :

1)。是RSMB免费的吗?有没有适合我的情况下,任何其他的选择吗?

1).Is RSMB free? Is there any other alternatives that suit my case?

2)。如何将我能够连接到使用C#(用于发布和订阅的RSMB经纪人)。是否有任何RSMB C#的客户端库?

2).how will I be able to connect to the RSMB broker using C# (for publishing and subscribing). Are there any C# client library for RSMB?

3)。如何是MQTT的性能和可靠性?我可能需要推几百消息同时

3).How is the performance and reliability of the MQTT ? I might need to push a few hundreds of messages at the same time.

4)。如果没有其他的方法,然后我想执行我的C#应用​​程序内的stdinpub.exe的。(这听起来不错)。

4).If there is no other ways then I am thinking of executing the stdinpub.exe inside my C# application.(It might sound bad).

我发现,有大约MQTT在网络上的信息非常少,我真的应该走那条路还是有什么其他选择?

I find that there is very little information about MQTT on the web and should I really go that way or are there any other alternatives?

推荐答案

好了,这里有一个为你详解:

Ok, here's a breakdown for you:

1)你需要阅读所包含的RSMB当你下载了它的许可文件。我的理解是,你不能使用RSMB用于商业用途,如果IBM发布它作为一个商业产品,你必须停止使用。

1) You need to read the license file that was included with RSMB when you downloaded it. My understanding is that you can't use RSMB for commercial purposes and if IBM release it as a commercial product you have to stop using it.

有一个开源的MQTT经纪人可称为Mosquitto(我开发)。它提供了完整的MQTT协议支持,并提供了多个平台。它还包括客户端库中的C,与C ++和Python的包装,以及例如发布和订阅的客户。您可以在 http://mosquitto.org/

There is an open source MQTT broker available called Mosquitto (which I develop). It provides full MQTT protocol support and is available for a number of platforms. It also includes client libraries in C, with C++ and Python wrappers, as well as example publish and subscribe clients. You can get more information at http://mosquitto.org/

2)有两个C#库提供,虽然我从来没有使用其中任何一个自己。你可以找到一个链接到他们以及其他MQTT相关软件的整体负载 http://mqtt.org/software

2) There are two C# libraries available, although I've never used either of them myself. You can find a link to them as well as a whole load of other MQTT related software at http://mqtt.org/software

3)我已经RSMB和Mosquitto处理1500消息(每个100字节)每秒一个古老的VIA C3 600MHz的机器上。在更现代化的硬件,我期望他们执行显著更好。

3) I've had RSMB and Mosquitto handling 1500 messages (100 bytes each) per second on an old VIA C3 600MHz machine. On more modern hardware I'd expect them to perform significantly better.

随着MQTT问候信息,我希望有一个合理的量上mosquitto网站 - 详见的http:// mosquitto.org/man/mqtt-7.html~~V 为例子概述。你也可以来问的Freenode网络的#mqtt IRC频道的问题在 http://webchat.freenode.net/ 有此外,在 https://launchpad.net/~mqtt-users 一个邮件列表,这可能是使用的。

With regards to information on MQTT, I hope that there is a reasonable amount on the mosquitto website - see http://mosquitto.org/man/mqtt-7.html for an overview for example. You can also come ask questions on the #mqtt irc channel on the Freenode network at http://webchat.freenode.net/ There is also a mailing list at https://launchpad.net/~mqtt-users which may be of use.

我怕我真的不能对是否应该使用MQTT或其他意见。

I'm afraid I can't really comment on whether you should be using MQTT or something else.