Status

Current state: Accepted

Discussion thread: here

Voting thread: here

JIRA: KAFKA-18068 - Getting issue details... STATUS

Please keep the discussion on the mailing list rather than commenting on the wiki (wiki discussions get unwieldy fast).

Motivation

PARTITIONER_ADPATIVE_PARTITIONING_ENABLE_CONFIG in ProducerConfig is a misspelling; the correct spelling is PARTITIONER_ADAPTIVE_PARTITIONING_ENABLE_CONFIG.

Public Interfaces

  • org.apache.kafka.clients.producer.ProducerConfig.PARTITIONER_ADPATIVE_PARTITIONING_ENABLE_CONFIG

Proposed Changes


ProducerConfig
public class ProducerConfig extends AbstractConfig {
	...
 	// new
 	public static final String PARTITIONER_ADAPTIVE_PARTITIONING_ENABLE_CONFIG = "partitioner.adaptive.partitioning.enable";
	@Deprecated
    public static final String PARTITIONER_ADPATIVE_PARTITIONING_ENABLE_CONFIG = PARTITIONER_ADAPTIVE_PARTITIONING_ENABLE_CONFIG

    // Remove
    private static final String PARTITIONER_ADPATIVE_PARTITIONING_ENABLE_DOC = ...
	// new
	private static final String PARTITIONER_ADAPTIVE_PARTITIONING_ENABLE_DOC = ...

    ...

	private static final String PARTITIONER_AVAILABILITY_TIMEOUT_MS_DOC =
            "If a broker cannot process produce requests from a partition for <code>" + PARTITIONER_AVAILABILITY_TIMEOUT_MS_CONFIG + "</code> time, "
            + "the partitioner treats that partition as not available.  If the value is 0, this logic is disabled. "
            + "Note: this setting has no effect if a custom partitioner is used or <code>" + PARTITIONER_ADAPTIVE_PARTITIONING_ENABLE_CONFIG // Fix this name
            + "</code> is set to 'false'.";

	 ...

     static {
        CONFIG = new ConfigDef().define(
								...
								// Remove
							    .define(PARTITIONER_ADPATIVE_PARTITIONING_ENABLE_CONFIG, Type.BOOLEAN, true, Importance.LOW, PARTITIONER_ADPATIVE_PARTITIONING_ENABLE_DOC)
							 	// Use correct config and correct doc
								.define(PARTITIONER_ADAPTIVE_PARTITIONING_ENABLE_CONFIG, Type.BOOLEAN, true, Importance.LOW, PARTITIONER_ADAPTIVE_PARTITIONING_ENABLE_DOC)

Compatibility, Deprecation, and Migration Plan

  • Deprecated PARTITIONER_ADPATIVE_PARTITIONING_ENABLE_CONFIG
  • Users using parameter name "partitioner.adaptive.partitioning.enable" directly are not affected
  • Users using ProducerConfig#PARTITIONER_ADPATIVE_PARTITIONING_ENABLE_CONFIG  can update their code to ProducerConfig#PARTITIONER_ADAPTIVE_PARTITIONING_ENABLE_CONFIG 
  • The deprecated constants PARTITIONER_ADPATIVE_PARTITIONING_ENABLE_CONFIG will be removed in the next major release.

Test Plan

N/A

Rejected Alternatives

N/A

  • No labels