Operation: Subscribe
The Subscribe operation subscribes to an Apache Kafka topic in order to receive messages. An existing client from the apachekafka-config.xml file is used for this.
Required parameters: clusterId, clientId, topic, process
The Assign and Subscribe operations are mutually exclusive.
Only one client can be used for the Assign operation if it is not already being used for another topic. A client cannot be assigned to several topics.
This means that the Assign operation can only be carried out for one specific client. This client is then assigned and cannot be used for other operations.
Input
The adapter does not expect any input.
Output
No direct output is issued for the Subscribe operation. If a new message is received in a subscribed topic, a process is started with the received message as input. This message is transferred in the following structure:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Message>
<ClusterId>X4Kafka</ClusterId>
<Topic>noKeyTopic</Topic>
<Offset>0</Offset>
<Headers>
<Header key="value 1">header1</Header>
<Header key="value 2">header2</Header>
<Header key="value 3">header3</Header>
</Headers>
<Content encoding="base64" key="055b93a8-4eda-41d8-8b73-b852a1d4da1e">055b93a8-4eda-41d8-8b73-b852a1d4da1e</Content>
</Message>