MQ

MQ

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only

MQ Light nodes are now available in Node-RED 

Wed March 04, 2020 02:31 PM

Matthew Whitehead
Published on 10/10/2014 / Updated on 03/03/2015

 

Node-RED is a simple, open sourced flow tool  for wiring together hardware devices, APIs and online services in new and interesting ways. Node-RED is open source Node.JS program. It is available for download from the Node-RED website.

MQ Light nodes are now available for Node-RED.  If you use Node-RED in bluemix then the mqlight nodes are included automatically. If you download NodeRed and run it locally then you will need to install the mqlight support. To do this, first install the mqlight driver

npm install mqlight

then install the Node-RED support for MQ Light:

npm install node-red-node-mqlight

In either case you can now connect your flow to MQ Light using the new input and output nodes.

                             

Using the nodes you can offload work from your application to be processed by a Node-RED flow, using function nodes, sentiment analysis, IBM Watson Q & A, or any other function Node-RED provides. Then you can have the flow return the results back to your application as an MQ Light message.

Here’s a simple flow I created using the new nodes:

I’ve configured an MQ Light input node to subscribe for messages on the topic ‘data’, and wired the node to both a sentiment analysis node and an IBM Watson Q & A node. The results from the two parts of the flow are returned to my application on the topics sentiment/response and watson/answer respectively. I’ve also used a function node to prevent answers from Watson being sent back to my application if the confidence of the answer isn’t high enough.

 

Statistics
0 Favorited
8 Views
1 Files
0 Shares
4 Downloads
Attachment(s)
pdf file
MQ Light nodes are now available in Node-RED.pdf   267 KB   1 version
Uploaded - Wed March 04, 2020