infosphere-spl

MQTTSource Operator compilation error in IBM Infosphere Streams


System : Running VMPlayer on Windows Server. One VM is playing image of IBM Infosphere Streams (3.2) QuickStart Edition and Other MessageSight(1.1) Virtual Appliance.

When using MQTTSource Operator I get following compilation error

   1. "make: *** No rule to make target `/home/streamsadmin/sdk/clients/c/include/MQTTAsync.h', needed by `build/operator/mqttStream.o'. Stop.
2. CDISP0141E ERROR: The compilation of the generated code failed."

The sdk path is the SDK of IBM MessageSight. I am trying to connetc streams with MessageSight using MQTT operator. Is the problem with SDK or with my code? Please find the code below.

composite MQTTtestApp {

 graph
     (stream<blob demoData> mqttStream;stream<rstring errorMessage> myErrorStream) = MQTTSource()
     {
         param
             serverURI : "192.168.206.130:1883";
             topics : ["DemoMessagingPolicy"];
             format: block;
         output
             myErrorStream : errorMessage = getError();
     }

     stream<rstring dataSchema> ParsedMsg = Parse(mqttStream)
     {
         param
             format :csv;
     }

     () as myMessageSink = FileSink(ParsedMsg)
     {
         param
             file : "data.csv";
             format : csv;
     }

Solution

  • In this version of the operator, you will need to do the following to get the code to compile:

    1) Download the MQTT client and have it installed on the VM. See this link for details: http://www-01.ibm.com/support/knowledgecenter/SSCRJU_3.2.0/com.ibm.swg.im.infosphere.streams.messaging-toolkit.doc/doc/msgtoolkit-reqs.html?lang=en

    2) Set he STREAMS_MESSAGING_MQTT_HOME environment variable. This environment should point to the install location of the MQTT client

    There is a newer version of the MQTT operators that is easier to set up. In the new version, the MQTT client is included as part of the package. Therefore, you will no longer need to install the client separately, or set the environment variable.

    See this project for details. http://ibmstreams.github.io/streamsx.messaging/