-
Notifications
You must be signed in to change notification settings - Fork 2.8k
feat(events): raise k8s events with fake provider #5659
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(events): raise k8s events with fake provider #5659
Conversation
80243c1
to
029c972
Compare
42071de
to
3f6008f
Compare
Signed-off-by: ivan katliarchuk <[email protected]>
3f6008f
to
dcbcf99
Compare
4942eb4
to
772e5de
Compare
fa0af46
to
9973da2
Compare
9973da2
to
7eab91c
Compare
Signed-off-by: ivan katliarchuk <[email protected]>
7eab91c
to
f57baa4
Compare
Signed-off-by: ivan katliarchuk <[email protected]>
Tested once again. Seems like working |
Co-authored-by: Michel Loiseleur <[email protected]>
Heh silly things missed ;-) |
Signed-off-by: ivan katliarchuk <[email protected]>
Signed-off-by: ivan katliarchuk <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
Signed-off-by: ivan katliarchuk <[email protected]>
rebase and resolved merge conflicts |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: mloiseleur The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
This PR cause a panic at: external-dns/pkg/events/controller.go Lines 136 to 137 in 81290c0
external-dns/controller/events.go Lines 27 to 30 in 81290c0
But we receive a typed pointer to nil, not nil directly. This value come from here: external-dns/controller/execute.go Lines 362 to 385 in 81290c0
Passing an nil *events.Controller to an interface field is not the same as passing nil to this field. Which is quite confusing.
This is shown in debugger: |
* feat(events): publish k8s events Signed-off-by: ivan katliarchuk <[email protected]> * feat(events): publish k8s events Signed-off-by: ivan katliarchuk <[email protected]> * feat(events): publish k8s events Signed-off-by: ivan katliarchuk <[email protected]> * feat(events): publish k8s events Signed-off-by: ivan katliarchuk <[email protected]> * feat(events): publish k8s events Signed-off-by: ivan katliarchuk <[email protected]> * feat(events): raise k8s events with fake provider Signed-off-by: ivan katliarchuk <[email protected]> * feat(events): raise k8s events with fake provider Signed-off-by: ivan katliarchuk <[email protected]> * feat(events): raise k8s events with fake provider Signed-off-by: ivan katliarchuk <[email protected]> * feat(events): raise k8s events with fake provider Signed-off-by: ivan katliarchuk <[email protected]> * feat(events): raise k8s events with fake provider Co-authored-by: Michel Loiseleur <[email protected]> * feat(events): raise k8s events with fake provider Signed-off-by: ivan katliarchuk <[email protected]> * feat(events): raise k8s events with fake provide Co-authored-by: Michel Loiseleur <[email protected]> * feat(events): raise k8s events with fake provider Signed-off-by: ivan katliarchuk <[email protected]> * feat(events): raise k8s events with fake provider Signed-off-by: ivan katliarchuk <[email protected]> --------- Signed-off-by: ivan katliarchuk <[email protected]> Co-authored-by: Michel Loiseleur <[email protected]>
What does it do ?
Note: safe to merge as it does not break any current functionality, and only supported with
fake
sourcefake
source, to keep change size relatively small.successful
events, as to support failed cases need more effort--service-type-filter
logicI'm slicing this feature into multiple PRs, as there is a lot to add + tests are usually 3x lines vs actual logic + docs + smoke testing is simpler when delivered in chunks
High Level Diagram
Follow-up:
Success
,Skip
,Failed
so that we could emit correct event per endpiont. This may take time.func (ec *Controller) run(ctx context.Context)
with metrics instrumentationMotivation
Fixes #646
Relates #5243. The change will enable us to raise events for CRD changes
More
what does it do
with references if anyExample Fake event initiated for core-dns pod.

At the moment plan is not aware where or not changes applied or skipped, or failed for certain Endpoints. This will be added in follow-up PR
example, skipped endpoint creation due to domain is not supported

Example Event in Json format