Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

ZooKeeper znode controller: release finalizer without connecting when the parent is deleting

オープン
#1,049 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
68/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
kubernetes, rust

調査の方向性

finalizer::Event::Cleanup アームから開始し、deletionTimestamp を持つ参照先の ZookeeperCluster をどのように処理するかを追跡します。ensure_znode_missing のクリーンアップパスと、Terminating で停止した namespace を明らかにする統合テストを確認します。削除時に ZooKeeper 接続をスキップし、数分間のバックオフなしで finalizer を解放できれば完了です。

索引モデルが issue の本文から書いたものです。

説明

Problem

In some scenarios, the ZookeeperZnode finalizer (zookeeper.stackable.tech/znode) can take around 130–150s to release. That's what sometimes leaves namespaces stuck in Terminating in our integration tests.

This can happen when the operator tries connection to Zookeeper to delete the node, while ZooKeeper is being torn down, the delete/cleanup path (ensure_znode_missing) runs its errors through controller-runtime's exponential backoff, and that's where the multi-minute stall comes from.

Mechanism

  1. znode cleanup (ensure_znode_missing) tries to connect to the ZK service and gets Connection refused — the ZK pods/endpoints are already gone — so the reconcile errors out.
  2. The ZookeeperCluster CR then drops out of the watch cache. At this point the finalizer's fast path (cluster doesn't exist → assume the znode is gone → drop the finalizer without connecting) would kick in, but the failed reconcile is already sitting in exponential backoff.
  3. ~139s gap: nothing re-runs, even though the fast-path condition is now true.
  4. Backoff finally expires, the reconcile re-runs, the fast path fires, the finalizer is removed, and the namespace deletes.

So it comes down to queue ordering under load. If cleanup runs after the CR leaves the store, it's instant if it runs before, it errors, hits backoff, and takes 130s+.

Fix

In the finalizer::Event::Cleanup arm: if the referenced ZookeeperCluster has a deletionTimestamp, drop the finalizer straight away without connecting to ZK. Retrying an unreachable server makes sense on the create path; on the delete path it shouldn't be allowed to block teardown.

主要言語
Rust
スター
37
フォーク
11
平均マージ
1日 8時間
マージ済み PR(30日)
10

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

stackabletech/zookeeper-operator のほかの issue

stackabletech/zookeeper-operator の issue をすべて見る

似ている issue

Rust の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。