September 2017
Beginner to intermediate
360 pages
8h 13m
English
Download RabbitMQ from http://www.rabbitmq.com/download.html and set up. The following steps are required to integrate Flink with RabbitMQ:
<dependency> <groupId>org.apache.flink</groupId> <artifactId>flink-connector-rabbitmq_2.11</artifactId> <version>1.2.0</version></dependency>
ConnectionFactory factory = new ConnectionFactory(); // line 1factory.setUsername("guest");factory.setPassword("guest");factory.setVirtualHost("/");factory.setHost("localhost");factory.setPort(5672);Connection newConnection = factory.newConnection(); // line 2Channel channel = newConnection.createChannel(); // line 3Scanner scanner = new Scanner(System.in); // line 5String message = ...Read now
Unlock full access