You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "Bruno Cadonna (Jira)" <ji...@apache.org> on 2019/12/04 14:45:00 UTC

[jira] [Commented] (KAFKA-9195) Use Randomized State Directory Names in Streams System Tests

    [ https://issues.apache.org/jira/browse/KAFKA-9195?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16987922#comment-16987922 ] 

Bruno Cadonna commented on KAFKA-9195:
--------------------------------------

I guess your proposal would also work. However, I guess your proposal would be harder to maintain, because using a randomized path is a environment setting that can be done once for all (or at least a bunch of)  system tests whereas {{KafkaStreams#cleanup()}} needs to be called in each Streams application. Every person that adds a test need to know/remember to add  {{KafkaStreams#cleanup()}}.

Maybe not a big deal because the same Streams application code is shared by multiple tests. Just wanted to point out the difference.

> Use Randomized State Directory Names in Streams System Tests 
> -------------------------------------------------------------
>
>                 Key: KAFKA-9195
>                 URL: https://issues.apache.org/jira/browse/KAFKA-9195
>             Project: Kafka
>          Issue Type: Improvement
>          Components: streams, system tests
>            Reporter: Bruno Cadonna
>            Priority: Major
>
> Currently, the state directory property in streams' system tests is set to the {{PERSISTENT_ROOT}} variable. Since Streams applications in different tests have the same application ID and the state directory path consists of state directory property + application ID + task ID, it might happen that a dirty state directory of one test is re-used by another test if the state directory is not properly cleaned up. This may lead to unexpected results and false positive and/or flaky failures.
> The state directory property shall be set to a randomized path inside {{PERSISTENT_ROOT}} to ensure that tests may not interfere with each other in the case of missing state clean-ups.    



--
This message was sent by Atlassian Jira
(v8.3.4#803005)