def test_compile_MQTTSource(self): print ('\n---------'+str(self)) name = 'test_MQTTSource' topo = Topology(name) streamsx.spl.toolkit.add_toolkit(topo, self.mqtt_toolkit_home) src = MQTTSource(server_uri='tcp://server:1833', topics=['topic1', 'topic2'], schema=MqttDataTuple) # simply add all parameters; let' see if it compiles src.qos = [1, 2] src.message_queue_size = 122 src.client_id = "client-IDsrc" src.reconnection_bound = 25 src.trusted_certs = [TRUSTED_CERT_PEM, CLIENT_CA_CERT_PEM] src.client_cert = CLIENT_CERT_PEM src.client_private_key = PRIVATE_KEY_PEM src.ssl_protocol = 'TLSv1.1' src.vm_arg = ["-Xmx13G"] src.ssl_debug = True src.app_config_name = "abbconf2" src.command_timeout_millis=30000 src.keep_alive_seconds = 65 src.password = "******" src.username = "******" src.app_config_name = "mqtt_app_cfg" source_stream = topo.source(src, name='MqttStream') source_stream.print() # build only self._build_only(name, topo)
topic_attribute_name="bla") #src.qos = 1 a = 4 - 3 b = a + 1 print('a=' + str(a)) print('b=' + str(b)) src.qos = [a, b] src.message_queue_size = 122 src.client_id = "client-IDsrc" src.reconnection_bound = -1 src.trusted_certs = [ '/tmp/secrets/cluster_ca_cert.pem', '/tmp/secrets/cluster-ca.crt' ] #src.truststore = "/tmp/truststore-4657686007309004.jks" src.truststore_password = '******' src.client_cert = '/home/rolef/infosphereStreams/development/tk/ws_el7_43/kafkaTransactionSupport/etc/amqstreams/rolef.crt' src.client_private_key = '/home/rolef/infosphereStreams/development/tk/ws_el7_43/kafkaTransactionSupport/etc/amqstreams/rolef.key' #src.keystore = "/tmp/keystore-8728817490056367.jks" src.keystore_password = '******' src.ssl_protocol = 'TLSv1.1' src.vm_arg = ["-Xmx13G"] src.ssl_debug = True src.app_config_name = "abbconf2" src.command_timeout_millis = 247 src.keep_alive_seconds = 23 src.password = "******" src.username = "******" topo = Topology() #data = topo.source(["A","B","C","D","E","F","G","H","I","J"]).as_string()