Hello Tim, 

Thank you for your reply. I highly appreciate it. 

Regarding my questions I found some of the answers:

Q1: Given that STOMP is a protocol, if I find a NPM library for any of the
other protocols, can I use Node.js with that given protocol?

A1: The answer is yes. For example, using a MQTT library for Node.js, I can
communicate with the ActiveMQ broker. There are usually some quirks that one
has to considerate, but it definitely works. 

Q2: If such libraries exist, can you point some?

A2: MQTT: https://www.npmjs.com/package/mqtt
      AMQ 1.0 : https://www.npmjs.com/package/amqp10 (doesn't work out of
the box:
http://stackoverflow.com/questions/43873400/unable-to-connect-to-apache-activemq-with-node-js)
 
      STOMP: The recommended STMOPIT library.

Personally I would like to at least see the MQTT library added to the
official documentation, as I believe it would help clear many questions from
users.

Q3: Are there any caveats in using Node.js and ActiveMQ with another
protocol other than STOMP?

A3: Yes. ActiveMQ has weird authentication requirements which lead to
clients using a protocol's supported version to fail on connect (an example
is with the previous AMQP 1.0 npm library). Furthermore, each library has
its quirks, that you need to check. Usually the library's github page or
issues page will give you some light on the integration issues with
ActiveMQ, but it helps if the creators state clear support for ActiveMQ
(which is not always the case). 

Q4: Is it possible to use any of the EIPs that ActiveMQ offers with Node.js?
If so, how?

A4: WIP

Regarding this last question ... I don't know of any frameworks to achieve
this for nodejs.  I understand I can implement the patterns myself, but then
if I do it, what's the point of using ActiveMQ when compared, lets say, to
RabbitMQ which is lighter and supports more versions of AMQP? 

In my eyes, the real power of ActiveMQ lies in its integration with Camel,
otherwise it is just yet another message broker with nothing special to add
(correct me if I am wrong here ... ). 

With this in mind, I am aware that I can integrate Camel with the ActiveMQ
broker. But how would I use Node.js and configure the Camel routes then?
These can only be configured via the the DSL's present in this page:
http://camel.apache.org/dsl.html

The majority of them are for Java environments. I guess I could give a shot
to the REST DSL, but I am not sure how I would make it work. Would this
approach work?



--
View this message in context: 
http://activemq.2283324.n4.nabble.com/Integration-between-Node-js-and-ActiveMQ-how-to-use-tp4725822p4725871.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Reply via email to