kubernetes-client / kubernetes-client/python

Add support for bookmark events

Open
#1,729 7 comments 10 reactions 0 assignees View on GitHub
help wanted kind/feature
Dominant language
Python
Stars
7.7k
Forks
3.5k
Avg merge
1d 14h
Merged PRs (30d)
18

Description

**What is the feature and why do you need it**:

In kubernetes-client/python-base#234 the parsing of BOOKMARK events has been bypassed ([and still is as of today](https://github.com/kubernetes-client/python/blob/master/kubernetes/base/watch/watch.py#L103)). But those events exist for a reason and can be useful in some circumstances. A motivational example is this Airflow issue: https://github.com/apache/airflow/issues/21087.

As Airflows scheduler can be stopped and restarted, while many events occur on k8s, it would need to process BOOKMARK to recover its state. Sadly because those are ignored by the Python client, it cannot. Which manifests itself in varied ways (see the different issues referenced in the ticket above)

**Describe the solution you'd like to see**:

We'd like for the bookmark event to be parsed and yield by the watcher, so it is possible for clients to consume them.

(copied from kubernetes-client/python-base#286)

Contributor guide

Open the contributing guide

Research direction

Start in kubernetes/base/watch/watch.py around line 103, where BOOKMARK event parsing is bypassed. Trace how the watcher handles other events and make the completed behavior allow clients to consume BOOKMARK events as yielded results.

Written by the indexing model from the issue text.

Assessment

Tech stack
kubernetes, python
Domain
api
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.