Configuring Network Socket as Input

<< Click to Display Table of Contents >>

Navigation:  Using StreamLab > StreamLab Sources Overview > Configuring Line, CSV, XML, and JSON Sources >

Configuring Network Socket as Input

Previous pageReturn to chapter overviewNext page

To read from a line, CSV, XML, or JSON file over AMQP, you need to configure the socket connection. AMQP stands for Advanced Message Queuing Protocol, and is an Open Standard for Messaging Middleware. For more information, see see http://www.amqp.org/confluence/display/AMQP/About+AMQP. You may want to consult with whoever has set up AMQP in your environment.

AMQP 0.9.1 vs 1.0

There are distinct differences between the way AMQP up to 0.9.1 works and the way AMQP 1.0 works. Roughly, AMQP 1.0  only provides network wire-level protocol for the exchange of messages, while up to 0.9.1, AMQP employed a system of  exchanges, queues and bindings to exchange messages. As a result of this change, you configure StreamLab for AMQP differently for 1.0 than for up to 0.9.1

Connection Options for AMQP 0.9.1

The AMQP option lets you define a source with an AMQP 0.9.1 message bus. AMQP stands for Advanced Message Queuing Protocol, and is an Open Standard for Messaging Middleware. For more information, see see http://www.amqp.org/confluence/display/AMQP/About+AMQP.

As with other input formats, AMQP simply intakes rows as strings in CSV, XML, or JSON format.

To set up an AMQP 0.9.1 source, you need the following pieces of information:

The hostname or IP address of the AMQP server (defaults to localhost)
The port of the AMQP server (defaults to 5672)
The name of the AMQP exchange--the place where AMQP messages are routed. See https://www.rabbitmq.com/tutorials/amqp-concepts.html for more details.
The type of AMQP exchange--either fanout, topic, or direct. See https://www.rabbitmq.com/tutorials/amqp-concepts.html for more details.

sl_amqp_091_options

Name

Description

Name

hostname or IP address of the AMQP server (default localhost)

Port

port of the AMQP server (default 5672)

EXCHANGE_TYPE

the type of exchange to connect to (default fanout)

EXCHANGE_NAME

the name of the exchange to send/receive tuples to/from,

required

Connection Options for AMQP 1.0

To set up an AMQP 1.0 source, you need the following pieces of information:

The hostname or IP address of the AMQP server (defaults to localhost)
The port of the AMQP server (defaults to 5672)
The queue or topic name. This is a string value that identifies a target object to read from or to write to. See https://activemq.apache.org/apollo/documentation/amqp-manual.html for more details.
User name and password for AMQP server.

As with other input formats, AMQP 1.0 simply intakes rows as strings in CSV, XML, or JSON format.

sl_amqp_10_options

Name

Description

Name

This is the hostname or IP address of the AMQP server. Defaults to localhost.

Port

This is the port of the AMQP server. Defaults to 5672.

Queue or Topic

String value which identifies a target object to read from or to write to.

User ID

Required. This is the user ID to use to connect to the AMQP 1.0 server,.

Password

Required. This is the password to use to connect to the AMQP 1.0 server.