You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kafka.apache.org by "Ken Huang (Jira)" <ji...@apache.org> on 2026/10/15 07:59:00 UTC

[jira] [Resolved] (KAFKA-21153) ClusterInstance#waitTopicDeletion should not wait the file cleanup

     [ https://issues.apache.org/jira/browse/KAFKA-21153?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ken Huang resolved KAFKA-21153.
-------------------------------
    Resolution: Fixed

> ClusterInstance#waitTopicDeletion should not wait the file cleanup
> ------------------------------------------------------------------
>
>                 Key: KAFKA-21153
>                 URL: https://issues.apache.org/jira/browse/KAFKA-21153
>             Project: Kafka
>          Issue Type: Improvement
>            Reporter: Chia-Ping Tsai
>            Assignee: Kuan Po Tseng
>            Priority: Minor
>
> {code:java}
>         TestUtils.waitForCondition(() -> brokers.stream().allMatch(broker ->
>                 broker.config().logDirs().stream().allMatch(logDir ->
>                     Arrays.stream(Objects.requireNonNull(new File(logDir).list())).noneMatch(partitionDirectoryName ->
>                         partitionDirectoryName.startsWith(topicPartition.topic() + "-" + topicPartition.partition()) &&
>                             partitionDirectoryName.endsWith(UnifiedLog.DELETE_DIR_SUFFIX)))
>         ), "Failed to hard-delete the delete directory"); {code}
> This hard-delete check forces callers to set the internal configs {{log.initial.task.delay.ms}} and {{log.segment.delete.delay.ms}} to avoid timeout. I took a glance at all callers and none of them actually care about the file cleanup. Hence, we should remove the wait logic and the configs from the callers.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)