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

Shilun Fan resolved HDFS-17830.
-------------------------------
    Fix Version/s: 3.5.0
     Hadoop Flags: Reviewed
       Resolution: Fixed

> Fix failing TestZKDelegationTokenSecretManagerImpl due to static Curator reuse
> ------------------------------------------------------------------------------
>
>                 Key: HDFS-17830
>                 URL: https://issues.apache.org/jira/browse/HDFS-17830
>             Project: Hadoop HDFS
>          Issue Type: Improvement
>          Components: rbf
>    Affects Versions: 3.5.0
>            Reporter: Hualong Zhang
>            Assignee: Hualong Zhang
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 3.5.0
>
>
> TestZKDelegationTokenSecretManagerImpl tests fail with “Expected state 
> [STARTED] was [STOPPED]” due to static Curator reuse
> {code:java}
> IllegalStateException: Expected state [STARTED] was [STOPPED]
>   at CuratorFrameworkImpl.checkState / usingNamespace
>   at ZKDelegationTokenSecretManager.<init>(...)
> {code}
> CI evidence:
> [https://ci-hadoop.apache.org/job/hadoop-qbt-trunk-java8-linux-x86_64/2051/artifact/out/patch-unit-hadoop-hdfs-project_hadoop-hdfs-rbf.txt]
> Under JUnit 5’s PER_METHOD lifecycle, static fields persist; this suite 
> shares a static CuratorFramework that some tests close without resetting, so 
> later tests reuse a STOPPED client and fail in 
> ZKDelegationTokenSecretManagerImpl (“Expected [STARTED] was [STOPPED]”). It’s 
> an isolation/cleanup issue, not a Curator change—reset or recreate the static 
> client between tests (in @AfterEach).



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

---------------------------------------------------------------------
To unsubscribe, e-mail: hdfs-dev-unsubscr...@hadoop.apache.org
For additional commands, e-mail: hdfs-dev-h...@hadoop.apache.org

Reply via email to