Go to the OpenShift Administrator console and click the command line terminal icon >_ in the top-right corner to open a Web Terminal.
Copy and paste the following commands to retrieve events from your Kafka topics.
oc rsh warehouse-kafka-0
cat <<EOF> /tmp/client.properties
sasl.mechanism=SCRAM-SHA-512
security.protocol=SASL_PLAINTEXT
sasl.jaas.config=org.apache.kafka.common.security.scram.ScramLoginModule required \
username="mm2" \
password="s3cr3t";
EOF
./bin/kafka-console-consumer.sh --bootstrap-server warehouse-kafka-bootstrap:9092 --topic warehouse-in --consumer.config /tmp/client.properties --from-beginning
./bin/kafka-console-consumer.sh --bootstrap-server warehouse-kafka-bootstrap:9092 --topic warehouse-out --consumer.config /tmp/client.properties --from-beginning
You should see similar results as the followings: