Tuesday, September 11, 2018

How to start KSQL server in server-client mode on MapR platform

Goal:

KSQL can start in local(standalone mode) using CLI, and it also can start the server-client mode shown as below.

This article just shows the exact commands on MapR 6.1 platform.

Env:

MapR 6.1
MEP 6.0
4 nodes

Solution:

1. Install KSQL from MEP 6.0 package on all 4 nodes.

yum install mapr-kafka-ksql

2. Configure KSQL properties

"ksql.service.id" should be set to the same value so that all 4 KSQL servers are in the same application.
vim /opt/mapr/ksql/ksql-4.1.1/etc/ksql/ksql-server.properties
Sample configuration is:
listeners=http://localhost:8084
ksql.server.ui.enabled=false
confluent.support.metrics.enable=false
ksql.service.id=myksqlapp

3. Start KSQL servers on all 4 nodes

/opt/mapr/ksql/ksql-4.1.1/bin/ksql-server-start /opt/mapr/ksql/ksql-4.1.1/etc/ksql/ksql-server.properties
Note: This is not running in background by default. Use "nohup" if you want to run KSQL servers in background.

4. Connect KSQL client to KSQL server

/opt/mapr/ksql/ksql-4.1.1/bin/ksql http://localhost:8084

Then you may want to run through the test case mentioned in How to use ksql on MapR Streams(MapR-ES).

No comments:

Post a Comment

Popular Posts