Description of the Sample Project Configuration File
Descriptions about configuration files and key parameters in the Conf directory
- Producer API configuration items
Parameter |
Description |
Remarks |
---|---|---|
security.protocol |
Security protocol type |
The Producer uses the security protocol of the type specified by this parameter. When Kerberos authentication is enabled, only the SASL protocol is supported, and this parameter must be set to SASL_PLAINTEXT. Set this parameter to PLAINTEXT when Kerberos authentication is disabled. |
kerberos.domain.name |
Domain name |
Kerberos domain name of the MRS cluster. This parameter is not required for clusters with Kerberos authentication disabled. |
sasl.kerberos.service.name |
Service name |
The service name indicates the Kerberos username used by Kafka clusters for running. This parameter must be configured as kafka. You do not need to configure this parameter for clusters with Kerberos authentication disabled. |
- Consumer API configuration items
Parameter |
Description |
Remarks |
---|---|---|
security.protocol |
Security protocol type |
The Consumer uses the security protocol of the type specified by this parameter. When Kerberos authentication is enabled, only the SASL protocol is supported, and this parameter must be set to SASL_PLAINTEXT. Set this parameter to PLAINTEXT when Kerberos authentication is disabled. |
kerberos.domain.name |
Domain name |
Kerberos domain name of the MRS cluster. This parameter is not required for clusters with Kerberos authentication disabled. |
group.id |
Consumer group ID |
- |
auto.commit.interval.ms |
Indicates whether to automatically submit the offset. |
Boolean value. The default value is true. |
sasl.kerberos.service.name |
Service name |
The service name indicates the Kerberos username used by Kafka clusters for running. This parameter must be configured as kafka. You do not need to configure this parameter for clusters with Kerberos authentication disabled. |
- Configuration items of the client information
Parameter |
Description |
Remarks |
---|---|---|
metadata.broker.list |
Metadata Broker address list |
This parameter is used to create a connection to the metadata broker. This parameter is required for APIs that are used to access metadata directly. The access port does not support Kerberos authentication. For details about the port description, see Security APIs. |
kafka.client.zookeeper.principal |
Authentication and domain name used by the Kafka cluster to access ZooKeeper |
- |
bootstrap.servers |
Broker address list |
Connections with the Broker are created based on this parameter. For details about the port configuration items, see Security APIs. |
zookeeper.connect |
ZooKeeper address list |
This parameter is used to access the ZooKeeper. The Kafka service name kafka must be added at the end. |
- Indicates whether to enable Kerberos authentication for MRS.
Parameter |
Description |
Remarks |
---|---|---|
kafka.client.security.mode |
Whether to enable Kerberos authentication for the MRS cluster where Kafka is located. |
If Kerberos authentication is enabled, set this parameter to yes. Otherwise, set this parameter to no. |
- Configuration items in the log4j.properties file
Configuration file of the Log4j framework. By default, no run log of the sample project is entered.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.