Skip to content

[Flaky Test] TTestKafkaPublish/run_test(1):_publish_single_event_with_topic_from_type #50899

@khushijain21

Description

@khushijain21

Flaky Test

Stack Trace

    logger.go:146: 2026-05-25T10:38:39.375Z	INFO	kafka	kafka message: Initializing new client
    logger.go:146: 2026-05-25T10:38:39.375Z	INFO	kafka	kafka message: Successfully initialized new client
    logger.go:146: 2026-05-25T10:38:39.375Z	INFO	kafka	client/metadata fetching metadata for [log-type-6055449951074597455] from broker localhost:9094
    logger.go:146: 2026-05-25T10:38:39.375Z	INFO	kafka	Connected to broker at localhost:9094 (unregistered)
    logger.go:146: 2026-05-25T10:38:39.615Z	INFO	kafka	client/brokers registered new broker #0 at localhost:9094
    logger.go:146: 2026-05-25T10:38:39.615Z	INFO	kafka	kafka message: client/metadata found some partitions to be leaderless
    logger.go:146: 2026-05-25T10:38:39.866Z	INFO	kafka	client/metadata retrying after 250ms... (2 attempts remaining)
    logger.go:146: 2026-05-25T10:38:39.866Z	INFO	kafka	client/metadata fetching metadata for [log-type-6055449951074597455] from broker localhost:9094
    logger.go:146: 2026-05-25T10:38:39.866Z	INFO	kafka	Connected to broker at localhost:9094 (registered as #0)
    logger.go:146: 2026-05-25T10:38:39.872Z	INFO	kafka	kafka message: client/metadata found some partitions to be leaderless
    logger.go:146: 2026-05-25T10:38:40.122Z	INFO	kafka	client/metadata retrying after 250ms... (1 attempts remaining)
    logger.go:146: 2026-05-25T10:38:40.122Z	INFO	kafka	client/metadata fetching metadata for [log-type-6055449951074597455] from broker localhost:9094
    logger.go:146: 2026-05-25T10:38:40.125Z	INFO	kafka	kafka message: client/metadata found some partitions to be leaderless
    logger.go:146: 2026-05-25T10:38:40.375Z	INFO	kafka	client/metadata retrying after 250ms... (0 attempts remaining)
    logger.go:146: 2026-05-25T10:38:40.376Z	INFO	kafka	client/metadata fetching metadata for [log-type-6055449951074597455] from broker localhost:9094
    logger.go:146: 2026-05-25T10:38:40.379Z	INFO	kafka	kafka message: client/metadata found some partitions to be leaderless
    logger.go:146: 2026-05-25T10:38:40.379Z	DEBUG	kafka	finished kafka batch
    logger.go:146: 2026-05-25T10:38:40.379Z	ERROR	kafka	Kafka publish failed with: kafka server: In the middle of a leadership election, there is currently no leader for this partition and hence it is unavailable for writes
    kafka_integration_test.go:314:
        	Error Trace:	/opt/buildkite-agent/builds/bk-agent-prod-gcp-1779704923432404915/elastic/beats-libbeat/libbeat/outputs/kafka/kafka_integration_test.go:655
        	            				/opt/buildkite-agent/builds/bk-agent-prod-gcp-1779704923432404915/elastic/beats-libbeat/libbeat/outputs/kafka/kafka_integration_test.go:314
        	Error:      	Not equal:
        	            	expected: 0x0
        	            	actual  : 0x4
        	Test:       	TestKafkaPublish/run_test(1):_publish_single_event_with_topic_from_type
        	Messages:   	expected batch to be ACKed, got 4

Metadata

Metadata

Assignees

No one assigned

    Labels

    flaky-testUnstable or unreliable test cases.needs_teamIndicates that the issue/PR needs a Team:* label

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions