operator-framework / operator-framework/java-operator-sdk

[Feature Request/Question] Controller watch namespaces based on labels (and event sources)

Đang mở
#2,434 4 bình luận 1 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Ngôn ngữ chính
Java
Star
944
Fork
242
Merge trung bình
1 ngày 4 giờ
Pull request đã merge (30 ngày)
43

Mô tả

Description

Based on the documentation, the controller is able to dynamically adjust the watched namespaces based on explicit namespace names (often provided through a config map or similar). A convenient extension to this would be able to watch namespaces based on the labels/annotations for a given namespace. I would be helpful if this was built into the machinery of the controller itself, so it could be controlled by some high level configuration

Motivation

Sometimes the creation of new namespaces that need to interact (be watched by) with the operator are done through workflows outside of the purview of the "operator admin". Currently, in order to ensure coverage of all namespaces, either (1) both workflows need to interact and inform the operator deployment when namespaces are added, or (2) the operator simply needs to watch all namespaces. This is where a third option, of only coordinating the appropriate labels would be beneficial

(Somewhat) Related Projects

https://github.com/kubernetes-sigs/hierarchical-namespaces/blob/master/docs/user-guide/concepts.md

Workarounds considered

Use the Kubernetes client itself to query for namespaces upon controller start, periodically poll for changes. Similarly, try to use some form of an Informer to get the same information

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Hướng nghiên cứu

Bắt đầu bằng cách xác định cấu hình namespace tường minh hiện có của controller và cách xử lý event-source, sau đó xem xét các phương án sử dụng Kubernetes client và informer được đề cập trong issue. Làm rõ việc lựa chọn label và annotation, cấu hình cấp cao, cũng như hành vi khi các namespace phù hợp được tạo; hoàn thành có nghĩa là controller theo dõi các namespace đã chọn mà không yêu cầu điều phối workflow hoặc theo dõi tất cả namespace.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
java, kubernetes
Lĩnh vực
infrastructure
Loại issue
Tính năng
Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
35/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.